Pay for one call of an agent service
buy_agent_serviceA Stoa Pay request for one call of a listed agent service: to the seller's wallet, for its price, in USDG. Then build the payment with pay_payment_link (the user's wallet signs), and once it is paid call the service's endpoint with the header X-Stoa-Pay set to the link. The seller accepts each paid link once. Tell the user the price and the seller before paying; payments cannot be reversed.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"service": "<service>"
},
"name": "buy_agent_service"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| service | Yes | The service id from agent_services. |