GET
/
v1
/
apps
/
{name}
/
analytics
/
{report}
Get an analytics report
curl --request GET \
  --url https://platform.jobbit.uk/v1/apps/{name}/analytics/{report} \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://platform.jobbit.uk/v1/apps/{name}/analytics/{report}"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://platform.jobbit.uk/v1/apps/{name}/analytics/{report}', 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://platform.jobbit.uk/v1/apps/{name}/analytics/{report}",
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://platform.jobbit.uk/v1/apps/{name}/analytics/{report}"

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://platform.jobbit.uk/v1/apps/{name}/analytics/{report}")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://platform.jobbit.uk/v1/apps/{name}/analytics/{report}")

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
{
  "visitors": 1284,
  "pageviews": 4312,
  "bounce_rate": 0.41
}
{
"error": {
"code": "steps_required",
"message": "a funnel needs the event names in order as steps",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "invalid_key",
"message": "the API key is missing or invalid",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "insufficient_scope",
"message": "this key does not have the deploy:write permission",
"details": {
"required": "deploy:write"
},
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "analytics_not_enabled",
"message": "analytics is not on for this app",
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "invalid_request",
"message": "the request is not valid",
"details": [
{
"location": [
"body",
"name"
],
"message": "String should match pattern '^[a-z0-9][a-z0-9-]*$'",
"type": "string_pattern_mismatch"
}
],
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}
{
"error": {
"code": "rate_limited",
"message": "too many read requests, retry in 4 s",
"details": {
"group": "read",
"limit": 120,
"window_seconds": 60
},
"request_id": "5d3f0b7c8a2e4e19b6c47a90d1e2f3a4"
}
}

Authorizations

Authorization
string
header
required

An API key from Settings → API keys, sent as Authorization: Bearer jb_live_…

Path Parameters

name
string
required

The app name.

Required string length: 1 - 100
Pattern: ^[A-Za-z0-9][A-Za-z0-9-]*$
report
enum<string>
required

The report: stats, timeseries, realtime, events, errors, sessions, web-vitals, retention, funnel, export.csv or top/<dimension> (pages, referrers, countries, devices, browsers, os, languages, timezones, screen-sizes, hostnames, routes, outbound, downloads, utm-sources, utm-campaigns, utm-mediums, utm-terms, utm-contents).

Available options:
errors,
events,
export.csv,
funnel,
realtime,
retention,
sessions,
stats,
timeseries,
top/browsers,
top/countries,
top/devices,
top/downloads,
top/hostnames,
top/languages,
top/os,
top/outbound,
top/pages,
top/referrers,
top/routes,
top/screen-sizes,
top/timezones,
top/utm-campaigns,
top/utm-contents,
top/utm-mediums,
top/utm-sources,
top/utm-terms,
web-vitals

Query Parameters

period
enum<string>
default:7d

The time range to report on.

Available options:
1h,
24h,
7d,
30d,
90d
limit
integer

How many rows to return, for list reports.

Required range: 1 <= x <= 500
steps
string[]

Event names in order, for the funnel report. Repeat the parameter for each step.

Maximum array length: 10
Required string length: 1 - 100

Response

The report as JSON, or as CSV for export.csv.

Visitor analytics for the app. The shape depends on the report and comes from the analytics service as it is.