Skip to content
Updated May 27, 2026

Connection

AgentPMT exposes one MCP server for your Agent Group. Use the hosted Streamable HTTPS endpoint when your client supports remote MCP. Use the local STDIO router when your client requires a command-based MCP server.

The Bearer token belongs to one Agent Group. The tools, credentials, spending caps, and activity log for that group define what the connected agent can do.

Prerequisites

  1. Create or choose an Agent Group

    In the dashboard, open Control Center -> Agent Groups. Add the tools and workflows this agent may use, bind required credentials, and set spend controls.

  2. Copy the Bearer token

    Click Show Bearer Token on the group card. Treat the token like a password; it authorizes every MCP call for that group.

  3. Choose a transport

    Prefer hosted Streamable HTTPS for remote-MCP clients. Choose local STDIO only when the client needs a local command.

Hosted Streamable HTTPS Endpoint

text
Endpoint:  https://api.agentpmt.com/mcp
Transport: Streamable HTTP over HTTPS
Auth:      Authorization: Bearer <AGENTPMT_BEARER_TOKEN>

Hosted MCP does not require a local package. Your client connects directly to AgentPMT over HTTPS, sends the Bearer token in config or a secret field, and receives the current tool catalog for the agent group.

Complete Hosted Config Examples

Use this generic shape for MCP clients that accept remote Streamable HTTP servers in a config file:

json
{
  "mcpServers": {
    "agentpmt": {
      "type": "streamable-http",
      "url": "https://api.agentpmt.com/mcp",
      "headers": {
        "Authorization": "Bearer <AGENTPMT_BEARER_TOKEN>",
        "x-instance-metadata": "{\"client\":\"generic-mcp\",\"platform\":\"remote\"}"
      }
    }
  }
}

x-instance-metadata is optional. When your client supports custom headers, use it to identify the client and platform in activity logs.

If your editor build exposes a remote MCP server option, use the hosted config shape above and set:

text
URL: https://api.agentpmt.com/mcp
Authorization: Bearer <AGENTPMT_BEARER_TOKEN>

If the editor only accepts command-based MCP servers, use the local STDIO fallback below.

Local STDIO Fallback

Install the local router when your MCP client requires a command. The router does not execute tools locally. It reads AGENTPMT_BEARER_TOKEN, receives JSON-RPC over STDIO, and forwards requests to https://api.agentpmt.com/mcp.

bash
npm install -g @agentpmt/mcp-router
agentpmt-setup

The setup command detects supported clients, asks for the Bearer token, and writes the appropriate config. Re-run agentpmt-setup when you switch agent groups or add another local client.

Platform-Specific Local Config Examples

Use these blocks only for clients that need a local command. Keep AGENTPMT_BEARER_TOKEN in the config file or the client secret store. X_INSTANCE_METADATA is optional and must be a JSON string.

Config files:

- Windows: %APPDATA%\Claude\claude_desktop_config.json - macOS: ~/Library/Application Support/Claude/claude_desktop_config.json - Linux: ~/.config/Claude/claude_desktop_config.json

json
{
  "mcpServers": {
    "agentpmt": {
      "command": "npx",
      "args": ["--package=@agentpmt/mcp-router@latest", "agentpmt-router"],
      "env": {
        "AGENTPMT_BEARER_TOKEN": "<AGENTPMT_BEARER_TOKEN>",
        "X_INSTANCE_METADATA": "{\"client\":\"claude_desktop\",\"platform\":\"desktop\"}"
      }
    }
  }
}

Browser-Based Clients

Use the hosted endpoint for browser clients that support remote MCP connectors. Store the Bearer token in the connector's secret/auth field, not in a chat message.

If the browser client does not support remote MCP, use AgentPMT's direct HTTP API from your own server-side runtime instead of exposing the Bearer token in client-side code.

Postman Testing

Postman is useful for verifying an agent group before you rely on an agent prompt.

  1. Create an MCP request

    Choose Postman's MCP request type and set the URL to https://api.agentpmt.com/mcp.

  2. Add auth and metadata

    Add Authorization: Bearer <AGENTPMT_BEARER_TOKEN>. Optionally add x-instance-metadata: {"client":"postman","platform":"desktop"}.

  3. Connect and run a tool

    Connect, choose one of the loaded tools, fill in the displayed parameters, and run the request.

  4. Verify activity

    Open Control Center -> Agent Activity and confirm the request, response, status, and metadata are logged.

Troubleshooting

SymptomCheck
No tools appearConfirm the Bearer token belongs to the agent group you configured and that tools are added to that group.
401 or auth failureRe-copy the Bearer token, remove extra whitespace, and check whether the token was rotated.
Client rejects hosted configUse the local STDIO fallback; that client likely requires a command-based MCP server.
Tool is listed but failsBind any required credentials on the Agent Group and review the tool's current schema.
Activity log is missing metadataConfirm the client supports custom headers for hosted MCP or X_INSTANCE_METADATA for the local router.

Discovery and Protocol Reference

MCP Endpoint

  • https://api.agentpmt.com/mcp

Native MCP Methods

  • initialize: Negotiates MCP protocol capabilities and starts a session.
  • notifications/initialized: Confirms client initialization after a successful initialize call.
  • tools/list: Returns the currently available native tool set for the authenticated context.
  • tools/call: Invokes a selected native tool by name with tool-specific arguments.

Fetch Native Tools And Call Them

1) Initialize

bash
curl -X POST "https://api.agentpmt.com/mcp" \
  -H "Authorization: Bearer <oauth_access_token>" \
  -H "Content-Type: application/json" \
  -d '{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "initialize",
  "params": {
    "protocolVersion": "2025-03-26",
    "clientInfo": {
      "name": "agentpmt-docs-example-client",
      "version": "1.0.0"
    },
    "capabilities": {
      "tools": {}
    }
  }
}'

2) List current native tools

bash
curl -X POST "https://api.agentpmt.com/mcp" \
  -H "Authorization: Bearer <oauth_access_token>" \
  -H "Content-Type: application/json" \
  -d '{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/list",
  "params": {}
}'

3) Call a tool returned by tools/list

bash
curl -X POST "https://api.agentpmt.com/mcp" \
  -H "Authorization: Bearer <oauth_access_token>" \
  -H "Content-Type: application/json" \
  -d '{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "<tool_name_from_tools_list>",
    "arguments": {
      "example_input": "value"
    }
  }
}'

Get More Tools

1) Browse available external tools

bash
curl -X GET "https://www.agentpmt.com/api/external/tools?limit=20"

2) Create an auth session for wallet signing

bash
curl -X POST "https://www.agentpmt.com/api/external/auth/session" \
  -H "Content-Type: application/json" \
  -d '{
    "wallet_address": "0xYOUR_WALLET"
  }'

3) Invoke a selected tool

bash
curl -X POST "https://www.agentpmt.com/api/external/tools/<product_slug>/actions/<action_slug>/invoke" \
  -H "Content-Type: application/json" \
  -d '{
    "wallet_address": "0xYOUR_WALLET",
    "session_nonce": "<session_nonce>",
    "request_id": "<unique_request_id>",
    "signature": "0x<wallet_signature>",
    "parameters": {
      "example": "value"
    }
  }'

Well-Known Discovery URLs

  • https://www.agentpmt.com/.well-known/mcp
  • https://www.agentpmt.com/.well-known/mcp/server.json
  • https://www.agentpmt.com/.well-known/mcp/server-card.json
  • https://www.agentpmt.com/mcp.json
  • https://www.agentpmt.com/.well-known/mcp.json
  • https://www.agentpmt.com/.well-known/glama.json
  • https://api.agentpmt.com/.well-known/mcp
  • https://api.agentpmt.com/.well-known/mcp/server.json
  • https://api.agentpmt.com/.well-known/mcp/server-card.json
  • https://api.agentpmt.com/mcp.json
  • https://api.agentpmt.com/.well-known/mcp.json
  • https://api.agentpmt.com/mcp/.well-known/mcp
  • https://api.agentpmt.com/.well-known/glama.json

Raw Bearer-token API callers should use Programmatic Access. Wallet-authenticated autonomous agents should use the Autonomous Agents API. Agents paying for one eligible tool action with direct x402 should use X402 Payments For Tool Usage.