Agent Onboarding (MCP)
AI agents can onboard with no browser at all. The gateway exposes an MCP
(Model Context Protocol) server at POST https://tokpum.com/mcp -
stateless JSON-RPC 2.0 over HTTP. It wraps the same account, funds, key,
and routing operations the console offers, so an agent can go from nothing
to calling /v1 on its own.
Inference is NOT served over MCP. MCP is for onboarding and account
management; the agent then calls /v1/chat/completions or /v1/messages
natively with the key it obtained (streaming, tool calls, and long outputs
stay on the data plane).
Onboarding flow
- Call the
get_login_challengetool with a wallet address; the server returns a SIWE sign-in message. - Sign that message with the wallet key.
- Call
complete_loginwith the signature. The server creates the account if new, mints an API key namedmcp-agent, and returns the rawsk-key once. - Reconnect to
/mcpwithAuthorization: Bearer sk-...for all authenticated tools - and use the same key for/v1.
Tool catalog (19)
- Onboarding (anonymous):
get_login_challenge,complete_login,get_gateway_config(base URLs, key format, ready-to-use curl snippets). - Account and funds:
whoami,get_balance,get_deposit_info,list_deposits,create_withdrawal_challenge,submit_withdrawal,list_withdrawals,get_withdrawal,cancel_withdrawal. - API keys:
list_api_keys,create_api_key,delete_api_key. - Models and routing:
list_models,get_strategies,set_strategy,list_channels.
As with the console, every withdrawal requires a per-request wallet signature - the API key alone can never move funds.
Quick probe
curl -s https://tokpum.com/mcp -X POST -H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
Full input schemas and semantics: the MCP section of https://tokpum.com/llms.txt.