Coupon Codes
Coupon Codes are a feature that allow you to track performance using codes unique to each partner. They are documented in detail on the Everflow Helpdesk/.
Find All
/v1/networks/couponcodes
Filters
This endpoint supports the following API filters. Refer to our User Guide for usage.
Value | Description |
---|---|
time_created | Filter based on the creation time |
time_saved | Filter based on the last update time |
coupon_status | Filter based on the coupon status |
coupon_code | Filter based on the coupon name |
network_offer_id | Filter based on the offer id |
network_affiliate_id | Filter based on the affiliate id |
Relationships
This endpoint supports the following additional relationships. Refer to our User Guide for usage.
Value | Description |
---|---|
offer | Includes the offer information |
affiliate | Includes the affiliate information |
Request Example
cURL
curl --request GET 'https://api.eflow.team/v1/networks/couponcodes' \
--header 'X-Eflow-API-Key: <INSERT API KEY>'
Response
{
"coupon_codes": [
{
"network_coupon_code_id": 1,
"network_id": 1,
"network_affiliate_id": 14,
"network_offer_id": 4,
"coupon_code": "Summer20",
"coupon_status": "active",
"internal_notes": "This coupon is only available to new customers",
"start_date": "2020-06-01",
"end_date": "2020-09-30"
}
]
}
Find By ID
/v1/networks/couponcodes/:couponCodeId
Path Parameters
Parameter | Description |
---|---|
couponCodeId | The ID of the coupon code you want to fetch |
Request Example
cURL
curl --request GET 'https://api.eflow.team/v1/networks/couponcodes/1' \
--header 'X-Eflow-API-Key: <INSERT API KEY>'
Response
{
"network_coupon_code_id": 1,
"network_id": 1,
"network_affiliate_id": 14,
"network_offer_id": 4,
"coupon_code": "Summer20",
"coupon_status": "paused",
"internal_notes": "This coupon is only available to new customers",
"start_date": "2020-06-01",
"end_date": "2020-09-30"
}
Create
/v1/networks/couponcodes
Body Params
ID of the Affiliate for which the coupon applies.
ID of the offer for which the coupon applies.
Coupon code value
Status of the coupon code. Can be one of the following values: active
or paused
.
Notes for internal usage.
An optional date starting at which the coupon code can be used
An optional date at which the coupon code becomes obsolete
Payload Example
{
"network_coupon_code_id": 1,
"network_id": 1,
"network_affiliate_id": 14,
"network_offer_id": 4,
"coupon_code": "Summer20",
"coupon_status": "active",
"internal_notes": "This coupon is only available to new customers",
"start_date": "2020-06-01",
"end_date": "2020-09-30"
}
Update
/v1/networks/couponcodes/:couponCodeId
You must specify all the fields, not only the ones you wish to update.
If you omit a field that is not marked as required, its default value will be used.
Path Parameters
Parameter | Description |
---|---|
couponCodeId | The ID of the coupon code you want to update |
Body Params
ID of the Affiliate for which the coupon applies.
ID of the offer for which the coupon applies.
Coupon code value
Status of the coupon code. Can be one of the following values: active
or paused
.
Notes for internal usage.
An optional date starting at which the coupon code can be used
An optional date at which the coupon code becomes obsolete
Payload Example
{
"network_coupon_code_id": 1,
"network_id": 1,
"network_affiliate_id": 14,
"network_offer_id": 4,
"coupon_code": "Summer20",
"coupon_status": "paused",
"internal_notes": "This coupon is only available to new customers",
"start_date": "2020-06-01",
"end_date": "2020-09-30"
}
Delete
/v1/networks/couponcodes/:couponCodeId
Path Parameters
Parameter | Description |
---|---|
couponCodeId | The ID of the coupon code you want to delete |
Request Example
cURL
curl --request DELETE 'https://api.eflow.team/v1/networks/couponcodes/1' \
--header 'X-Eflow-API-Key: <INSERT API KEY>'
Response
{
"result": true
}