The promo code object

The promo code object holds information about a promo code being used in your program. You can create, retrieve, update, and delete a promo code, as well as list all promo codes.

Attributes


Id integer

Unique identifier for the object referred to as the impact.com Promo Code Id_.


Code string

The promo code.


Type enum

Matching type of the promo code.

View possible enum values
LIEXACT match type. When a customer enters a promo code on a store page, it must exactly match how it was entered in impact.com to be tracked.
REREGEX match type. When a customer enters a promo code on a store page, it must match the regular expression of how the promo code was entered in impact.com to be tracked. Learn more about regular expression. Test a regular expression.

CreditPolicy enum

Promo code's credit policy.

View possible enum values
ALWAYSPromo code's assigned partner will always be credited with the sale.
INVOLVEDPromo code's assigned partner will be credited with the sale if they were involved in driving it.
WINNERPromo code's assigned partner will be credited with the sale if they drove the last click.

CampaignId integer

Program Id associated with the promo code.


CampaignName string

Program name associated with the promo code.


AssignedPartnerId integer

Partner Id that was assigned the promo code.


AssignedPartnerName string

Partner name that was assigned the promo code.


CreatedDate string

Date and time the promo code was created. See ISO 8601.


StartDate string

Date and time the promo code starts. See ISO 8601.


EndDate string

Date and time the promo code ends. See ISO 8601.


State enum

State of a promo code.

View possible enum values
ACTIVEPromo is currently live.
INACTIVEPromo code is not currently active.

DealId integer

Deal Id associated with the promo code.


Uri string

Promo code's direct URI to view only one specific promo code.

More attributes

Click to view...

DealName string

Deal associated with the promo code.


DealDescription string

Deal description associated with the promo code.


DealState enum

Deal state associated with the promo code. Will be empty if no deal is associated with the promo code.

View possible enum values
ACTIVE Deal is currently active.
EXPIRED Deal is not currently active.
PENDING Deal is currently waiting for approval.

DealType enum

Deal type associated with the promo code. Will be empty if no deal is associated with the promo code.

View possible enum values
GENERAL_SALE Deal applies a general discount to the products identified in `DealScope`.
FREE_SHIPPING Deal applies free shipping to the order.
GIFT_WITH_PURCHASE A gift will come with the order.
REBATE A rebate will be available to the customer upon purchase.
BOGO Deal will apply a buy-one-get-one deal to the order.

DealScope enum

Deal scope associated with the promo code. Will be empty if no deal is associated with the promo code or if DealType=BOGO.

View possible enum values
CATEGORY Deal applies to a category of products.
ENTIRE_STORE Deal applies to the entire store.
PRODUCT Deal only applies to a specific product or a specific group of products.

DealProducts array

If DealScope: "PRODUCT", then product info appears. Child attributes will also appear.

View child attributes

ProductName string

Product's name.


ProductImageURL string

Product's image URL


ProductBeforePriceAmount integer

Product's price prior to the deal applying.


ProductBeforePriceCurrency string

Product's currency code prior to the deal applying. See ISO 4217.


ProductAfterPriceAmount integer

Product's price after the deal applies.


ProductAfterPriceCurrency string

Product's currency code after the deal applies. See ISO 4217.


DealCategories string

If DealScope="CATEGORY", then category info appears.


DiscountType enum

Type of deal discount associated with the promo code.

View possible enum values
FIXED Deal applies a fixed discount to the deal scope.
PERCENT Deal applies a percentage off of the deal scope.
PERCENT_RANGE Deal applies a percent within the percentage range off of the deal scope.
PERCENT_MAXIMUM Deal applies up to a certain percentage off of the deal scope.

DiscountAmount decimal

If DiscountType="FIXED", then the discount amount appears.


DiscountCurrency string

If DiscountType="FIXED", then the discount currency code appears. See ISO 4217.


DiscountPercent integer

If DiscountType="PERCENT", then the discount percent appears.


DiscountMaximumPercent integer

If DiscountType="PERCENT_MAXIMUM", then the maximum discount percentage appears.


DiscountPercentRangeStart integer

If DiscountType="PERCENT RANGE", then the discount range beginning appears.


DiscountPercentRangeEnd integer

If DiscountType="PERCENT_RANGE", then the discount range end appears.


Gift string

If DealType="GIFT_WITH_PURCHASE", then the gift's name appears.


RebateAmount integer

If DealType="REBATE", then the rebate's amount appears.


RebateCurrency string

If DealType="REBATE", then the rebate's currency code appears. See ISO 4217.


DealDefaultPromoCode string

Associated deal's default promo code.


MinimumPurchaseAmount integer

Associated deal's minimum purchase amount.


MinimumPurchaseAmountCurrency string

Currency of the associated deal's minimum purchase amount. See ISO 4217.


MaximumSavingsAmount integer

Associated deal's maximum purchase savings.


MaximumSavingsCurrency string

Currency of the associated deal's maximum purchase savings. See ISO 4217.


BogoBuyQuantity integer

If DealType="BOGO", the "buy" amount appears.


BogoBuyScope enum

if DealType="BOGO", the "buy" scope appears. Will be empty if DealType≠BOGO.

View possible enum values
CATEGORY Deal applies to a category of products.
ENTIRE_STORE Deal applies to entire store.
PRODUCT Deal only applies to a specific product or a specific group of products.

BogoBuyName string

If DealType="BOGO", the "buy" product name appears.


BogoBuyImageUrl string

If DealType="BOGO", the "buy" product image URL appears.


BogoGetQuantity integer

If DealType="BOGO", the "get" amount appears.


BogoGetScope enum

If DealType="BOGO", the "get" scope appears. Will be empty if DealType≠"BOGO".

        <tr>
            <td>
                <code>CATEGORY</code>
            </td>
            <td>Deal applies to a category of products.</td>
        </tr>
View possible enum values
ENTIRE_STORE Deal applies to entire store.
PRODUCT Deal only applies to a specific product or a specific group of products.

BogoGetDiscountType enum

If DealType="BOGO", the "get" discount type appears. Will be empty if DealType≠"BOGO".

View possible enum values
FREE Customer will receive the `GET` item for free.
AMOUNT Customer will receive a specific amount of money off of the `GET` item's cost.
PERCENT Customer will receive a percent off of the `GET` item's cost.

BogoGetName string

If DealType="BOGO", the "get" product name appears.


BogoGetImageUrl string

If DealType="BOGO", the "get" product image URL appears.


BogoGetDiscountAmount decimal

If BogoGetDiscountType="AMOUNT", the "get" discount amount appears.


BogoGetDiscountCurrency string

If BogoGetDiscountType="AMOUNT", the currency of the "get" discount amount appears.


BogoGetDiscountPercent integer

If BogoGetDiscountType="PERCENT", the "get" discount percent appears.


PurchaseLimitQuantity integer

If DealType="BOGO", the amount of "buy" product purchasable at once. If 0, no purchase limit.


DealStartDate string

Associated deal's start date. See ISO 8601.


DealEndDate string

Associated deal's end date. See ISO 8601.


SynchAdsPromoCodes boolean

Has the value true if the associated deal aligns the state and date range of all ads and promo codes to the deal's. Has the value false if the associated deal does not have this.


DealRestrictedMediaPartners string

A comma-separated string of the partners that can use the associated deal.


DealRestrictedMediaPartnerGroups string

A comma-separated string of the partner groups that can use the associated deal.

{
  "Id": "7777777",
  "Code": "APlusAnvils",
  "Type": "RE",
  "CreditPolicy": "ALWAYS",
  "CampaignId": "1000",
  "CampaignName": "AcmeCampaign",
  "AssignedPartnerId": "10000",
  "AssignedPartnerName": "AcmePartner",
  "CreatedDate": "2020-12-11T10:10:07-08:00",
  "StartDate": "2020-12-11T10:10:07-08:00",
  "EndDate": "",
  "State": "ACTIVE",
  "DealId": "00003",
  "DealName": "AcmeDeal3",
  "DealDescription": "",
  "DealState": "ACTIVE",
  "DealType": "GENERAL_SALE",
  "DealScope": "PRODUCT",
  "DealProducts": [
    {
	    "ProductName": "Gray Anvil",
      "ProductImageUrl": "/images/Gray_Anvil.png",
      "ProductBeforePriceAmount": "50.00",
      "ProductBeforePriceCurrency": "USD",
      "ProductAfterPriceAmount": "45.00",
      "ProductAfterPriceCurrency": "USD"
     }
  ],
  "DealCategories": "",
  "DiscountType": "FIXED",
  "DiscountAmount": "5.00",
  "DiscountCurrency": "USD",
  "DiscountPercent": "",
  "DiscountMaximumPercent": "",
  "DiscountPercentRangeStart": "",
  "DiscountPercentRangeEnd": "",
  "Gift": "",
  "RebateAmount": "",
  "RebateCurrency": "",
  "DealDefaultPromoCode": "APlusAnvils",
  "MinimumPurchaseAmount": "",
  "MinimumPurchaseAmountCurrency": "",
  "MaximumSavingsAmount": "",
  "MaximumSavingsCurrency": "",
  "BogoBuyQuantity": "0",
  "BogoBuyScope": "",
  "BogoBuyName": "",
  "BogoBuyImageUrl": "",
  "BogoGetQuantity": "0",
  "BogoGetScope": "",
  "BogoGetDiscountType": "",
  "BogoGetName": "",
  "BogoGetImageUrl": "",
  "BogoGetDiscountAmount": "",
  "BogoGetDiscountCurrency": "",
  "BogoGetDiscountPercent": "",
  "PurchaseLimitQuantity": "0",
  "DealStartDate": "",
  "DealEndDate": "",
  "SynchAdsPromoCodes": "false",
  "DealRestrictedMediaPartners": [],
  "DealRestrictedMediaPartnerGroups": [],
  "Uri": "/Advertisers/<AccountSID>/PromoCodes/7777777"
}
{
  "Id": "7777777",
  "Code": "Acme20",
  "Type": "LI",
  "CreditPolicy": "ALWAYS",
  "CampaignId": "1000",
  "CampaignName": "AcmeCampaign",
  "AssignedPartnerId": "10000",
  "AssignedPartnerName": "AcmePartner",
  "CreatedDate": "2020-09-10T10:51:23-07:00",
  "StartDate": "2020-12-11T10:12:39-08:00",
  "EndDate": "2020-12-11T10:13:06-08:00",
  "State": "ACTIVE",
  "DealId": "98765",
  "DealName": "Acme Deal2",
  "DealDescription": "",
  "DealState": "ACTIVE",
  "DealType": "GENERAL_SALE",
  "DealScope": "CATEGORY",
  "DealProducts": [],
  "DealCategories": "Anvils",
  "DiscountType": "FIXED",
  "DiscountAmount": "20.00",
  "DiscountCurrency": "USD",
  "DiscountPercent": "",
  "DiscountMaximumPercent": "",
  "DiscountPercentRangeStart": "",
  "DiscountPercentRangeEnd": "",
  "Gift": "",
  "RebateAmount": "",
  "RebateCurrency": "",
  "DealDefaultPromoCode": "Acme20",
  "MinimumPurchaseAmount": "",
  "MinimumPurchaseAmountCurrency": "",
  "MaximumSavingsAmount": "",
  "MaximumSavingsCurrency": "",
  "BogoBuyQuantity": "0",
  "BogoBuyScope": "",
  "BogoBuyName": "",
  "BogoBuyImageUrl": "",
  "BogoGetQuantity": "0",
  "BogoGetScope": "",
  "BogoGetDiscountType": "",
  "BogoGetName": "",
  "BogoGetImageUrl": "",
  "BogoGetDiscountAmount": "",
  "BogoGetDiscountCurrency": "",
  "BogoGetDiscountPercent": "",
  "PurchaseLimitQuantity": "0",
  "DealStartDate": "",
  "DealEndDate": "",
  "SynchAdsPromoCodes": "false",
  "DealRestrictedMediaPartners": [],
  "DealRestrictedMediaPartnerGroups": [],
  "Uri": "/Advertisers/<AccountSID>/PromoCodes/7777777"
}
{
  "Id": "7777777",
  "Code": "Acme BOGO10",
  "Type": "LI",
  "CreditPolicy": "ALWAYS",
  "CampaignId": "1000",
  "CampaignName": "AcmeCampaign",
  "AssignedPartnerId": "10000",
  "AssignedPartnerName": "AcmePartner",
  "CreatedDate": "2020-12-11T11:43:37-08:00",
  "StartDate": "2020-12-11T11:43:37-08:00",
  "EndDate": "",
  "State": "ACTIVE",
  "DealId": "00004",
  "DealName": "ACME BOGO Deal",
  "DealDescription": "",
  "DealState": "ACTIVE",
  "DealType": "BOGO",
  "DealScope": "",
  "DealProducts": [],
  "DealCategories": "",
  "DiscountType": "",
  "DiscountAmount": "",
  "DiscountCurrency": "",
  "DiscountPercent": "",
  "DiscountMaximumPercent": "",
  "DiscountPercentRangeStart": "",
  "DiscountPercentRangeEnd": "",
  "Gift": "",
  "RebateAmount": "",
  "RebateCurrency": "",
  "DealDefaultPromoCode": "ACME BOGO",
  "MinimumPurchaseAmount": "",
  "MinimumPurchaseAmountCurrency": "USD",
  "MaximumSavingsAmount": "",
  "MaximumSavingsCurrency": "",
  "BogoBuyQuantity": "1",
  "BogoBuyScope": "PRODUCT",
  "BogoBuyName": "Gray Anvil",
  "BogoBuyImageUrl": "",
  "BogoGetQuantity": "1",
  "BogoGetScope": "Product",
  "BogoGetDiscountType": "AMOUNT",
  "BogoGetName": "Hammer",
  "BogoGetImageUrl": "",
  "BogoGetDiscountAmount": "10.00",
  "BogoGetDiscountCurrency": "USD",
  "BogoGetDiscountPercent": "",
  "PurchaseLimitQuantity": "4",
  "DealStartDate": "2020-12-23T00:11:00-08:00",
  "DealEndDate": "2020-12-24T14:53:00-08:00",
  "SynchAdsPromoCodes": "false",
  "DealRestrictedMediaPartners": [],
  "DealRestrictedMediaPartnerGroups": [],
  "Uri": "/Advertisers/<AccountSID>/PromoCodes/7777777"
        }