SDKs
SDK Overview
Advaita provides official SDKs for web, server, and mobile. All SDKs share the same event model and a consistent track / identify / setGroup / revenue / flush API surface.
Open-source attribution
All Advaita SDKs are open source, released under the MIT License (Go SDK: Apache 2.0). We retain full upstream attribution and license compliance. The wire protocol is a standard HTTP API v2 format (POST /2/httpapi), pointing to your self-hosted Advaita collector.
Available SDKs
Web
Server
Mobile
Choosing an SDK
| Use case | SDK | Package |
|---|---|---|
| Single-page app (React, Vue, Svelte) | TypeScript Browser | @acai/analytics-browser |
| Legacy browser or vanilla JS project | JavaScript | acai-js |
| Node.js API or background job | Node.js | acai-node |
| Python backend, FastAPI, Django | Python | acai-analytics |
| Java server-side | Java | com.acai:acai-java-sdk |
| Go microservice | Go | github.com/acai/analytics-go |
| Cross-platform iOS + Android app | Flutter | acai_flutter |
| React Native app | React Native | @acai/react-native-sdk |
| Native Android (Kotlin/Java) | Android | com.acai:analytics-android |
| Native iOS (Swift) | iOS / Swift | AcaiSwift |
Common API surface
Every SDK implements these core methods. Method names follow platform conventions (camelCase for JS/Kotlin/Swift, snake_case for Python, PascalCase for Go).
| Method | Description |
|---|---|
track / logEvent | Record a user action with an event name and optional properties object. |
identify | Set persistent user traits (name, email, plan, etc.) on the current user profile. |
setUserId | Associate all future events with an authenticated user ID. |
setGroup / groupIdentify | Assign a user to a group (company, workspace) and set group properties. |
revenue | Log a purchase with price, quantity, product ID, and revenue type. |
flush | Force-send all queued events immediately. |
setOptOut | Disable all event collection (e.g. for user privacy preference). |
add / remove | Add or remove an enrichment plugin (supported by TS, Python, Kotlin, Swift, Go). |
Versioning & support
- All SDKs follow semantic versioning. Breaking changes only occur on major bumps.
- All SDKs accept a
serverUrl/apiEndpointconfig option to point to your self-hosted Advaita collector. - The ingest payload format is HTTP API v2:
POST /2/httpapiwith{ api_key, events: [...] }. - Minor and patch releases are always backward-compatible within a major version.
