Skip to content
Betav0.62.0
All tools
Free tool

Telemetry setup generator

Choose your AI coding tools and enter your OpenTelemetry endpoint. You get the settings each tool documents for sending usage, tokens and cost, with prompt and content capture left off unless you choose otherwise.

Runs in your browser. Nothing you type or paste leaves this page.

AI coding tools

The base URL of your collector. The tools add /v1/traces, /v1/logs and /v1/metrics themselves.

Protocol

Collectors usually listen for OTLP/HTTP on port 4318 and gRPC on 4317.

Authentication

One key=value per line, such as team or department. Leave empty for none.

Claude Code export intervals (optional)
Content capture (off)

Prompts can contain source code, customer data and secrets. Turn this on only for a collector you trust, and tell the people whose prompts it records.

Your settings

Settings for 2 tools, with prompt and content capture off.

Claude Code

Shell (each computer)

In ~/.zshrc, ~/.bashrc or the environment Claude Code starts in

export CLAUDE_CODE_ENABLE_TELEMETRY=1
export OTEL_METRICS_EXPORTER=otlp
export OTEL_LOGS_EXPORTER=otlp
export OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf
export OTEL_EXPORTER_OTLP_ENDPOINT=https://otel.example.com:4318
export OTEL_RESOURCE_ATTRIBUTES=team=platform,department=engineering

Managed settings (whole organisation)

In the env block of Claude Code's managed settings file

{
  "env": {
    "CLAUDE_CODE_ENABLE_TELEMETRY": "1",
    "OTEL_METRICS_EXPORTER": "otlp",
    "OTEL_LOGS_EXPORTER": "otlp",
    "OTEL_EXPORTER_OTLP_PROTOCOL": "http/protobuf",
    "OTEL_EXPORTER_OTLP_ENDPOINT": "https://otel.example.com:4318",
    "OTEL_RESOURCE_ATTRIBUTES": "team=platform,department=engineering"
  }
}

What each setting does

CLAUDE_CODE_ENABLE_TELEMETRY
Turns telemetry on (required).
OTEL_METRICS_EXPORTER / OTEL_LOGS_EXPORTER
Send metrics (including claude_code.cost.usage and claude_code.token.usage) and events over OTLP.
OTEL_EXPORTER_OTLP_PROTOCOL
The OTLP protocol. Claude Code has no default, so it is always set.
OTEL_EXPORTER_OTLP_ENDPOINT
Your collector, for every signal.
OTEL_RESOURCE_ATTRIBUTES
Labels such as team or department on everything sent. Values can't contain spaces, so they are percent-encoded.
OTEL_LOG_USER_PROMPTS / OTEL_LOG_TOOL_DETAILS
Left unset: prompt text and tool details stay out (the default).
  • Claude Code ignores these exporter settings in a repository's .claude/settings.json: use managed settings, ~/.claude/settings.json or the shell.

Source, checked on 22 October 2026: Claude Code: Monitoring (opens in a new tab)

GitHub Copilot

Copilot CLI: shell (each computer)

In ~/.zshrc, ~/.bashrc or the environment Copilot CLI starts in

export COPILOT_OTEL_ENABLED=true
export OTEL_EXPORTER_OTLP_ENDPOINT=https://otel.example.com:4318
export OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf
export OTEL_RESOURCE_ATTRIBUTES=team=platform,department=engineering

Enterprise managed settings (whole organisation)

In managed-settings.json

{
  "telemetry": {
    "enabled": true,
    "endpoint": "https://otel.example.com:4318",
    "protocol": "http/protobuf",
    "capture": {
      "identity": false,
      "prompts": false,
      "responses": false,
      "toolArguments": false,
      "toolOutput": false,
      "policyDetail": false
    },
    "captureContent": false,
    "lockCaptureContent": true,
    "resourceAttributes": {
      "team": "platform",
      "department": "engineering"
    }
  }
}

What each setting does

COPILOT_OTEL_ENABLED / telemetry.enabled
Turns OpenTelemetry export on.
OTEL_EXPORTER_OTLP_ENDPOINT / telemetry.endpoint
Your collector's base URL.
OTEL_EXPORTER_OTLP_PROTOCOL / telemetry.protocol
http/json (the CLI's default) or http/protobuf.
telemetry.capture
Every capture class off (the default), written out so it is clear: no identity, prompts, responses, tool arguments, tool output or policy detail.
telemetry.lockCaptureContent
Stops local settings on each computer from turning content capture on.
OTEL_RESOURCE_ATTRIBUTES / telemetry.resourceAttributes
Labels such as team or department on everything sent.
  • Copilot CLI captures no prompt content, responses or tool arguments unless OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT is set.
  • Managed telemetry settings override local settings and environment variables.

Sources, checked on 22 October 2026: Copilot CLI command reference: OpenTelemetry monitoring (opens in a new tab); Enterprise managed settings: telemetry (opens in a new tab); OpenTelemetry for Copilot (opens in a new tab)

What it covers

Claude Code, GitHub Copilot (Copilot CLI and enterprise managed settings), OpenAI Codex CLI and Gemini CLI. Each block uses only the setting names and values in that tool’s own documentation, linked under it with the date it was checked. If a tool can’t use the protocol you chose, it says so instead of guessing.

Authentication comes from an environment variable on each computer, so no token is written into a settings file. Where a file can’t read a variable, the header is left out and the note says what to do instead.

SpanDock receives OTLP/HTTP, in protobuf or JSON, and forwards what it receives to the destinations you add, such as Langfuse, Grafana Cloud, New Relic or any OTLP/HTTP endpoint. Forwarding to more than one destination is in the Standard plan and above. See Destinations.

Cookie categories

Details: Cookie Policy.