Install the SDK
Prerequisites
- Node.js 18+
- TypeScript 5+ (recommended)
Installation
npm install @tokenive/sdk
Initialize the Client
import { Tokenive } from '@tokenive/sdk';
const client = new Tokenive({
baseUrl: 'https://your-project.supabase.co/functions/v1',
apiKey: process.env.TOKENIVE_API_KEY, // tok_live_...
});
Configuration Options
| Option | Type | Required | Description |
|---|---|---|---|
apiKey | string | One of apiKey or token | Institution API key (tok_live_...) |
token | string | One of apiKey or token | Supabase JWT for admin UI auth |
baseUrl | string | No | Override the API base URL |
Verify It Works
const providers = await client.providers.list();
console.log('Available providers:', providers);
If this returns a list of providers, your SDK is configured correctly.