Browse developer documentation
Get started
Make your first API request
Find your key, choose a website and read your first revenue report.
1. Configure a private credential
Sign in to Attriboo and open Settings → API & MCP. Workspace owners and admins can copy the workspace key. Set ATTRIBOO_TOKEN in your server's environment or local secret manager before running these examples. Do not paste a real key into this page, client-side JavaScript or a public repository.
The cURL examples use Bash environment-variable syntax. On Windows, use Bash or adapt variables to your shell. A connected app can use an approved OAuth access token instead of a workspace key for reports.
2. List your websites
Use GET /sites to find the real ID, domain and currency. Replace site_example in the following examples with a returned ID. The API does not return public demo numbers for your account.
curl "https://www.attriboo.com/api/v1/sites" \
-H "Authorization: Bearer $ATTRIBOO_TOKEN"3. Read a revenue overview
This example requests October 1–7, 2026, inclusive, without a comparison. Choose dates containing your own recorded activity. Read revenue in cents: 20000 is 200.00 in the website's currency.
curl "https://www.attriboo.com/api/v1/stats/overview?site=site_example&from=2026-10-01&to=2026-10-07&compare=none" \
-H "Authorization: Bearer $ATTRIBOO_TOKEN"4. Call the API from your server
This Node.js example checks the HTTP result and the response envelope before reading metrics. Run it on the server with ATTRIBOO_TOKEN and ATTRIBOO_SITE configured privately. An empty report on a new installation is not a tracking verification.
const url = new URL("https://www.attriboo.com/api/v1/stats/overview");
url.search = new URLSearchParams({
site: process.env.ATTRIBOO_SITE, period: "7d", compare: "none"
});
const response = await fetch(url, {
headers: { Authorization: "Bearer " + process.env.ATTRIBOO_TOKEN }
});
const result = await response.json();
if (!response.ok || result.status !== "success") {
throw new Error(result.error?.message || "Request failed");
}
console.log(result.data.metrics.revenue / 100, result.data.site.currency);