Vitally's Analytics API is an HTTPS API that uses an Authorization header to provide authentication. The API requires you to send an Authorization header containing your API token with every request:
Authorization: Basic [Your token]
To get started, first get the API token for your account by going to the the navigate to your Settings (⚙️) by selecting your Account Logo on the top left and under Connectors select Integrations. Then select Vitally Analytics API (or via Quick Jump Mac: ⌘ + j Windows: Alt + j) . Toggle the switch on the top right to enable the integration.
The Analytics API has no rate limit.
An example curl request using this header would look like:
curl -X POST https://api.vitally.io/analytics/v1/batch \
-H "Authorization: Basic [your token]" \
-H "Content-Type: application/json" \
-d '[ ...your data... ]'
Restricting Analytics API Message Types
Vitally supports restricting which message types your Analytics API will accept — for example, blocking track or account messages entirely. This is useful as a security enhancement if you want to limit what changes are accepted via the Analytics API, even in the event that your credentials are accidentally exposed.
How it works:
Requests to a single-message endpoint for a blocked type will return a
400 Bad Request.Within a batch request, blocked messages are automatically ignored. If all messages in a batch are of a blocked type, the entire request will return a
400 Bad Request.
