Change a process
const url = 'https://api.asklucy.eu/v1/memory/processes/example/versions';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"title":"example","when":"example","body":"example","reads":["example"],"writes":["example"],"applies_to":["example"],"rationale":"example","base_version_id":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.asklucy.eu/v1/memory/processes/example/versions \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "title": "example", "when": "example", "body": "example", "reads": [ "example" ], "writes": [ "example" ], "applies_to": [ "example" ], "rationale": "example", "base_version_id": "example" }'A new version, from the current one (base_version_id). In your
own scope it is accepted and becomes current; for a group or the
organization it is proposed. If base_version_id is no longer
the current version, someone changed the process meanwhile: 409
…/errors/proposal-stale.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Header Parameters
Section titled “Header Parameters”Any unique string (a UUID works). Retries with the same key return the first result.
Request Bodyrequired
Section titled “Request Bodyrequired”object
The steps, in Markdown.
The entities it is about (IDs). They must be shared at least as widely as the process.
The current version you started from; null when the process has none yet.
Example generated
{ "title": "example", "when": "example", "body": "example", "reads": [ "example" ], "writes": [ "example" ], "applies_to": [ "example" ], "rationale": "example", "base_version_id": "example"}Responses
Section titled “Responses”Created
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
{ "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" }}The request is invalid; errors lists what’s wrong.
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.
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 lacks the role this needs (…/errors/forbidden), or
memory is off for the organization or, in your own scope, for you
(…/errors/memory-disabled; getMemory says which).
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.
No such object in your organization.
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 version isn’t in a state that allows this, e.g. the proposal
was already decided (…/errors/version-state), or its base is no
longer the process’s current version (…/errors/proposal-stale).
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.