curl --request POST \
--url https://api.tryprofound.com/v2/reports/referrals \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"metrics": [],
"domain": "<string>",
"start_date": "2023-11-07T05:31:56Z",
"date_interval": "day",
"dimensions": [],
"order_by": {
"date": "asc"
},
"pagination": {
"limit": 10000,
"offset": 0
},
"end_date": "2023-11-07T05:31:56Z",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "UTC",
"view_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metric_filters": [
{
"field": "<string>",
"value": 123
}
],
"filters": [
{
"field": "path",
"value": "<string>"
}
]
}
'import requests
url = "https://api.tryprofound.com/v2/reports/referrals"
payload = {
"metrics": [],
"domain": "<string>",
"start_date": "2023-11-07T05:31:56Z",
"date_interval": "day",
"dimensions": [],
"order_by": { "date": "asc" },
"pagination": {
"limit": 10000,
"offset": 0
},
"end_date": "2023-11-07T05:31:56Z",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "UTC",
"view_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metric_filters": [
{
"field": "<string>",
"value": 123
}
],
"filters": [
{
"field": "path",
"value": "<string>"
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metrics: [],
domain: '<string>',
start_date: '2023-11-07T05:31:56Z',
date_interval: 'day',
dimensions: [],
order_by: {date: 'asc'},
pagination: {limit: 10000, offset: 0},
end_date: '2023-11-07T05:31:56Z',
organization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
timezone: 'UTC',
view_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
metric_filters: [{field: '<string>', value: 123}],
filters: [{field: 'path', value: '<string>'}]
})
};
fetch('https://api.tryprofound.com/v2/reports/referrals', 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.tryprofound.com/v2/reports/referrals",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'metrics' => [
],
'domain' => '<string>',
'start_date' => '2023-11-07T05:31:56Z',
'date_interval' => 'day',
'dimensions' => [
],
'order_by' => [
'date' => 'asc'
],
'pagination' => [
'limit' => 10000,
'offset' => 0
],
'end_date' => '2023-11-07T05:31:56Z',
'organization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'timezone' => 'UTC',
'view_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'metric_filters' => [
[
'field' => '<string>',
'value' => 123
]
],
'filters' => [
[
'field' => 'path',
'value' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tryprofound.com/v2/reports/referrals"
payload := strings.NewReader("{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.post("https://api.tryprofound.com/v2/reports/referrals")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tryprofound.com/v2/reports/referrals")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"info": {
"total_rows": 123,
"query": {}
},
"data": [
{
"metrics": [
123
],
"dimensions": [
"<string>"
]
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Get Referrals Report V2
Get referral traffic report from the hourly aggregated materialized view (UTC-based).
Supports date_interval=“hour”, calendar intervals through “year”, “quarter”, and “relative_week”.
When view_id is provided, the query is scoped to that domain segment’s hosts and paths.
curl --request POST \
--url https://api.tryprofound.com/v2/reports/referrals \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"metrics": [],
"domain": "<string>",
"start_date": "2023-11-07T05:31:56Z",
"date_interval": "day",
"dimensions": [],
"order_by": {
"date": "asc"
},
"pagination": {
"limit": 10000,
"offset": 0
},
"end_date": "2023-11-07T05:31:56Z",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "UTC",
"view_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metric_filters": [
{
"field": "<string>",
"value": 123
}
],
"filters": [
{
"field": "path",
"value": "<string>"
}
]
}
'import requests
url = "https://api.tryprofound.com/v2/reports/referrals"
payload = {
"metrics": [],
"domain": "<string>",
"start_date": "2023-11-07T05:31:56Z",
"date_interval": "day",
"dimensions": [],
"order_by": { "date": "asc" },
"pagination": {
"limit": 10000,
"offset": 0
},
"end_date": "2023-11-07T05:31:56Z",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"timezone": "UTC",
"view_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"metric_filters": [
{
"field": "<string>",
"value": 123
}
],
"filters": [
{
"field": "path",
"value": "<string>"
}
]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
metrics: [],
domain: '<string>',
start_date: '2023-11-07T05:31:56Z',
date_interval: 'day',
dimensions: [],
order_by: {date: 'asc'},
pagination: {limit: 10000, offset: 0},
end_date: '2023-11-07T05:31:56Z',
organization_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
timezone: 'UTC',
view_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
metric_filters: [{field: '<string>', value: 123}],
filters: [{field: 'path', value: '<string>'}]
})
};
fetch('https://api.tryprofound.com/v2/reports/referrals', 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.tryprofound.com/v2/reports/referrals",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'metrics' => [
],
'domain' => '<string>',
'start_date' => '2023-11-07T05:31:56Z',
'date_interval' => 'day',
'dimensions' => [
],
'order_by' => [
'date' => 'asc'
],
'pagination' => [
'limit' => 10000,
'offset' => 0
],
'end_date' => '2023-11-07T05:31:56Z',
'organization_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'timezone' => 'UTC',
'view_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'metric_filters' => [
[
'field' => '<string>',
'value' => 123
]
],
'filters' => [
[
'field' => 'path',
'value' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tryprofound.com/v2/reports/referrals"
payload := strings.NewReader("{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.post("https://api.tryprofound.com/v2/reports/referrals")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tryprofound.com/v2/reports/referrals")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"metrics\": [],\n \"domain\": \"<string>\",\n \"start_date\": \"2023-11-07T05:31:56Z\",\n \"date_interval\": \"day\",\n \"dimensions\": [],\n \"order_by\": {\n \"date\": \"asc\"\n },\n \"pagination\": {\n \"limit\": 10000,\n \"offset\": 0\n },\n \"end_date\": \"2023-11-07T05:31:56Z\",\n \"organization_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"timezone\": \"UTC\",\n \"view_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"metric_filters\": [\n {\n \"field\": \"<string>\",\n \"value\": 123\n }\n ],\n \"filters\": [\n {\n \"field\": \"path\",\n \"value\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"info": {
"total_rows": 123,
"query": {}
},
"data": [
{
"metrics": [
123
],
"dimensions": [
"<string>"
]
}
]
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Body
visits, last_visit Domain to query logs for.
Start date for logs. Accepts: YYYY-MM-DD, YYYY-MM-DD HH:MM, YYYY-MM-DD HH:MM:SS, or full ISO timestamp.
Date interval for the report. (only used with date dimension)
hour, day, week, month, quarter, year, relative_week Dimensions to group the report by.
date, hour, host, path, referral_source, referral_type Custom ordering of the report results.
The order is a record of key-value pairs where:
- key is the field to order by, which can be a metric or dimension
- value is the direction of the order, either 'asc' for ascending or 'desc' for descending.
When not specified, the default order is the first metric in the query descending.
Show child attributes
Show child attributes
{ "date": "asc" }
Pagination settings for the report results.
Show child attributes
Show child attributes
End date in UTC. Accepts same formats as start_date. Defaults to now UTC if omitted.
IANA timezone name for date bucketing and filter boundaries.
Domain segment UUID used to scope the query to a configured subset of hosts and paths.
Numeric filters applied after report metrics are calculated.
Show child attributes
Show child attributes
Filters for referrals report.
Filter by request path
- PathFilter
- ReferralSourceFilter
- ReferralTypeFilter
Show child attributes
Show child attributes
Was this page helpful?