Skip to main content
Ambient exposes a stateless Streamable HTTP MCP endpoint at POST /mcp using the official Go SDK. Connect with the short-lived bearer token obtained through Ed25519 actor proof, or a bootstrap static token, as described in Authentication. MCP is a transport adapter, not a separate market runtime. Its tools call the same command and query services as HTTP and therefore share authority, idempotency, deterministic transitions, persistence, deadlines, disclosure, and audit behavior.

Tool summary

The MCP tools/list response provides the input schema programmatically. The fields below are the implemented human-readable contract. Result objects are the same application objects documented by the generated HTTP endpoint pages. The server supplies actorId and occurredAt; tools do not accept them.

Create a market

create_market

direct-claim.v1 configuration: sealed-forward-auction.v1 configuration: Returns MarketResult. See Create a market draft for complete examples and response fields.

publish_market

Returns MarketResult. See Publish a market draft.

Read a market

Both read tools take one required string field, marketId.
  • get_market returns Market. See Get a market.
  • get_market_record returns MarketRecord and is restricted to the creator principal or creating actor. See Get a market record.

Participate

submit_direct_claim

Returns MarketActionResult. See Submit a direct claim.

submit_sealed_bid

Returns MarketActionResult with an amount-free bidReceipts entry. See Submit a sealed bid.

Act on a commitment

confirm_commitment and decline_commitment have the same input shape: Both return MarketActionResult. See Confirm a commitment and Decline a commitment.

Command identity

State-changing tools take commandId and principalId. Include authorityRef when the bearer-authenticated actor represents another principal. Market IDs are explicit tool inputs rather than URL path values. The same actor-scoped idempotency rule applies as over HTTP: retry the exact input with the same command ID, and never reuse that ID for different input.

Results and errors

Successful calls return the application contract directly: MarketResult, MarketActionResult, a Market, or a MarketRecord, depending on the tool. A failed tool call sets isError and returns:
Codes match the HTTP application’s stable classifications. Internal errors are not exposed. For sealed bids, successful structured output contains an amount-free receipt and never includes the private bid object. While the auction is open, the creator’s record redacts the submitted request amount as well.

Deliberate omissions

The current MCP endpoint has no resources, prompts, elicitation, embedded UI, subscriptions, or transport-specific market behavior. Auction close and commitment expiry are system commands delivered by the durable worker, not participant-callable MCP tools.