Rivet Context API · for developers and providers

Give your agents the transaction, not just the document.

One API for the context behind every transaction. Read the shared record, write to it where your environment allows, hand it to your agent as MCP tools, and prove its history. The same Connected Ledger your team and Gio work from.Next, Gio and other agents pay per call for the answers a transaction is missing, under your policy, with a record on both sides. Coming

Each part is tagged: Available where it ships today, Coming where it doesn’t yet.

Context · INV-4417 / PO-8842Carmony’s side
What the Context API holds for one transaction, and which part supplies it.
recordBill from Ridgeline Parts Supply · $48,200.00API
statusWaiting on freight approval · $1,240.00API
lineagePO-8842 v3 → INV-4417Ledger
history7 transitions · chain verifiedLedger
eventsdocument.status_changed → your ERPWebhooks
toolsgetDocument · transitionDocument · payDocumentMCP
Coming
evidenceProof of delivery from Tamarack Freight · $0.05 a callx402
callergio.carmony@rivet.network, for Jordan KimIdentity
receiptOne ledger line on each sideLedger

Illustrative, not a product screenshot.

Whoever calls, your systems, your own agent, or an agent on the network, works against the same transaction context, inside the same permissions, and leaves a record on it.

What’s in the Context API

Your systems, your agents, the network. One context.

A key acts as your organization and only ever sees your side of a connection. Everything it reads or writes is the same record Workspace shows your team and Gio reasons over.

Your systems

Read and write the record.

Documents, payments, and treasury over one org-scoped contract, with document writes where your environment has them enabled.

GET /v1/documents?type=invoice
200 · 2 invoices, your side
The v1 APIAPI Available
Signed webhooks for the lifecycleWebhooks Coming
A sandbox to practise againstAPI Available
Your agents

Give your own agent the same context.

The Rivet MCP server runs beside your agent and turns the contract into MCP tools, one per operation, acting as your organization with the scopes of the key you give it.

$ npx -y @rivet-network/mcp
# tools: listDocuments · getDocument · transitionDocument · payDocument …
An MCP server for your own agentMCP Available
The network

Get the answers a transaction is missing.

Gio and other agents find what providers offer, pay per call over x402 within your policy, and bring the answer back to the transaction it was for.

GET /pod/SHP-77120
402 Payment Required · 0.05 USDC
200 OK · signed proof of delivery
Provider tools, discoverable to agentsMCP Coming
Per-call payment over x402x402 Coming
Agent identity on every callIdentity Coming
One context · the Connected Ledger
Every change leaves a record on the Connected Ledger.

Who did what, when, with what evidence: verified on every read, attributed down to the key, and exported as a bundle anyone can check offline without trusting Rivet.

Verified history, lineage, and exportLedgerComing
One ledger line per paid call, on both sidesLedgerComing
How a paid call will work
Coming

One request. One payment. One record.

x402 puts the price in the HTTP response. The Context API puts the transaction around it: who is asking, for which transaction, under what authority, and where the record goes.

  1. 1
    The transactionThe transaction needs an answer

    INV-4417’s freight line, $1,240.00, is waiting on proof of delivery.

  2. 2
    GioGio asks the carrier

    As gio.carmony@rivet.network, attached to INV-4417. Tamarack Freight’s endpoint answers 402 with its terms.

  3. 3
    RivetRivet checks Gio’s authority

    All four, or Jordan Kim decides.

    AuthorizedRelevant to a transactionWithin spending policyVendor permitted
  4. 4
    GioThe payment settles; Gio retries with proof

    0.05 USDC from Carmony’s Rivet wallet. The retry carries the signed payment in PAYMENT-SIGNATURE.

  5. 5
    Both sidesThe answer lands on the transaction

    The signed proof of delivery attaches to INV-4417, each side gets one ledger line, and Jordan approves the freight line.

Step 2 · the carrier’s responsex402 v2 · example values
HTTP/1.1 402 Payment Required
PAYMENT-REQUIRED: eyJ4NDAyVmVyc2lvbiI6Miwi…

# PAYMENT-REQUIRED, decoded
{
  "x402Version": 2,
  "resource": {
    "url": "https://api.provider.example/pod/SHP-77120",
    "description": "Signed proof of delivery",
    "mimeType": "application/json"
  },
  "accepts": [{
    "scheme": "exact",
    "network": "eip155:8453",
    "amount": "50000",
    "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "payTo": "0x4b1e…9c07",
    "maxTimeoutSeconds": 60,
    "extra": { "name": "USD Coin", "version": "2" }
  }]
}
Step 4 · the retry, and the 200
GET /pod/SHP-77120
PAYMENT-SIGNATURE: eyJ4NDAyVmVyc2lvbiI6Miwi…

HTTP/1.1 200 OK
PAYMENT-RESPONSE: eyJzdWNjZXNzIjp0cnVlLCJ0…

The wire is open x402, version 2, the one Rivet’s pay-by-agent guide documents. The Context API’s part is around it: the authority check before Gio pays, and the ledger line after.

For providers
Coming

Publish the answers you hold. Get paid on every call.

A carrier, a manufacturer, a credit bureau: each holds context a transaction needs. Publish it once as a priced resource and Gio can use it for the businesses on the network. No payment system to build, no agent accounts, no connector to build per customer.

What platforms publishPriced per call by each platform, in dollars · settled in USDC
GETpod/{shipment}CarrierSigned proof of delivery and exceptions
GETtracking/{shipment}Carrier or 3PLPickup, ETA, and delivery status
GETavailability/{sku}ManufacturerPrice, stock, and lead time
GETcredit/{customer}Trade credit bureauCredit limit and payment history
Works today: put x402 v2 in front of one resource and any x402-capable agent can pay you per request. It needs nothing from Rivet.
What Rivet handles
Authorization

Whether this agent may buy this, for this transaction, under its business’s policy.

Payment

Priced in dollars, settled in USDC per request, swept to your treasury on your schedule.

Identity

Every call names a verified business, a person, and an agent.

Context

Each request arrives attached to its transaction: the connection, the document, the workflow step.

Reconciliation

One ledger line per request on both sides, exportable.

Rivet Context API

Start with an account. Keys come with it.

There is no separate developer account. A key acts as your organization, and an admin mints it in Settings → Developers.Providers: tell us what you’d publish, and we’ll set you up as the agent surface opens. Partner with Rivet →