get_code
Fetch one code, either by its coupon_token, or by the code itself plus the sweepstakes_token — the second form is what a point-of-sale system has in hand. Send one form or the other: coupon_token wins if both are sent. Codes are matched exactly and case-sensitively. Read-only; it never redeems anything — use redeem_code for that. Read-only and NOT gated by the Codes & Coupons module: only the writes of this category document a module-not-enabled 403. If this call returns 403, look for another cause before telling the user the module is off.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coupon_code | No | The code itself — up to 20 letters, digits, - or _. Matched exactly and case-sensitively. Requires sweepstakes_token | |
| coupon_token | No | The code token (UUID v4). Required unless coupon_code is sent; takes precedence when both are sent | |
| sweepstakes_token | No | The sweepstakes token (UUID v4). Required together with coupon_code |