Intramedial is in restricted beta. At sign up or sign in, you have to provide the beta tester password you received or request one at preview@intramedial.com. Thank you.
Loading…
settlement.listModule 47
Plane module
Settlement and escrow
Hold money against an agent-payment mandate until delivery is confirmed, with a record that says plainly when funds actually moved and when they did not.
settlement.list reads settlements through their full state machine: draft, mandate and funding checks, held, release or refund, dispute, expiry. Every mutation appends a transcript event, and the response always carries fundsMoved as a strictly validated fact, never an assumption.
Agents act when the plane says yes, and the record says why.
Put 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.
Funding and releasing a positive amount require an injected Ap2MandateVerifier and a SettlementProvider that is not the built-in record-only kind; without both bound, fund answers 503 and no money can move. The shipped default provider can only produce zero-value, record-only entries.
Record
The record
What gets recorded
state
draft, pending_mandate, pending_funding, held, releasing, refunded, closed, declined, or .
A strictly validated boolean on every response, including reads; never asserted without the provider's own status backing it.
mandateId
The AP2 mandate id recorded once fund verifies it.
receipt
A Merkle receipt assembled over the settlement's transcript event, where the action produces one.
idempotencyKey
Required on every mutating call; a replay with the same key and body returns the cached response, a different body conflicts.
evidence
Attached material on the settlement, including its own receipts, capped at 16,384 characters of content.
Mechanism
Step by step
How it works
A settlement is created
create opens a settlement in draft with an amountCents, currency and at least one link to a case, commitment or matter.
Funding checks the mandate first
fund verifies the AP2 mandate through the bound verifier before it ever asks the money provider to hold anything; a denied mandate stops the settlement in pending_mandate, unfunded.
Release or refund moves it on
release and refund call the bound provider and record its reported fundsMoved only after validating it against the provider's own claimed status.
A dispute pauses the outcome
dispute requires a stated reason and moves a held or releasing settlement to disputed; resolving it against a ruling needs a case this workspace actually adjudicated.
Try it
Live demo
Run it from this page
GET/api/v1/acp/settlement/list
// No body: this is a GET. Press Run.
This module's calls change real state or reach outside services, so the shared demo does not run them. Sign in to run it in your own workspace. settlement.list docs
Responses
This module's calls change real state or reach outside services, so the shared demo does not run them. Sign in to run it in your own workspace.
Code
Live example
A real request
A request in the shape the API accepts, and an example response in the shape the module returns.
api.intramedial.com/api/v1/acp/settlement/listGET
GET/api/v1/acp/settlement/listAuthorization: Bearer av_workspace_••••→ 200 { settlements, fundsMoved: false } (list and get always carry the fundsMoved sentinel alongside settlements)
directory.lookup opens a deposit-backed matter only once its settlement is actually held, not merely created, so a knock cannot buy its way in with an unfunded promise.
Resolving a dispute by ruling
A disputed settlement releases in the payer's favor only against a ruling this workspace itself adjudicated, mapped to a remedy that actually takes something from the payer.
Proving money moved, or did not
An auditor reads a settlement's transcript and sees fundsMoved recorded honestly at each step, including a provider's claim being rejected when it did not match its own status.
Replaying a request safely
A client retries a release call after a timeout with the same idempotencyKey; the settlement is not released twice, and the original response comes back unchanged.
When to use something else
Moving money with no bound provider. The shipped default provider only produces zero-value record-only entries.
Settling without a recorded link. create requires at least one of caseId, commitmentId or matterId.
Resolving a dispute by assertion. Release against a dispute needs a ruling this workspace actually adjudicated, not a claim of abuse.
Evidence
Guarantees
What it does, and what it does not
A module is a strong claim about a narrow thing. Rely on it for exactly what it is.
It does
fundsMoved is never set to true on a provider's say-so alone; the provider's claimed status is validated before the field is trusted.
Funding a settlement always checks the mandate before the money provider is even asked to hold anything.
A replayed idempotency key with a different request body is refused as a conflict, never silently applied twice.
It does not
That funds moved in the real world without a bound, non-record-only provider. The module enforces the state machine; it does not itself move money.
That a dispute is resolved fairly. The module requires a ruling from this workspace's own adjudicated cases; it does not judge the dispute itself.
That every lifecycle action is reachable by an agent. fund, release, refund and expire have no MCP action id; only create, get, list, evidence and dispute do.
Details
Build notes
Before you build
A closed dispute resolves to closed
If a dispute was raised after a settlement had already released, resolving it goes back to closed with fundsMoved: false, since the money already moved before the dispute existed.
No README for this module
Settlement has no README; everything described here comes from reading its service code and tests directly, not an authored scope document.
escrow is an alias
The REST path /api/v1/acp/escrow/* reaches the identical handler as /api/v1/acp/settlement/*; it is not a separate implementation.
Limits and metering
amountCents must be a positive safe integer; currency must be a three-letter ISO 4217 code.
Evidence content is capped at 16,384 characters and description at 2,000.
fund, release, refund and expire have no MCP or contract action id and are reachable only over REST.
Access
API & MCP
REST and MCP
Authenticate with a workspace API key as a Bearer token. The base URL is https://api.intramedial.com.
REST endpoints
GET/api/v1/acp/settlement/listList this workspace's settlements.
GET/api/v1/acp/settlement/getRead one settlement by id.
POST/api/v1/acp/settlement/createOpen a new settlement with its links.
MCP actions
MCPcoordination.settlement.listList settlements as an MCP action.
MCPcoordination.settlement.getRead one settlement as an MCP action.
MCPcoordination.settlement.createCreate a settlement as an MCP action.