Content-Type: application/json for JSON, or
Content-Type: application/x-protobuf for protobuf. Gzip and deflate
request-body compression are supported for protobuf through the standard
Content-Encoding header. Send JSON exports uncompressed.
This endpoint supports OTLP/HTTP only; OTLP/gRPC is not supported.
This endpoint ingests OTLP traces. OTLP metrics and logs are not accepted today.
Prerequisites
Get your write key by logging in to app.raindrop.ai. Send it as a bearer token:400; an inactive or disallowed project
returns 403. See the HTTP API reference for the full
project behavior table.
Send a trace with curl
This sends one OTLP/HTTP JSON export with a model, token usage, input message, and output message:ExportTraceServiceResponse in the same encoding as
the request. For protobuf, send a protobuf-encoded
ExportTraceServiceRequest body with
Content-Type: application/x-protobuf. Compression can be enabled for
protobuf by sending the encoded body with Content-Encoding: gzip (or
deflate). JSON exports should be sent uncompressed.
OpenTelemetry Collector
Configure the Collector’sotlphttp exporter with the Raindrop endpoint and
write key:
/v1/traces to the endpoint. You can
also set the exporter endpoint explicitly to
https://api.raindrop.ai/v1/traces.
Standard OTLP environment variables
The standard OTLP environment variables are the language-agnostic way to configure an OTLP exporter:%20 encodes the space after Bearer, which opentelemetry-python and other
SDKs URL-decode when reading these variables.
OpenTelemetry SDKs
TypeScript
Use the OpenTelemetry OTLP/HTTP trace exporter:await sdk.shutdown() after creating spans so
the exporter flushes before exit.
Python
Use the standard OTLP environment variables above with the Python OTLP/HTTP exporter, keeping the%20 after Bearer.
Attributes Raindrop maps
These current GenAI semantic conventions populate the corresponding span and interaction fields:gen_ai.systemidentifies the provider, and marks the span as an LLM call. Set it on every span you want treated as a generation.gen_ai.response.modelpopulates the model.gen_ai.usage.input_tokensandgen_ai.usage.output_tokenspopulate token usage. Send both, alongsidegen_ai.response.model.gen_ai.input.messagesandgen_ai.output.messagespopulate input and output messages. Use JSON arrays of message objects withroleandcontentfields; content can be text or structured parts.gen_ai.system_instructionspopulates system instructions.
Limits and troubleshooting
The default rate limit is 1,000 requests per 60 seconds per write key. Organizations may have a different configured limit. When the endpoint returns429, honor Retry-After: 60 and retry with backoff. Batch spans through the
Collector or SDK exporter rather than sending one request per span.
The route treats application/json as OTLP/HTTP JSON and everything else,
including a missing content type, as protobuf. Always set Content-Type
explicitly.
gzip and deflate are the supported Content-Encoding values; any other
value, including zstd, returns 400. A request body that exceeds 32 MiB once
decompressed returns 413.