Batch-reassign brought creatives to placements
curl --request POST \
--url https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"mappings": [
{
"creative_id": "<string>",
"format_ids": [
{
"agent_url": "<string>",
"id": "<string>"
}
]
}
]
}
'import requests
url = "https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements"
payload = { "mappings": [
{
"creative_id": "<string>",
"format_ids": [
{
"agent_url": "<string>",
"id": "<string>"
}
]
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
mappings: [
{creative_id: '<string>', format_ids: [{agent_url: '<string>', id: '<string>'}]}
]
})
};
fetch('https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"coverage": {
"total_placements": 0,
"covered_placements": 0
},
"files": [
{
"file_id": "<string>",
"filename": "<string>",
"detected": {
"dimensions": "<string>",
"duration": "<string>",
"codec": "<string>",
"bitrate": "<string>",
"frameRate": "<string>",
"sampleRate": "<string>",
"container": "<string>",
"fileSize": "<string>",
"tagType": "<string>"
},
"suggestion": "<string>",
"format_incompatible": "<string>",
"preview_url": "<string>",
"message": "<string>",
"suggestions": [
"<string>"
],
"accepts_context": true,
"placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"product_name": "<string>"
}
]
}
],
"campaign_id": "<string>",
"campaign_name": "<string>",
"missing_placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"spec_label": "<string>",
"product_name": "<string>"
}
],
"available_placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"spec_label": "<string>",
"product_name": "<string>"
}
],
"truncated": true,
"unreadable_placements": 4503599627370496,
"skipped_files_notice": "<string>",
"skipped_files": [
"<string>"
]
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}Creatives
Batch-reassign brought creatives to placements
Buyer-creative-v2 (feature-flagged). Reassigns several already-attached creatives to placements in one call (the card’s “Save mappings” commit), then returns the refreshed confirmation card once. mappings is [{ creative_id, format_id }]. Returns 404 for callers not enrolled in the flag.
POST
/
campaigns
/
{campaignId}
/
creatives
/
placements
Batch-reassign brought creatives to placements
curl --request POST \
--url https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"mappings": [
{
"creative_id": "<string>",
"format_ids": [
{
"agent_url": "<string>",
"id": "<string>"
}
]
}
]
}
'import requests
url = "https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements"
payload = { "mappings": [
{
"creative_id": "<string>",
"format_ids": [
{
"agent_url": "<string>",
"id": "<string>"
}
]
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
mappings: [
{creative_id: '<string>', format_ids: [{agent_url: '<string>', id: '<string>'}]}
]
})
};
fetch('https://api.interchange.io/api/v2/buyer/campaigns/{campaignId}/creatives/placements', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"coverage": {
"total_placements": 0,
"covered_placements": 0
},
"files": [
{
"file_id": "<string>",
"filename": "<string>",
"detected": {
"dimensions": "<string>",
"duration": "<string>",
"codec": "<string>",
"bitrate": "<string>",
"frameRate": "<string>",
"sampleRate": "<string>",
"container": "<string>",
"fileSize": "<string>",
"tagType": "<string>"
},
"suggestion": "<string>",
"format_incompatible": "<string>",
"preview_url": "<string>",
"message": "<string>",
"suggestions": [
"<string>"
],
"accepts_context": true,
"placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"product_name": "<string>"
}
]
}
],
"campaign_id": "<string>",
"campaign_name": "<string>",
"missing_placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"spec_label": "<string>",
"product_name": "<string>"
}
],
"available_placements": [
{
"placement_id": "<string>",
"placement_name": "<string>",
"spec_label": "<string>",
"product_name": "<string>"
}
],
"truncated": true,
"unreadable_placements": 4503599627370496,
"skipped_files_notice": "<string>",
"skipped_files": [
"<string>"
]
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}{
"data": null,
"error": {
"code": "<string>",
"message": "<string>",
"field": "<string>",
"details": {}
}
}Authorizations
API key or access token
Path Parameters
Body
application/json
Required array length:
1 - 50 elementsShow child attributes
Show child attributes
Response
Batch-reassign brought creatives to placements
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Required range:
1 <= x <= 9007199254740991⌘I