Create a new coupon campaign.
Notice
This API call does not contain the project_id
path-parameter, so you need to use the API key that is valid in all the company’s projects to set up authorization.
campaign_code required | string Campaign name. |
project_id required | integer Project ID. |
required | object Object containing localized campaign names. |
expiration_date | string <datetime> Campaign expiration date in the |
virtual_currency_amount | number <float> Virtual currency amount in a reward. |
object Array of virtual items parameters in a reward. | |
object Object containing subscription parameters in a reward. | |
redeems_count | integer Maximum number of coupon redeems. If |
redeems_count_for_user | integer Maximum number of coupon redeems per user. If |
campaign_redeems_count_for_user | integer Maximum number of coupon redeems per user within a campaign. If |
Created.
{- "campaign_code": "sample_campaign",
- "campaign_names": {
- "en": "Campaign Name",
- "ru": "Название кампании"
}, - "campaign_redeems_count_for_user": 1,
- "expiration_date": "2019-12-31",
- "project_id": 12345,
- "redeems_count": 10,
- "redeems_count_for_user": 1,
- "subscription_coupon": {
- "plan_id": 123,
- "product_id": 456,
- "trial_period": 30
}, - "virtual_currency_amount": 200
}
{- "id": 9134
}