Credits
How a service asks for payment, how an agent escalates to a human, and what a credit actually is. Specification v0.1.
Status v0.1
Credits are prepaid access to services provided or resold by The Interagentic Company. They are a unit of account inside a closed loop with a single issuer.
A credit is not a currency and not electronic money. It is redeemable only with The Interagentic Company and the providers it resells, cannot be transferred between accounts, and cannot be redeemed for cash. This protocol describes how an agent discovers a price and obtains a human's approval — it is not a payment network and does not move funds between parties.
1. Asking for payment
When an action costs credits, the service answers 402:
HTTP/1.1 402 Payment Required
X-Payment: interagentic-credit; amount=9.00
Link: <https://id.interagentic.dev/approve/4c7e…>; rel="approve"
Content-Type: application/json
{
"error": "payment_required",
"asset": "interagentic-credit",
"amount": "9.00",
"description": "2 × Classic popcorn",
"approveUrl": "https://id.interagentic.dev/approve/4c7e…"
}| Field | Required | Notes |
|---|---|---|
asset | yes | Always interagentic-credit. Not an ISO currency code. |
amount | yes | Decimal string, in credits. |
description | yes | Shown to the human. Say what is being bought. |
approveUrl | yes | Where a person can authorise this. |
The X-Payment header carries the same information for clients that stop at
headers. The Link relation approve is the machine-readable route to the same
URL.
2. Escalating to a human
The approval URL is deterministic, so an agent can also construct it without a round trip:
https://id.interagentic.dev/approve
?service=popcorn.club
&amount=9.00
&reason=2+bags+of+Classic
&state=<opaque>A client SHOULD print it rather than retrying, and SHOULD exit non-zero so a supervising process notices.
402 Payment Required — 9.00 credits
Ask your human to approve a budget:
https://id.interagentic.dev/approve/4c7e…3. Approvals
An approval is held by the broker, not by the service and not by the agent.
| Field | Type | Required | Notes |
|---|---|---|---|
service | string | yes | Exactly one domain |
limit | number | no | Ceiling for the period; omit for a single charge |
period | string | no | once, daily or monthly |
expiresAt | string | no | Hard stop |
An agent can read its own approvals and can never widen them. Revocation takes effect immediately.
npx interagentic credits
npx interagentic credits ledger --limit 254. Settlement
After the human approves, the agent repeats its original request unchanged. The service verifies the approval with the broker and, on success, records the charge against the agent's identity — so a statement shows which agent triggered what, and a single agent can be revoked without touching the others.
09-17 popcorn.club 2 × Classic 9.00
09-16 extraorbital mongo/orders 1.205. Relationship to x402
The shape follows the x402 convention for machine-payable endpoints: a 402
carrying a price and a way to satisfy it, retried unchanged once satisfied. A
client that already implements x402 needs little new code.
The difference is what is being settled. x402 typically denominates in a
transferable asset. Here the asset is interagentic-credit, which never leaves
the issuer's loop; approval is an authorisation recorded by the broker, not a
transfer between parties.
Command model
How a service declares its commands as arrays of segments, and how a client resolves them into a subcommand chain of any depth.
Secure calls
Two ways to call any API — provider actions and direct HTTP — and the proxy both share. Placeholders, scopes, refusals and self-repair. Specification v0.1.