Hey! These docs are for version 1.0, which is no longer officially supported. Click here for the latest version, 2.0!

Errors

📘

Work in progress

We are working on improving this section of documentation. Please check back in a few days!

Vouchery API will return error responses on invalid requests. Each response will include error_code and message. For POST and PATCH requests a list of detailed errors will be returned, including attribute name and, in some cases, expected value or range.

All of API errors are documented below. Where necessary additional description is provided to clarify under what conditions given error can be expected.

Redemption

Attribute

Error Code

Message

Description

base

can_not_delete_already_confirmed

Redemption was already previously confirmed and can not be updated or deleted

categories

missing_required_tags

Categories do not include any of the required tags

categories

includes_forbidden_tags

Categories include forbidden tags

categories

missing_required_category

Categories are missing a required category

location

required

Location is required to redeem this voucher

Returned if no location was provided for a voucher belonging to a campaign limited by area rule

location

invalid

Location coordinates are not valid

Returned if provided location was in invalid format

location

outside_of_permitted_areas

Location is outside of permitted areas

Returned if provided location is outside of permitted areas

voucher

not_valid_at_this_time

Voucher is not valid at this time

Returned if campaign is limited by time of order or time frame rule

voucher

unique_code_already_used

Voucher was already used

campaign

not_active

Campaign is not accepting redemptions because it is not active

campaign

maximum_redemptions_exceeded

Campaign maximum number of redemptions for this campaign has been already reached

Returned if campaign has max_redemptions set and it has been exceeded

campaign

budget_exceeded

Campaign maximum budget has already been reached

Returned if campaign has max_total_budget set and it has been exceeded

campaign

total_budget_exceeded

Campaign maximum budget has already been reached

Returned if campaign has a budget rule of total type and it's limit has been exceeded

campaign

yearly_budget_exceeded

Campaign yearly budget has already been reached

Returned if campaign has a budget rule of yearly type and it's limit has been exceeded

campaign

quarterly_budget_exceeded

Campaign quarterly budget has already been reached

Returned if campaign has a budget rule of quarterly type and it's limit has been exceeded

campaign

monthly_budget_exceeded

Campaign monthly budget has already been reached

Returned if campaign has a budget rule of monthly type and it's limit has been exceeded

campaign

weekly_budget_exceeded

Campaign weekly budget has already been reached

Returned if campaign has a budget rule of weekly type and it's limit has been exceeded

campaign

daily_budget_exceeded

Campaign daily budget has already been reached

Returned if campaign has a budget rule of daily type and it's limit has been exceeded

campaign

hourly_budget_exceeded

Campaign hourly budget has already been reached

Returned if campaign has a budget rule of hourly type and it's limit has been exceeded

customer

new_customer_required

Customer needs to be a new customer

Returned if campaign has new customer rule applied and provided customer has redeemed any voucher in the past

customer

per_customer_limit_exceeded

Customer has already reached maximum number of redemptions

Returned if campaign has per customer rule applied and customer had exceeded limit of redemptions defined

customer

time_limit_expired

Customer can no longer reedem this discount

Returned if campaigns has subscription rule

customer

redemptions_limit_exceeded

Customer has already reached maximum number of redemptions

Returned if campaigns has subscription rule

customer

does_not_match_assigned_customer

Customer does not match customer identifier associated with the voucher

Returned if a voucher has customer identifier assigned and identifier provided for a redemption doesn't match

customer

required

Customer identifier is required to redeem this voucher

Returned if voucher is has customer identifier assigned but no identifier was provided for a redemption

origin_redemption

not_original

Origin redemption can not be a re-redemption

Returned if campaigns has subscription rule

total_transaction_cost

not_a_number

Total transaction cost must be a decimal number

total_transaction_cost

below_campaign_minimum

Total transaction cost must be greater than or equal to the campaign minimum of %{count}

Returned if campaign has minimum value set and a redemption total transaction value is below that value

total_transaction_cost

above_campaign_maximum

Total transaction cost must be less than or equal to the campaign maximum of %{count}

Returned if campaign has maximum value set and a redemption total transaction value is above that value

transaction_id

required

Transaction ID is required

transaction_id

must_be_unique

Transaction ID must be unique