Skip to content

ADC04 - Create Sponsored Product campaigns

Request

Bodyapplication/json
Array [
budgetnumber, (with decimals), [ 0 .. 10000000000000000000 ]required

Maximum amount the campaign is allowed to spend according to the selected budget type

Example:100
budget_typestringrequired

Campaign budget type

Enum: "DAILY", "LIFETIME"

Example:"DAILY"
end_datestring, (date)

When the campaign ends

Example:"2024-06-30"
insertion_orderstring

Insertion order of the campaign

modestringrequired

Campaign mode

Enum: "AUTO", "MANUAL"

Example:"MANUAL"
namestringrequired

Campaign name

on_behalf_of_agency_idstring

For 1P campaigns, Agency ID to create the campaign on behalf of

Example:"01966c73-ac9f-6122-7127-e84b2862830c"
opt_out_enabledboolean

Enable opt-out for this campaign. Requires publisher to have opt-out enabled at the account level.

Example:false
publisher_idstringrequired

Publisher id

Example:"99976f22-9900-adef-1235-bff3faaafff1"
start_datestring, (date)required

When the campaign starts

Example:"2024-06-14"
target_idstringrequired

Id of the targeted store or advertiser.
Is the store-id for stores imported through API (ADST01)
Is the shop_id, the identifier of the Mirakl Marketplace shop.

Example:"public_id_01"
target_typestringrequired

For a 1P campaign, use ADVERTISER. Else, for a 3P campaign, use STORE

Enum: "STORE", "ADVERTISER"

Example:"ADVERTISER"
]
curl -i -X POST \
  https://retailmedia.mirakl.net/api/v1/sp/campaigns \
  -H 'Content-Type: application/json' \
  -d '[
    {
      "budget": 100,
      "budget_type": "DAILY",
      "end_date": "2024-06-30",
      "insertion_order": "",
      "mode": "MANUAL",
      "name": "My campaign",
      "on_behalf_of_agency_id": "01966c73-ac9f-6122-7127-e84b2862830c",
      "publisher_id": "99976f22-9900-adef-1235-bff3faaafff1",
      "start_date": "2024-06-14",
      "target_id": "public_id_01",
      "target_type": "ADVERTISER"
    }
  ]'

Responses

OK

Bodyapplication/json
failureArray of objects

List of campaigns that failed registration

successArray of objects

List of campaigns successfully registered

Response
{ "failure": [ { … } ], "success": [ { … } ] }