/ad-stack/:id
curl --request PUT \
--url https://api.tagdeliver.com/v1/ad-stack/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"config": {
"ad_demand": {
"bidderTimeout": 50,
"syncDelay": 1000,
"priceGranularity": "dense",
"useBidCache": true,
"enableTIDs": false,
"s2sConfig": {
"timeout": 1000
},
"throttling": {
"thresholdType": "count",
"thresholdValue": 3,
"actions": {
"actionTarget": "page_view"
},
"scope": "ad_unit",
"filter": {
"type": "include",
"list": []
},
"enabled": true
}
},
"ad_server/2": {
"ad_unit": "jamiedruce.io__2",
"mcm": "5568767400"
},
"fallback/676": {
"weight": 1
},
"fallback/760": {
"weight": 1
}
},
"name": "Jamies Ad Stack",
"stack": [
{
"id": 2,
"type": "ad_server"
},
{
"id": 676,
"type": "fallback"
},
{
"id": 760,
"type": "fallback"
},
{
"id": 838,
"type": "ad_tech"
},
{
"id": 839,
"type": "ad_tech"
}
]
}
'import requests
url = "https://api.tagdeliver.com/v1/ad-stack/{id}"
payload = {
"config": {
"ad_demand": {
"bidderTimeout": 50,
"syncDelay": 1000,
"priceGranularity": "dense",
"useBidCache": True,
"enableTIDs": False,
"s2sConfig": { "timeout": 1000 },
"throttling": {
"thresholdType": "count",
"thresholdValue": 3,
"actions": { "actionTarget": "page_view" },
"scope": "ad_unit",
"filter": {
"type": "include",
"list": []
},
"enabled": True
}
},
"ad_server/2": {
"ad_unit": "jamiedruce.io__2",
"mcm": "5568767400"
},
"fallback/676": { "weight": 1 },
"fallback/760": { "weight": 1 }
},
"name": "Jamies Ad Stack",
"stack": [
{
"id": 2,
"type": "ad_server"
},
{
"id": 676,
"type": "fallback"
},
{
"id": 760,
"type": "fallback"
},
{
"id": 838,
"type": "ad_tech"
},
{
"id": 839,
"type": "ad_tech"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
config: {
ad_demand: {
bidderTimeout: 50,
syncDelay: 1000,
priceGranularity: 'dense',
useBidCache: true,
enableTIDs: false,
s2sConfig: {timeout: 1000},
throttling: {
thresholdType: 'count',
thresholdValue: 3,
actions: {actionTarget: 'page_view'},
scope: 'ad_unit',
filter: {type: 'include', list: []},
enabled: true
}
},
'ad_server/2': {ad_unit: 'jamiedruce.io__2', mcm: '5568767400'},
'fallback/676': {weight: 1},
'fallback/760': {weight: 1}
},
name: 'Jamies Ad Stack',
stack: [
{id: 2, type: 'ad_server'},
{id: 676, type: 'fallback'},
{id: 760, type: 'fallback'},
{id: 838, type: 'ad_tech'},
{id: 839, type: 'ad_tech'}
]
})
};
fetch('https://api.tagdeliver.com/v1/ad-stack/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tagdeliver.com/v1/ad-stack/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'config' => [
'ad_demand' => [
'bidderTimeout' => 50,
'syncDelay' => 1000,
'priceGranularity' => 'dense',
'useBidCache' => true,
'enableTIDs' => false,
's2sConfig' => [
'timeout' => 1000
],
'throttling' => [
'thresholdType' => 'count',
'thresholdValue' => 3,
'actions' => [
'actionTarget' => 'page_view'
],
'scope' => 'ad_unit',
'filter' => [
'type' => 'include',
'list' => [
]
],
'enabled' => true
]
],
'ad_server/2' => [
'ad_unit' => 'jamiedruce.io__2',
'mcm' => '5568767400'
],
'fallback/676' => [
'weight' => 1
],
'fallback/760' => [
'weight' => 1
]
],
'name' => 'Jamies Ad Stack',
'stack' => [
[
'id' => 2,
'type' => 'ad_server'
],
[
'id' => 676,
'type' => 'fallback'
],
[
'id' => 760,
'type' => 'fallback'
],
[
'id' => 838,
'type' => 'ad_tech'
],
[
'id' => 839,
'type' => 'ad_tech'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tagdeliver.com/v1/ad-stack/{id}"
payload := strings.NewReader("{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.tagdeliver.com/v1/ad-stack/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tagdeliver.com/v1/ad-stack/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": {
"id": 338
},
"success": true
}Ad Stack
/ad-stack/:id
Updates an existing ad stack. Call the /v1/integration?target=ad_stack endpoint to find available integrations, and call the /v1/integration/{id}/stack-schema endpoint to find the field requirements for each integration.
PUT
/
v1
/
ad-stack
/
{id}
/ad-stack/:id
curl --request PUT \
--url https://api.tagdeliver.com/v1/ad-stack/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"config": {
"ad_demand": {
"bidderTimeout": 50,
"syncDelay": 1000,
"priceGranularity": "dense",
"useBidCache": true,
"enableTIDs": false,
"s2sConfig": {
"timeout": 1000
},
"throttling": {
"thresholdType": "count",
"thresholdValue": 3,
"actions": {
"actionTarget": "page_view"
},
"scope": "ad_unit",
"filter": {
"type": "include",
"list": []
},
"enabled": true
}
},
"ad_server/2": {
"ad_unit": "jamiedruce.io__2",
"mcm": "5568767400"
},
"fallback/676": {
"weight": 1
},
"fallback/760": {
"weight": 1
}
},
"name": "Jamies Ad Stack",
"stack": [
{
"id": 2,
"type": "ad_server"
},
{
"id": 676,
"type": "fallback"
},
{
"id": 760,
"type": "fallback"
},
{
"id": 838,
"type": "ad_tech"
},
{
"id": 839,
"type": "ad_tech"
}
]
}
'import requests
url = "https://api.tagdeliver.com/v1/ad-stack/{id}"
payload = {
"config": {
"ad_demand": {
"bidderTimeout": 50,
"syncDelay": 1000,
"priceGranularity": "dense",
"useBidCache": True,
"enableTIDs": False,
"s2sConfig": { "timeout": 1000 },
"throttling": {
"thresholdType": "count",
"thresholdValue": 3,
"actions": { "actionTarget": "page_view" },
"scope": "ad_unit",
"filter": {
"type": "include",
"list": []
},
"enabled": True
}
},
"ad_server/2": {
"ad_unit": "jamiedruce.io__2",
"mcm": "5568767400"
},
"fallback/676": { "weight": 1 },
"fallback/760": { "weight": 1 }
},
"name": "Jamies Ad Stack",
"stack": [
{
"id": 2,
"type": "ad_server"
},
{
"id": 676,
"type": "fallback"
},
{
"id": 760,
"type": "fallback"
},
{
"id": 838,
"type": "ad_tech"
},
{
"id": 839,
"type": "ad_tech"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
config: {
ad_demand: {
bidderTimeout: 50,
syncDelay: 1000,
priceGranularity: 'dense',
useBidCache: true,
enableTIDs: false,
s2sConfig: {timeout: 1000},
throttling: {
thresholdType: 'count',
thresholdValue: 3,
actions: {actionTarget: 'page_view'},
scope: 'ad_unit',
filter: {type: 'include', list: []},
enabled: true
}
},
'ad_server/2': {ad_unit: 'jamiedruce.io__2', mcm: '5568767400'},
'fallback/676': {weight: 1},
'fallback/760': {weight: 1}
},
name: 'Jamies Ad Stack',
stack: [
{id: 2, type: 'ad_server'},
{id: 676, type: 'fallback'},
{id: 760, type: 'fallback'},
{id: 838, type: 'ad_tech'},
{id: 839, type: 'ad_tech'}
]
})
};
fetch('https://api.tagdeliver.com/v1/ad-stack/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.tagdeliver.com/v1/ad-stack/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'config' => [
'ad_demand' => [
'bidderTimeout' => 50,
'syncDelay' => 1000,
'priceGranularity' => 'dense',
'useBidCache' => true,
'enableTIDs' => false,
's2sConfig' => [
'timeout' => 1000
],
'throttling' => [
'thresholdType' => 'count',
'thresholdValue' => 3,
'actions' => [
'actionTarget' => 'page_view'
],
'scope' => 'ad_unit',
'filter' => [
'type' => 'include',
'list' => [
]
],
'enabled' => true
]
],
'ad_server/2' => [
'ad_unit' => 'jamiedruce.io__2',
'mcm' => '5568767400'
],
'fallback/676' => [
'weight' => 1
],
'fallback/760' => [
'weight' => 1
]
],
'name' => 'Jamies Ad Stack',
'stack' => [
[
'id' => 2,
'type' => 'ad_server'
],
[
'id' => 676,
'type' => 'fallback'
],
[
'id' => 760,
'type' => 'fallback'
],
[
'id' => 838,
'type' => 'ad_tech'
],
[
'id' => 839,
'type' => 'ad_tech'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tagdeliver.com/v1/ad-stack/{id}"
payload := strings.NewReader("{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.tagdeliver.com/v1/ad-stack/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tagdeliver.com/v1/ad-stack/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"config\": {\n \"ad_demand\": {\n \"bidderTimeout\": 50,\n \"syncDelay\": 1000,\n \"priceGranularity\": \"dense\",\n \"useBidCache\": true,\n \"enableTIDs\": false,\n \"s2sConfig\": {\n \"timeout\": 1000\n },\n \"throttling\": {\n \"thresholdType\": \"count\",\n \"thresholdValue\": 3,\n \"actions\": {\n \"actionTarget\": \"page_view\"\n },\n \"scope\": \"ad_unit\",\n \"filter\": {\n \"type\": \"include\",\n \"list\": []\n },\n \"enabled\": true\n }\n },\n \"ad_server/2\": {\n \"ad_unit\": \"jamiedruce.io__2\",\n \"mcm\": \"5568767400\"\n },\n \"fallback/676\": {\n \"weight\": 1\n },\n \"fallback/760\": {\n \"weight\": 1\n }\n },\n \"name\": \"Jamies Ad Stack\",\n \"stack\": [\n {\n \"id\": 2,\n \"type\": \"ad_server\"\n },\n {\n \"id\": 676,\n \"type\": \"fallback\"\n },\n {\n \"id\": 760,\n \"type\": \"fallback\"\n },\n {\n \"id\": 838,\n \"type\": \"ad_tech\"\n },\n {\n \"id\": 839,\n \"type\": \"ad_tech\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": {
"id": 338
},
"success": true
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
application/json
Lists the connected integrations
Show child attributes
Show child attributes
Fields configured for any integration in the stack. Key is in the format {integration_type}/{integration_type} or simply ad_demand for overaching configuration options. Value of each key is an object specific to that integration (integration schemas can be retrieved from /ad-stack/integration/:type/:id)
Was this page helpful?
⌘I