Prerequisites
- A Tracia account (sign up)
- Node.js 18 or later
- An API key from a supported LLM provider (OpenAI, Anthropic, Google, Amazon Bedrock)
Step 1: Get Your API Key
- Log in to tracia.io
- Navigate to Settings > API Keys
- Click Create API Key
- Copy your key (starts with
tr_)
Step 2: Install the SDK
Step 3: Configure Your LLM Provider
- Go to Settings > Providers in the Tracia dashboard
- Add your OpenAI, Anthropic, Google, or Amazon Bedrock provider API key
- Tracia encrypts and stores your key securely
Step 4: Create Your First Prompt
- Go to Prompts in the dashboard
- Click New Prompt
- Enter a name (e.g., “Welcome Email”)
- Add your prompt messages:
- Click Save
Step 5: Run Your Prompt
Step 6: View Spans
After running your prompt:- Go to Spans in the dashboard
- See the full execution details including:
- Input/output content
- Token usage and cost
- Latency metrics
- Variables used
Next Steps
Prompts SDK
Learn all prompt operations: list, get, create, update, delete
Error Handling
Handle errors gracefully in your application

