POST https://win.oneshotagent.com/mcp (Streamable HTTP): wallet-minted token, credits, local MCP tools. Staging: https://api-stg.oneshotagent.com/mcp.
1. Mint an access token
First set budgets, then mint:- TypeScript (≥ 0.33.0)
- Python (≥ 0.26.0)
agent.revokeAccessToken(id) revokes; agent.listAccessTokens(): labels, last use, today’s spend. Python: snake case, plus a* async variants. Raw routes: POST/GET/DELETE /v1/agents/me/access-tokens, wallet-signed.
2. Add credits
From a wallet session; x402 pays the amount credited (Pricing).- TypeScript
- Python
- HTTP
503 route_unavailable_for_access_tokens. Insufficient credits: isError: true:
insufficient_credits: top up before retrying. budget_exceeded: spending cap reached.
3. Connect a client
- ChatGPT
- Claude
- Grok
- Cursor
- Claude Code
- Any MCP client
Settings → Apps & Connectors → Developer mode → Create: name
OneShot, URL https://win.oneshotagent.com/mcp, OAuth. Sign in.Connect with your OneShot account (OAuth)
OAuth clients usehttps://win.oneshotagent.com/mcp with no header; discovery at /.well-known/oauth-protected-resource/mcp. Sign in and choose an organization or your personal workspace; calls use its default agent and credits. Disconnect in account settings to stop spending; revoking the console token only rotates it next call.
A new default agent has no sending domain: set from_domain to one you own, or request a new one (status: 'confirmation_required', quote_id, no charge). Repeat with confirm_new_domain: quote_id to register, charge exactly the quoted total and send. Wrong/expired quotes: no charge; omit the id for a fresh quote.
Budgets
PUT /v1/agents/me/budgets before hosted-token use (TypeScript SDK ≥ 0.54.0):
isError: true:
agent.budgets() or oneshot_budget_status. Tokens cannot raise caps.
Funding compute goals
fundComputeGoal(goalId, amount), Python fund_compute_goal, MCP oneshot_compute_fund. Credits must cover the full amount; stored caps apply. Short of credits: top up from a wallet, or POST /v1/credits/checkout so a person pays by card.
Local server with a token
@oneshot-agent/mcp-server ≥ 0.20.0: ONESHOT_ACCESS_TOKEN replaces wallet credentials; credits only. Cannot combine with ONESHOT_BUDGET_*.