Skip to content
Back to the app

Governed actions ​

A governed action is a change to a record in one of your connected systems. It can be proposed by a CHANGENTS.AI agent, by another system holding an API key, or by a person. Nothing is written until a person approves it. Every action carries a proof bundle: what was read, what will change, why, and who approved it. Anyone can check the bundle.

How a change goes through ​

  1. Propose. POST /api/v1/actions names an object from the Object Graph and the fields to change. The change is checked against the object's type and against what the target system can write. The current values are recorded, and the proof bundle is built. Nothing is written. Webhook: action.proposed.
  2. Approve. The change appears in your approvals inbox, and in Slack or Microsoft Teams if you use them, like any other approval. Your organisation's review rules apply; for example, someone other than the proposer reviews when another admin exists. An API key cannot approve.
  3. Write. On approval, CHANGENTS.AI writes the change to the system, naming the approval. Webhook: action.committed, or action.failed with the system's reason. Each step is written to your organisation's audit chain.
  4. Undo. For 30 minutes after a write, a signed-in person can undo it: POST /api/v1/actions/{id}/undo writes back the values recorded before the change.

What can be written ​

SystemObjectFields
XeroInvoice, BilldueDate
XeroPartyemail

Any other change, to any object and system, can be handed to your own system. Subscribe a webhook endpoint to action.approved (see Webhooks). When a person approves, that event carries the record, the values before, and the exact change, signed like every webhook, and your system applies it. CHANGENTS.AI writes nothing itself. Such a change is undone in your own system, not here.

A proposal that neither a native writer nor an action.approved webhook can carry out is refused, with the reason.

Your own databases connected through the read-only SQL connector are never written to.

Propose a change ​

http
POST /api/v1/actions
Authorization: Bearer cgnt_sk_...
Content-Type: application/json

{
  "type": "Invoice",
  "objectId": "xero:Invoice:8f2c...",
  "change": { "dueDate": "2026-12-31" },
  "reason": "Customer agreed a 30-day extension on the call of 22 November.",
  "computed": { "daysExtended": 30 },
  "checks": [{ "name": "credit limit not exceeded", "passed": true }]
}
  • An API key needs the actions scope (see Authentication). A change proposed with a key is marked as proposed by an agent; one proposed in a signed-in session, by a person.
  • The response is the action, with its status (pending until decided), its approvalId and the proof bundle's digest.
  • GET /api/v1/actions lists actions, and ?status=pending filters them. GET /api/v1/actions/{id} returns one.

The proof bundle ​

GET /api/v1/actions/{id}/proof returns the bundle (changents.proof/v1):

  • object: the object and the records it joins across systems;
  • target: where the change is written, natively or by your webhook;
  • lineage: for each changed field, the system, entity and field it was read from and when, plus every read behind the object;
  • before and after: the values;
  • computed and checks: the figures and checks the proposer supplied;
  • reason, proposedBy, runId, proposedAt;
  • approval: who approved it and when, added on approval;
  • commit: what was written and when, added on the write.

digest is a SHA-256 over the canonical JSON of everything proposed: the bundle without digest, approval and commit. The response recomputes it (verification.matches) and lists the action's audit-chain entries, so the bundle can be checked against the chain without trusting the model that proposed the change.

Current limits ​

  • The Xero writes have been tested against a stand-in for the Xero API, not yet against a real Xero organisation.
  • Agents inside CHANGENTS.AI do not yet propose actions on their own; a person or another system proposes them through this API.

Served from this deployment. No page view leaves it.