Publisher/Experiment
Compare ad units
Takes a list of the publisher’s configs (ad units) and returns only the settings that differ between them, with readable setting names. Used before creating an experiment to confirm what is being tested.
GET
/
v1
/
tag
/
{uid}
/
experiment
/
compare
Compare ad units
curl --request GET \
--url https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare', 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/tag/{uid}/experiment/compare",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"config_id": 8390,
"real_allocation": 0,
"allocation": "n/a",
"unit": "iab",
"label": "MPU 2",
"status": 0,
"config": {
"In View": true
}
},
{
"config_id": 8391,
"real_allocation": 0,
"allocation": "n/a",
"unit": "iab",
"label": "MPU 2 (no in-view)",
"status": 0,
"config": {
"In View": false
}
}
],
"success": true
}{
"success": false,
"message": "Token not found."
}{
"success": false,
"message": "User forbidden"
}{
"success": false,
"message": "Resource not found"
}{
"status": 500,
"message": "An error occurred [4f2k], please try again shortly or contact your account manager for further assistance."
}Authorizations
Query Parameters
Was this page helpful?
⌘I
Compare ad units
curl --request GET \
--url https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare', 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/tag/{uid}/experiment/compare",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tagdeliver.com/v1/tag/{uid}/experiment/compare")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"config_id": 8390,
"real_allocation": 0,
"allocation": "n/a",
"unit": "iab",
"label": "MPU 2",
"status": 0,
"config": {
"In View": true
}
},
{
"config_id": 8391,
"real_allocation": 0,
"allocation": "n/a",
"unit": "iab",
"label": "MPU 2 (no in-view)",
"status": 0,
"config": {
"In View": false
}
}
],
"success": true
}{
"success": false,
"message": "Token not found."
}{
"success": false,
"message": "User forbidden"
}{
"success": false,
"message": "Resource not found"
}{
"status": 500,
"message": "An error occurred [4f2k], please try again shortly or contact your account manager for further assistance."
}