add_payment_to_cart
Assign a saved payment method (credit or campus card) to a cart by providing cart ID, payment type, and payment ID. Optionally set amount in cents for partial payment.
Instructions
attach a saved payment method to a cart.
Args: cart_id: The cart ID payment_type: Grubhub payment type, such as CREDIT_CARD or CAMPUS_CARD payment_id: Payment method ID amount_cents: Optional amount in cents; omit to cover remaining balance
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": {
"cart_id": "<cart_id>",
"payment_type": "<payment_type>",
"payment_id": "<payment_id>"
},
"name": "add_payment_to_cart"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cart_id | Yes | ||
| payment_type | Yes | ||
| payment_id | Yes | ||
| amount_cents | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |