Campaign
List campaign
This API provides the data of created campaigns for the current user's organization
curl -X POST -H X-API-Key: <API_KEY> -d '`{"page": {"offset":0, "limit": 100}`, "filter":`{"networkVendor":"<vendor name>", "externalCampaignId": "<external campaign id>"}`}'
https://api.justtrack.io/management/v0/campaigns
Request
{
"page": {
"offset": 0,
"limit": 100
},
"filter": {
"networkVendor": "<networkVendor>",
"externalCampaignId": "<external campaign id>"
}
}
Name | Type | Description |
---|---|---|
offset | int | offset clause skips the offset rows before beginning to return the response. Default 0 |
limit | int | limit determines the number of campaigns returned in the response. Default 100 |
networkVendor | string | networkVendor determines the supported network vendor. Not required |
externalCampaignId | string | externalCampaignId determines the network-specific campaign ID. Not required |
Response
{
"result": [
{
"id": int,
"campaignTypeId": int,
"goalId": int,
"name": "string",
"networkId": int,
"optimizationType": "string",
"clientId": int,
"createdAt": "string",
"updatedAt": "string",
"attributes": [
{
"name": "fb_adgroup_id",
"value": "string"
},
{
"name": "fb_adset_id",
"value": "string"
},
{
"name": "fb_campaign_id",
"value": "string"
},
{
"name": "act",
"value": "string"
}
]
}
]
}
Create campaign
This API allows you to create a campaign.
curl -X POST -H X-API-Key: <API_KEY>
https://api.justtrack.io/management/v0/campaign
Request
The general request to the Create Campaign API looks like:
{
"optimizationType": "string",
"campaignTypeId": int,
"externalCampaignId": string,
"clientId": int,
"networkId": int,
"countries": ["string", "string"],
"name": "string",
"attributes": [
{
"name": "string",
"value": "string"
},
...
]
}
Name | Type | Description |
---|---|---|
optimizationType | string | Available options are cpa or cpi . |
campaignTypeId | int | Available options are: 1 for acquisition, 2 for retargeting |
externalCampaignId | int | Source Campaign ID. Provided by the partner |
clientId | int | The ID of the client. You can obtain it by using the app API. |
networkId | int | The ID of the network. You can obtain it by using the network API. |
countries | []string | The list of the countries in ISO2 format. For example ["DE", "EN"]. |
name | string | The name of the new campaign. |
attributes | Attributes list | The attributes are network-specific data to link JustTrack with the Ad Partner. |
info
Depending on the partner, externalCampaignId
may refer to different fields, e.g. source campaign id
, campaign uuid
, ...
Attributes
Name | Type | Description |
---|---|---|
name | string | The attribute name specific for the Ad Partner. |
value | string | The attribute value specific for the Ad Partner. |
Attributes Facebook example:
"attributes": [
{
"name": "fb_adgroup_id",
"value": "string"
},
{
"name": "fb_adset_id",
"value": "string"
},
{
"name": "fb_campaign_id",
"value": "string"
},
{
"name": "act",
"value": "string"
}
]
Response
{
"id": int,
"active": boolean
}