Skip to main content
This is a public endpoint for booking engines to look up voucher details by code.
Authorization
string
required
Bearer token with marketing:read scope
code
string
required
The voucher code to look up

Response

Returns whether the voucher is valid and its details.
valid
boolean
Whether the voucher is valid for use
error
string
Error code if invalid
message
string
Human-readable error message if invalid
voucher
object
Voucher details

Error codes

ErrorDescription
voucher_not_foundNo voucher with this code exists
voucher_inactiveVoucher is not active
voucher_expiredVoucher has expired
voucher_depletedVoucher has no remaining balance
Request
curl -X GET "https://api.voyantcloud.com/v1/vouchers/lookup?code=GC1A2B3C4D" \
  -H "Authorization: Bearer $API_KEY"
Response (Valid)
{
  "valid": true,
  "voucher": {
    "id": "voucher_abc123",
    "code": "GC1A2B3C4D",
    "type": "gift_card",
    "status": "active",
    "current_balance_minor": 7500,
    "initial_balance_minor": 10000,
    "currency": "EUR",
    "expires_at": "2025-12-31T23:59:59Z",
    "is_transferable": true
  }
}
Response (Invalid)
{
  "valid": false,
  "error": "voucher_depleted",
  "message": "Voucher has no remaining balance",
  "voucher": {
    "code": "GC1A2B3C4D",
    "status": "depleted",
    "current_balance_minor": 0,
    "currency": "EUR"
  }
}