@tranthor/wizard CLI configures Tranthor in your codebase with a single command.
What It Does
- Authenticates your workspace in the browser and fetches your public write key.
- Detects your stack (Next.js App & Pages Router, React/Vite, Remix, Astro, SvelteKit, Nuxt/Vue, HTML/Blade/ERB templates, Node.js, iOS Swift, Android Kotlin, React Native).
- Configures your project:
- Writes your public write key to
.envor.env.local. - Adds the
<script id="tr-tracker">snippet (with automatic page and SPA route tracking) to your root layout. - Generates a zero-dependency typed helper (
src/lib/tranthor.tsor.js) foridentify,reset, canonical Commerce events (Product Viewed,Product Added,Cart Viewed,Checkout Started,Order Placed,Order Paid,TRANSACTION), and mobile push registration.
- Writes your public write key to
- Proposes event instrumentation diffs for your auth and checkout handlers, gated behind your confirmation in the terminal.
- Sends and verifies a test event end-to-end.

