Export my memory
const url = 'https://api.asklucy.eu/v1/memory/export';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 https://api.asklucy.eu/v1/memory/export \ --header 'Authorization: Bearer <token>'Everything in your own scope, as one JSON document. Works even when memory is off.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”OK
Everything in your own scope, including facts and relations that were replaced or found wrong, and every version of your processes.
object
object
Zitadel user ID.
service is a customer system’s Zitadel service user; agent is a service agent (its ID is the agt_ ID), the author of its runs’ messages.
Something the organization deals with (a person, a company, a contract…).
object
Lowercase, singular, snake_case: person, company, contract…
Other names it goes by.
Empty when there is none.
Structured details (e.g. a registration number).
object
Who a piece of memory is for: user (only you, and Lucy when she
works for you), group:<groupId> (the members of a group from the
identity provider) or org (everyone in the organization).
Live facts about it that you can see.
One statement about an entity, with where it comes from. Facts are never changed; a correction replaces them.
object
object
Who a piece of memory is for: user (only you, and Lucy when she
works for you), group:<groupId> (the members of a group from the
identity provider) or org (everyone in the organization).
Since when it holds, when known.
Until when it held, when known.
When Lucy learned it.
When it was replaced or found wrong; null while it is live.
The fact that replaced it.
Where it comes from. The conversation, message and file are given only to the person they belong to (null for others).
object
The person who said it, or for whom Lucy was working.
object
Lowercase snake_case, read from from to to: works_at, party_to, supplier_of…
object
object
Who a piece of memory is for: user (only you, and Lucy when she
works for you), group:<groupId> (the members of a group from the
identity provider) or org (everyone in the organization).
object
When it was found wrong; null while it is live.
object
Who a piece of memory is for: user (only you, and Lucy when she
works for you), group:<groupId> (the members of a group from the
identity provider) or org (everyone in the organization).
archived: Lucy no longer uses it; its versions are kept.
object
1, 2, … in order of creation, proposals included.
proposed: waiting for an admin.accepted: the current version.superseded: was current, replaced by a later version.rejected: an admin turned the proposal down.withdrawn: its author took it back or undid it.
When to use it (the requests or situations it is for).
The steps, in Markdown.
Types of entities and relations it reads.
Types of entities and relations it writes.
The entities it is about (IDs).
Why it was written or changed; empty when not given.
The version it was written from; null for a first version.
A person, or Lucy working for that person. The person is null once their memory was erased.
object
The person’s name.
The conversation Lucy wrote it in; given only to its author.
untrusted_input: Lucy wrote it after reading a file or a tool’s output, which may have steered her. Review it with care.
How many times Lucy read it to follow it.
Proposals waiting for review; for members, only their own.
Every version, version 1 first.
object
1, 2, … in order of creation, proposals included.
proposed: waiting for an admin.accepted: the current version.superseded: was current, replaced by a later version.rejected: an admin turned the proposal down.withdrawn: its author took it back or undid it.
When to use it (the requests or situations it is for).
The steps, in Markdown.
Types of entities and relations it reads.
Types of entities and relations it writes.
The entities it is about (IDs).
Why it was written or changed; empty when not given.
The version it was written from; null for a first version.
A person, or Lucy working for that person. The person is null once their memory was erased.
object
The person’s name.
The conversation Lucy wrote it in; given only to its author.
untrusted_input: Lucy wrote it after reading a file or a tool’s output, which may have steered her. Review it with care.
Example
{ "user": { "kind": "person" }, "entities": [ { "id": "ent_5Tq9Bm", "type": "company", "name": "Acme SA", "scope": "user" } ], "facts": [ { "id": "fact_2Rk8Vp", "entity": { "id": "ent_5Tq9Bm", "type": "company" }, "text": "Custody fees are billed quarterly, in arrears.", "scope": "user", "source": { "kind": "said_by_person" } } ], "relations": [ { "id": "rel_8Nw3Js", "type": "party_to", "from": { "id": "ent_5Tq9Bm", "type": "company" }, "to": { "id": "ent_5Tq9Bm", "type": "company" }, "scope": "user" } ], "processes": [ { "id": "proc_3Fz7Xa", "scope": "user", "status": "active", "current": { "id": "prv_7Hc2Lw", "state": "proposed", "title": "Answer a custody-fee question", "when": "Someone asks why custody fees changed, or to check a custody invoice.", "reads": [ "company" ], "writes": [ "invoice" ], "applies_to": [ "ent_5Tq9Bm" ], "author": { "kind": "person" }, "flags": [ "untrusted_input" ], "decided_by": { "kind": "person" } }, "versions": [ { "id": "prv_7Hc2Lw", "state": "proposed", "title": "Answer a custody-fee question", "when": "Someone asks why custody fees changed, or to check a custody invoice.", "reads": [ "company" ], "writes": [ "invoice" ], "applies_to": [ "ent_5Tq9Bm" ], "author": { "kind": "person" }, "flags": [ "untrusted_input" ], "decided_by": { "kind": "person" } } ] } ]}Missing, expired or invalid token.
RFC 9457 problem details.
object
For quota-exceeded, the window that is used up.
object
Null for a rolling window that hasn’t started.
organization when the organization’s budget is closer to running out than the member’s own limit.
Field-level problems (400 only).
object
JSON pointer into the request body.
Example
{ "type": "https://docs.asklucy.eu/errors/answer-in-progress", "quota": { "window": "five_hours", "limited_by": "personal", "request": { "status": "pending" } }}Headers
Section titled “Headers”Unique per request; quote it to support.
The token is valid but lacks the role this needs.
RFC 9457 problem details.
object
For quota-exceeded, the window that is used up.
object
Null for a rolling window that hasn’t started.
organization when the organization’s budget is closer to running out than the member’s own limit.
Field-level problems (400 only).
object
JSON pointer into the request body.
Example
{ "type": "https://docs.asklucy.eu/errors/answer-in-progress", "quota": { "window": "five_hours", "limited_by": "personal", "request": { "status": "pending" } }}Headers
Section titled “Headers”Unique per request; quote it to support.