SDK
TypeScript SDK with batching, backoff, circuit breaker, and browser persistence. Billable runtime events sent to api.eventra.dev.
npm i @eventra_dev/eventra-sdkOne SDK for the events, one CLI for the catalog. Three steps from install to your first event.
The SDK sends usage. The CLI reads your code and registers the catalog.
TypeScript SDK with batching, backoff, circuit breaker, and browser persistence. Billable runtime events sent to api.eventra.dev.
npm i @eventra_dev/eventra-sdkStatic analysis via the TypeScript compiler API. init, sync, check, watch, and send. Catalog sync is non-billable and never counts as usage. Plugins for Vue, Svelte, Astro, and Angular read their templates.
npm i -D @eventra_dev/eventra-cliInstall, add one line where a feature runs, then let the CLI list your features.
Add the SDK to your app and the CLI as a dev dependency.
npm i @eventra_dev/eventra-sdk
npm i -D @eventra_dev/eventra-cliCreate the tracker once, then call track() where the feature runs.
import { Eventra } from "@eventra_dev/eventra-sdk";
// create it once, when your app starts
const tracker = new Eventra({ apiKey: "YOUR_PROJECT_API_KEY" });
// call it where the feature runs
tracker.track("export.clicked");
// on a server, use tracker.withUser(userId).track("export.clicked")The CLI reads your code and tells Eventra which features exist.
npx eventra init # asks for your API key, writes eventra.json
npx eventra sync # finds every tracker.track() call in your code
npx eventra send # uploads that list, so unused features show upUsing Next.js, Vue, NestJS, Cloudflare or something else? Every stack has its own example in the docs and in the examples repository.
40 stacks and tools, 19 with a runnable example in the examples repository. The rest are covered in the docs or marked as not tested.
cli-plugin-vueSDKSDK runs as isOpen example ↗cli-plugin-vueSDKSDK runs as isOpen example ↗cli-plugin-svelteSDKSDK runs as isOpen example ↗cli-plugin-astroSDKSDK runs as isOpen example ↗cli-plugin-angularSDKSDK runs as isOpen example ↗cli-plugin-svelteRead the docs →Plugins are for the CLI scanner only. The SDK needs none and runs in browsers, Node.js and edge runtimes. Four template dialects need a plugin so the scanner can read them: Vue and Nuxt, Svelte, Astro and Angular.
Static analysis cannot see everything, for example event names computed at runtime. What the CLI does not cover, the latest test results and all examples on GitHub are public.
The honest list, so you do not find out after you install.
There is no SDK for other languages yet, and the CLI cannot read their code. They are on the roadmap, with no date.
RoadmapThe CLI reads TypeScript, JavaScript and JSX, and Vue, Svelte, Astro and Angular through the official plugins. Other template languages, such as Pug, are not read.
Not supportedRemix, SolidStart, Preact, Qwik, Gatsby, Koa, AdonisJS, Electron, Deno and Bun. The SDK and the CLI should work there, but we have not tested them, so there is no example.
Not testedOnly the official @eventra_dev/cli-plugin-* packages are loaded. Third-party plugins are not supported.
Not supportedSvelteKit, AWS Lambda, Netlify and React Native are described in the docs but have no runnable example project yet.
In the docsThe docs cover every command, option and framework plugin. When you are ready, create a workspace and get an API key.