Read many objects by ref
const url = 'http://localhost:3000/v1/objects?refs=example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'http://localhost:3000/v1/objects?refs=example' \ --header 'Authorization: Bearer <token>'Revalidates a page’s objects sidecar in one request. Pass refs once per
object (?refs=session:1&refs=session:2) — repeated rather than
comma-separated, because an object id may legally contain a comma.
A ref with no stored object is simply absent from the map, exactly as in the
feed-read sidecar; this is never a 404. Duplicate refs are collapsed rather
than rejected (unlike an activity’s refs, where a duplicate is a client bug
with a visible consequence) — the response is keyed by ref, so a duplicate has
no meaning to reject.
Costs one request against the normal tenant window, not the batch window: this is an ordinary user-token read, not an import.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”1–100 type:id refs. Repeat the parameter per ref.
Responses
Section titled “Responses”Found objects keyed by type:id. Missing refs are absent from the map, so
an empty object is a valid answer.
object
Tenant-owned mutable data that activities point at. Opaque to dropin — we
store, update, and return custom, and never interpret it. Writes are
server-token only.
object
object
Example
{ "additionalProperty": { "type": "session", "id": "1234" }}refs absent, empty, over 100, or not type:id.
object
object
Present only for VALIDATION_FAILED.
object
Example
{ "error": { "code": "VALIDATION_FAILED" }}