Require a human approval for a write
Let a refused write wait in the approval queue until a signed-in person approves it, then retry with the token.
coordination.approve
Let a refused write wait in the approval queue until a signed-in person approves it, then retry with the token.
coordination.approvePut admission in front of your MCP servers, repositories, SaaS tools and cloud accounts. Every agent gets a lease or a reason – and you keep the lever to stop any of them.
Some writes should not go through on an agent's say-so. Admission refuses a write with no token and leaves a request; an administrator or granted approver decides it, and approving issues a token for that actor, resource and verb.
The code reads the key from INTRAMEDIAL_KEY. Keep it in your shell or your secret store, never in a file you commit. Calls that need a signed-in person cannot use a key: the console makes them.
Declare a write with no token. Admission refuses it, and the approvalId in the answer names the request waiting in the queue for a person to decide.
The decision returns as approval, with its state.
{
"approval": {
"id": "apr_7f3a",
"actorDid": "did:web:acme.example:agent:billing",
"resource": "repo:payments/main",
"action": "write",
: ,
: ,
: ,
: ,
: ,
: ,
: ,
: ,
:
},
:
}coordination.approvecoordination-approve
curl -sS -X POST https://api.intramedial.com/api/v1/acp/coordination/admit \
-H "Authorization: Bearer $INTRAMEDIAL_KEY" \
-H "Content-Type: application/json" \
-d '{
"actorDid": "did:web:acme.example:agent:billing",
"resource": "repo:payments/main",
"action": "write"
}'const res = await fetch("https://api.intramedial.com/api/v1/acp/coordination/admit", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
actorDid: "did:web:acme.example:agent:billing",
resource: "repo:payments/main",
action: "write",
}),
});
console.log(res.status, await res.json());import os, requests
res = requests.post(
"https://api.intramedial.com/api/v1/acp/coordination/admit",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
json={
"actorDid": "did:web:acme.example:agent:billing",
"resource": "repo:payments/main",
"action": "write",
},
timeout=30,
)
print(res.status_code, res.json())A signed-in approver reads the request in the console and approves it. A key or an agent cannot decide; this is the body the console sends.
{
"id": "apr_7f3a",
"reason": "expected batch"
}The agent retries with the token as confirmationToken. It is single use and bound to the actor, resource and verb.
curl -sS -X POST https://api.intramedial.com/api/v1/acp/coordination/admit \
-H "Authorization: Bearer $INTRAMEDIAL_KEY" \
-H "Content-Type: application/json" \
-d '{
"actorDid": "did:web:acme.example:agent:billing",
"resource": "repo:payments/main",
"action": "write",
"confirmationToken": "…"
}'const res = await fetch("https://api.intramedial.com/api/v1/acp/coordination/admit", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
actorDid: "did:web:acme.example:agent:billing",
resource: "repo:payments/main",
action: "write",
confirmationToken: "…",
}),
});
console.log(res.status, await res.json());import os, requests
res = requests.post(
"https://api.intramedial.com/api/v1/acp/coordination/admit",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
json={
"actorDid": "did:web:acme.example:agent:billing",
"resource": "repo:payments/main",
"action": "write",
"confirmationToken": "…",
},
timeout=30,
)
print(res.status_code, res.json())Copied from: /docs/coordination-approve
The ledger is append-only and sealed under Merkle roots. The time on an entry is Intramedial's own clock, and a signed bundle can be checked offline with the published key.
Open a dual-control request for a fixed scope, have a second administrator approve its digest, then run the gated action.
dual.control-scopesDeclare a write with coordination.admit, read the refusal and its reason, and find the request it left behind.
coordination.admitAdmit an agent's write to a repository through Intralock and post the verdict to the commit as a check run or status.
github.enforceOne short email when we add recipes to the cookbook. No other mail, and you can unsubscribe from any message.
No key or account: Try it on the coordination.admit module page runs the real kernel in your browser. Use a workspace key for your own workspace.