Get User Spots
curl --request GET \
--url https://api.adgreg.com/user-spots \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.adgreg.com/user-spots"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.adgreg.com/user-spots', 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.adgreg.com/user-spots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$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.adgreg.com/user-spots"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
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.adgreg.com/user-spots")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.adgreg.com/user-spots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"page": 123,
"sites": 123,
"page_size": 123,
"page_count": 123,
"response": [
{
"website": "<string>",
"website_id": 123,
"configured_spots": [
{
"adnetwork": "<string>",
"api_spot_id": "<string>",
"api_spot_name": "<string>",
"user_spot_type": "<string>",
"api_site_id": "<string>",
"api_site_name": "<string>"
}
]
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Dashboard configuration
Get user spots
GET
/
user-spots
Get User Spots
curl --request GET \
--url https://api.adgreg.com/user-spots \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.adgreg.com/user-spots"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.adgreg.com/user-spots', 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.adgreg.com/user-spots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$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.adgreg.com/user-spots"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
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.adgreg.com/user-spots")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.adgreg.com/user-spots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"page": 123,
"sites": 123,
"page_size": 123,
"page_count": 123,
"response": [
{
"website": "<string>",
"website_id": 123,
"configured_spots": [
{
"adnetwork": "<string>",
"api_spot_id": "<string>",
"api_spot_name": "<string>",
"user_spot_type": "<string>",
"api_site_id": "<string>",
"api_site_name": "<string>"
}
]
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Returns the ad spots you have configured in the spot connector in your Adgreg dashboard.
In the spot connector, spots from all adnetwork sites linked to an Adgreg website are fetched automatically. You then assign each spot a group — a user-defined label such as
popunder or banner that categorises spots across adnetworks. This group is exposed as the user_spot_type field.
site_id— filter by an Adgreg website ID (thewebsite_idfrom Get user sites), not an adnetwork site ID.user_spot_type— filter by one of your user-defined groups.
Authorizations
Query Parameters
Available options:
exoclick, trafficstars, kadam, clickadilla, onclicka, twinred, trafficshop, hilltop Required range:
x >= 1Required range:
10 <= x <= 100