Telemetry
Integration guide

Vercel AI SDK Telemetry

Track streaming completions, token usage, retries, latency, and accepted results from AI SDK workflows.

Useful for
  • Streaming LLM analytics
  • Feature cost reporting
  • Reliability dashboards

Snippet

Start with one structured event

Add this shape where the workflow completes, fails, or retries. Then build the dashboard from real fields.

vercel-ai-sdk

Vercel AI SDK Telemetry event

javascript
await telemetry.log("llm_request_completed", {
  provider: "openai",
  model: "gpt-4.1-mini",
  feature: "draft_reply",
  input_tokens: 924,
  output_tokens: 218,
  latency_ms: 1380,
  status: "success",
});

Templates to pair with this integration

More integrations