log_purchase
Record a card purchase, calculate the rewards it earns, and check whether another card in the wallet would have earned more.
Instructions
Record a purchase made on a card and calculate the rewards it earned. Also says whether another card in the wallet would have earned more.
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": {
"card": "<card>",
"amount": "<amount>",
"merchant": "<merchant>"
},
"name": "log_purchase"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| card | Yes | Card id, or its name (a unique part is enough) | |
| note | No | ||
| amount | Yes | Amount in ₹ | |
| channel | No | offline | |
| category | No | Spending category, see the smartcard://categories resource. Leave empty to guess from a well-known merchant. | |
| merchant | Yes | ||
| spent_on | No | YYYY-MM-DD, defaults to today |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||