OxinionDevelopers
Quick Start

Getting Started

Location-based marketing automation — geofencing, event tracking, and real-time webhooks.

Install

npm install oxinion

Single package — all modules included. Requires Node.js 18+ or any modern browser.

Initialize

Use your oxk_live_ API key from the console. Keep it in an environment variable — never commit it.

typescript
1import { createOxinion } from 'oxinion'
2
3const oxinion = createOxinion({
4 apiKey: process.env.OXINION_API_KEY!, // oxk_live_...
5})
6
7// Send a location event
8await oxinion.track({
9 type: 'enter',
10 lat: 43.6532,
11 lng: -79.3832,
12 userId: 'user-123',
13})
14
15// List your geofences
16const { geofences } = await oxinion.geofencing.list()
17
18// Create a geofence
19const { geofence } = await oxinion.geofencing.create({
20 name: 'My Store',
21 lat: 43.6532,
22 lng: -79.3832,
23 radius: 150,
24 triggerType: 'enter',
25})

Modules

All async methods return Promise<{ data, error, status }>.

Next Steps

Geofencing Guide

Create zones, handle enter/exit/dwell events, and manage geofences at scale.

Read Guide
Event Reference

Full list of all typed events across geofencing, rewards, indoor, DOOH, and AR.

View Events

Interactive Playground

// Run a method to see the response