Pay a service
pay_serviceOne call for paid registry tools: quotes the seller's x402 challenge (legacy single-object or standard v2 accepts[] — BSV exact only), pays it from the site wallet on BSV mainnet, debits the agent wallet, and returns the seller's result plus txid. If the seller rejects the payment, the debit is refunded. For pay-per-call LLM with no API key, use chat; for typed values from messy text or receipts, use extract. Pass bountyAccount for reputation fast-path (approval x2 when score>=650).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | Agent key (agp_…). Optional when the MCP connection sends Authorization: Bearer. | |
| ref | No | ||
| tool | Yes | Tool name on that service | |
| dryRun | No | Sandbox: quote + policy check only, no debit or settlement | |
| params | No | Tool arguments (body for POST, query for GET) | |
| serviceId | Yes | Registry service id (from list_services) | |
| approvalId | No | Approval id from a prior approval_required response | |
| amountCents | No | Override the USD cents charged (min 1 cent default) | |
| description | No | ||
| bountyAccount | No | BSVBounties account # for trust fast-path |