Mercator documentation
Mercator gives agents one interface to:
- Find tools for an open-ended workflow.
- Quote an immutable plan of one or more tool calls.
- Pay for and run the plan as one durable job.
Downstream services remain independently operated and use open payment protocols such as MPP and x402.
Choose a path
| You want to… | Start here |
|---|---|
| Use Mercator with your agent | Get started |
| Connect a specific app | Agent setup |
| Build an integration | API |
| Add funds or manage spending | Payments |
| Make your service discoverable | Service owners |
Installation
-
Run the installer in your computer's terminal:
curl -fsSL https://mercator.sh/install.sh | sh -
Select the installed agents you want to connect.
-
Complete authorization in your agent, then run your first job.
- Claude Desktop, Claude web, or ChatGPT: use Agent setup.
- Updates and installer options: see the CLI reference.
- New wallet session: sign in and approve payment permission in one Tempo Wallet approval.
- Existing wallet session: approve access for the same account wallet.
Run your first job
-
Authorize Mercator in your agent and fund your wallet in Account.
-
Give your agent this prompt:
Use Mercator to find NVIDIA's latest 10-Q and 8-K via SEC submissions. Return official links, dates, and one-sentence summaries. -
Expect both filings, dates, official links, and summaries.
-
If execution is still pending, keep the job ID and ask the agent to resume polling it.
- Search, service inspection, and quotes are free.
- Paid execution uses the wallet limits approved during authorization; an explicit prompt budget is an additional limit.
- Native MPP clients such as Hermes need a configured payment wallet and quote approval or an explicit spending budget.
- A pending job does not need another purchase.
Example prompts
Ask for get_suggested_queries to retrieve the same examples shown under Try Mercator after setup.
| Demo | Complexity | Prompt |
|---|---|---|
| Tokenized NVIDIA comparison | Complex | Compare tokenized NVDA: issuer, chains, value, dividend-adjusted price, liquidity, redemption; flag conflicts and missing data. |
| Escape the fog | Moderate | Compare tomorrow's SF, Half Moon Bay and Livermore forecasts; map the sunniest trip from the Ferry Building with two food stops. |
| Research to launch artwork | Complex | Research 3 AI expense-report competitors; propose sourced positioning, generate launch artwork, and return a one-page brief. |
Agent setup
Choose your app below, or use the standalone setup checklist.
| Where you use your agent | Setup path |
|---|---|
| Claude Code, Codex, Cursor, or another installed client | Local agents |
| Claude Desktop chat, Claude web, or Cowork | Claude connectors |
| ChatGPT on the web | Developer-mode app |
| Cloud agent, team-managed host, or remote machine | Managed and remote environments |
| Another MCP client | Manual installation |
Local agents
Run the installer in the terminal where your agent runs:
curl -fsSL https://mercator.sh/install.sh | shTo configure just one client during installation, pass its ID after sh -s --:
curl -fsSL https://mercator.sh/install.sh | sh -s -- --client cursorActivate after installation
- Load the installed configuration using your client's action below.
- Complete the client's OAuth flow. Mercator requests
mercator:toolsfor/mcp/auth. - Call
search_servicesandget_connection_statusin that client.
- Setup lists each client under Client readiness with its activation and authorization steps. A written registration stays "authorization pending" until you authorize in the client.
mercator refreshupdates managed files but does not restart clients.mercator doctorverifies the separate CLI connection.
| Client / change | Next step |
|---|---|
| Claude Code terminal plugin | Run /reload-plugins in the current session. If it warns about the prompt cache, run /reload-plugins --force. Restart Claude Code if unsupported. |
| Claude Code without an interactive terminal | Start a new session to load plugin MCP changes. |
| Codex plugin | Check plugin/MCP status first: recent versions support live refresh. If tools remain missing, fully quit and reopen the desktop app, or exit and resume the CLI. |
| Grok plugin | Restart Grok after a plugin refresh when setup requests it. |
| Standalone MCP configuration | If Mercator is missing, restart the client, then authorize. Plugin reload may not load standalone registrations. |
Codex AGENTS.md guidance | Start a new session to load changed instructions. |
For immediate terminal access, use the CLI MCP client.
Claude Code
User MCP registration and Mercator plugin.
mercator setup --client claudeIn Claude Code, run /mcp, select Mercator, and complete browser authorization.
See Claude Code MCP.
Codex
Local Codex MCP registration. Setup picks the newest Codex 0.151.0 or newer from PATH and the
ChatGPT or Codex app bundle, and prints its path and version. Override with --codex-path or
MERCATOR_CODEX_BIN.
mercator setup --client codexRun codex mcp login mercator to authorize. See Codex MCP configuration.
Cursor
User MCP configuration in ~/.cursor/mcp.json.
mercator setup --client cursorOpen Cursor's Customize page, find Mercator under MCP servers, and complete its OAuth sign-in. See Cursor MCP.
Visual Studio Code
MCP registration through the code command, or the CLI bundled in Visual Studio Code on macOS.
Setup reads the user mcp.json to detect an existing registration.
mercator setup --client vscodeRun MCP: List Servers from the Command Palette, select Mercator, and start it. Complete any trust and sign-in prompts, then enable its tools in agent chat. See VS Code MCP.
Gemini CLI
User MCP registration.
mercator setup --client geminiIn Gemini CLI, run /mcp auth mercator and complete browser authorization.
See Gemini MCP authentication.
Cline
Cline CLI settings in ~/.cline/data/settings/cline_mcp_settings.json, or CLINE_MCP_SETTINGS_PATH.
mercator setup --client clineRun cline mcp, select Mercator, and complete browser authorization; use Authorize OAuth to
retry. The IDE extension keeps its own settings: use MCP Servers > Remote Servers there.
See Cline MCP configuration.
Continue
Project .continue/mcpServers/mercator.json.
mercator setup --client continueUse Agent mode in Continue and complete the OAuth sign-in for Mercator. See Continue MCP.
Windsurf
User ~/.codeium/windsurf/mcp_config.json.
mercator setup --client windsurfOpen MCPs in the Cascade panel, select Mercator, and complete OAuth authorization. See Cascade MCP.
Grok
User MCP registration and Mercator plugin.
mercator setup --client grokOpen /mcps, select Mercator, and press i to authorize.
See Grok MCP.
Hermes
Native MPP integration at /mcp, not hosted OAuth.
mercator setup --client hermesThe installer selects /mcp and sets up the hermes-mpp payment plugin. Complete any
remaining plugin and wallet steps it prints before paid use. Native MPP requires quote approval
or an explicit spending budget. See Hermes MCP commands.
Kiro
User ~/.kiro/settings/mcp.json.
mercator setup --client kiroConnect to Mercator from Kiro's MCP controls and complete the browser authorization it opens. See Kiro MCP authentication.
LM Studio
User ~/.lmstudio/mcp.json.
mercator setup --client lmstudioEnable Mercator in LM Studio and complete the browser authorization it opens. See LM Studio MCP authentication.
Muse Code
XDG Muse settings, normally ~/.config/muse/settings.json.
mercator setup --client museRun muse mcp login mercator to authorize.
OpenClaw
Native MCP configuration with OAuth enabled.
mercator setup --client openclawInteractive setup starts login; otherwise run openclaw mcp login mercator.
See OpenClaw OAuth.
Zed
context_servers in Zed user settings.
mercator setup --client zedOpen Settings > AI > MCP Servers and complete Mercator's OAuth prompt. Use it from Zed's Agent Panel. See Zed MCP.
Claude Desktop chat and Claude web
- Open Customize > Connectors, click +, then Add custom connector in Claude Desktop or claude.ai.
- Name it Mercator and enter
https://mercator.sh/mcp/auth. - Complete Claude's connection and authorization flow, then check the free
search_servicesandget_connection_statustools in your conversation.
This uses Claude's remote connector; no terminal installation is required. The user completes authorization and chooses wallet limits. See Claude's connector guide if your organization manages connector access.
Cowork can use the same remote connector. If the connector controls are unavailable, check the host's current account and organization requirements; installing a CLI inside the conversation does not enable them.
ChatGPT web
Where your account and workspace permit custom apps:
- Enable Developer mode in Settings > Security and login.
- Open Plugins, use the + button, and create a developer-mode app named Mercator.
- Enter
https://mercator.sh/mcp/auth, choose OAuth, and complete authorization. If prompted for a registration method, use dynamic client registration (DCR). - Select the app from the conversation's Developer mode tools, then verify the connection.
Follow OpenAI's developer-mode guide
for current availability and controls. A local Codex registration or mercator login does not
authorize this ChatGPT connection. Do not run the installer in ChatGPT's code-execution sandbox.
Managed and remote environments
- Cloud or team-managed agents: use the host's native plugin or connector controls. Where it
supports remote MCP with OAuth, add
https://mercator.sh/mcp/authusing Streamable HTTP and complete authorization. An administrator may need to enable the integration first. - SSH, containers, and remote development: run setup where the intended agent client runs. Configuration written there does not configure a separate desktop app. If the browser cannot reach the client's loopback callback, use Mercator's browser handoff and copy the completion link back to the same client. Use its documented code input or port forwarding if it cannot accept the full link. Hosted and app-link callbacks return normally.
- No connector controls or compatible OAuth support: use a supported client instead. Do not repeatedly run the installer in a disposable sandbox or paste tokens or private keys into chat.
- Unclear app or mode: identify it before choosing a setup path. Claude Code, Claude Desktop chat, local Codex, and ChatGPT web do not share one installation or authorization flow.
Verify the connection
In the client you connected, ask:
Use Mercator to search for web research services, then check my connection status.
Do not create a paid job.- Confirm the agent can call
search_servicesandget_connection_status; both checks are free. The status response includes the wallet address and public access-key address. - For a REST client, call
GET /v1/connection/statuswith its/mcp/authOAuth bearer token. Missing, invalid, or revoked tokens return401; the response is never cached. - Follow any returned authorization or funding steps. Registration, a browser account login, or an HTTP 401 challenge alone does not prove the client's connection is ready.
- Hosted OAuth: choose wallet limits and expiry during authorization. Zero limits allow connecting without spending authority; a successful connection does not imply paid readiness.
- Hermes/native MPP:
get_connection_statusreportsmcp_challengewithout wallet balances. Check the native payment plugin and wallet separately; this response does not verify spending readiness. - Keep each client's authorization in that client. CLI login and
mercator doctorcannot verify credentials owned by another agent host.
Payments
Mercator sponsors up to 8,000,000 declared gas per Tempo charge, including first-use access-key installation. This sponsor policy is separate from Tempo’s transaction gas limit; fee-price and total-fee ceilings still apply.
For LLM calls, follow the service’s input schema: include an output token limit and keep streaming/background execution disabled. The proxy RPC service accepts read-only methods.
Pricing and spending limits
| Operation | Cost |
|---|---|
| Discovery, inspection, quotes, result reads, product feedback | Free |
| Paid job | Quoted provider costs plus Mercator's cost multiplier, paid before execution |
| Job review | Free; original-payer proof required |
- Pass the quote token and exact quote total into submission; Mercator charges that quote until
validUntil. Requote expired quotes. - Hosted OAuth limits and any explicit user budget cap spending.
- Native MPP and local wallets require quote approval or a sufficient explicit budget, and a new quote after a price change.
- Never paste or send private keys; wallet tooling handles signing and authorization.
Mercator supports MPP with two payment methods:
- Tempo: Mercator displays prices denominated in USDC.e, but clients also can pay for Mercator services in MACH credits or through a supported pathUSD auto-swap.
- Stripe: Pay in USD with a shared payment token (SPT). Configured payments require whole-cent totals of at least $0.01.
Settlement and provider payment validation
- When configured, Tempo charges above 0.01 USDC.e settle to Stripe's Tempo deposit address; smaller charges settle to Mercator.
- Mercator pays providers through MPP on Tempo or x402 on Base. Base is not a customer payment rail.
- Monid operations use live Base USDC quotes with a $0.01 minimum. Metered operations are unsupported. Mercator retrieves async results using a wallet signature, without a second payment or a Monid API key. Directory coverage follows Monid's public catalog releases, not its advertised hosted endpoint count.
- Tempo clients use
mercator.shfor MPP attribution in transfer memos; downstream payments retain the provider's realm. - Reviewed endpoints' live
402responses supply realm and recipient; catalog pins are not required. - Validation enforces supported chain, currency, recipient address format, expiry, and spending limits. Extra challenge fields do not alter the original challenge.
Funding and MACH
MACH is a credit that can be used on Tempo for paying approved merchants, including Mercator.
- Open Account, or ask your agent to call
fund_wallet. - Confirm the authenticated wallet address.
- Choose an amount and complete checkout; the connected wallet uses MACH for subsequent paid jobs.
| Property | Rule |
|---|---|
| Purchase rate | 1 USD buys 1 MACH, minted to the authenticated wallet |
| Spending | Approved merchants only, including Mercator |
| Transfers | Cannot transfer between wallets |
| Redemption | Cannot redeem for cash, swap, or bridge through Mercator |
| Expiry | None |
| Provider | Provided by Coinflow, subject to their terms of service |
Claim a grant
Claim five free MACH with GitHub or X on your Mercator account page or through the CLI:
mercator account claim githubmercator account claim xFailed-job refunds
| Payment | Refund behavior |
|---|---|
| Tempo | Unused capacity on failed or succeeded jobs will appear in your wallet as MACH credits at a 1:1 value |
| Stripe | No automatic refunds; contact support for interrupted payments |
- A failed provider purchase is billable only when the provider caused it: an HTTP failure, a terminal failure status, or an incomplete result.
- Purchases wasted by Mercator, such as output limits or completion timeouts, are refunded.
- Invalid Monid sign-in challenges during result retrieval are nonbillable. Failures report
providerStatus: 402,providerErrorKind: "authentication", andretryable: false; use theerror_idfor support rather than paying to repeat the job. - Execution completion and refund settlement are separate; inspect
usage.refundStatusand continue polling pending settlement. For Tempo payments, an uncertain provider call is provisionally billed and the rest is refunded automatically. When a provider refuses Mercator's payment with a fresh challenge, Mercator confirms on chain within about 30 seconds that nothing was paid, then retries the node or refunds its share when the job finishes. Ifusage.refundStatusisfailedandusage.refundErrorisreconciliation_required, the Tempo refund is held: contact the operator with the job ID. Polling or resubmitting does not release the hold. The operator must reconcile provider settlement and any prior issuance before releasing funds.
CLI reference
Install, configure, and call Mercator from your terminal.
- The installer downloads a checksum-verified standalone executable; Node.js and Bun are not required.
- It updates the active shell's PATH profile when needed.
- A failed reinstall keeps the existing executable.
Configuration
Pass setup arguments after sh -s --:
curl -fsSL https://mercator.sh/install.sh | sh -s -- --client codex- Codex/ChatGPT desktop: Installs one local plugin by default. ChatGPT web uses the separate developer-mode app setup.
- Claude Code and Grok CLI: Registers the public
tempoxyz/pluginsmarketplace and installs its Mercator plugin. - No detected client: Installs the local desktop plugin when enabled. Install a supported
client and rerun setup, or use
mercator setup --manualfor other MCP clients. - Cloud/team marketplaces: Managed by the host.
CLI commands
| Command | Purpose |
|---|---|
mercator login | Authorize the CLI through browser OAuth. |
mercator logout | Remove local CLI credentials. |
mercator tools | List live MCP tools and schemas. |
mercator call <tool> --input '{…}' | Invoke an MCP tool. |
mercator setup | Connect Mercator to installed agent clients. |
mercator status | Show client registrations and connection status. |
mercator account | Manage hosted wallet access, limits, funding, and revocation. |
mercator refresh | Update and refresh existing managed integrations using saved setup choices. |
mercator doctor | Check MCP transport, discovery, and local integrations. |
mercator uninstall | Remove MCP registrations, the plugin, and managed guidance. |
mercator local | Use a separate local wallet and submit REST jobs. |
Use the CLI as an MCP client
- Run
mercator loginand complete browser authorization. - Inspect live tools with
mercator tools. - Call a tool with
mercator call:
mercator login
mercator tools
mercator call get_connection_status
mercator call search_services \
--input '{
"query": "web research"
}'
mercator doctormercator setupreuses existing CLI credentials to check discovery and spending capacity. Interactivemercator setup --loginsigns in when needed.- The CLI connection is named mercator cli; agent clients authorize separately.
- Setup authorizes the CLI only with
--login; CLI login creates a separate access key that can spend. --yes, non-interactive setup, andmercator refreshnever launch login.- Cancelled login leaves integrations installed; retry with
mercator setup --login. - Choose wallet limits in the browser authorization flow. Login and doctor create no paid jobs.
- If approval happens on another device, copy the completion link and paste it into the waiting
mercator loginprompt. The CLI also accepts the code from that link. toolsreturns current tool descriptions and input schemas.callaccepts a JSON object and returns the MCP result; tool errors exit nonzero. Paid tools use the connection's approved limits.- Credentials stay in endpoint-scoped, owner-only files under
~/.local/share/mercator/oauth/. Expiring bearers refresh automatically. Other agent clients retain their own authorization. - The Tempo access key remains valid until revoked by default. Revoke the connection in Account to disable OAuth first, then ask Tempo Wallet to revoke the on-chain key. For a key that has not yet been published, Account returns its signed public authorization so Wallet can authorize and revoke it in one transaction.
mercator logoutremoves local CLI credentials. Revoke mercator cli in Account to revoke its wallet access.
Setup options
| Option | Behavior |
|---|---|
--client <name> | Configure one client; repeat for several. IDs: claude, cline, codex, continue, cursor, gemini, grok, hermes, kiro, lmstudio, muse, openclaw, vscode, windsurf, and zed. |
--url <url> | Use another Mercator MCP endpoint, including a local development endpoint. |
--dry-run | Preview configuration changes without writing them. |
--yes | Select every detected client unless --client is specified, and apply without setup prompts or installer-initiated login. Existing CLI credentials are reused. |
--login | Also authorize the Mercator CLI during readiness checks. Creates a separate spending access key; agent clients authorize on their own. |
--codex-path <path> | Use this absolute Codex executable instead of discovery. MERCATOR_<CLIENT>_BIN, such as MERCATOR_CODEX_BIN or MERCATOR_VSCODE_BIN, sets a persistent override. |
--verbose | Keep progress output and append detailed setup diagnostics. |
--manual | Print MCP/OAuth connection instructions without configuring integrations. Incompatible with --client, --force, and --remove-agents. |
--force | Recreate MCP registrations; complete native OAuth in the client. |
--plugin / --no-plugin | Enable or disable the local desktop plugin. Enabled by default. |
--skill / --no-skill | Include or omit the Mercator skill inside the plugin. Included by default. |
--agents / --no-agents | Enable or disable managed Codex AGENTS.md guidance. Enabled by default. |
--remove-agents | Remove only managed Codex guidance and stop; incompatible with --force and --no-agents. |
The bootstrap installer accepts these environment overrides:
| Variable | Behavior |
|---|---|
MERCATOR_BIN_DIR | Set the executable directory; highest precedence. Relative paths are resolved before installation. |
MERCATOR_INSTALL_DIR | Set the executable directory when MERCATOR_BIN_DIR is unset. |
INSTALL_DIR | Generic fallback when neither Mercator-specific directory is set. |
MERCATOR_INSTALLER_URL | Download a specific trusted HTTPS release installer. |
MERCATOR_NO_MODIFY_PATH=true | Leave shell profiles unchanged and print the PATH command instead. |
MERCATOR_SKIP_SETUP=true | Install the CLI without running setup. Run mercator setup later. |
Install the plugin from the Tempo marketplace
The installer bootstraps the Mercator plugin for detected supported clients. To install it directly,
add the public Tempo marketplace and select the mercator@tempo plugin:
Codex
codex plugin marketplace add tempoxyz/plugins --ref main
codex plugin add mercator@tempoClaude Code
claude plugin marketplace add tempoxyz/plugins
claude plugin install mercator@tempo --scope userGrok
grok plugin marketplace add tempoxyz/plugins
grok plugin install mercator@tempoManual installation
Merge configuration examples into the existing file; preserve other servers and settings.
- Run
mercator setup --manual. - Add
https://mercator.sh/mcp/authusing Streamable HTTP. - Complete OAuth in the client; use the registration instructions if it requires a client ID.
- Verify with
search_servicesandget_connection_statusthere.
- Registration or a 401 challenge does not prove payment readiness.
mercator doctorcannot read client-managed credentials.
You can register the remote MCP endpoint directly in a supported harness:
- For harnesses with tool search, such as Claude Code and Codex, append
?tools=allto the URL to list every catalog service as its own tool. Omit it for clients that load every tool into context.
Codex
codex mcp add mercator --url https://mercator.sh/mcp/auth --oauth-client-registration dcrClaude Code
claude mcp add --scope user --transport http mercator https://mercator.sh/mcp/authGemini CLI
gemini mcp add mercator https://mercator.sh/mcp/auth --transport http --scope userVS Code
code --add-mcp '{"name":"mercator","type":"http","url":"https://mercator.sh/mcp/auth"}'OpenClaw
openclaw mcp set mercator '{"url":"https://mercator.sh/mcp/auth","transport":"streamable-http","auth":"oauth"}'
openclaw mcp login mercatorIf the browser cannot reach OpenClaw's loopback callback, use its documented remote-browser fallback. Do not paste authorization codes into chat.
Hermes
hermes mcp add mercator --url https://mercator.sh/mcpThis registers the MCP server only. Paid use also requires the native MPP plugin and wallet;
mercator setup --client hermes checks the plugin and prints any remaining steps.
Kiro
Add to ~/.kiro/settings/mcp.json:
{"mcpServers":{"mercator":{"url":"https://mercator.sh/mcp/auth"}}}LM Studio
Add to ~/.lmstudio/mcp.json:
{"mcpServers":{"mercator":{"url":"https://mercator.sh/mcp/auth"}}}Muse Code
Bootstrap only Muse's MCP configuration, then authorize with Muse:
mercator setup --client muse --no-plugin --no-agents
muse mcp login mercatorSetup preserves other entries in ~/.config/muse/settings.json (or the XDG_CONFIG_HOME
equivalent), initializes schema_version: 1, and adds Mercator using transport: "streamable_http".
It uses an existing mcpServers map when present, otherwise mcp_servers. Start a new Muse session
and check /mcp. Configuration does not complete OAuth; Muse stores and refreshes the credentials.
This integration does not require Muse's experimental plugin commands.
Zed
Add mercator under context_servers in the Zed user settings file:
{"context_servers":{"mercator":{"url":"https://mercator.sh/mcp/auth"}}}Manual registration saves the server configuration. Complete authorization and
verify the connection in that client. OAuth-capable clients open Account
when authorization is required. Run mercator account to manage wallet access, limits, funding, and revocation.
Mercator for service owners
Request discovery for services using supported open payment protocols such as MPP and x402.
Email mercator@tempo.xyz with:
- Service URL.
- Documentation or OpenAPI URL.
- Supported payment protocol.
- Short capability description.
Mercator ingests reviewed catalogs and endpoint metadata.
Troubleshooting
| Problem | Next action |
|---|---|
| Tools missing after installation | Activate the client, then verify there |
| Connected but unable to pay | Check connection; distinguish authorization, funding, and spending limits |
| Browser cannot reach a remote callback | Use browser handoff or the client's documented remote flow |
| Job pending after disconnect | Poll the same job |
| Lost job ID | List retained jobs with the payer wallet |
| Some nodes failed | Keep successful results and inspect per-node failures |
| Unexpected error persists after one safe retry | Draft a sanitized bug report |
Contact support
- Email mercator@tempo.xyz, or use Report a bug.
- Include the
x-mercator-request-idresponse header or MCPerror.request_id, and any failureerror_id; neither grants access to results. - Include a known job ID only when authorizing maintainers to access its results.
- Exclude secrets, credentials, payment material, personal data, and raw inputs or outputs.
- Use Review a job for workflow and service-quality feedback.
API reference
Choose REST or MCP
| Interface | Recommended use | Connection |
|---|---|---|
| MCP | Agent workflows | Streamable HTTP at https://mercator.sh/mcp/auth |
| REST | Direct application integrations | https://mercator.sh/v1 |
| CLI MCP client | Terminal use and debugging | mercator login, then mercator call |
Authentication
| Operation | Authentication |
|---|---|
| Search, describe, quote, suggested queries | Free REST calls need no wallet authorization |
| Connection status | OAuth bearer issued for /mcp/auth |
| Create a job | Hosted MCP wallet authorization, or a supported payment client |
| List jobs | OAuth bearer or verified Tempo Wallet account session |
| Read hosted wallet jobs and node results | Original payer's OAuth bearer or account session |
| Read main direct payer, Stripe, or sponsored jobs | Private job ID |
| Review a job | Original payer's route-bound zero-value proof |
| Read review status | Private job ID |
| Download artifacts | Signed url from a job read (expires after 1 hour), or the job-read authentication above |
Discovery and OAuth metadata
- OAuth setup guide
- If
GET /authorize?client_id=https%3A%2F%2Fclient.example%2Fclient.json&response_type=codecannot fetch or validate the client metadata document, it returns HTTP400with{"error":"Invalid OAuth client metadata"}without redirecting. Correct the client metadata URL or document and retry authorization. - OAuth protected-resource metadata
- API catalog
- Agent discovery document
- MCP server card
- Agent skills index
- WebMCP: read-only service search and description tools on the homepage.
REST and MCP operation index
| Operation | REST | MCP |
|---|---|---|
| List curated Mercator quick-start queries | GET /v1/suggested-queries | get_suggested_queries |
| List executable recipes | GET /v1/recipes | list_recipes |
| Build a recipe into a quotable plan | POST /v1/recipes/{recipeId}/plan | build_recipe_plan |
| Open mercator | — | open_mercator |
| Inspect the current OAuth connection and spending readiness | GET /v1/connection/status | get_connection_status |
| Search downstream MPP services | GET /v1/services/search | search_services |
| Describe a downstream MPP service | GET /v1/services/{serviceId} | describe_service |
| Live-price a plan without a budget or payment | POST /v1/quote | quote_plan |
| Submit a durable plan | POST /v1/jobs | create_job |
| List retained jobs for the authenticated wallet | GET /v1/jobs | list_jobs |
| Poll or retrieve a cached job result | GET /v1/jobs/{jobId} | get_job |
| Retrieve one cached node result or selected field | GET /v1/jobs/{jobId}/results/{nodeId} | get_job_details |
| Fund wallet | — | fund_wallet |
| Claim wallet | — | claim_wallet |
| Review a completed workflow and its tool calls | POST /v1/jobs/{jobId}/feedback | create_job_review |
| Retrieve feedback reward status | GET /v1/jobs/{jobId}/feedback | get_job_review |
| Send product feedback or a bug report to Mercator maintainers | POST /v1/product-feedback | send_product_feedback |
Run a REST workflow
-
Search services for the complete outcome.
-
Describe the endpoint if you need its input schema.
-
Save the exact service, method, path, and schema-valid input in
plan.json:{ "nodes": [{ "id": "filing", "serviceId": "{{SERVICE_ID}}", "method": "{{METHOD}}", "path": "{{PATH}}", "input": {"query": "latest official NVIDIA SEC filing"}, "dependsOn": [] }] } -
Quote the plan for free and check the total against your budget.
-
Create a job with the unchanged plan, the quote's
quoteTokenandtotalAmountasapprovedTotal, and a persisted idempotency key. -
Get the job until it reaches a terminal status.
-
Read selected node results if you only need part of the output.
- The
inputabove is a template: replace it with the endpoint's actual fields. - New jobs may acquire an optional
titleasynchronously, summarizing requested work. Job history and job reads return it when available; execution does not wait for it, and older jobs are not backfilled. Titles can also appear in shared receipt metadata. - MCP follows the same sequence:
search_services→describe_servicewhen needed →quote_plan→create_job→get_job. - Pass the search response's
idunchanged to quote and submission when available. - Keep the returned job ID; resume polling after a disconnect.
Call specific services
Skip search and call endpoints you already chose, such as fal, Exa, or Parallel, with your existing Mercator connection and balance.
-
Run
mercator loginonce, or connect any MCP client tohttps://mercator.sh/mcp/auth. No provider API keys are needed. -
Get the endpoint's input schema with
describe_service:mercator call describe_service \ --input '{"service_id": "fal", "method": "POST", "path": "/minimax/h3-max/text-to-video"}' -
Put one node per endpoint in a plan, using the exact
serviceId,method, andpath:mercator call quote_plan --input '{ "plan": {"nodes": [{ "id": "video", "serviceId": "fal", "method": "POST", "path": "/minimax/h3-max/text-to-video", "input": {"prompt": "A cinematic ocean wave at sunrise"}, "dependsOn": [] }]} }' -
Submit the unchanged plan with the quoted
quoteTokenandtotalAmountand a new idempotency key:mercator call create_job --input '{ "approved_total": "{{QUOTED_TOTAL}}", "quote_token": "{{QUOTE_TOKEN}}", "idempotency_key": "ocean-video-001", "plan": {"nodes": [{ "id": "video", "serviceId": "fal", "method": "POST", "path": "/minimax/h3-max/text-to-video", "input": {"prompt": "A cinematic ocean wave at sunrise"}, "dependsOn": [] }]} }' -
Poll
get_jobwith the returnedjob_iduntil the job is terminal.
- Hosted OAuth limits authorize the charge; no per-job approval or provider account is needed.
describe_servicereturns the authoritativeinputSchema; the inputs below are minimal examples.- Writes that act outside Mercator, such as orders, uploads, calls, and email, include
effects(kind,reversible,cleanup,retention) indescribe_service, andquote_planlists them innext_action. Confirm them with the user before submitting; Mercator cannot undo them. - To search only providers you chose, pass
service_idswithservice_mode: "require"tosearch_services. Use"prefer"to rank them first while keeping fallbacks.
Common endpoints
| Service | serviceId | method and path | Example input |
|---|---|---|---|
| fal MiniMax H3 Max text-to-video | fal | POST /minimax/h3-max/text-to-video | {"prompt": "A cinematic ocean wave at sunrise"} |
| Exa web search | exa | POST /search | {"query": "Series A fintech startups in Berlin"} |
| Exa page contents | exa | POST /contents | {"ids": ["https://arxiv.org/pdf/2307.06435"]} |
| Parallel web search | parallel | POST /api/search | {"query": "recent Tempo news"} |
| Parallel extract | parallel | POST /api/extract | Describe for fields |
| Parallel deep research | parallel | POST /api/task | Describe for fields |
| Brave web search | brave | POST /brave/web-search | Describe for fields |
| Deepgram text-to-speech | deepgram | POST /deepgram/speak | Describe for fields |
| Deepgram transcription | deepgram | POST /deepgram/transcribe | Describe for fields |
Combine services in one job
Chain several chosen services in one plan and pay once. This plan searches with Exa, then reads every result URL:
{
"nodes": [
{
"id": "find",
"serviceId": "exa",
"method": "POST",
"path": "/search",
"input": {"query": "Series A fintech startups in Berlin"},
"dependsOn": []
},
{
"id": "read",
"serviceId": "exa",
"method": "POST",
"path": "/contents",
"input": {"ids": {"$map": {"from": "flow://find/output#/results", "path": "/url"}}},
"dependsOn": ["find"]
}
]
}- Nodes without dependencies run concurrently, at most 3 at once per service; a plan has at most 10 nodes.
flow://node_id/outputpasses an earlier output; append#/json/pointerto select a field.- Check the upstream output shape with
describe_servicebefore mapping fields.
Search services
- Start with the complete task; use the default static resolution for fast discovery.
- Use
requirefor mandatory providers orpreferto retain relevant alternatives. - Follow the returned
nextTool; inspect missing inputs before quoting.
Usage
MCP
mercator call search_services \
--input '{
"query": "find the latest official NVIDIA SEC filing",
"limit": 5
}'Response
MCP response excerpt:
{
"id": "123e4567-e89b-42d3-a456-426614174000",
"resolution": "static",
"endpoints": [{
"rank": 1,
"serviceId": "parallel",
"method": "POST",
"path": "/api/search",
"requiredArguments": ["query"],
"nextTool": "describe_service"
}],
"nextTool": "describe_service"
}rankis display order after provider preference and health routing.scoremeasures relevance and price; scores need not descend with rank.- Thirty-day provider failures apply ranking multipliers of
0.75(degraded) or0.5(severely degraded); quarantined endpoints are excluded before confidence filtering while ingestion continues. Non-402 errors, including 404, downrank services; caller-input 400 and 422 do not unless the endpoint has stopped succeeding, and other input-dependent 4xx cannot alone quarantine them. Quarantine requires at least 50% failures and reopens after 24 hours at the severe penalty to allow recovery traffic. Full recovery requires three clean windows in each failed phase. Valid unsigned 402 challenges remain successful probes; payer-side credential rejections stay neutral. estimatedPriceis a discovery hint; use a quote for the exact plan total.
Query Parameters
string'pre-confidence' returns the bounded static candidate pool before confidence filtering for diagnostic ranking replay.
pre-confidencestring·default static'static' returns ranked catalog results without provider probes; 'live' attempts bounded availability probes when globally enabled. Indeterminate probes retain unconfirmed endpoints.
staticlivestring[]·min 1·max 20Service allowlist or preference set. Repeat the parameter for multiple IDs.
Responses
Constraints
- Free; search does not execute provider work.
- Live resolution attempts bounded probes; indeterminate endpoints can remain in results.
- Catalog examples describe accepted input; do not submit them as the user's request.
Errors and recovery
| Outcome | Next action |
|---|---|
| No unconstrained or preferred match | Retry once with a broader task description |
| Required provider or excluded capability has no match | Keep the constraint; ask the user before changing it |
| Missing required inputs | Call describe_service and fill the schema |
Describe a service
- Use after search when an endpoint needs its complete input schema, examples, or payment offers.
- Select one endpoint with both
methodandpath, especially for large services.
Usage
MCP
mercator call describe_service \
--input '{
"service_id": "parallel",
"method": "POST",
"path": "/api/search"
}'Response
Response excerpt; the live inputSchema is authoritative:
{
"service": {
"id": "parallel",
"endpoints": [{
"method": "POST",
"path": "/api/search",
"inputSchema": {"type": "object", "required": ["query"]}
}]
}
}Constraints
- Free; inspection does not purchase provider results.
- Copy the exact cataloged service, method, and path into the plan.
Errors and recovery
- A missing or stale service or endpoint requires a new search.
- If the service is too large to describe, supply both endpoint selectors.
Suggested queries
- Use when the user wants ideas; present suggestions before executing one.
Usage
mercator call get_suggested_queriesResponse
Response excerpt with one suggestion:
{
"queries": [{
"id": "escape-the-fog",
"title": "Escape the fog",
"complexity": "moderate",
"prompt": "Compare tomorrow's SF, Half Moon Bay and Livermore forecasts; map the sunniest trip from the Ferry Building with two food stops."
}]
}Constraints
- No parameters; free and read-only.
- Listing a prompt does not authorize a paid job.
List recipes
- Use when the outcome matches a curated workflow: a web research brief, a three-place forecast comparison, or a token market snapshot.
- Each recipe lists typed parameters, defaults, and its plan template; the matching use case shows the workflow.
Usage
mercator call list_recipesResponse
Response excerpt with one recipe:
{
"recipes": [{
"id": "web-research-brief",
"title": "Web research brief",
"useCase": "deep-research",
"parameters": [
{"name": "topic", "type": "string", "maxLength": 300, "example": "Series A fintech startups in Berlin"},
{"name": "result_count", "type": "integer", "minimum": 1, "maximum": 10, "default": 5}
],
"plan": {"nodes": [
{"id": "search", "serviceId": "exa", "method": "POST", "path": "/search", "input": {"query": {"$param": "topic"}, "numResults": {"$param": "result_count"}}, "dependsOn": []},
{"id": "read", "serviceId": "exa", "method": "POST", "path": "/contents", "input": {"ids": {"$map": {"from": "flow://search/output#/results", "path": "/url"}}}, "dependsOn": ["search"]}
]}
}]
}Constraints
- No parameters; free and read-only.
{"$param": "name"}marks a parameter value;{"$template": "text {name}"}marks parameters interpolated into a string. Build the plan instead of filling templates by hand.
Build a recipe plan
- Turn a recipe and its parameters into a plan, then quote it and create a job unchanged.
- Ask for required parameters; omitted optional parameters use their defaults.
Usage
mercator call build_recipe_plan \
--input '{
"recipe_id": "web-research-brief",
"parameters": {"topic": "Series A fintech startups in Berlin"}
}'Response
Response excerpt; pass plan unchanged to quote_plan:
{
"recipeId": "web-research-brief",
"parameters": {"topic": "Series A fintech startups in Berlin", "result_count": 5},
"plan": {"nodes": [
{"id": "search", "serviceId": "exa", "method": "POST", "path": "/search", "input": {"query": "Series A fintech startups in Berlin", "numResults": 5}, "dependsOn": []},
{"id": "read", "serviceId": "exa", "method": "POST", "path": "/contents", "input": {"ids": {"$map": {"from": "flow://search/output#/results", "path": "/url"}}, "text": {"maxCharacters": 4000}}, "dependsOn": ["search"]}
]}
}Build a recipe into a quotable plan
/v1/recipes/{recipeId}/planFree and deterministic. Validates parameters against the recipe, applies defaults, and returns a catalog-valid plan. It does not probe providers, pay, or create a job: quote the plan unchanged with POST /v1/quote, then submit it with POST /v1/jobs. Unknown recipes return 404 recipe_not_found; invalid parameters return 400 invalid_recipe_parameters; a recipe whose endpoints left the catalog returns 409 recipe_unavailable.
Constraints
- Free and deterministic; building a plan does not call providers, pay, or create a job.
- Parameter values are literal: strings cannot be
flow://references. - The quote and job follow the ordinary payment, idempotency, and retry rules.
Errors and recovery
| Error | Recovery |
|---|---|
recipe_not_found | List recipes and use an exact recipe ID |
invalid_recipe_parameters | Correct the named parameters; ask the user for missing values |
recipe_unavailable | A recipe endpoint left the catalog; search services for the same outcome |
Quote a plan
- Quote the complete plan after filling required inputs.
- Keep the plan unchanged between quote and submission.
- Submit
quoteTokenunchanged as MCPquote_tokenor RESTquoteToken. - Use
totalAmountas MCPapproved_total, RESTapprovedTotal, or the local CLI's--max-spendvalue.
Usage
Use plan.json from the workflow example.
MCP input — pass your saved plan under plan to quote_plan:
{
"plan": {
"nodes": [{
"id": "filing",
"serviceId": "{{SERVICE_ID}}",
"method": "{{METHOD}}",
"path": "{{PATH}}",
"input": {"query": "latest official NVIDIA SEC filing"},
"dependsOn": []
}]
}
}Response
Illustrative response excerpt:
{
"advisory": true,
"currency": "USD",
"totalAmount": "0.02",
"dynamic": false,
"stages": [["filing"]],
"quotedAt": "2026-09-25T12:00:00Z",
"quoteToken": "mq1.eyJjb3N0TXVsdGlwbGllciI6IjEi...",
"validUntil": "2026-09-25T12:05:00Z"
}Live-price a plan without a budget or payment
/v1/quoteValidates current provider terms without payment and returns a signed quoteToken that POST /v1/jobs charges unchanged until validUntil. Provider challenges remain bound to the reviewed request target, chain, currency, expiry, settlement mode, and amount. The live 402 response supplies the realm and recipient; catalog realm and recipient pins are not enforced. Additional Tempo request fields are preserved without weakening validation of known payment terms.
Constraints
- Free: a quote does not pay providers or create a job.
- With a hosted OAuth wallet, MCP
quote_planaddspayment:statusisready(with thefundingCurrencyandspendableNowthat would pay; a free quote has neither),blocked(withactionfund_walletorreconnect), ornot_verifiedwhen the wallet could not be read in time. It is a snapshot;create_jobchecks capacity again. - Prices are server-derived; do not add client-owned prices to the plan.
- Free endpoints are priced at zero from the catalog and are not called while quoting.
dynamic: truemeans a dependent node was priced with example values for its upstream inputs.- Submission charges the signed quote without probing providers again until
validUntil, 15 minutes after quoting; execution revalidates terms within accepted total and per-node limits. - Repeating a quote for the same endpoint and input may reuse the provider's unexpired price instead of probing again.
Errors and recovery
| Outcome | Next action |
|---|---|
validUntil elapsed or plan changed | Quote again |
| Stale endpoint or invalid schema | Search or describe again, correct the plan, then requote |
quote_unavailable with retryAfterSeconds | Wait at least that long before quoting again |
Create a job
- Persist an idempotency key before submitting.
- Submit the unchanged quoted plan within the authorized budget.
- Save the returned job ID and poll it.
- Hosted OAuth clients that already know a plan may pass
max_totaltocreate_jobinstead ofquote_tokenandapproved_total. Mercator quotes and submits in one call, and returnsquote_changedwithout charging when the live total exceedsmax_total. - REST clients that already know a plan may send
maxTotalinstead ofquoteTokenandapprovedTotaltoPOST /v1/jobs. Each request, including the paid retry, quotes the plan and fails withquote_changedbefore payment when the live total exceedsmaxTotal.
Usage
MCP input — pass this object to create_job, replacing placeholders with the quoted values:
{
"approved_total": "{{QUOTED_TOTAL}}",
"quote_token": "{{QUOTE_TOKEN}}",
"idempotency_key": "{{IDEMPOTENCY_KEY}}",
"plan": {
"nodes": [{
"id": "filing",
"serviceId": "{{SERVICE_ID}}",
"method": "{{METHOD}}",
"path": "{{PATH}}",
"input": {"query": "latest official NVIDIA SEC filing"},
"dependsOn": []
}]
}
}Response
MCP accepted-job example:
{
"job": {"jobId": "123e4567-e89b-42d3-a456-426614174000", "status": "pending"},
"next_action": "Poll get_job with the returned job_id."
}Header Parameters
Request Body
application/jsonstringExact quote totalAmount. Required; omission returns approval_required before payment.
stringInstead of quoteToken and approvedTotal: quote the plan in this request and submit it when the live total is at most this USD amount; otherwise quote_changed before payment.
Responses
Constraints
- Paid and side-effecting: the signed quote total is charged before execution.
- Every payment path requires the quote token and the exact approved total.
- Hosted OAuth limits authorize spending; respect any additional user budget.
- Native MPP and local wallets need quote approval or a sufficient explicit budget before paying.
- Hosted MCP authorization does not create a local wallet.
- MCP challenge clients handle the payment challenge through MCP metadata.
- Keep retries bound to the same payer, key, and unchanged plan. A new key can create a second paid job.
- Configured Stripe SPT payments require exact whole-cent totals of at least $0.01. Retry with the same SPT and idempotency key; a new SPT is a new payment identity.
Errors and recovery
| Outcome | Next action |
|---|---|
| Lost submission response | Retry the same request with the same key |
| Changed plan | Requote and use a new key for a separate job |
quote_required, approval_required, quote_invalid, quote_expired, or quote_changed | Requote the unchanged plan, then retry with the same key, the new quote token, and its total; nothing was charged |
payment_challenge_mismatch | Requote and retry; the hosted wallet signed nothing. Include error_id if you report it |
| Pending or running job | Poll; do not resubmit |
| Unexpected MCP payment request | Check connection status and follow the payment mode's guidance |
conflict (409, recoverable) | Another submission with the same key is still paying; retry the same request after a short delay |
payment_unavailable | Retry with backoff using the same key and plan; no charge was made |
payment_settlement_unrecorded | Retry after a short delay with the same key and plan; Mercator reconciles the broadcast payment, so do not start a second purchase |
| MCP submission and one retry fail | Use REST only if a local wallet is already ready; preserve plan, key, quote token, and approved total |
Payment discovery challenges
- Invalid unauthenticated submissions return a zero-value discovery challenge; it cannot create a job. Retrying that invalid request with a credential returns
400. - Use a valid quoted plan to obtain the actual charge.
Get a job
- Send
Prefer: wait=20onPOST /v1/jobsorGET /v1/jobs/{jobId}to receive the finished job in the same response (at most 25 seconds);Preference-Appliedechoes the honored wait. MCPget_jobwaits up to 20 seconds on its own. - Poll with bounded backoff while still active; stop execution polling at a terminal status.
- Use summary mode for large results, then retrieve only the nodes you need.
- Present successful outputs first when a job partially succeeds.
Usage
MCP
mercator call get_job \
--input '{
"job_id": "123e4567-e89b-42d3-a456-426614174000",
"result_mode": "summary"
}'Response
REST terminal summary excerpt:
{
"jobId": "123e4567-e89b-42d3-a456-426614174000",
"status": "succeeded",
"cached": true,
"result": {},
"result_mode": "summary",
"result_node_ids": ["filing"],
"summary": {"succeeded": 1, "failed": 0, "skipped": 0},
"failures": []
}- MCP wraps the job in
job;result_mode,result_node_ids, andnext_actionsit outside that wrapper. - Inline mode returns successful node outputs in
result. - Terminal responses include usage and provider payment accounting.
usage.currencyis the settlement token you were charged in;usage.fundingCurrency, when present, is the token your wallet spent to fund it, such as MACH.payments.legsare Mercator's own payments to providers, not your charge; when present,shareCard.urlis a public receipt that may include a generated task title alongside services and payment totals. Raw inputs and provider outputs are excluded.
| Status | Meaning | Next action |
|---|---|---|
pending / running | Active; REST returns 202 | Continue polling the same ID |
succeeded | All nodes completed | Use cached outputs |
partially_succeeded | A final node succeeded; others failed or were skipped | Use successful outputs; explain failures |
failed | No successful completion | Inspect sanitized failure reasons |
Poll or retrieve a cached job result
/v1/jobs/{jobId}Free read. Hosted wallet jobs require the original payer’s OAuth bearer or Tempo Wallet session; direct payer and ownerless main jobs use the private jobId as their access capability. Defaults to inline output. result_mode=summary returns terminal metadata, result: {}, result_mode, and result_node_ids. include_plan=true adds replayPlan with original inputs and without stored quote amounts; edit it, quote again, and submit a separate job with a new idempotency key. Pending or running jobs retain HTTP 202 and the ordinary readiness shape. Unknown query parameters, such as utm_* tags, are ignored.
Constraints
- Cached reads are free and do not execute providers again.
- Hosted job reads require the original payer; other supported payment modes use the private job ID.
- Job records, results, and charged idempotency records expire after 30 days.
- Disconnecting does not cancel execution.
- Free calls retry upstream
408,425,429, 5xx, network, and timeout failures up to three times with jitter and a bounded providerRetry-After; other upstream 4xx responses fail after one attempt. After a durable purchase claim, a paid provider request is attempted at most once. - Each entry in
failureshas a closedreasonandretryable, which is true only when an identical new job may succeed later. When known, it adds the upstreamproviderStatus,providerErrorKind,retryAfterSeconds, the providerattempts, and anerror_idto quote in bug reports. provider_rate_limitedandprovider_unavailablewithretryable: trueare transient provider capacity failures. Quote a new plan for only the failed nodes later, splitting large batches for one service. Whenretryableis false, the provider may already have been paid, so do not resubmit.- Completed purchases remain billable when other nodes fail.
Errors and recovery
| Outcome | Next action |
|---|---|
401 on a hosted job | Authenticate as the original payer |
403 job_owner_mismatch | Reconnect with the wallet that created the job; do not resubmit |
404 job_not_found | Stop; check the ID, connected wallet, and 30-day retention. Never resubmit to recover a job |
| Partial success | Keep successful outputs and inspect failures by node |
| Pending refund | Continue polling settlement separately; execution may already be complete |
Explicit reruns and file outputs
- Request
include_plan=trueonly when the user wants a new execution. - Edit the returned
replayPlaninputs and quote the complete plan again. - Submit with a new idempotency key; this is a separate paid job.
- Binary outputs and oversized results use signed artifact links that expire after 1 hour; MCP exposes them as resource links. Read the job again for a fresh link. Outputs that dependent nodes read keep their inline shape: JSON stays inline, and stored binary outputs (up to 2 MiB in total) still resolve
#/datato base64. - Binary outputs of completion-polled endpoints stay inline with
contentType,encoding: "base64", anddata. - Share the accounting receipt URL instead of the private job ID; the receipt excludes provider outputs. Its 2400 × 1260 image shows a compact dependency rail, distinct completion status, and net cost. Jobs with more than five calls retain the first and last two calls around a counted middle group.
Get node results
- Select a successful node from
result_node_idsafter a summary read. - Use
result_pointerto retrieve just the required field. - Job and node-result reads ignore unknown query parameters, such as
utm_*tags on shared links; invalid values for known parameters return400 invalid_request.
Usage
mercator call get_job_details \
--input '{
"job_id": "123e4567-e89b-42d3-a456-426614174000",
"node_id": "filing",
"result_pointer": "/results/0"
}'Response
Illustrative response; provider result fields vary by endpoint:
{
"jobId": "123e4567-e89b-42d3-a456-426614174000",
"nodeId": "filing",
"resultPointer": "/results/0",
"result": {"title": "Example filing", "url": "https://www.sec.gov/"}
}Retrieve one cached node result or selected field
/v1/jobs/{jobId}/results/{nodeId}Free read with the same wallet-owner or ownerless job-ID access rule as GET /v1/jobs/{jobId}. Returns one successful cached node from a terminal job, optionally selected with an RFC 6901 result_pointer. Empty pointer selects the whole output. Returns 409 while execution is pending or running, 404 for a missing job, unsuccessful node, or missing field, and 400 for invalid query parameter values; unknown query parameters are ignored. No provider execution or new payment.
Constraints
- Free; the node is never rerun.
- The same authentication and retention rules apply as for Get a job.
Errors and recovery
| Error | Next action |
|---|---|
409 job_not_ready | Keep polling the job |
403 job_owner_mismatch | Reconnect with the wallet that created the job |
404 job_not_found | Stop; check the ID, connected wallet, and 30-day retention |
404 job_result_not_found | Choose a successful node |
404 job_result_path_not_found | Correct the pointer or request the whole node |
400 | Correct invalid query parameters |
List and recover jobs
History defaults to 10 jobs per request and accepts a maximum limit of 100.
- List jobs using the wallet that paid for them.
- Select a returned
jobId. - Use Get a job to retrieve cached outputs for free.
Usage
mercator call list_jobs \
--input '{
"limit": 10,
"status": "succeeded"
}'Response
Response excerpt:
{
"jobs": [{
"jobId": "123e4567-e89b-42d3-a456-426614174000",
"status": "succeeded",
"services": ["parallel"],
"resultAvailable": true,
"expiresAt": "2026-10-02T12:00:00Z"
}],
"nextCursor": "123e4567-e89b-42d3-a456-426614174000"
}List retained jobs for the authenticated wallet
/v1/jobsUse a verified Tempo Wallet account session or the OAuth bearer token issued for /mcp/auth. Lists only the authenticated wallet; sign-in does not require a spending key. An explicit invalid bearer never falls back to the session. The cursor is the last job ID; restart without it if the job expires.
Constraints
- Free; requires OAuth or a verified account session, even for direct payer jobs.
- Newest first; history contains accounting summaries, not provider inputs or outputs.
- 30-day retention; agent-composed reports are not stored in job history.
- When recorded,
connectionidentifies the original hosted connection's public wallet and access-key addresses. netChargedmatches the job'susage.netCharged; labelrefundedwithrefundCurrencywhen present, otherwisecurrency.
Errors and recovery
- If the cursor job expires, restart without a cursor.
- If no jobs appear, confirm the wallet identity and retention window.
Same-origin browser example
const history = await fetch('/v1/jobs?limit=10', { credentials: 'same-origin' })
.then((response) => response.json())Check connection
- Check before paid execution when readiness is uncertain or submission unexpectedly requests payment.
- Report connection and payment readiness separately.
- MCP App hosts can open Mercator from the sidebar or conversation panel through the
user-only
open_mercator({})launcher (ui://mercator/app-v8), with a MACH balance, recent jobs, job details, and links to Account funding and receipts.
Usage
mercator call get_connection_statusResponse
Response excerpt for a ready hosted connection:
{
"oauthAuthenticated": true,
"paymentMode": "hosted_oauth",
"readiness": {
"authorization": "ready",
"walletBinding": "ready",
"funding": "ready",
"spendPolicy": "ready",
"paidExecution": "ready",
"confirmationPolicy": "standing_authorization"
}
}Inspect the current OAuth connection and spending readiness
/v1/connection/statusUse the OAuth bearer token issued for /mcp/auth. Returns the current connection’s public access-key address, wallet, live balances, limits, and readiness. Read-only; never executes a job or creates a payment. Unavailable chain reads remain unknown.
Constraints
- No parameters; free and never cached over REST.
accountcontains public wallet/access-key identity, balances, limits, and expiry—not private keys.- Unavailable chain data does not mean a zero balance.
- Capacity is not reserved; compare it with the exact quote.
- Native MCP challenge mode omits wallet balances; verify that client's payment wallet separately.
Errors and recovery
| Outcome | Next action |
|---|---|
401 | Authorize or reconnect the OAuth client |
| Funding or limits insufficient | Follow the returned next_action and Account controls |
| Chain data unavailable | Retry the free check before inferring payment capacity |
Fund wallet
Open Account to add MACH with the MCP tool fund_wallet.
Recommended usage
- Call only when the user wants to add funds.
Usage
mercator call fund_walletResponse
{
"handoff": {"action": "fund", "status": "user_action_required", "url": "https://mercator.sh/account"},
"next_action": "Open Account to choose an amount and payment method."
}Constraints
- No parameters or equivalent public REST operation.
- The tool is free and read-only; the user completes checkout in the browser.
- See Funding and MACH for purchase terms.
Claim credits
Open Account to claim MACH with the MCP tool claim_wallet.
The shared GET /v1/claims/config defaults to GitHub/X; ?provider=slack selects
the Slack campaign. Anonymous requests return availability only.
Connected clients can read GET /v1/claims/config?provider=slack with their Mercator OAuth
bearer token. The authenticated wallet determines the lookup; wallet query
parameters are ignored. Like GitHub/X account preflight, claimed means an
existing reservation, including pending or failed issuance.
GET /v1/claims/config?provider=slack
Authorization: Bearer <access_token>{"enabled":true,"claimed":false,"wallet_address":"0x1212121212121212121212121212121212121212","mach_amount_atomics":"100000000","providers":["slack"]}Recommended usage
- Call only when the user wants to claim credits.
Usage
mercator call claim_walletResponse
{
"handoff": {"action": "claim", "status": "user_action_required", "url": "https://mercator.sh/account"},
"next_action": "Open Account and choose GitHub or X to claim MACH."
}Constraints
- No parameters or equivalent public REST operation.
- Free and read-only; available only when social claims are configured.
- One grant per wallet per campaign across GitHub and X; the user completes browser authorization.
Review a job
- Review a terminal job using an overall rating, tool ratings, or both.
- Call
create_job_reviewonhttps://mercator.sh/mcpto obtain the zero-spend REST handoff. On hosted OAuth connections at/mcp/authit returnsjob_review_unavailable. - Authorize that request as the original payer.
- Get review status while its reward is pending.
Usage
mercator call create_job_review \
--input '{
"job_id": "123e4567-e89b-42d3-a456-426614174000",
"review": {
"rating": 5,
"comment": "Useful result and good value.",
"tools": [
{
"nodeId": "filing",
"rating": 5,
"tags": [
"accurate",
"fast"
]
}
]
}
}' \
--url https://mercator.sh/mcpThe returned handoff includes a command equivalent to:
mercator local submit \
--url 'https://mercator.sh/v1/jobs/{{JOB_ID}}/feedback' \
--max-spend 0 \
--body '{"rating":5,"comment":"Useful result and good value.","tools":[{"nodeId":"filing","rating":5,"tags":["accurate","fast"]}]}'Response
MCP handoff excerpt; no review has been stored yet:
{
"handoff": {
"status": "authorization_required",
"maxSpend": "0",
"nextAction": "run_rest_request",
"client": {"executable": "mercator", "arguments": ["local", "submit", "--url", "https://mercator.sh/v1/jobs/{{JOB_ID}}/feedback", "--max-spend", "0", "--body", "{\"rating\":5}"]}
}
}Constraints
- Free; the original payer signs a route-bound zero-value proof and transfers no tokens.
- The CLI command requires an existing local wallet that matches the original job payer; hosted MCP authorization does not create it.
- Hosted OAuth connections answer
create_job_reviewwithjob_review_unavailable, because their payer key stays in the hosted wallet. - Reviews are immutable: the same body replays safely; changes return
409. - Reviews are retained for 90 days.
- Eligible reviews may receive 0.01 MACH: submit within five minutes of completion, with retained spend after refundable unused capacity strictly greater than
0.01.
Errors and recovery
- A conflicting review cannot replace the stored review; retrieve its status.
- Use Report a bug for product issues.
Get review status
- Poll while the reward is
queuedorsubmitting; stop at a terminal reward state.
Usage
mercator call get_job_review \
--input '{
"job_id": "123e4567-e89b-42d3-a456-426614174000"
}'Response
{"reward": {"status": "ineligible", "reason": "claim_window_expired"}}| Status | Next action |
|---|---|
queued / submitting | Continue polling |
paid | Reward settled; stop |
failed / ineligible | Inspect the returned reason when present; stop |
Constraints
- Requires only the private job ID throughout feedback retention.
- Free and idempotent, but reading a pending reward may start or resume its payout workflow.
- MCP adds
next_actionto the reward response.
Report a bug
- Include reproduction steps, expected behavior, actual behavior, and a safe error code.
- Show the draft and ask before sending unless the user already authorized reporting this issue.
Usage
mercator call send_product_feedback \
--input '{
"kind": "bug_report",
"summary": "Search failed after one retry",
"details": "A free service search returned an unexpected error twice.",
"expected_behavior": "Return matching endpoints.",
"actual_behavior": "No search result returned."
}'Response
{"accepted": true, "report_id": "123e4567-e89b-42d3-a456-426614174000"}Constraints
- Free and side-effecting; reports are not idempotent.
- Exclude secrets, credentials, payment material, personal data, and raw tool inputs or outputs.
- Omit
job_idif unknown; do not invent an ID or create a job for reporting. - Send at most once per issue; do not retry uncertain delivery or report feedback-tool failures.