Documentation
Server integrations guide
Record goals, payments, and identity from your backend. Create a scoped afx_api_… token in the workspace (owner or admin) and keep it on the server. The browser Site ID is not a credential.
New callers send integer minor units plus an ISO 4217 currency. In @analyticfast/node that is amountMinor and currency (2999 + USD is $29.99). On the wire the fields are amount_minor and currency. Do not send the legacy major-unit amount field from new code. The package is private: vendor packages/node/src/index.ts. It has no dependencies and is not on npm.
| Call | Scope | Path |
|---|---|---|
track | events:write | POST /api/v1/events |
payment / refund | payments:write | POST /api/v1/payments |
identify | identify:write | POST /api/v1/identify |
A workspace token must send site_id. A site token may omit it and cannot name another site. Server events attach to a visitor the website tracker already created (ml_vid cookie or attribution().ml_visitor_id). They do not create visitors. Retrying the same eventId or transactionId records the action once.
Recipes: Supabase, Next.js server actions, Express, Django and Flask, Laravel, web to app.
Checked 2026-10-26.
Questions, answered.
How do I use server integrations with AnalyticFast?
Follow the Server integrations instructions on this page using your own website’s Site ID and configuration. Verify a real event before relying on the reports.
Where can I get setup help?
Contact support@analyticfast.com with the website domain and a redacted description. Do not send API tokens, signing secrets or personal customer data.