Skip to content

Cursor OpenTelemetry export to your own collector

On the Enterprise plan, Cursor sends its usage data, and on request the text of agent conversations, from its own servers to an OpenTelemetry collector you run. This page sets up that collector inside your infrastructure, so the data stays there: a new collector on a virtual machine with Docker Compose, the same on Kubernetes, or the tools your teams already use, from Datadog to Grafana, Elastic, Splunk, ClickHouse and S3. Nothing is installed on developers’ workstations and no Idun code runs on your side: the collector is the official OpenTelemetry image, and this page gives its configuration. Every file and command below was run end to end before publication, with traffic built from Cursor’s Wire Reference; the few points we could not test are named where they come up.

To send the export to Idun’s collection address instead, see the Cursor connector. When the data stays with you, we agree at the start of the audit how Idun Cockpit reads it: read access to the storage, or the Cockpit installed in your infrastructure.

Cursor sends its OpenTelemetry export from its own servers to a collector inside your infrastructure.CURSORDevelopersCursor IDE and CLInothing installednormal useCursor's serversOpenTelemetry Export27 fixed IP addressesHTTPS, OTLPBearer tokenYOUR INFRASTRUCTUREReverse proxyTLS certificateCursor IPs onlyOpenTelemetryCollectorchecks the tokendrops the peopleyou excludeFilesJSON Lineson diskYour toolsGrafana, Datadog,Elastic, Splunk,ClickHouse, S3
  • Cursor pushes, you receive. Cursor’s servers send OTLP over HTTP, in binary protobuf, to the base address you give them: POST <base>/v1/logs and POST <base>/v1/metrics. gRPC and JSON are not used. See Collector recipes in Cursor’s documentation.
  • From 27 fixed addresses. The traffic leaves Cursor through a proxy with 27 published IP addresses, so your endpoint must be reachable from the internet, over HTTPS. Cursor gives notice before they change.
  • With your token. Each request carries the header Authorization: Bearer <token>. You choose the token, store it in the collector and enter it in Cursor.
  • The collector decides what is kept. It refuses a request without the right token, drops the people you exclude, writes the rest to files on disk and, if you want, forwards it to your tools.
  • No history. Data flows from the moment the export is turned on. Cursor’s Admin API, read separately, gives past usage and cost.
What Why How to check
The Cursor Enterprise plan OpenTelemetry Export is an Enterprise feature. A team admin sees Team Settings > OpenTelemetry Export in the Cursor dashboard.
A team not in Privacy Mode (Legacy) In that mode, conversation content cannot be exported. On the same page, Allow conversation content export is not greyed out.
A team admin They create the destination in Cursor. Their role in the dashboard’s member list.
A public HTTPS name Cursor connects from the internet. For example otel.example.com, resolving to your reverse proxy.
A certificate the public trusts Cursor must be able to verify it. Let’s Encrypt, or a public certificate authority. An internal authority is not enough.
Port 443 open to Cursor’s 27 addresses The only inbound traffic needed. Your firewall rule, or the allowlist of the reverse proxy below.
A host for the collector A Linux VM with Docker Compose, or a Kubernetes cluster. 1 vCPU and 2 GB of memory for the collector; disk to size during the first week.
Developers informed The export can send the text of their requests. See Usage, not individuals.
Setup Choose it when
A collector on a virtual machine You want the simplest start: one VM, Docker Compose, files on disk.
Kubernetes Your services run on Kubernetes. The same collector, through the official Helm chart.
Your existing tools Your teams already read logs and metrics in Datadog, Grafana, Elastic, Splunk, ClickHouse or S3. The collector forwards to them and keeps a copy on disk.

The three share the same collector configuration. Start with the first section even if you choose another: it explains each setting once.

Three files in one folder: docker-compose.yml starts the official image, config.yaml tells the collector what to do, .env holds the token and the list of excluded people. Tested on a Linux virtual machine with Docker Engine 29 and Compose 5.

  1. Create the folder and copy the three files

    On the VM, create a folder, for example ~/cursor-otel, and put in it the three files below, unchanged.

  2. Write the token into .env

    Fenêtre de terminal
    cp .env.example .env && chmod 600 .env &&
    sed -i.bak '/^CURSOR_OTLP_TOKEN=$/d' .env && rm .env.bak &&
    printf 'CURSOR_OTLP_TOKEN=%s\n' "$(openssl rand -hex 32)" >>.env

    Keep this token: you will enter it in Cursor. Read it with grep '^CURSOR_OTLP_TOKEN=' .env.

  3. Start the collector

    Fenêtre de terminal
    sudo docker compose up -d

    A first task gives the data/ folder to the collector’s user, then the collector starts. sudo docker compose ps shows it healthy after about ten seconds.

With a proxy or a tool, declare your Compose files once. The next sections add a second Compose file, sometimes a third. List them all in .env, with COMPOSE_FILE, as .env.example shows: every sudo docker compose command of this page then uses the same files. Without it, the next sudo docker compose up -d restarts the collector without the extra files, and forwarding to your tool stops without an error.

docker-compose.yml
# OpenTelemetry Collector for the Cursor OTLP export, on a VM with Docker Compose.
# Start: cp .env.example .env, fill in .env, then: docker compose up -d
# Data lands in ./data (JSON Lines).
services:
# One-off setup task, which exits right away:
# - gives ./data and its content to user 10001, the user of the collector image;
# the folder gets mode 0700;
# - copies busybox for the health check (the collector image has no shell and no curl).
prepare:
image: busybox:1.38.0-musl@sha256:80e38f9a1b39188b8bdb28879178edb322a4402b081a9aedda1924609decd6f6
command: ["sh", "-c", "chown -R 10001:10001 /data && chmod 0700 /data && cp /bin/busybox /tools/busybox"]
volumes:
- ./data:/data
- tools:/tools
restart: "no"
collector:
# Version pinned by digest: the same image everywhere, updated only on purpose.
image: otel/opentelemetry-collector-contrib:0.166.0@sha256:3e18fe04181de50bdd72e23ad4a4d6214b54351e63d496f1c58127cc4541ad7f
user: "10001:10001"
command: ["--config=/etc/otelcol/config.yaml"]
environment:
CURSOR_OTLP_TOKEN: ${CURSOR_OTLP_TOKEN:?set CURSOR_OTLP_TOKEN in .env}
# Token rotation: when empty in .env, it takes the value of CURSOR_OTLP_TOKEN.
CURSOR_OTLP_TOKEN_NEXT: ${CURSOR_OTLP_TOKEN_NEXT:-${CURSOR_OTLP_TOKEN}}
BLOCKED_EMAILS: ${BLOCKED_EMAILS:-}
RETENTION_DAYS: ${RETENTION_DAYS:-90}
# The Go garbage collector aims at 1,600 MiB, below the container limit (2 GB).
GOMEMLIMIT: 1600MiB
volumes:
- ./config.yaml:/etc/otelcol/config.yaml:ro
- ./data:/data
- tools:/tools:ro
ports:
# Local only: the reverse proxy (TLS) sits in front.
- "127.0.0.1:${OTLP_PORT:-4318}:4318"
- "127.0.0.1:${HEALTH_PORT:-13133}:13133"
depends_on:
prepare:
condition: service_completed_successfully
healthcheck:
test: ["CMD", "/tools/busybox", "wget", "-q", "-O", "/dev/null", "http://127.0.0.1:13133/"]
interval: 30s
timeout: 5s
retries: 3
start_period: 10s
restart: unless-stopped
read_only: true
cap_drop: [ALL]
security_opt: ["no-new-privileges:true"]
deploy:
resources:
limits:
cpus: "1.0"
memory: 2g
logging:
driver: json-file
options:
max-size: "10m"
max-file: "3"
volumes:
tools:
config.yaml
# OpenTelemetry Collector for the Cursor OTLP export.
# Official otel/opentelemetry-collector-contrib image, no custom component.
# Path of a record: receiver -> processors (in order) -> exporter.
# No batch processor: the reply to Cursor waits for the write to disk. A 200 means
# "written"; a full disk returns 503, and Cursor sends the logs again.
extensions:
# Rejects (401) any request without the "Authorization: Bearer <token>" header.
# The token comes from the .env file; it is the same as in Cursor. A second token,
# CURSOR_OTLP_TOKEN_NEXT, is used during a rotation; without it, the first one is reused.
bearertokenauth:
scheme: Bearer
tokens:
- ${env:CURSOR_OTLP_TOKEN}
- ${env:CURSOR_OTLP_TOKEN_NEXT:-${env:CURSOR_OTLP_TOKEN}}
# Liveness probe: GET http://<host>:13133/ returns 200 while the collector runs.
# Do not expose it on the Internet.
health_check:
endpoint: 0.0.0.0:13133
receivers:
# Cursor sends OTLP/HTTP protobuf to /v1/logs and /v1/metrics.
otlp:
protocols:
http:
endpoint: 0.0.0.0:4318
auth:
authenticator: bearertokenauth
# Maximum size of a request, measured after decompression. Above it, the collector
# returns 400 ("request body too large"), and Cursor does not resend a 4xx:
# keep a margin (one message is up to 32 KiB).
max_request_body_size: 67108864 # 64 MiB
# Timeouts: 10 s for the headers, 60 s for the whole request
# (defaults: 1 min for the headers, none for the body).
read_header_timeout: 10s
read_timeout: 60s
processors:
# Refuses data (a temporary error, which Cursor resends for logs) before memory
# runs out. The percentages apply to the memory limit of the container.
memory_limiter:
check_interval: 1s
limit_percentage: 80
spike_limit_percentage: 25
# Block list: BLOCKED_EMAILS (.env), addresses separated by commas, semicolons or
# spaces, case ignored. For these people, logs and metrics are dropped.
# If the list is not empty, conversation content without an email (which cannot be
# checked) is dropped too. Spaces and ";" are first turned into commas, then split.
filter/blocklist:
error_mode: ignore
log_conditions:
- &blocked_email >-
resource.attributes["cursor.user.email"] != nil and
resource.attributes["cursor.user.email"] != "" and
ContainsValue(Split(Concat(Split(Concat(Split(ToLowerCase("${env:BLOCKED_EMAILS}"), " "), ","), ";"), ","), ","),
ToLowerCase(resource.attributes["cursor.user.email"]))
- >-
IsMatch("${env:BLOCKED_EMAILS}", "@") and
(resource.attributes["cursor.user.email"] == nil or resource.attributes["cursor.user.email"] == "") and
log.attributes["cursor.conversation.provenance"] != nil
metric_conditions:
- *blocked_email
exporters:
# One file per signal, in JSON Lines: one line = one request from Cursor, as OTLP JSON.
# Rotation: above max_megabytes, the file is renamed
# (cursor-logs-<UTC date>-size.jsonl) and a new one is opened.
# max_days: at each rotation, renamed files older than RETENTION_DAYS days
# (date read from their name) are deleted. 0: never. Without the variable: 90.
# max_backups: 0 = no limit on the number of files. Do not omit it: its default (100)
# would delete the oldest files.
file/logs:
path: /data/cursor-logs.jsonl
format: json
rotation:
max_megabytes: 100
max_days: ${env:RETENTION_DAYS:-90}
max_backups: 0
file/metrics:
path: /data/cursor-metrics.jsonl
format: json
rotation:
max_megabytes: 100
max_days: ${env:RETENTION_DAYS:-90}
max_backups: 0
service:
extensions: [bearertokenauth, health_check]
pipelines:
logs:
receivers: [otlp]
processors: [memory_limiter, filter/blocklist]
exporters: [file/logs]
metrics:
receivers: [otlp]
processors: [memory_limiter, filter/blocklist]
exporters: [file/metrics]
.env.example
# Copy this file to .env, then run: chmod 600 .env
# Compose files read by every "docker compose ..." (up, exec, run, restart).
# As soon as you add a file (proxy, tool), uncomment the line below and list them all,
# separated by ":". Without it, a plain "docker compose up -d" only reads docker-compose.yml,
# and the collector loses their settings. With it, a docker-compose.override.yml is only read
# if it is in the list.
# COMPOSE_FILE=docker-compose.yml:docker-compose.nginx.yml:docker-compose.grafana.yml
# Token that Cursor sends in "Authorization: Bearer <token>".
# Generate it with: openssl rand -hex 32
# Enter the same value in Cursor (Team Settings > OpenTelemetry Export).
CURSOR_OTLP_TOKEN=
# Token rotation, without data loss: 1) put the new token here and run
# "docker compose up -d" (both tokens are accepted); 2) enter it in Cursor;
# 3) wait a few minutes; 4) copy it into CURSOR_OTLP_TOKEN, empty this line,
# and run "docker compose up -d" again. Empty outside a rotation.
CURSOR_OTLP_TOKEN_NEXT=
# Block list: addresses for which nothing is kept, separated by commas,
# semicolons or spaces. Case does not matter. No double quotes.
# Leave empty to keep everything.
# Example: BLOCKED_EMAILS=jane.doe@example.com, john.roe@example.com
BLOCKED_EMAILS=
# Retention of the files renamed by rotation, in days (0: never deleted).
RETENTION_DAYS=90
# Listening ports on the VM (127.0.0.1 only).
OTLP_PORT=4318
HEALTH_PORT=13133
  • The token. The bearertokenauth extension refuses, with 401, any request without Authorization: Bearer <token>. Compose refuses to start while the token is empty, rather than starting a collector that refuses everything.
  • The size of a request. Up to 64 MiB, measured after decompression. Beyond that the collector answers 400, and Cursor does not retry a 4xx: keep the margin. A message is at most 32 KiB.
  • Memory. The container is limited to 2 GB, and the collector refuses data before reaching it, with a temporary error.
  • People left out. The filter/blocklist processor drops what belongs to the addresses listed in BLOCKED_EMAILS. See Leave people out.
  • The files. One file per signal in data/, in JSON Lines: each line is one request from Cursor, in OTLP JSON. Past 100 MB, the file is renamed with its date and a new one starts.
  • No batch processor. Cursor’s minimal example uses one, and so do most collector examples. Here it is left out on purpose: it answers Cursor before the data is written. Without it, 200 means “written to disk”, and a full disk returns 503, a temporary error.
  • The container. The image is pinned by its digest, runs as user 10001, with a read-only file system, no Linux capabilities, and listens only on 127.0.0.1: the reverse proxy sits in front.
  • What Cursor does with an error. According to its Wire Reference, Cursor replays the logs of a request refused with a temporary error (5xx, or no answer) for about 7 days. It does not replay metrics, nor a request refused with a 4xx. Each restart of the collector refuses connections for a few seconds: the logs come back, the metrics of those seconds are lost.

The collector listens only on the VM itself. A reverse proxy in front of it carries the certificate, lets in only Cursor’s addresses and accepts requests of 64 MiB. Two tested configurations: nginx or Caddy.

  1. Put the certificate in tls/

    tls/fullchain.pem and tls/privkey.pem, next to docker-compose.yml. The certificate must be trusted by the public: Cursor connects from the internet. Replace otel.example.com with your name in nginx/cursor-otel.conf or caddy/Caddyfile.

  2. Generate the allowlist of Cursor’s addresses

    Copy cursor-ips.txt and make-allowlist.sh, create the nginx/ or caddy/ folder, then run bash make-allowlist.sh. Run it again if Cursor announces a change of address.

  3. Start the proxy with the collector

    Add the overlay file of your choice, below, to COMPOSE_FILE in .env, for example COMPOSE_FILE=docker-compose.yml:docker-compose.nginx.yml, then run sudo docker compose up -d.

  4. Reload the proxy after a change

    After a new allowlist or a renewed certificate (a Let’s Encrypt certificate lasts 90 days):

    Fenêtre de terminal
    sudo docker compose exec nginx nginx -s reload # nginx
    sudo docker compose exec caddy caddy reload --config /etc/caddy/Caddyfile # Caddy
cursor-ips.txt
# Source IPs of the Cursor OTLP export (Cursor docs "OpenTelemetry Export", Source IPs section, read on 2026-11-26).
# Cursor gives notice before changing them. One IP per line; lines starting with # are ignored.
3.208.51.163
3.209.66.12
3.218.161.44
3.224.130.48
3.231.18.206
3.234.118.132
18.210.232.136
34.197.19.148
34.198.251.120
34.199.187.247
35.170.160.152
35.174.159.35
44.215.226.85
52.44.113.131
52.202.172.69
54.81.109.217
54.204.61.44
54.236.99.119
67.202.63.191
100.63.97.141
100.63.144.57
184.73.225.134
184.193.125.229
184.193.223.40
184.194.140.210
184.194.175.144
184.194.208.56
make-allowlist.sh
#!/usr/bin/env bash
# Builds the nginx and Caddy allow lists from cursor-ips.txt.
# Run it again when Cursor announces an IP change, then reload the proxy (command printed).
# Usage: bash make-allowlist.sh (Cursor IPs only)
# bash make-allowlist.sh 203.0.113.7 (adds an IP, for example a test machine)
set -euo pipefail
cd "$(dirname "$0")"
ips=$( { grep -v '^#' cursor-ips.txt; printf '%s\n' "$@"; } | grep -E '^[0-9]{1,3}(\.[0-9]{1,3}){3}(/[0-9]{1,2})?$' )
[ -n "$ips" ] || { echo "no IP read from cursor-ips.txt" >&2; exit 1; }
header="# Generated by make-allowlist.sh from cursor-ips.txt: do not edit by hand."
written=""
reload=""
if [ -d nginx ]; then
{ echo "$header"; for ip in $ips; do echo "allow $ip;"; done; echo "deny all;"; } >nginx/cursor-allowlist.conf
written="$written nginx/cursor-allowlist.conf"
reload="$reload
docker compose exec nginx nginx -s reload"
fi
if [ -d caddy ]; then
{ echo "$header"; echo "@not_cursor_ips not remote_ip" $ips; } >caddy/cursor-allowlist.caddy
written="$written caddy/cursor-allowlist.caddy"
reload="$reload
docker compose exec caddy caddy reload --config /etc/caddy/Caddyfile"
fi
[ -n "$written" ] || { echo "no nginx/ or caddy/ folder next to this script" >&2; exit 1; }
echo "$(echo "$ips" | wc -l | tr -d ' ') IPs written to$written"
echo "Reload the running proxy to apply them:$reload"
nginx/cursor-otel.conf
# nginx in front of the collector: HTTPS, Cursor IP list, body size, timeouts.
# Only POST /v1/logs and POST /v1/metrics go through; another method on these paths gets 403,
# any other path 404.
server {
listen 443 ssl;
http2 on;
server_name otel.example.com; # replace with your domain name
# A publicly trusted certificate (Let's Encrypt, a company CA trusted by browsers...):
# Cursor connects from the Internet and must be able to verify it.
ssl_certificate /etc/nginx/tls/fullchain.pem;
ssl_certificate_key /etc/nginx/tls/privkey.pem;
ssl_protocols TLSv1.2 TLSv1.3;
# Body: up to 64 MiB, like max_request_body_size in the collector.
# A 413 here is a 4xx, which Cursor does not resend.
client_max_body_size 64m;
client_body_buffer_size 1m;
# Timeouts
client_header_timeout 10s;
client_body_timeout 60s;
keepalive_timeout 75s;
proxy_connect_timeout 5s;
proxy_send_timeout 60s;
proxy_read_timeout 60s;
# Docker internal DNS, read again every 10 s: if the collector is recreated on another IP,
# nginx follows it instead of returning 502.
resolver 127.0.0.11 valid=10s;
set $collector http://collector:4318;
location ~ ^/v1/(logs|metrics)$ {
include /etc/nginx/cursor-allowlist.conf; # allow <Cursor IP>; ... deny all; -> 403
limit_except POST { deny all; }
proxy_pass $collector;
proxy_http_version 1.1;
# By default nginx passes on the request headers, including Authorization,
# Content-Type and Content-Encoding (gzip). The client origin is added.
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
}
location / {
return 404;
}
}
docker-compose.nginx.yml
# nginx with HTTPS in front of the collector. Put it next to docker-compose.yml.
# Add it to COMPOSE_FILE in .env (see .env.example), then: docker compose up -d
# Needs: ./tls/fullchain.pem and ./tls/privkey.pem, ./nginx/cursor-allowlist.conf (make-allowlist.sh).
services:
nginx:
image: nginx:1.30.8-alpine@sha256:8eb04fe3b385090e9aa02961f77398ad09b6bf33ab07f6669a5bb7acce22c0d3
ports:
- "${HTTPS_PORT:-443}:443"
volumes:
- ./nginx/cursor-otel.conf:/etc/nginx/conf.d/default.conf:ro
- ./nginx/cursor-allowlist.conf:/etc/nginx/cursor-allowlist.conf:ro
- ./tls:/etc/nginx/tls:ro
depends_on:
collector:
condition: service_healthy
restart: unless-stopped
  • Only two paths. POST /v1/logs and POST /v1/metrics reach the collector. Any other path gets 404, any other address 403. The health port, 13133, is never exposed.
  • 64 MiB, as the collector. nginx refuses bodies over 1 MB by default, with 413, which Cursor does not retry. With Caddy, write 64MiB: 64MB means 64,000,000 bytes.
  • Behind a load balancer. The proxy then sees the load balancer’s address, not Cursor’s, and refuses everything with 403. Give it the real address first: set_real_ip_from and real_ip_header for nginx, trusted_proxies and client_ip for Caddy. This case was not part of our tests.
  • From your own network, the public address answers 403. That is the allowlist working. To test the whole chain from a workstation, add its address for the time of the test: bash make-allowlist.sh 203.0.113.7, then reload the proxy (step 4).

The official Helm chart open-telemetry/opentelemetry-collector, with the same collector configuration, a persistent volume for the files and an Ingress for HTTPS. Tested on Kubernetes 1.37 with chart 0.183.2 and ingress-nginx 1.15.1.

On the cluster you need Helm, an ingress controller of class nginx (or the Gateway API, below), a default StorageClass for the volume, and a public DNS name pointing to the Ingress, with its certificate.

  1. Create the namespace, the secrets and the volume

    Put secrets.sh, below, in a folder with your certificate as fullchain.pem and privkey.pem. Run it a first time: it creates cursor-otel.env (mode 600) with a new token, which you will enter in Cursor; fill in BLOCKED_EMAILS there if needed. Run it a second time: it creates the cursor-otel namespace and the two secrets, without the token ever appearing on a command line. Then create the volume:

    Fenêtre de terminal
    bash secrets.sh # first run: creates cursor-otel.env
    bash secrets.sh # second run: creates the secrets
    kubectl apply -f pvc.yaml
  2. Install the chart

    Replace otel.example.com with your name in values.yaml (under hosts and tls), then:

    Fenêtre de terminal
    helm install cursor-otel opentelemetry-collector \
    --repo https://open-telemetry.github.io/opentelemetry-helm-charts --version 0.183.2 \
    --namespace cursor-otel -f values.yaml
  3. Check it

    Run verify-k8s.sh, below.

values.yaml
# Values for the official Helm chart open-telemetry/opentelemetry-collector (version 0.183.2)
# to receive the Cursor OTLP export. Same collector configuration as the Docker Compose setup.
#
# helm install cursor-otel opentelemetry-collector \
# --repo https://open-telemetry.github.io/opentelemetry-helm-charts --version 0.183.2 \
# --namespace cursor-otel -f values.yaml
#
# Needed in the namespace: the cursor-otel and cursor-otel-tls Secrets (secrets.sh)
# and the cursor-otel-data PVC (pvc.yaml).
mode: deployment
# A single replica: the file exporter writes to a ReadWriteOnce volume. Two pods would write
# to the same files (or each to its own, and the data would be split in two).
replicaCount: 1
# Recreate: the old pod stops before the new one opens the files.
rollout:
strategy: Recreate
image:
repository: otel/opentelemetry-collector-contrib
tag: "0.166.0"
digest: sha256:3e18fe04181de50bdd72e23ad4a4d6214b54351e63d496f1c58127cc4541ad7f
command:
name: otelcol-contrib
# Token, block list and retention, from the cursor-otel Secret (created by secrets.sh from
# cursor-otel.env: CURSOR_OTLP_TOKEN, BLOCKED_EMAILS, RETENTION_DAYS, and CURSOR_OTLP_TOKEN_NEXT
# during a rotation).
extraEnvsFrom:
- secretRef:
name: cursor-otel
# Persistent volume for the JSON Lines files (see pvc.yaml).
extraVolumes:
- name: data
persistentVolumeClaim:
claimName: cursor-otel-data
extraVolumeMounts:
- name: data
mountPath: /data
podSecurityContext:
runAsUser: 10001
runAsGroup: 10001
runAsNonRoot: true
fsGroup: 10001 # makes the volume writable by the collector user
securityContext:
readOnlyRootFilesystem: true
allowPrivilegeEscalation: false
capabilities:
drop: [ALL]
resources:
requests:
cpu: 100m
memory: 256Mi
limits:
cpu: "1"
memory: 2Gi # the chart derives GOMEMLIMIT from it (80%)
# Only the OTLP/HTTP port is used; the other chart ports are closed.
ports:
otlp:
enabled: false
jaeger-compact:
enabled: false
jaeger-thrift:
enabled: false
jaeger-grpc:
enabled: false
zipkin:
enabled: false
# The chart merges this block with its default configuration: the "null" values remove
# what the chart adds (Jaeger, Zipkin, Prometheus, gRPC, traces, debug).
config:
extensions:
bearertokenauth:
scheme: Bearer
tokens:
- ${env:CURSOR_OTLP_TOKEN}
- ${env:CURSOR_OTLP_TOKEN_NEXT:-${env:CURSOR_OTLP_TOKEN}}
health_check:
endpoint: 0.0.0.0:13133
receivers:
jaeger: null
zipkin: null
prometheus: null
otlp:
protocols:
grpc: null
http:
endpoint: 0.0.0.0:4318
auth:
authenticator: bearertokenauth
max_request_body_size: 67108864 # 64 MiB
read_header_timeout: 10s
read_timeout: 60s
processors:
memory_limiter:
check_interval: 1s
limit_percentage: 80
spike_limit_percentage: 25
# Block list: see the Docker Compose setup. Separators: comma, semicolon, space.
filter/blocklist:
error_mode: ignore
log_conditions:
- &blocked_email >-
resource.attributes["cursor.user.email"] != nil and
resource.attributes["cursor.user.email"] != "" and
ContainsValue(Split(Concat(Split(Concat(Split(ToLowerCase("${env:BLOCKED_EMAILS}"), " "), ","), ";"), ","), ","),
ToLowerCase(resource.attributes["cursor.user.email"]))
- >-
IsMatch("${env:BLOCKED_EMAILS}", "@") and
(resource.attributes["cursor.user.email"] == nil or resource.attributes["cursor.user.email"] == "") and
log.attributes["cursor.conversation.provenance"] != nil
metric_conditions:
- *blocked_email
batch: null # processor added by default by the chart: removed (see the Docker Compose setup)
exporters:
debug: null
file/logs:
path: /data/cursor-logs.jsonl
format: json
rotation:
max_megabytes: 100
max_days: ${env:RETENTION_DAYS:-90}
max_backups: 0 # 0 = no limit; if omitted, it would be 100
file/metrics:
path: /data/cursor-metrics.jsonl
format: json
rotation:
max_megabytes: 100
max_days: ${env:RETENTION_DAYS:-90}
max_backups: 0 # 0 = no limit; if omitted, it would be 100
service:
extensions: [bearertokenauth, health_check]
pipelines:
traces: null
logs:
receivers: [otlp]
processors: [memory_limiter, filter/blocklist]
exporters: [file/logs]
metrics:
receivers: [otlp]
processors: [memory_limiter, filter/blocklist]
exporters: [file/metrics]
# HTTPS exposure through ingress-nginx. Only /v1/logs and /v1/metrics are published.
ingress:
enabled: true
ingressClassName: nginx
annotations:
# Body up to 64 MiB, like the collector (above: 413, which Cursor does not resend).
nginx.ingress.kubernetes.io/proxy-body-size: "64m"
nginx.ingress.kubernetes.io/proxy-connect-timeout: "5"
nginx.ingress.kubernetes.io/proxy-send-timeout: "60"
nginx.ingress.kubernetes.io/proxy-read-timeout: "60"
# Cursor source IPs (Cursor docs, 2026-11-26). Others get 403.
nginx.ingress.kubernetes.io/whitelist-source-range: "3.208.51.163,3.209.66.12,3.218.161.44,3.224.130.48,3.231.18.206,3.234.118.132,18.210.232.136,34.197.19.148,34.198.251.120,34.199.187.247,35.170.160.152,35.174.159.35,44.215.226.85,52.44.113.131,52.202.172.69,54.81.109.217,54.204.61.44,54.236.99.119,67.202.63.191,100.63.97.141,100.63.144.57,184.73.225.134,184.193.125.229,184.193.223.40,184.194.140.210,184.194.175.144,184.194.208.56"
hosts:
- host: otel.example.com # replace with your domain name
paths:
- path: /v1/logs
pathType: Exact
port: 4318
- path: /v1/metrics
pathType: Exact
port: 4318
tls:
- secretName: cursor-otel-tls
hosts:
- otel.example.com # the same name
pvc.yaml
# Persistent volume for the collector JSON Lines files.
# ReadWriteOnce: one node at a time, hence a single collector replica.
# Without storageClassName, the cluster default class is used.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: cursor-otel-data
namespace: cursor-otel
spec:
accessModes: [ReadWriteOnce]
resources:
requests:
storage: 20Gi
reader.yaml
# One-off reader pod: the collector image has no shell, so the files are read from
# this pod, which mounts the same volume read-only.
# kubectl apply -f reader.yaml
# kubectl -n cursor-otel exec cursor-otel-reader -- cat /data/cursor-logs.jsonl | jq ...
# kubectl delete -f reader.yaml
# ReadWriteOnce volume: on a cluster with several nodes, this pod must run on the node
# of the collector (uncomment nodeName and set that node).
apiVersion: v1
kind: Pod
metadata:
name: cursor-otel-reader
namespace: cursor-otel
spec:
terminationGracePeriodSeconds: 1 # stops at once (it only sleeps)
# nodeName: <node of the collector pod>
securityContext:
runAsUser: 10001
runAsGroup: 10001
runAsNonRoot: true
containers:
- name: reader
image: busybox:1.38.0-musl@sha256:80e38f9a1b39188b8bdb28879178edb322a4402b081a9aedda1924609decd6f6
command: ["sleep", "3600"]
securityContext:
readOnlyRootFilesystem: true
allowPrivilegeEscalation: false
capabilities:
drop: [ALL]
volumeMounts:
- name: data
mountPath: /data
readOnly: true
volumes:
- name: data
persistentVolumeClaim:
claimName: cursor-otel-data
readOnly: true
secrets.sh
#!/usr/bin/env bash
# Creates or updates the two collector Secrets from files: the token never appears on
# a command line (neither in the shell history nor in "ps").
#
# First run: creates cursor-otel.env (mode 600) with a new token, then stops.
# Read the token there to enter it in Cursor, and fill in BLOCKED_EMAILS if needed.
# Second run: creates the cursor-otel Secret (from cursor-otel.env) and cursor-otel-tls
# (from fullchain.pem and privkey.pem, the certificate of your domain name).
# After any change to cursor-otel.env: run this script again, then
# kubectl -n cursor-otel rollout restart deployment cursor-otel-opentelemetry-collector
set -euo pipefail
umask 077
NS=cursor-otel
if [ ! -f cursor-otel.env ]; then
# printf is a shell builtin: the token goes through no visible process.
printf '%s\n' \
"# Token expected in \"Authorization: Bearer <token>\", the same as in Cursor." \
"CURSOR_OTLP_TOKEN=$(openssl rand -hex 32)" \
"# Rotation: add CURSOR_OTLP_TOKEN_NEXT=<new token> here for the time of the switch." \
"# Block list: addresses separated by commas, semicolons or spaces." \
"# No double quotes (the collector would not start)." \
"BLOCKED_EMAILS=" \
"# Retention of the renamed files, in days (0: never deleted)." \
"RETENTION_DAYS=90" >cursor-otel.env
echo "cursor-otel.env created (600). Fill in BLOCKED_EMAILS if needed, then run this script again."
exit 0
fi
# A double quote in BLOCKED_EMAILS stops the collector from starting: refuse it here,
# before touching the cluster (with Recreate, the old pod would already be stopped).
if grep '^BLOCKED_EMAILS=' cursor-otel.env | grep -q '"'; then
echo "Error: BLOCKED_EMAILS contains a double quote. Remove it from cursor-otel.env." >&2
exit 1
fi
kubectl get namespace "$NS" >/dev/null 2>&1 || kubectl create namespace "$NS"
# --dry-run=client -o yaml | kubectl apply --server-side: creates the Secret, or updates it.
# --server-side: no copy of the Secret (token, TLS key) in the last-applied-configuration
# annotation, and a key removed from the file disappears from the Secret.
kubectl -n "$NS" create secret generic cursor-otel --from-env-file=cursor-otel.env \
--dry-run=client -o yaml | kubectl apply --server-side -f -
kubectl -n "$NS" create secret tls cursor-otel-tls --cert=fullchain.pem --key=privkey.pem \
--dry-run=client -o yaml | kubectl apply --server-side -f -
# Secrets created earlier by a "kubectl apply" without --server-side: --server-side still
# updates their last-applied-configuration annotation (a copy of the Secret). Remove it.
kubectl -n "$NS" annotate secret cursor-otel cursor-otel-tls \
kubectl.kubernetes.io/last-applied-configuration- >/dev/null
  • One replica, Recreate. The files are written to a ReadWriteOnce volume: two pods would write to the same files. On an upgrade, the old pod stops before the new one opens them.
  • The chart adds its own defaults. It merges config with a configuration that opens Jaeger, Zipkin, gRPC, traces and a batch processor: the null values in values.yaml remove them.
  • Behind a cloud load balancer. With externalTrafficPolicy: Cluster, the default, the ingress controller sees a node’s address instead of Cursor’s, and the allowlist answers 403. Set externalTrafficPolicy: Local on the controller’s Service, or enable the PROXY protocol. This case was not part of our tests.
  • ingress-nginx is retired. The project stopped in March 2026. Keep it if you already run it; otherwise expose the collector through your Gateway API implementation, with the same three rules: the certificate, Cursor’s addresses, 64 MiB.
  • Reading the files. The collector image has no shell: reader.yaml starts a short-lived pod that mounts the same volume read-only.

The collector forwards what it receives to your tool and keeps writing the files on disk, as a local copy. Each tool takes one extra file, collector.<tool>.yaml, read by the collector after config.yaml, and on a VM one Compose overlay that passes the address and the credentials from .env. Each was tested end to end: the data was read back in the tool (for Datadog, in a local stand-in for its intake), then the tool was cut off and restored, with a restart of the collector in between, without loss. One exception, for Datadog, is explained in its tab.

  • A stop of the tool delays the data, it does not lose it. Each forwarding keeps its queue on disk (file_storage), up to 5 GiB per exporter, and retries without time limit; the queue survives a restart of the collector. In our tests, 1,000 requests with 32 KiB prompts took 35 to 40 MB of queue. Once the queue is full, the collector answers 503: Cursor replays the logs, and the metrics of that moment are kept only in the files on disk.
  • Duplicates. Cursor can deliver a log twice, with the same cursor.event.id. Remove duplicates on that field when reading, or at write time where the tool allows it (Elasticsearch, below).
  • On Kubernetes, the same blocks go under config: in values.yaml. Two examples, values.grafana.yaml and values.datadog.yaml, both deployed and tested on Kubernetes, are in the Grafana and Datadog tabs: pass them to Helm after values.yaml.

Logs to Loki and metrics to Prometheus or Mimir, both through their native OTLP endpoint. Tested with Loki and Prometheus.

collector.grafana.yaml
# Grafana: logs to Loki, metrics to Prometheus or Mimir, both over native OTLP.
# Added to config.yaml, which stays unchanged: the collector reads both files,
# and the lists below replace those of config.yaml. The JSON Lines file is kept.
extensions:
# Queue on disk, in data/queue: if Loki or Prometheus stop answering, or if
# the collector restarts, pending sends are kept and resumed.
file_storage/queue:
directory: /data/queue
create_directory: true
compaction:
directory: /data/queue
on_start: true
processors:
# Loki does not keep the OTLP event name: without this copy into an attribute (which Loki
# stores as event_name metadata), prompts and responses can no longer be told apart.
transform/loki:
log_statements:
- set(log.attributes["event.name"], log.event_name) where log.event_name != ""
# Prometheus only turns service.name and service.instance.id into labels: the series of
# two people would merge. The resource attributes (email, surface,
# team...) are copied onto each data point.
transform/prometheus:
metric_statements:
- merge_maps(datapoint.attributes, resource.attributes, "insert")
# Cursor sends delta sums; Prometheus and Mimir store cumulative totals.
# This processor adds up the deltas of each series. It keeps state in memory:
# after a restart, totals start again from zero (seen as a counter reset).
delta_to_cumulative:
max_stale: 1h
exporters:
# Loki: native OTLP endpoint, <url>/v1/logs. Example: http://loki:3100/otlp
otlp_http/loki:
endpoint: ${env:LOKI_OTLP_URL}
sending_queue:
storage: file_storage/queue
sizer: bytes
queue_size: 5368709120 # 5 GiB pending at most; above, 503 (Cursor resends the logs)
retry_on_failure:
max_elapsed_time: 0 # retries with no time limit
# Prometheus (started with --web.enable-otlp-receiver): http://prometheus:9090/api/v1/otlp
# Mimir: http://mimir:9009/otlp
otlp_http/prometheus:
endpoint: ${env:PROMETHEUS_OTLP_URL}
sending_queue:
storage: file_storage/queue
sizer: bytes
queue_size: 5368709120 # 5 GiB pending at most; above, 503 (Cursor resends the logs)
retry_on_failure:
max_elapsed_time: 0
service:
extensions: [bearertokenauth, health_check, file_storage/queue]
pipelines:
logs:
processors: [memory_limiter, filter/blocklist, transform/loki]
exporters: [file/logs, otlp_http/loki]
metrics:
processors: [memory_limiter, filter/blocklist, transform/prometheus, delta_to_cumulative]
exporters: [file/metrics, otlp_http/prometheus]
docker-compose.grafana.yml
# Adds sending to Grafana (Loki, Prometheus or Mimir) to the Docker Compose collector.
# Add it to COMPOSE_FILE in .env (see .env.example), then: docker compose up -d
# In .env:
# LOKI_OTLP_URL=http://loki.internal:3100/otlp
# PROMETHEUS_OTLP_URL=http://prometheus.internal:9090/api/v1/otlp
services:
collector:
command: ["--config=/etc/otelcol/config.yaml", "--config=/etc/otelcol/grafana.yaml"]
environment:
LOKI_OTLP_URL: ${LOKI_OTLP_URL:?set LOKI_OTLP_URL in .env}
PROMETHEUS_OTLP_URL: ${PROMETHEUS_OTLP_URL:?set PROMETHEUS_OTLP_URL in .env}
volumes:
- ./collector.grafana.yaml:/etc/otelcol/grafana.yaml:ro
  • Loki does not keep the OTLP event name: the transform/loki processor copies it, otherwise requests and responses look the same.
  • Prometheus and Mimir store totals, Cursor sends increments: delta_to_cumulative adds them up. Prometheus must be started with --web.enable-otlp-receiver.
  • In Grafana Explore: {service_name="cursor"} | event_name="cursor.conversation.user_message".

On Kubernetes:

Fenêtre de terminal
helm upgrade --install cursor-otel opentelemetry-collector \
--repo https://open-telemetry.github.io/opentelemetry-helm-charts --version 0.183.2 \
--namespace cursor-otel -f values.yaml -f values.grafana.yaml
values.grafana.yaml
# Adds sending to Grafana (Loki, Prometheus or Mimir) to the collector of the Helm chart.
# Same blocks as collector.grafana.yaml (Docker Compose setup); Helm merges them with
# values.yaml, and the lists below replace those of values.yaml.
# helm upgrade --install cursor-otel opentelemetry-collector \
# --repo https://open-telemetry.github.io/opentelemetry-helm-charts --version 0.183.2 \
# --namespace cursor-otel -f values.yaml -f values.grafana.yaml
extraEnvs:
- name: LOKI_OTLP_URL
value: http://loki.monitoring:3100/otlp # your Loki
- name: PROMETHEUS_OTLP_URL
value: http://prometheus.monitoring:9090/api/v1/otlp # your Prometheus, or Mimir: .../otlp
config:
extensions:
# Queue on disk, on the persistent volume (/data/queue).
file_storage/queue:
directory: /data/queue
create_directory: true
compaction:
directory: /data/queue
on_start: true
processors:
# Loki does not keep the OTLP event name: it is copied into an attribute.
transform/loki:
log_statements:
- set(log.attributes["event.name"], log.event_name) where log.event_name != ""
# Prometheus: resource attributes (email, surface...) copied as labels.
transform/prometheus:
metric_statements:
- merge_maps(datapoint.attributes, resource.attributes, "insert")
# Cursor deltas turned into cumulative totals.
delta_to_cumulative:
max_stale: 1h
exporters:
otlp_http/loki:
endpoint: ${env:LOKI_OTLP_URL}
sending_queue:
storage: file_storage/queue
sizer: bytes
queue_size: 5368709120 # 5 GiB pending at most; above, 503 (Cursor resends the logs)
retry_on_failure:
max_elapsed_time: 0 # retries with no time limit
otlp_http/prometheus:
endpoint: ${env:PROMETHEUS_OTLP_URL}
sending_queue:
storage: file_storage/queue
sizer: bytes
queue_size: 5368709120 # 5 GiB pending at most; above, 503 (Cursor resends the logs)
retry_on_failure:
max_elapsed_time: 0
service:
extensions: [bearertokenauth, health_check, file_storage/queue]
pipelines:
logs:
processors: [memory_limiter, filter/blocklist, transform/loki]
exporters: [file/logs, otlp_http/loki]
metrics:
processors: [memory_limiter, filter/blocklist, transform/prometheus, delta_to_cumulative]
exporters: [file/metrics, otlp_http/prometheus]

Grafana Explore showing Cursor requests in Loki, with the person’s address, the surface and the text

Grafana Explore on Loki: Cursor requests and responses, with the person’s address, the surface (desktop or cli) and the event name, sent by the collector over OTLP. Test data.

Can Cursor send straight to the tool, without a collector? Only to a Datadog Agent, and its OTLP receiver has no authentication. Loki has no metrics endpoint, Prometheus refuses Cursor’s increments, and Elasticsearch, Splunk, ClickHouse and S3 have no native OTLP endpoint in the versions tested. With a single destination in Cursor, the collector is the simplest way.

Once the collector answers on its public address, a team admin creates the destination. The steps follow Cursor’s documentation: Enable and Conversation content.

  1. Create the destination

    In the Cursor dashboard, Team Settings > OpenTelemetry Export, then Create destination. The base address is https://otel.example.com, without /v1 and without :4318: Cursor adds /v1/logs and /v1/metrics. Add the header Authorization with the value Bearer <token>, the token from .env (or from cursor-otel.env on Kubernetes).

  2. Test, then enable

    Test connection checks the address and the token. Then Enable: according to Cursor, data starts within about a minute.

  3. Allow conversation content

    Still in Team Settings > OpenTelemetry Export, turn on Allow conversation content export for the team. Then, on the destination, turn on Conversation content: Prompts and Responses turn on, Tool I/O stays off unless you turn it on.

  4. Choose what else is sent

    Each family of data has its own toggle on the destination. New families Cursor adds turn on by themselves unless you turn off auto_enable_new_families: turn it off if you want to decide on each one.

First without Cursor, on the collector’s host, with a request that imitates Cursor’s: the collector must be alive, refuse a request without the token, accept a request with it, and write it.

In the folder of docker-compose.yml, with curl and jq installed: bash verify.sh. It writes one test record, from test.otel@example.com, into your data, and into your tools if the collector forwards to them.

verify.sh
#!/usr/bin/env bash
# Check the collector without Cursor. Run it on the VM, in the folder of docker-compose.yml.
# Needs: curl and jq.
# One test record (test.otel@example.com) is written to the data, and forwarded to the
# tools connected to the collector, if any.
# The token, read from .env
TOKEN=$(grep '^CURSOR_OTLP_TOKEN=' .env | cut -d= -f2-)
# 1. The collector is running: 200 and "Server available"
curl -sS -w '\n' http://127.0.0.1:13133/
# 2. Without a token, the request is refused: 401
curl -sS -o /dev/null -w '%{http_code}\n' -X POST http://127.0.0.1:4318/v1/logs \
-H 'Content-Type: application/x-protobuf' --data-binary ''
# 3. A fake Cursor prompt, as OTLP JSON, with the token: 200 and {"partialSuccess":{}}
# The token goes through the standard input of curl (-K -): it does not show in "ps".
NOW=$(date +%s)000000000
cat >cursor-test.json <<EOF
{"resourceLogs":[{"resource":{"attributes":[
{"key":"service.name","value":{"stringValue":"cursor"}},
{"key":"cursor.team.id","value":{"intValue":"1"}},
{"key":"cursor.surface","value":{"stringValue":"cli"}},
{"key":"cursor.entrypoint","value":{"stringValue":"cli"}},
{"key":"cursor.user.id","value":{"intValue":"1"}},
{"key":"cursor.user.account_id","value":{"stringValue":"user_test"}},
{"key":"cursor.user.email","value":{"stringValue":"test.otel@example.com"}}]},
"scopeLogs":[{"scope":{"name":"cursor.telemetry","version":"0.1.0"},
"logRecords":[{"timeUnixNano":"$NOW","severityNumber":9,
"eventName":"cursor.conversation.user_message",
"body":{"stringValue":"Collector test: this prompt should appear in the output."},
"attributes":[
{"key":"cursor.event.id","value":{"stringValue":"customer-telemetry:v1:test-$NOW"}},
{"key":"cursor.conversation.id","value":{"stringValue":"test-conversation"}},
{"key":"cursor.conversation.provenance","value":{"stringValue":"server"}},
{"key":"cursor.conversation.message.id","value":{"stringValue":"test-message"}},
{"key":"cursor.conversation.content_truncated","value":{"boolValue":false}}]}]}]}]}
EOF
printf 'header = "Authorization: Bearer %s"\n' "$TOKEN" |
curl -sS -K - -w '\n%{http_code}\n' http://127.0.0.1:4318/v1/logs \
-H 'Content-Type: application/json' --data-binary @cursor-test.json
rm cursor-test.json
# 4. Read the last 5 prompts written: email, surface, text. The 200 comes after the write.
# data/ belongs to the collector user (10001): read it with sudo.
sudo jq -r '.resourceLogs[]
| (.resource.attributes | map({(.key): .value.stringValue}) | add) as $r
| .scopeLogs[].logRecords[]
| select((.eventName // (.attributes[] | select(.key == "event.name") | .value.stringValue))
== "cursor.conversation.user_message")
| [$r["cursor.user.email"], $r["cursor.surface"], .body.stringValue] | @tsv' data/cursor-logs.jsonl | tail -n 5

Expected output, line by line: the health status, 401, the collector’s acknowledgement and 200, then the address, the surface and the text of the test request.

{"status":"Server available","upSince":"2026-11-26T21:19:45.435442802Z","uptime":"6.11524917s"}
401
{"partialSuccess":{}}
200
test.otel@example.com cli Collector test: this prompt should appear in the output.

Then with Cursor: once the destination is enabled, send a request to Cursor’s agent, in the editor or the CLI. It appears in data/cursor-logs.jsonl within a minute, as a cursor.conversation.user_message record, followed by cursor.conversation.assistant_message for the response.

BLOCKED_EMAILS, in .env (or in the Kubernetes secret), lists the addresses for which nothing is kept: their requests, their responses, their usage and their metrics are dropped by the collector before anything is written or forwarded.

  • Separate the addresses with commas, semicolons or spaces. Case does not matter.
  • No double quote in the list: the collector would not start. On a VM, validate, below, catches it; on Kubernetes, secrets.sh refuses it.
  • While the list is not empty, conversation content without an address is dropped too, since it cannot be checked.
  • After a change, apply it with sudo docker compose up -d. On Kubernetes, run bash secrets.sh again, then kubectl -n cursor-otel rollout restart deployment cursor-otel-opentelemetry-collector.
  • The list relies on cursor.user.email. Cursor does not send it for a team in Privacy Mode (Legacy), nor for a run without an owner, such as a Cloud Agent started with a team API key.
  • The data still leaves Cursor and reaches your collector, which drops it. Cursor’s documentation also says that a member’s turns in Privacy Mode (Legacy) are never exported.
  • Retention. RETENTION_DAYS (90 by default) removes renamed files older than that, at each rotation. Rotation only happens at 100 MB: with little traffic, also schedule the purge below, with your own number of days in place of 90. The current file is never removed.

    Fenêtre de terminal
    sudo find data -name 'cursor-*-size.jsonl' -mtime +90 -print -delete

    Every night at 3, in root’s crontab (sudo crontab -e), with the path of your folder:

    0 3 * * * cd /home/admin/cursor-otel && find data -name 'cursor-*-size.jsonl' -mtime +90 -delete
  • Reading the files. data/ belongs to the collector’s user, mode 700: read it with sudo, as in verify.sh.

  • Changing the token without losing data. A 401 is not retried by Cursor, so the old and the new token must both be accepted for a while. The four steps, tested with continuous traffic and without a single 401, are also in .env.example:

    1. Generate a new token with openssl rand -hex 32, write it in CURSOR_OTLP_TOKEN_NEXT, then run sudo docker compose up -d: both tokens are accepted.
    2. In Cursor, edit the destination and save the new token. Do not delete and recreate it: according to Cursor, that drops the data in flight. The change takes effect in about 30 seconds.
    3. Wait a few minutes.
    4. Copy the new token into CURSOR_OTLP_TOKEN, empty CURSOR_OTLP_TOKEN_NEXT, then run sudo docker compose up -d again.

    On Kubernetes, the same steps happen in cursor-otel.env, applied with bash secrets.sh, then kubectl -n cursor-otel rollout restart deployment cursor-otel-opentelemetry-collector.

  • Updating the collector. The image is pinned by its digest. To move to a new version, change the tag and the digest in docker-compose.yml, validate the configuration, then restart. If the collector forwards to a tool, add its file to the validation, for example --config=/etc/otelcol/grafana.yaml:

    Fenêtre de terminal
    sudo docker compose run --rm --no-deps collector validate --config=/etc/otelcol/config.yaml
    sudo docker compose up -d

    Some components used here are still in alpha (the filter processor, the file exporter): their settings can change between versions, which is one more reason to validate before each upgrade. On Kubernetes, change image.tag and image.digest in values.yaml, then run the helm upgrade --install command of the tools section, with your own -f files.

  • Watching it. The Docker health check, or the pod’s readiness, says whether the collector is alive. Watch the disk of data/, the size of data/queue/ if the collector forwards to a tool, and, in Cursor, the destination’s status.

Family Default What it carries
model_usage On Tokens, estimated cost, API requests, errors
tool_calls On Tool calls, as metrics
skills_hooks_plugins On Skills, hooks and plugins used
cloud_agents On Cloud Agent lifecycle events
grok_bot_agent_actions On, if Action Recording is on Grok Bot actions
conversation_content Off Text of requests (cursor.conversation.user_message), responses (cursor.conversation.assistant_message), and on request tool inputs and outputs (cursor.conversation.tool_io)

Source: Cursor’s Wire Reference, which lists every event and attribute.

  • Who and where. Each record carries the team, the surface (desktop for the editor, cli, sdk, cloud_agent, bugbot, grok_bot, or unspecified) and, when known, the person: cursor.user.email, cursor.user.account_id.
  • Cleaned and capped by Cursor. Cursor removes the secrets it recognizes from the text before sending, and caps each message at 32 KiB, tool inputs and outputs at 8 KiB.
  • At least once. A log can arrive twice, with the same cursor.event.id. Metrics are increments, at most once.
  • Not sent. Turns from before the export was turned on, subagents a local agent starts, Tab and inline edit, and turns from a member in Privacy Mode (Legacy). Delivery is best effort: a turn can be missing.
Symptom Cause Fix
Test connection fails in Cursor The certificate, the allowlist or the token. Read the proxy’s log: the method, the path and the status Cursor received.
After docker compose up -d, nothing reaches the tool any more Compose started without the overlay files. Declare them in COMPOSE_FILE, in .env.
503 “sending queue is full” in the logs The tool has been unreachable for a long time. Restore the tool: the queue empties, and Cursor replays the refused logs.
docker compose up refuses to start: “set CURSOR_OTLP_TOKEN” The token is empty in .env. Write it (step 2 above).
401 on every request Wrong or missing token, or another scheme than Bearer. The header in Cursor is Authorization with Bearer <token>, the token from .env.
403 through the public address The address is not on Cursor’s list, or a load balancer hides it. Normal from your network. Behind a load balancer, give the proxy the real address.
413 through the proxy nginx’s default limit is 1 MB. client_max_body_size 64m, or proxy-body-size: "64m" on ingress-nginx.
400 “request body too large” The request is over 64 MiB after decompression. Raise max_request_body_size, and the proxy’s limit with it.
503 and “no space left” in the logs The disk of data/ is full. Free space: Cursor replays the logs.
permission denied on /data The folder belongs to root. The prepare task fixes it on start: sudo docker compose up -d.
The collector does not start: “condition failed to parse” A double quote in BLOCKED_EMAILS. Remove it.
An excluded address still appears Case, spaces or separators. The list accepts all three; check the spelling of the address.
source .env prints “command not found” .env is read by Compose, not by the shell. Read a value with grep '^NAME=' .env | cut -d= -f2-.
Files older than RETENTION_DAYS stay Removal happens only at a rotation. Schedule the purge find command.
The same request twice in the files Cursor delivers logs at least once. Remove duplicates on cursor.event.id when reading.
413 from Caddy at exactly 64 MiB 64MB means 64,000,000 bytes. Write 64MiB.
In Loki, requests and responses look the same Loki does not keep the event name. The transform/loki processor.
Prometheus answers 500 “invalid temporality” Cursor sends increments. The delta_to_cumulative processor.

Does any data go to Idun through this setup?

Section titled “Does any data go to Idun through this setup?”

No. Cursor sends to your collector, which writes to your disk or your tools. How Idun Cockpit reads these data is agreed at the start of the audit: read access to the storage, or the Cockpit installed in your infrastructure.

No. The export runs on Cursor’s servers, after the fact. Nothing runs on workstations.

Can we get the history from before the export?

Section titled “Can we get the history from before the export?”

Not through the export: it starts when the destination is enabled. Past usage and cost per person, per model and per conversation come from Cursor’s Admin API, without the text of conversations.

Why not the batch processor, as in Cursor’s example?

Section titled “Why not the batch processor, as in Cursor’s example?”

Because it answers Cursor before writing. In our tests, with a full disk, Cursor received 200 and the data was lost. Without it, 200 means “written”, and an error goes back to Cursor, which retries the logs.

To see what the tool shows on your own tools, book a call.