Client and server libraries for sending events and managing identity from your apps. Every integration shares one mental model (initialize once, track events, identify users, reset on sign-out) whether you use a browser/app SDK, a server-side SDK (Node, Go or Ruby), or call the API directly. The one exception is reset: a server SDK has no ambient user or session to reset, so you name the user’s distinct ID on each call instead.
Choose your platform
| Platform | Use it when | Package |
|---|---|---|
| Web | Browser apps: React, Vue, Next.js, or plain JavaScript | @pug-sh/browser |
| Android | Native Android apps, in Kotlin or Java | sh.pug:android |
| Flutter | Cross-platform mobile & desktop apps | pug_flutter |
| Node | A Node.js backend that sends events and reads analytics | @pug-sh/node |
| Go | A Go backend that sends events and reads analytics | github.com/pug-sh/sdk-go |
| Ruby | A Ruby or Rails backend that sends events and reads analytics | pug-sh |
| HTTP API | Any other backend or language (anything that can POST JSON) | - |
Each SDK page follows the same outline: install, initialize, track events,
identify users, auto-tracking, consent, and upgrade notes. Every page is also
published as markdown for agents - append /index.md to its URL, as in
/sdks/flutter/index.md.
Native iOS and React Native SDKs are on the roadmap - for now, use Flutter for cross-platform mobile, or the HTTP API from any runtime.
Client vs server keys. The Web, Android and Flutter SDKs run in
untrusted environments and authenticate with your public key (pub_...) -
write-scoped (events + identify) and safe to ship in client code. The Node, Go and Ruby
SDKs run on your server and use your private key (prv_...), which
additionally unlocks analytics reads (profiles, activity, insights); never
embed it in client code. See Authentication.
Further reading
- Quickstart: your first event in five minutes
- Core concepts: events, profiles, sessions, identity
- Well-known events: the typed event catalog
- Auto-properties: every
$-property the SDKs and server attach - Authentication: public vs. private keys, rotation
- Self-hosting: run the Pug stack on your own infrastructure
- API reference: Events | Profiles | RPC services
- SDK source: browser | android | flutter | node | go | ruby