OpenTelemetry traces

Enable authenticated OTLP HTTP export, understand injected OTEL_* environment variables, inspect span waterfalls, and rotate ingestion tokens.

Traces connect incoming HTTP handlers, database queries, queue jobs, and outbound calls into one timeline linked directly to the deployed revision that served them.

Enable and instrument tracing

New applications start with Tracing enabled and an OTLP ingestion token provisioned automatically. For older apps, open Settings, turn on Tracing, and run Deploy/Redeploy.

  • Go, Node.js (18.19+), Python (3.10+), Java, and .NET (8+) on Railpack: Instrumented automatically via automatic Railpack instrumentation.
  • Dockerfiles, Nixpacks, Next.js 15+, Fastify, or custom builds: Install the 2–3 line Formatio SDK hook from tracing setup and SDKs (or any standard OTel SDK exporting OTLP HTTP).

Platform-injected OTLP variables

Every deployment with tracing enabled receives standard OpenTelemetry variables automatically—zero collector sidecars required:

Variable Injected value or role
OTEL_EXPORTER_OTLP_ENDPOINT Internal OTLP HTTP base endpoint (POST /otlp/v1/traces)
OTEL_EXPORTER_OTLP_PROTOCOL http/protobuf (receiver also accepts OTLP JSON over HTTP; not gRPC)
OTEL_EXPORTER_OTLP_HEADERS authorization=Bearer <token> application ingestion header
OTEL_SERVICE_NAME Formatio application name
OTEL_RESOURCE_ATTRIBUTES Deployment ID (formatio.deployment.id), deployed Git SHA (service.version) for Git builds, and environment (deployment.environment) when configured

To label spans with an environment such as staging or production, set OTEL_DEPLOYMENT_ENVIRONMENT as a non-secret application variable. Formatio does not infer it from the Git branch or the control plane's environment.

[!WARNING] Custom OTEL_* keys explicitly saved in an application's Environment tab override Formatio's automatic defaults. Remove conflicting OTEL_EXPORTER_OTLP_* variables if spans are still routing to a legacy collector.

Export from external or local processes

To send traces from a development laptop or external job into a Formatio application, copy the public OTLP endpoint and ingestion token from Settings › Tracing:

export OTEL_EXPORTER_OTLP_ENDPOINT='https://your-formatio-host/otlp'
export OTEL_EXPORTER_OTLP_PROTOCOL='http/protobuf'
export OTEL_EXPORTER_OTLP_HEADERS='authorization=Bearer REPLACE_INGESTION_TOKEN'
export OTEL_SERVICE_NAME='your-application'

Use a dedicated development/staging application token rather than mixing local test spans into production telemetry.

Search and inspect span waterfalls

Open Tools › Traces to filter by project, application, time window, error status, and minimum duration:

  1. Start with failing (Status: Error) or slow outlier traces.
  2. Click any trace to inspect its full parent-child waterfall, span kind (server, client, internal), attributes, and recorded exceptions.
  3. Spans crossing projects or applications outside your member access appear masked rather than exposing restricted application details.

[!NOTE] Your coding agent can query the exact same waterfall via get_trace over /mcp without opening a browser tab.

Token rotation and disabling intake

  • Rotate token: Click rotate in Settings › Tracing, redeploy platform-hosted services, and update external exporters. The previous token remains valid during a 24-hour overlap window to prevent trace drops during rollouts.
  • Disable intake: Switching tracing off stops intake immediately without removing SDK code from your repository.

Further reading