Installation
Install the Tracia SDK using your preferred package manager:Requirements
- Node.js 18+ (uses native
fetch) - Works in modern browsers with native
fetchsupport
Configuration
Initialize the Tracia client with your API key:Configuration Options
| Option | Type | Required | Description |
|---|---|---|---|
apiKey | string | Yes | Your Tracia API key (starts with tr_) |
onSpanError | (error: Error, spanId: string) => void | No | Callback for background span submission failures |
Environment Variables
We recommend storing your API key in environment variables:.env
TypeScript Support
The SDK is written in TypeScript and exports all types:Next Steps
Prompts SDK
Manage and run prompts stored in Tracia
Run Local
Execute prompts directly against LLM providers

