From 0216c969b85614fd986d59f4d9fcf4ccc25dfce2 Mon Sep 17 00:00:00 2001 From: yucheng-berri Date: Fri, 26 Jun 2026 20:39:39 -0700 Subject: [PATCH] fix(otel): point AgentOps OTLP exporter at otlp.agentops.ai (#31490) The AgentOps preset hardcoded https://otlp.agentops.cloud/v1/traces, a domain that no longer resolves (NXDOMAIN), so every span silently failed to export with a NameResolutionError in the BatchSpanProcessor worker. The live ingest host is otlp.agentops.ai (the auth host api.agentops.ai was already correct). Pin the endpoint to the resolvable host and add a regression test on the constant. --- litellm/integrations/otel/presets/agentops.py | 2 +- .../integrations/otel/test_otel_v2_presets.py | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/litellm/integrations/otel/presets/agentops.py b/litellm/integrations/otel/presets/agentops.py index 7b0783935ac..5d3ed91a711 100644 --- a/litellm/integrations/otel/presets/agentops.py +++ b/litellm/integrations/otel/presets/agentops.py @@ -23,7 +23,7 @@ from litellm.integrations.otel.model.config import ( ) from litellm.integrations.otel.plumbing.providers import register_exporter_factory -_AGENTOPS_ENDPOINT = "https://otlp.agentops.cloud/v1/traces" +_AGENTOPS_ENDPOINT = "https://otlp.agentops.ai/v1/traces" _AGENTOPS_AUTH_ENDPOINT = "https://api.agentops.ai/v3/auth/token" _AGENTOPS_EXPORTER_KIND = "agentops" diff --git a/tests/test_litellm/integrations/otel/test_otel_v2_presets.py b/tests/test_litellm/integrations/otel/test_otel_v2_presets.py index 13d2ac74ad2..add2caf9a48 100644 --- a/tests/test_litellm/integrations/otel/test_otel_v2_presets.py +++ b/tests/test_litellm/integrations/otel/test_otel_v2_presets.py @@ -151,3 +151,12 @@ def test_fetch_jwt_uses_owned_client_not_shared_pool(monkeypatch): result = _fetch_agentops_jwt("api-key") assert result == {"token": "jwt-123"} assert closed["n"] == 1 # the owned client was closed + + +def test_agentops_endpoint_points_at_live_host(): + # Regression: the OTLP endpoint must be the resolvable AgentOps host. The + # deprecated otlp.agentops.cloud domain no longer resolves (NXDOMAIN), so + # spans silently failed to export with a NameResolutionError. Pin the host + # so a typo or stale domain can never ship again. + assert _AGENTOPS_ENDPOINT == "https://otlp.agentops.ai/v1/traces" + assert "agentops.cloud" not in _AGENTOPS_ENDPOINT