Attach Payment Method
attach_payment_methodAssociate a payment method with a customer for future charges. Provide payment method ID and customer ID to complete the attachment.
Instructions
Attach a payment method to a customer.
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": {
"payment_method_id": "<payment_method_id>",
"customer": "<customer>"
},
"name": "attach_payment_method"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| payment_method_id | Yes | Payment method ID (pm_...) | |
| customer | Yes | Customer ID to attach to (cus_...) | |
| idempotency_key | No | Optional idempotency key for safe retries |