Get campaigns¶
GET
*base*/campaigns
GET
*base*/campaigns/*campaignId*
Fetches a specific campaign referenced by its ID, or the full campaigns list.
If the campaignId
parameter is specified, one campaign is fetched, otherwise all campaigns are fetched.
Parameters¶
int
optional
|
Campaign ID as integer. |
Response¶
200
Content-type: application/json
object key brand object
required
|
The
|
Response example¶
Fetching a list of campaigns:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | HTTP/1.1 200 OK
Content-type: application/json
{
"5": {
"name" : "Outlet",
"campaign" : "5",
"markets" : {
"16" : {
"pricelists" : {
"47" : {
"productsOnSale" : [
"2194",
"2172",
"1639",
]
}
}
}
}
}
}
|
Fetching a specific campaign using campaignId
:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | HTTP/1.1 200 OK
Content-type: application/json
{
"name" : "Outlet",
"campaign" : "5",
"markets" : {
"16" : {
"pricelists" : {
"47" : {
"productsOnSale" : [
"2194",
"2172",
"1639",
]
}
}
}
}
}
|
Error example¶
1 2 3 4 5 6 7 8 | HTTP/1.1 404 Not Found
Content-type: application/json
{
"errors" : {
"campaign" : "not found"
}
}
|