Skip to main content
POST
/
v2
/
offer
  curl -X POST \
  'https://api.appcharge.com/v2/offer' \
  -H 'Content-Type: application/json' \
  -H 'x-publisher-token: <x-publisher-token>' \
  --data '{
      "publisherOfferId": "post-purchase-1",
      "name": "Purchase Reward Offer",
      "displayName": "Purchase Reward Offer",
      "description": "Post purchase offer for VIP players.",
      "type": "PopUp",
      "subType": "PostPurchase",
      "active": true,
      "priority": 1,
      "offerExternalUiId": "popup",
      "segments": [],
      "productsSequence": [
          {
              "index": 1,
              "products": [
                  {
                      "priority":"Main",
                      "publisherProductId": "TreasureChest",
                      "quantity": 10
                  }
              ],
              "priceInUsdCents": 2000
          }
      ]
  }'
{
  "publisherId": "35nb7861ec9924a6b69a0fe59",
  "publisherOfferId": "post-purchase-1",
  "name": "Purchase Reward Offer",
  "displayName": "Purchase Reward Offer",
  "description": "Post purchase offer for VIP players.",
  "type": "PopUp",
  "subType": "PostPurchase",
  "active": true,
  "segments": [],
  "offerUi": {
      "offerUiId": "68b41c5aa1c5b1a284737e9b",
      "active": true,
      "offerUiType": "PopUp",
      "name": "popup",
      "description": "description",
      "backgroundImage": "https://media.appcharge.com/media/35nb7861ec9924a6b69a0fe59/2755379465856__fa883338-5790-47c8-a6a0-23cb43db58844",
      "externalId": "popup"
  },
  "productsSequence": [
      {
          "index": 1,
          "products": [
              {
                  "product": {
                      "publisherProductId": "TreasureChest",
                      "name": "Treasure Chest",
                      "type": "Quantity",
                      "prefix": "$",
                      "suffix": "M",
                      "priority": "Main",
                      "images": [
                          {
                              "type": "product",
                              "url": "https://media.appcharge.com/media/35nb7861ec9924a6b69a0fe59/2208472.png"
                          },
                          {
                              "type": "productPrefix",
                              "url": ""
                          }
                      ],
                      "displayName": "Treasure Chest"
                  }
              }
          ]
      }
  ],
  "priority": 1,
  "showAfter": "purchase",
  "triggers": [
      {
          "type": "event",
          "eventName": "purchase",
          "every": 1,
          "rules": []
      }
  ],
  "createdAt": "2025-09-01T14:16:09.499Z",
  "updatedAt": "2025-09-01T14:16:09.499Z",
  "offerId": "68b5aaa9b73fceb9ffc26f9b"
}
  curl -X POST \
  'https://api.appcharge.com/v2/offer' \
  -H 'Content-Type: application/json' \
  -H 'x-publisher-token: <x-publisher-token>' \
  --data '{
      "publisherOfferId": "post-purchase-1",
      "name": "Purchase Reward Offer",
      "displayName": "Purchase Reward Offer",
      "description": "Post purchase offer for VIP players.",
      "type": "PopUp",
      "subType": "PostPurchase",
      "active": true,
      "priority": 1,
      "offerExternalUiId": "popup",
      "segments": [],
      "productsSequence": [
          {
              "index": 1,
              "products": [
                  {
                      "priority":"Main",
                      "publisherProductId": "TreasureChest",
                      "quantity": 10
                  }
              ],
              "priceInUsdCents": 2000
          }
      ]
  }'
{
  "publisherId": "35nb7861ec9924a6b69a0fe59",
  "publisherOfferId": "post-purchase-1",
  "name": "Purchase Reward Offer",
  "displayName": "Purchase Reward Offer",
  "description": "Post purchase offer for VIP players.",
  "type": "PopUp",
  "subType": "PostPurchase",
  "active": true,
  "segments": [],
  "offerUi": {
      "offerUiId": "68b41c5aa1c5b1a284737e9b",
      "active": true,
      "offerUiType": "PopUp",
      "name": "popup",
      "description": "description",
      "backgroundImage": "https://media.appcharge.com/media/35nb7861ec9924a6b69a0fe59/2755379465856__fa883338-5790-47c8-a6a0-23cb43db58844",
      "externalId": "popup"
  },
  "productsSequence": [
      {
          "index": 1,
          "products": [
              {
                  "product": {
                      "publisherProductId": "TreasureChest",
                      "name": "Treasure Chest",
                      "type": "Quantity",
                      "prefix": "$",
                      "suffix": "M",
                      "priority": "Main",
                      "images": [
                          {
                              "type": "product",
                              "url": "https://media.appcharge.com/media/35nb7861ec9924a6b69a0fe59/2208472.png"
                          },
                          {
                              "type": "productPrefix",
                              "url": ""
                          }
                      ],
                      "displayName": "Treasure Chest"
                  }
              }
          ]
      }
  ],
  "priority": 1,
  "showAfter": "purchase",
  "triggers": [
      {
          "type": "event",
          "eventName": "purchase",
          "every": 1,
          "rules": []
      }
  ],
  "createdAt": "2025-09-01T14:16:09.499Z",
  "updatedAt": "2025-09-01T14:16:09.499Z",
  "offerId": "68b5aaa9b73fceb9ffc26f9b"
}

Headers

x-publisher-token
string
required

The publisher token used for authentication.

Body

application/json
publisherOfferId
string
required

The unique identifier for the post purchase offer.

name
string
required

The name of the post purchase offer (at least 3 characters).

type
enum<string>
default:PopUp
required

The type of offer - In this case 'PopUp'.

Available options:
PopUp
subType
enum<string>
default:PostPurchase
required

The subType of the offer - In this case 'PostPurchase'.

Available options:
PostPurchase
active
boolean
required

Whether the post purchase offer is active.

priority
integer
required

The priority level of the post purchase popup. The priority start from 1 (1 being the highest priority).

productsSequence
object[]
required

The sequence of products included in the post purchase offer.

displayName
string

The display name of the post purchase offer. If not provided, the name will be used.

description
string

The description of the post purchase offer.

offerUiId
string

Internal ID for the Offer UI (required if offerExternalUiId not provided).

offerExternalUiId
string

The external UI ID for the post purchase offer.

triggers
object[]

An array of objects specifying the conditions under which the popup should be triggered.

segments
string[]

List of player segments that this post purchase offer applies to.

showAfter
enum<string>
default:purchase

The player action after which the offer is displayed.

Available options:
purchase
Example:

"purchase"

Response

Post purchase offer created successfully.

publisherId
string

Publisher ID.

offerId
string

The unique identifier of the post purchase popup.

publisherOfferId
string

The post purchase offer ID provided by the publisher. This is the offer's External ID value in the Publisher Dashboard.

name
string

The name of the post purchase popup.

displayName
string

The display name of the post purchase popup. If not provided, the name will be used.

description
string

The description of the post purchase popup (conditionally returned).

type
string

The type of offer.

subtype
string

The subType of the offer - In this case 'PostPurchase'.

active
boolean

Whether the post purchase popup is active.

segments
string[]

List of player segments that this post purchase popup applies to (e.g., ["NewUser", "BigSpender"]). This is empty by default.

showAfter
string

The player action after which the offer is displayed.

Example:

"purchase"

offerUi
object

UI configuration for the post purchase offer.

triggers
object[]

An array of objects specifying the conditions under which the popup should be triggered.

productsSequence
object[]

A sequence of products in the post purchase popup.

createdAt
string<date-time>

Date the post purchase offer was created.

updatedAt
string<date-time>

Date the post purchase offer was updated.

I