11. API & Protocols/Telemetry Sentry

Analytics Sentry API

The Rust-powered Sentry API exposes asynchronous endpoints for high-velocity event ingestion, user identity stitching, and deep-query data extractions.

HIGH THROUGHPUT INGRESS
HTTP 202
Asynchronous Request Acceptance

The ingestion endpoint drops packets immediately into a Redis Stream buffer and returns 202 Accepted, ensuring client threads never hang during DB writes.

Non-Blocking API Design

Asynchronous Event Ingestion

Pushes telemetry events (page views, clicks, purchases) into the Sentry stream buffer.

POST/api/collect
1{
2 "projectId": "prj_clx1a2b3",
3 "sessionId": "sess_1718002000",
4 "visitorId": "vis_a1b2c3d4",
5 "messageId": "msg_9988776655",
6 "eventType": "purchase",
7 "url": "https://store.brand.com/checkout/success",
8 "ecommerce": {
9 "orderId": "ORD-5544",
10 "revenue": 150.00,
11 "currency": "USD"
12 },
13 "clientTimestamp": "2026-10-15T14:30:00Z"
14}

Identity Resolution & Aliasing

Stitch an anonymous hardware visitorId to an authenticated userId.

POST/api/identify
1{
2 "projectId": "prj_clx1a2b3",
3 "sessionId": "sess_1718002000",
4 "visitorId": "vis_a1b2c3d4",
5 "userId": "usr_998877",
6 "traits": {
7 "name": "Jane Doe",
8 "email": "jane@example.com",
9 "plan": "Enterprise"
10 }
11}

Querying Analytical Telemetry

Access pre-aggregated statistics (Fast Mode) for rapid dashboard rendering.

GET/v1/analytics/project/:projectId/overview
GET/v1/analytics/project/:projectId/visitors
ParameterTypeRequirementDescription
daysnumberOptionalNumber of trailing days to calculate aggregates across (Max: 365).
Default: 30

Funnel Analysis Computation

Submit a sequence of events to the engine to calculate step-by-step conversion drop-offs.

POST/v1/analytics/project/:projectId/funnel
1{
2 "steps": ["view_product", "add_to_cart", "checkout", "purchase"],
3 "filters": {
4 "geo.countryCode": "US"
5 }
6}