Accepts a DatadogApmConfig or plain options.
The SaaS spans query API (created on first use, closed by close). Throws
ConfigError when apiKey or appKey is missing.
Flushes and shuts down every tracing handle started with initTracing, then releases connections. Idempotent.
Agent liveness: GET /info. healthy with status ok and details version, git_commit
when the Agent answers; unreachable on network errors, unhealthy on HTTP errors. Never
throws except for CANCELLED and CONFIG.
initTracing with this client's configuration as the defaults (Agent host, OTLP endpoint and protocol, service/env/version, tags). close shuts the handle down.
Round trip to the Agent (GET /info), returning the latency in ms. The Agent has no
authentication; to check Datadog API credentials use client.spans.ping().
Datadog Agent version from GET /info (e.g. 7.85.4); UnsupportedError when absent.
StaticfromBuilds a client from GROW_DATADOG_APM_* and DD_* environment variables.
Client for Datadog APM.
health(),ping()andserverVersion()use the Datadog Agent'sGET /info; initTracing sets up OpenTelemetry exporting to the Agent; spans is the SaaS query API (needsapiKey+appKey).Example