OpenRouter Broadcast

Learn how to set up OpenRouter Broadcast to forward trace data from your LLM requests to Sentry.

OpenRouter is an AI API router that provides a unified interface for accessing multiple LLM providers. OpenRouter's Broadcast feature lets you send traces from your LLM requests to Sentry via the OpenTelemetry (OTLP) format.

Before you begin, ensure you have:

  • An OpenRouter account with API access
  • A Sentry project you want to send data to

  1. In Sentry, navigate to your Sentry Project Settings
  2. Go to Client Keys (DSN) and click on the OpenTelemetry tab
  3. Copy the OTLP Traces Endpoint URL (ends with /v1/traces):
Copied
___OTLP_TRACES_URL___
  1. Copy your DSN from the same page:
Copied
___DSN___

  1. Log in to your OpenRouter account
  2. Go to Settings > Broadcast
  3. Toggle Enable Broadcast to turn on the feature

  1. Click the edit icon next to Sentry
  2. Enter your OTLP Traces Endpoint (e.g., https://o123.ingest.us.sentry.io/api/456/integration/otlp/v1/traces)
  3. Enter your Sentry DSN (e.g., https://abc123@o123.ingest.us.sentry.io/456)

  1. Click Test Connection to verify the setup
  2. The configuration only saves if the test passes

Make an API request through OpenRouter and view the trace in Sentry's Trace Explorer. It may take a few minutes for traces to appear.

Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").