Skip to main content

Errors

Every error has a stable machine-readable code. Build on the code; the message is for humans and may change.

New codes may be added. If you get a code you do not know, handle it by its HTTP status.

{
"error": {
"code": "voucher_expired",
"message": "Voucher has expired",
"request_id": "req_…"
}
}

Quote request_id when you contact support.

Request and authentication​

HTTPcodeMeaning
400invalid_requestThe request is malformed or a field is missing
400idempotency_key_requiredA POST without an Idempotency-Key header (1–255 characters)
401unauthorizedNo key, an unknown, revoked or expired key, or a key for the other environment (a test key on production)
403insufficient_scopeThe key is valid but lacks the operation's scope
403plan_capability_missingYour Space's plan does not include the API (or this feature)
404not_foundNot found in your Space. Another Space's object is always 404, never 403
409idempotency_key_reusedThe Idempotency-Key was already used for a different request
409idempotency_request_in_progressThe first request with this key is still running; retry after Retry-After
429rate_limitedRate limit — see Rate limits
500internal_errorOur side. Retry with the same Idempotency-Key.
503temporarily_unavailableOur side, briefly. Retry after Retry-After with the same Idempotency-Key.
503api_not_configuredThe API is not enabled on this server

Every response, success or error, carries X-Request-Id; it is the same value as error.request_id.

POST /v1/sponsor-packages/{id}/redemptions:

HTTPcodeMeaning
404not_foundNo such sponsor package in your Space
404code_not_foundThat code is not part of this sponsor package
409already_redeemedThis code has already been redeemed
409not_redeemableThe perk is not in a redeemable state
409use_voucher_redeemThe perk is a voucher: redeem it with POST /v1/vouchers/redeem
422credits_exhaustedNot enough credits; top up and retry
422credits_suspendedYour credits account is suspended
422no_payerThe sponsor package has no paying Space
429allowance_exhaustedYour plan's monthly API action allowance is used up; retry after Retry-After (the next month, Asia/Jakarta). Nothing was charged
503temporarily_unavailableRedemptions are not priced right now; retry with the same key

Voucher codes​

POST /v1/vouchers/validate and POST /v1/vouchers/redeem. Validate answers a refused voucher with 200 and "valid": false, with the code in error.code. Redeem answers it with 422 and the code in error.code. A code that is not a voucher of your Space is 404 not_found on both.

codeMeaning
voucher_voidCancelled by the merchant
voucher_not_activeThe voucher is in a state that cannot be redeemed
voucher_not_redeemableThe voucher cannot be redeemed for another reason
max_redemptions_reachedNo redemptions left
not_yet_validBefore its start date
voucher_expiredAfter its end date
invalid_dayNot valid on this day of the week
blockout_dateNot valid on this date
wrong_locationNot valid at this location
booking_scoped_voucherCan only be used with its booking
crossbrand_redeem_deniedBelongs to another brand of the network
staff_confirm_requiredA perk that must be confirmed by staff at the counter (redeem)
wrong_outletNot valid at this outlet. Comes from a staff member's outlet limits; an API key acts for the whole Space, so you should not see it
wrong_sub_brandNot valid for this sub-brand. Same as wrong_outlet: not expected for an API key

When your Space enforces per-branch voucher allocations, validate and redeem must name the branch the voucher is used at (branch_id, or a location_id that identifies exactly one of your branches). Then you can also get:

codeMeaning
outlet_requiredName the branch: send branch_id (or a location_id that is a branch or a single-branch location)
branch_requiredThe location has several branches; send branch_id
branch_unknownNo such branch
branch_inactiveThe branch is not active
branch_not_authorizedThe voucher is not valid at this branch
branch_not_in_listingbranch_id does not belong to location_id
branch_not_in_spaceThe branch is not one of your Space's branches
outlet_not_allocatedThe voucher is not allocated to this branch
outlet_quota_exhaustedThis branch's voucher quota is used up
outlet_quota_invalidThis branch's quota is misconfigured
outlet_quota_unknown_valueThe voucher has no value, so this branch's quota cannot be checked

If the allocation cannot be checked, you get 503 temporarily_unavailable. Retry with the same Idempotency-Key.

How the quota is counted:

  • A redemption uses the quota when it is redeemed. A later refund does not give it back. Only a redemption that is voided before it is used (or a booking reservation released on cancel) frees it.
  • Each redemption uses the voucher's full face value, for every punch of a multi-punch pass.
  • Redemptions by platform staff count the same as the counter.
  • If the allocation cannot be read, the redemption is refused (503); it is never waved through.
  • Booking redemptions count too. A pass that secures a booking is held to the quota of the booking's branch, and the booking is refused with the same codes as above.

Check-in codes​

POST /v1/events/{id}/check-ins:

HTTPcodeMeaning
200already_usedTicket already checked in. Returned as check_in.result, not as an error. See the gate-scanner guide for every result
404not_foundNo such event in your Space, or no ticket with that code for this event
409cancelledTicket cancelled
409expiredTicket expired
409not_eligibleThe ticket is in some other state that cannot be checked in (not active, used, cancelled or expired)
409race_lostAnother scanner checked it in at the same moment
503temporarily_unavailableWe could not verify the event or ticket right now; retry with the same Idempotency-Key