Skip to main content
GET
Validate a Campaign Code

Path Parameters

campaign
string
required

The id or the vid of the campaigns to retrieve.

code
string
required

The id or the vid of the campaigns to retrieve.

Response

JSON A full Campaigns object.

object
string

Value is “Campaign”

id
string

An aggregator-specified unique identifier. If not specified, this object can be identified by its vid

vid
string

A Globally Unique Identifier (GUID) for this object. Assigned by CashBox

Maximum string length: 128
name
string

Name of campaign.

description
string

Description of campaign.

state
enum<string>

Can be Active, Canceled, Complete, Inactive, MatchAnyState, Pending, Undefined

Available options:
Active,
Canceled,
Complete,
Inactive,
MatchAnyState,
Undefined,
Pending
offer_start_date
string<date-time>

The first date on which the offers may be redeemed.

offer_end_date
string<date-time>

The last date on which the offers may be redeemed.

campaign_discount_method
string

Not implemented specifies the discounting method either Compounded or Direct

type
string

specifies what type of campaign this is Coupon, Promotion, Voucher (Not implemented), Undefined. Campaign is Active.

percentage_discount
string<float>

Defines the discount as a percentage of the original Product price. Note:- flat_amount_discounts and percentage_discount are mutually exclusive. It can be either or but not both

apply_discount_per_item
string

Not implemented If true, discounts on items will be multiplied by the item quantity.

account_level_eligible
string

Not implemented Campaign can be applied to customer Accounts.

purchase_level_eligible
string

Not implemented Campaign can be applied to all items (i.e. subtotal) on a Transaction.

eligible_products
object

Zero or more eligible Products eligible for this Campaign

eligible_billing_plans
object

Zero or more eligible BillingPlans eligible for this Campaign

restrict_to_new_subscription
boolean

If true, Campaign offer only applies to new subscriptions, not existing ones

expiration_date
string<date-time>

Expiration date of a “Fixed” Campaign. “Rolling” Campaigns should leave this blank

number_of_periods
integer<int32>

Number of times the promotion repeats, e.g. if you want to discount 3 cycles of a biweekly subscription, this would be 3

period_length
enum<string>

Can be Day, Week, Month, Year, Hour, BillingCycle

Available options:
Day,
week,
Mopnth,
year,
Hour,
BillingCycle
promotion_code
string

The redemption code associated with the Promotion

promotion_code_aliases
object

An array of alternative redemption codes for the Promotion Note:- Setting this array will replace any existing list of aliases; it will not add new values to an existing list.

flat_amount_discounts
object[]
voucher_credit
object

The Credit object represents a service credit granted to an account or subscription, taking the form of either currency, token, or time amounts.

coupons
object[]
item_display_text
string

Name to be placed on ItemDiscounts generated for this Campaign.

max_redemptions_per_customer
integer<int32>

Maximum number of Campaign redemptions for any given customer account.

max_redemptions_per_autobill
integer<int32>

Maximum number of Campaign redemptions for any given subscription

apply_voucher_pre_transaction
boolean

Voucher credits should be applied before the initial Transaction is processed