curl --request GET \
--url https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics', 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.usertour.io/v2/projects/{projectId}/content/{id}/analytics",
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.usertour.io/v2/projects/{projectId}/content/{id}/analytics"
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.usertour.io/v2/projects/{projectId}/content/{id}/analytics")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics")
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{
"object": "contentAnalytics",
"contentId": "<string>",
"environmentId": "<string>",
"startDate": "<string>",
"endDate": "<string>",
"timezone": "<string>",
"contentType": "flow",
"uniqueStarts": 4503599627370495,
"totalStarts": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495,
"byDay": [
{
"date": "<string>",
"uniqueStarts": 4503599627370495,
"totalStarts": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495
}
],
"steps": [
{
"name": "<string>",
"cvid": "<string>",
"stepIndex": 4503599627370495,
"type": "tooltip",
"uniqueViews": 4503599627370495,
"totalViews": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495,
"uniqueTooltipTargetMissing": 4503599627370495,
"totalTooltipTargetMissing": 4503599627370495
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}Get content analytics
The response shape follows the content type (discriminated on contentType): flows report starts + completions and a per-step funnel with tooltip-target-missing counts; checklists starts + completions and per-task rows; launchers seen + activations; banners seen + dismissals; resource centers opens + block clicks; trackers users + occurrences of the tracked event. All with a per-day series. Defaults to the last 30 days, UTC.
curl --request GET \
--url https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics', 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.usertour.io/v2/projects/{projectId}/content/{id}/analytics",
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.usertour.io/v2/projects/{projectId}/content/{id}/analytics"
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.usertour.io/v2/projects/{projectId}/content/{id}/analytics")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.usertour.io/v2/projects/{projectId}/content/{id}/analytics")
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{
"object": "contentAnalytics",
"contentId": "<string>",
"environmentId": "<string>",
"startDate": "<string>",
"endDate": "<string>",
"timezone": "<string>",
"contentType": "flow",
"uniqueStarts": 4503599627370495,
"totalStarts": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495,
"byDay": [
{
"date": "<string>",
"uniqueStarts": 4503599627370495,
"totalStarts": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495
}
],
"steps": [
{
"name": "<string>",
"cvid": "<string>",
"stepIndex": 4503599627370495,
"type": "tooltip",
"uniqueViews": 4503599627370495,
"totalViews": 4503599627370495,
"uniqueCompletions": 4503599627370495,
"totalCompletions": 4503599627370495,
"uniqueTooltipTargetMissing": 4503599627370495,
"totalTooltipTargetMissing": 4503599627370495
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"issues": [
{
"rule": "<string>",
"message": "<string>",
"path": "<string>"
}
],
"doc_url": "<string>"
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
Environment whose sessions to aggregate (content is project-level; pick the env).
ISO date, inclusive. Default: 30 days ago.
ISO date, inclusive. Default: today.
IANA timezone used for the per-day bucketing. Default: UTC.
Response
Content analytics — the shape follows the content type
- Option 1
- Option 2
- Option 3
- Option 4
- Option 5
- Option 6
- Option 7
contentAnalytics flow Distinct users who started it in the range.
0 <= x <= 9007199254740991Runs started in the range — one per session, so a user who ran it twice counts twice.
0 <= x <= 9007199254740991Distinct users who reached the end of the flow (or an explicit completion step).
0 <= x <= 9007199254740991Runs completed in the range.
0 <= x <= 9007199254740991Per-day activity: each row counts only that calendar day (increments, NOT a running total). Summing the total* rows reproduces the total* headline; a unique* row is distinct users WITHIN THAT DAY, so summing unique* rows over-counts a user active on several days — there is no daily series for range-wide unique users. Note the question-analytics nps/rating byDay uses the OPPOSITE convention (rolling-window cumulative).
Show child attributes
Show child attributes
Show child attributes
Show child attributes