Report rows: earned conversions and spend by channel
curl --request GET \
--url https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels \
--header 'Authorization: Bearer <token>'import requests
url = "https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels', 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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels",
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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels"
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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels")
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{
"table": "channels",
"generated_at": "<string>",
"rows": [
{
"level": "<string>",
"channel": "<string>",
"currency": "<string>",
"from": "<string>",
"to": "<string>",
"model": "<string>",
"lookback_days": 123,
"conversion_kind": "<string>",
"counted_appeared_in": 123,
"counted_earned": "<string>",
"counted_earned_value": "<string>",
"platform_spend": "<string>",
"platform_spend_null_reason": "<string>",
"platform_spend_source": "<string>",
"platform_spend_latest_date": "<string>",
"platform_spend_complete": true,
"meta_claimed_purchases": "<string>",
"meta_claimed_purchases_null_reason": "<string>",
"meta_claimed_value": "<string>",
"meta_claimed_cost_per_result": "<string>",
"meta_claimed_cost_per_result_null_reason": "<string>",
"meta_attribution_settings": "<string>",
"meta_attribution_settings_null_reason": "<string>",
"basis_note": "<string>",
"data_caveat": "<string>"
}
]
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}Reporting exports
Report rows: earned conversions and spend by channel
The cac-by-channel read as flat rows, one per channel and currency, for a reporting connector. Cached for a few minutes until new data lands.
GET
/
workspaces
/
{workspace}
/
admin
/
report-rows
/
channels
Report rows: earned conversions and spend by channel
curl --request GET \
--url https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels \
--header 'Authorization: Bearer <token>'import requests
url = "https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels', 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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels",
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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels"
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://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://plainrouter.com/api/v1/workspaces/{workspace}/admin/report-rows/channels")
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{
"table": "channels",
"generated_at": "<string>",
"rows": [
{
"level": "<string>",
"channel": "<string>",
"currency": "<string>",
"from": "<string>",
"to": "<string>",
"model": "<string>",
"lookback_days": 123,
"conversion_kind": "<string>",
"counted_appeared_in": 123,
"counted_earned": "<string>",
"counted_earned_value": "<string>",
"platform_spend": "<string>",
"platform_spend_null_reason": "<string>",
"platform_spend_source": "<string>",
"platform_spend_latest_date": "<string>",
"platform_spend_complete": true,
"meta_claimed_purchases": "<string>",
"meta_claimed_purchases_null_reason": "<string>",
"meta_claimed_value": "<string>",
"meta_claimed_cost_per_result": "<string>",
"meta_claimed_cost_per_result_null_reason": "<string>",
"meta_attribution_settings": "<string>",
"meta_attribution_settings_null_reason": "<string>",
"basis_note": "<string>",
"data_caveat": "<string>"
}
]
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}Authorizations
Query Parameters
Response
CAC by channel as flat rows, one per channel and currency, each with basis_note and data_caveat.