当在您的测试框架中运行的智能体向工具发送了错误的参数,或者某一步骤耗时两分钟时,请求日志并不能提供太多信息。它单独显示每次调用,因此您无法看到运行中的哪一步出错或为何出错。
智能体追踪(Agent tracing)提供了这种视角。它将运行的每一步记录为带时间戳的跨度(span),并将这些跨度链接为一个完整的追踪(trace)。您的代码记录工具调用以及运行的结束方式,而 OpenRouter Broadcast 记录每次模型生成和每次提供商尝试。双方均使用 OpenTelemetry,因此它们的跨度落入同一个追踪中,您可以从头到尾阅读一次运行过程。
我们对一个订单支持智能体在三个模型上进行了 27 次运行追踪,并将两组跨度发送到 Jaeger。智能体自身的跨度在所有 9 次模型发送错误参数的运行中都捕获到了该问题。我们的跨度显示了每次调用由哪个提供商服务,记录了三次我们成功恢复的提供商故障,并显示一次耗时 133 秒的模型调用几乎全部时间都花在等待提供商上。
简而言之
在您的代码中记录工具调用和运行过程,并添加一个 Broadcast 目标以获取我们针对每次生成和提供商尝试的跨度。
在请求的 trace 字段中传递您的追踪 ID 和跨度 ID,我们将把我们的跨度放入您的运行中。
TypeScript SDK 使用驼峰式命名键(traceId, parentSpanId),而原始 HTTP 请求体使用蛇形命名法。
隐私模式会删除提示词和补全文本,但保留令牌、成本和计时信息。
在 27 次运行中,所有 98 次模型调用都与我们的一次生成跨度匹配,且双方的成本一致。
什么是智能体追踪?
追踪是一次智能体运行的记录,由多个跨度组成。每个跨度是一个带时间戳的步骤,例如整个运行、一次模型调用、一次工具调用或一次提供商尝试。共享追踪 ID 并指向父节点的跨度形成一棵树,这正是 LLM 追踪与普通日志(每行独立存在)的区别所在。
您系统的每一侧只能看到树的一部分。您的智能体代码知道它发送给每个工具的内容以及运行如何结束,但不知道哪次提供商服务了模型调用、我们是否用其他提供商进行了重试,或者提供商发送首个令牌耗时多久。我们知道所有这些情况,但无法看到您的工具在回合之间做了什么。
双方均以 OpenTelemetry 协议(OTLP)格式发送跨度,因此此设置可接入您已用于 LLM 可观测性的任何后端。当每个请求都携带您的追踪 ID 和跨度 ID 时,后端会将两侧合并为一棵树。
智能体追踪应包含什么?
从您自己的代码中,您需要为运行创建一个跨度,为每次模型调用创建一个跨度,并为每次工具调用创建一个跨度。OpenRouter Agent SDK 的生命周期钩子(lifecycle hooks)为您提供每个钩子的数据。SessionEnd 告诉您运行为何结束(完成、错误、最大回合数或用户终止)。PostModelCall 为您提供生成 ID(responseId)、模型、持续时间、回合号以及带有成本的令牌使用情况,但不包括提示词或回复内容。PostToolUse 为您提供工具名称、参数、输出和持续时间,而 PostToolUseFailure 为您提供工具名称、参数和错误信息。
从我们这边来看,Broadcast 为每次模型调用发送一个 LLM Generation 跨度,无需您编写任何代码。它包含模型、提供商、令牌、成本、用户 ID、路由计时以及提供商的首个令牌时间。如果您在“附加生成元数据”中开启 Cost 选项,它还会携带计费字段,如 billed_service_tier 和 upstream_id(提供商自己的请求 ID)。
每个生成跨度有两种子跨度。一种称为 provider attempt span(提供商尝试跨度),命名方式如 “provider attempt 1: Google”,记录每次尝试及其各自的状态和持续时间。在我们的测试中,一次仅有一次尝试的调用,其尝试跨度的持续时间正好等于提供商的首个令牌时间。另一种生成跨度涵盖首个令牌之后的流式传输过程。
在智能体启动时打开运行跨度,从每个生命周期钩子添加子跨度,并在运行结束时关闭运行跨度,即使运行失败也是如此。
当 PostToolUseFailure 事件触发时,将工具跨度标记为错误并保留消息,以便即使模型修复了参数,错误的参数依然显眼。在您的模型调用跨度上存储 responseId,因为它与我们生成跨度上的 gen_ai.response.id 相匹配。此外,在 catch 块中将运行跨度也标记为错误,因为如果请求在返回完整响应之前失败,PostModelCall 不会触发。
同时在 user 字段中传入客户 ID。我们将其记录为 user.id,因此您可以按客户筛选两侧的数据。用户跟踪指南涵盖了如何选择稳定 ID 的方法。
如何将我们的跨度添加到代理的追踪中?
在“设置 > 可观测性”下添加一个 Broadcast 目标,然后在每次请求时发送您的 trace id 和 span id。Broadcast 可以发送到 Langfuse、Datadog、OpenTelemetry Collector、Webhook 以及许多其他目标。我们在每个请求完成后发送追踪数据,因此 Broadcast 不会拖慢您的响应速度。在我们的测试中,Jaeger 运行在一台 Broadcast 无法访问的笔记本电脑上,所以我们使用了一个 Webhook 目标和一个小型中继,将每个有效负载转发到 Jaeger。
请求的 trace 字段接受 trace_id、parent_span_id、trace_name、span_name 和 generation_name,任何其他键都会显示为 trace.metadata。使用 Agent SDK 时,您从运行跨度中获取 ID 并以 camelCase(小驼峰命名法)传入。
const { traceId, spanId } = runSpan.spanContext();
const result = callModel(client, {
model: "anthropic/claude-haiku-5.5",
input: prompt,
tools,
user: customerId,
trace: { traceId, parentSpanId: spanId, traceName: "support-agent run" },
hooks,
});
这里 client 是一个 OpenRouter 实例,callModel 来自 @openrouter/agent。每个生成跨度都返回了运行的 trace id 并将运行跨度作为其父跨度。这将它与匹配的模型调用跨度并列放置,并且 generation id 将两者对齐。
如果不使用 SDK,请将 ID 放入请求体中。
{
"model": "anthropic/claude-haiku-5.5",
"messages": [{ "role": "user", "content": "Where is my order ORD-10442?" }],
"user": "customer_8812",
"trace": {
"trace_id": "4bf92f3577b34da6a3ce929d0e0e4736",
"parent_span_id": "00f067aa0ba902b7",
"trace_name": "support-agent run"
}
}
在设置过程中我们犯了两个错误。首先,我们将 bcast_test_001 作为 trace id 发送。真实的 trace id 是 32 位十六进制字符,span id 是 16 位,因此我们的跨度返回了一个不匹配任何内容的不同 trace id。从 spanContext() 获取 ID 可避免此问题。
其次,我们将 snake_case(蛇形命名法)键传递给了 TypeScript SDK。TypeScript 拒绝 trace: { trace_id, parent_span_id } 并报错 TS2353。当我们通过类型强制转换强行通过时,SDK 未抛出错误并发送了一个空的 trace 对象,导致四次模型调用各自落入独立的追踪中。使用 camelCase 键后,所有四次调用都合并在一起了。
如何在不向追踪供应商发送提示的情况下追踪 LLM 调用?
在 Broadcast 目标的隐私部分开启隐私模式(Privacy Mode)。您可以按目标进行设置,因此可以将完整追踪发送到其中一个目标用于调试,将私有追踪发送到另一个目标用于成本跟踪。
开启隐私模式后,我们在发送追踪之前移除提示、回复和错误文本。我们以这种方式运行了所有 27 次测试运行,并在每个有效负载中搜索来自我们提示和工具结果的词汇,结果均未出现。tokens、cost、model、provider 和 user.id 出现在每个生成跨度上,失败的 provider 尝试保留了其 HTTP 状态码。
仍有一些内容会发送出去。模型参数被保留,包括任何停止序列,因此我们的测试停止序列 PRIVATE_STOP_TEST 显示为 gen_ai.request.stop_sequences,自定义追踪元数据仍然导出。每个生成跨度还携带您的 OpenRouter 账户的 user id 和发起请求的 API key 名称。
如果你完全无法向外部供应商发送提示,请将你的工具跨度(spans)发送到你自行运行的后端,并让 Broadcast 在开启隐私模式的情况下添加我们的跨度——确保自定义追踪元数据和调用者提供的停止序列严格保持非敏感状态;如果无法保证这一点,则干脆禁用追踪导出。
在 27 次智能体运行中,各方分别捕获到了什么?
我们使用 @openrouter/agent 0.11.0 并为户外装备商店构建了一个订单支持智能体,步骤限制为 8 步。其 lookup_order 工具会拒绝任何看起来不像 ORD-12345 的 ID,尽管其描述中并未说明这一点。get_shipment 工具总是回答“待处理,请稍后重试”,而 issue_refund 则接受以分为单位的金额。
我们给它布置了三项任务。一位顾客询问关于“订单 10442”的情况,但未加上 ORD- 前缀;另一位顾客询问为何订单 ORD-10518 尚未送达;还有一位顾客希望退还订单 ORD-10377 中两个头灯之一的款项。
2026 年 11 月 10 日,我们在 Gemini 3.8 Flash、Claude Haiku 5.5 和 DeepSeek V4.1 Flash 上分别运行了每项任务三次。这 27 次运行共进行了 98 次模型调用,总成本为 0.0227 美元。每次模型调用都精确对应我们的一次生成跨度(generation span),且每个跨度上的成本与 SDK 报告的成本相等。
智能体的跨度 vs OpenRouter 的跨度
模型发送了 10442 而非 ORD-10442,工具返回“order_id 必须看起来像 ORD-12345,收到 ‘10442’” 9/9 次。带有错误参数的失败 lookup_order 跨度。模型在 8/9 次运行中重试了 ORD-10442。多了一次生成,但未说明原因
承运人从未回复 9/9 次。每次 get_shipment 调用。Gemini 在每次运行中调用了两次,Haiku 一次,DeepSeek 一次或两次。每次调用多一次生成
智能体退还了一个头灯的费用 9/9 次正确。精确的参数(金额:4999,SKU LAMP-400)。未提及金额
哪个供应商处理了每次调用 全部 98 次调用。不可见。Gemini 通过 Google Vertex AI(35 次)和 Google AI Studio(3 次),Haiku 通过 AWS 上的 Claude Platform(30 次),DeepSeek 跨越九个供应商
某个供应商失败,OpenRouter 尝试了另一个供应商 3 次生成,均发生在同一次 Gemini 运行中。缓慢的模型调用。每次尝试都包含 HTTP 状态码和持续时间
没有运行以错误结束,但两次 Gemini 3.8 Flash 的运行展示了各方所看到的对方无法看到的内容。
最慢的一次运行耗时 151.7 秒。智能体的跨度显示一次模型调用耗时 133.5 秒,而我们的生成跨度显示该尝试中等待 Google 的时间为 131.2 秒。这次调用几乎全部时间都花在等待 Google 的第一个 token 上。
另一次是退款运行,耗时约 48 秒。其第一次模型调用在 10,282 毫秒后从 Google 收到 504 错误,随后我们在 2,044 毫秒内收到了来自 Google AI Studio 的响应。接下来的两次调用在 Google 返回 400 错误后也发生了同样的情况。智能体的跨度仅显示了缓慢的模型调用。在同一次运行中,SDK 为其第二次模型调用发送了两次 HTTP 请求,而我们仅对其中一次请求生成了跨度,该生成开始于智能体模型调用跨度之后 11.4 秒。我们没有记录未答复请求的去向,但这些秒数仅出现在智能体的追踪记录中。
我们的跨度还解释了模型之间的速度差异,这是你自己的代码无法测量的 LLM 监控部分。下表显示了一次模型调用的中位数。
| 模型 | 你的智能体看到的内容(SDK durationMs) | OpenRouter 生成跨度 | 供应商到达第一个 token 的时间 |
|---|---|---|---|
| Gemini 3.8 Flash | 3,154.5 ms | 2,454.5 ms | 1,963.5 ms |
| Claude Haiku 5.5 | 2,149.8 ms | 1,490.5 ms | 1,177.0 ms |
| DeepSeek V4.1 Flash | 1,848.2 ms | 1,350.5 ms | 769.0 ms |
智能体的数值比我们的数值长 498 到 700 毫秒,因为它们还计算了 OpenRouter 之外的时间,例如网络往返时间。Gemini 到达第一个 token 的中位时间约为 Haiku 的 1.7 倍,DeepSeek 的 2.6 倍。
常见问题
LLM 追踪(tracing)和日志记录(logging)有什么区别?
日志行记录其自身的一个事件。追踪(Trace)将一次运行中的每个步骤与时间戳及父子关系关联起来,从而让你看清哪个步骤引发了下一步,以及时间都花在了哪里。
OpenTelemetry 适用于 LLM 智能体吗?
是的。我们的智能体跨度(spans)和我们的 Broadcast 跨度均使用 OTLP,当每个请求携带运行的 trace_id 和 parent_span_id 时,它们便汇入同一个 Jaeger 追踪中。
我能否在不使用 OpenRouter Agent SDK 的情况下追踪 LLM 调用?
可以。任何智能体循环都可以为每次工具调用和模型调用开启一个跨度,且带有 trace_id 和 parent_span_id 的 trace 字段适用于任何 OpenRouter 请求。
我能否在记录提示词(prompts)的情况下追踪 LLM 调用?
可以。为 Broadcast 目标启用隐私模式,我们将剥离提示词、回复和错误文本,同时仍发送令牌数、成本、时间戳以及提供商信息。请注意,停止序列(stop sequences)仍会被发送。
我能否仅发送部分追踪数据?
可以。每个 Broadcast 目标都有各自的采样率,因此 0.5 的速率会发送约一半的追踪数据。当你传入 session_id 时,采样会将整个会话一起保留或丢弃。你还可以选择目标接收来自哪些 API 密钥的追踪数据,或排除某些密钥。
后续步骤
通过 Broadcast 指南设置一个目标。OpenTelemetry Collector 将我们的跨度发送至任何 OTLP 后端,而 Webhook 让你自行处理数据。然后,使用 Agent SDK 生命周期钩子为智能体添加工具和模型跨度,并在每个请求中传入用户 ID,以便按客户筛选双方数据。一旦你能看清每位客户的成本,我们的团队支出控制设置指南将向你展示如何设定上限。
When an agent running in your harness sends a tool the wrong argument, or one step takes two minutes, a request log will not tell you much. It shows each call on its own, so you cannot see which step in the run went wrong or why.
Agent tracing gives you that view. It records each step of a run as a timed span and links the spans into one trace. Your code records the tool calls and how the run ended, and OpenRouter Broadcast records each model generation and each provider attempt. Both sides use OpenTelemetry, so their spans land in the same trace and you can read one run from start to finish.
We traced 27 runs of an order-support agent on three models and sent both sets of spans into Jaeger. The agent’s own spans caught the bad tool argument in all 9 runs where the model sent one. Our spans showed which provider served every call, recorded three provider failures we recovered from, and showed that a 133-second model call was almost all spent waiting on the provider.
Tl;dr
Record tool calls and the run in your own code, and add a Broadcast destination to get our spans for each generation and provider attempt.
Pass your trace id and span id in the request’s trace field, and we place our spans inside your run.
The TypeScript SDK takes camelCase keys (traceId, parentSpanId), while a raw HTTP body takes snake_case.
Privacy Mode drops prompt and completion text but keeps tokens, cost, and timing.
In 27 runs, all 98 model calls matched one of our generation spans, with the same cost on both sides.
What is agent tracing?
A trace is the record of one agent run, and it is made of spans. Each span is one timed step, such as the whole run, a model call, a tool call, or a provider attempt. Spans that share a trace id and point to a parent form a tree, which is what separates LLM tracing from plain logging, where every line stands alone.
Each side of your system sees part of the tree. Your agent code knows what it sent to each tool and how the run ended, but not which provider served a model call, whether we retried with another provider, or how long the provider took to send its first token. We know all of that, but we cannot see what your tools did between turns.
Both sides send spans in the OpenTelemetry Protocol (OTLP) format, so this setup feeds any backend you already use for LLM observability. When every request carries your trace id and span id, the backend puts both sides in one tree.
What should an agent trace include?
From your own code, you want a span for the run, one for each model call, and one for each tool call. The OpenRouter Agent SDK lifecycle hooks give you the data for each. SessionEnd tells you why the run ended (complete, error, max_turns, or user). PostModelCall gives you the generation id (responseId), the model, the duration, the turn number, and token usage with cost, but not the prompt or reply. PostToolUse gives you the tool name, arguments, output, and duration, and PostToolUseFailure gives you the tool name, arguments, and error.
From our side, Broadcast sends an LLM Generation span for every model call, with no code on your part. It holds the model, the provider, tokens, cost, user.id, router timing, and the provider’s time to first token. If you turn on Cost under Additional generation metadata , it also carries billing fields such as billed_service_tier and upstream_id, the provider’s own request id.
Each generation span has two kinds of child span. A provider-attempt span, named like provider attempt 1: Google, records each attempt with its own status and duration. In our test, a call with one attempt always had an attempt span exactly as long as the provider’s time to first token. A generation span covers the streaming after the first token.
Open a run span when the agent starts, add a child span from each lifecycle hook , and close the run span when the run ends, even if it fails.
When PostToolUseFailure fires, mark the tool span as an error and keep the message, so a bad argument stands out even after the model fixes it. Store responseId on your model-call span, because it matches gen_ai.response.id on our generation span. Also mark the run span as an error in your catch block, because PostModelCall does not fire for a request that fails before a full response comes back.
Pass a customer id in the user field as well. We record it as user.id, so you can filter both sides by customer. The user tracking guide covers how to pick a stable id.
How do you add our spans to your agent’s trace?
Add a Broadcast destination under Settings > Observability , then send your trace id and span id with every request. Broadcast can send to Langfuse, Datadog, an OpenTelemetry Collector , a Webhook , and many other destinations . We send traces after each request finishes, so Broadcast does not slow down your responses. In our test, Jaeger ran on a laptop that Broadcast could not reach, so we used a Webhook destination and a small relay that forwarded each payload into Jaeger.
The request’s trace field takes trace_id, parent_span_id, trace_name, span_name, and generation_name, and any other key shows up as trace.metadata. . With the Agent SDK, you take the ids from your run span and pass them in camelCase.
const { traceId , spanId } = runSpan. spanContext ();
const result = callModel (client, {
model: "anthropic/claude-haiku-5.5" ,
input: prompt,
tools,
user: customerId,
trace: { traceId, parentSpanId: spanId, traceName: "support-agent run" },
hooks,
});
Here client is an OpenRouter instance, and callModel comes from @openrouter/agent. Every generation span came back with the run’s trace id and the run span as its parent. That places it next to the matching model-call span, and the generation id lines the two up.
Without the SDK, put the ids in the request body.
{
"model" : "anthropic/claude-haiku-5.5" ,
"messages" : [{ "role" : "user" , "content" : "Where is my order ORD-10442?" }],
"user" : "customer_8812" ,
"trace" : {
"trace_id" : "4bf92f3577b34da6a3ce929d0e0e4736" ,
"parent_span_id" : "00f067aa0ba902b7" ,
"trace_name" : "support-agent run"
}
}
We made two mistakes while setting this up. First, we sent bcast_test_001 as a trace id. Real trace ids are 32 hex characters and span ids are 16, so our span came back under a different trace id that matched nothing. Taking the ids from spanContext() avoids this.
Second, we passed snake_case keys to the TypeScript SDK. TypeScript rejects trace: { trace_id, parent_span_id } with error TS2353. When we forced it through with a type cast, the SDK threw no error and sent an empty trace object, so each of the four model calls landed in its own separate trace. With camelCase keys, all four joined.
How do you trace LLM calls without sending prompts to your tracing vendor?
Turn on Privacy Mode in the Privacy section of a Broadcast destination. You set it per destination, so you can send full traces to one destination for debugging and private traces to another for cost tracking.
With Privacy Mode on, we remove the prompt, the reply, and the error text before we send the trace. We ran all 27 test runs this way and searched every payload for words from our prompts and tool results, and none showed up. Tokens, cost, model, provider, and user.id were on every generation span, and failed provider attempts kept their HTTP status code.
Some things still go out. Model parameters are kept, including any stop sequences, so our test stop sequence PRIVATE_STOP_TEST appeared as gen_ai.request.stop_sequences, and custom trace metadata is still exported. Each generation span also carries your OpenRouter account’s user id and the name of the API key that made the request.
If you cannot send prompts to an outside vendor at all, send your tool spans to a backend you run yourself and let Broadcast add our spans with Privacy Mode on—keeping both custom trace metadata and caller-supplied stop sequences strictly non-sensitive, or disabling trace export altogether if you cannot guarantee that.
What did each side catch in 27 agent runs?
We built an order-support agent for an outdoor gear shop with @openrouter/agent 0.11.0 and a step limit of 8. Its lookup_order tool rejects any id that does not look like ORD-12345, though its description does not say so. Its get_shipment tool always answers “pending, try again”, and issue_refund takes the amount in cents.
We gave it three tasks. One customer asks about “order 10442” without the ORD- prefix, another asks why order ORD-10518 has not arrived, and a third wants a refund on one of two headlamps in order ORD-10377.
On November 10, 2026, we ran each task three times on Gemini 3.8 Flash, Claude Haiku 5.5, and DeepSeek V4.1 Flash. The 27 runs made 98 model calls for $0.0227 in total. Every model call matched exactly one of our generation spans, and the cost on each span equaled the cost the SDK reported.
What happened Runs Your agent’s spans OpenRouter’s spans
The model sent 10442 instead of ORD-10442, and the tool returned “order_id must look like ORD-12345, got ‘10442’” 9 of 9 The failed lookup_order span with the bad argument and error. The model retried with ORD-10442 in 8 of 9 runs One more generation, with nothing about why
The carrier never answered 9 of 9 Each get_shipment call. Gemini called it twice in every run, Haiku once, and DeepSeek once or twice One more generation for each call
The agent refunded one headlamp 9 of 9 correct The exact arguments (amount: 4999, sku LAMP-400) Nothing about the amount
Which provider served each call All 98 calls Not visible Gemini on Google Vertex AI (35) and Google AI Studio (3), Haiku on Claude Platform on AWS (30), DeepSeek across nine providers
A provider failed and OpenRouter tried another 3 generations, all in one Gemini run Slow model calls Both attempts for each, with HTTP status and duration
No run ended in an error, but two Gemini 3.8 Flash runs show what each side sees that the other cannot.
The slowest run took 151.7 seconds. The agent’s spans showed one model call taking 133.5 seconds, and our generation span showed that the attempt to Google lasted 131.2 seconds of it. Almost all of that call was spent waiting for Google’s first token.
The other was a refund run of about 48 seconds. Its first model call got a 504 error from Google after 10,282 ms, and we then got the response from Google AI Studio in 2,044 ms. The next two calls did the same after Google returned 400 errors. The agent’s spans showed only slow model calls. In the same run, the SDK sent the HTTP request for its second model call twice, and we have a generation for only one of those two requests, starting 11.4 seconds after the agent’s model-call span. We did not record what happened to the unanswered request, but those seconds appear only in the agent’s trace.
Our spans also explain speed differences between models, which is the part of LLM monitoring your own code cannot measure. The table shows medians for one model call.
Model Your agent sees (SDK durationMs) OpenRouter generation span Provider time to first token
Gemini 3.8 Flash 3,154.5 ms 2,454.5 ms 1,963.5 ms
Claude Haiku 5.5 2,149.8 ms 1,490.5 ms 1,177.0 ms
DeepSeek V4.1 Flash 1,848.2 ms 1,350.5 ms 769.0 ms
The agent’s numbers run 498 to 700 ms longer than ours because they also count time outside OpenRouter, such as the network trip. Gemini’s median time to first token was about 1.7 times Haiku’s and 2.6 times DeepSeek’s.
Frequently asked questions
What is the difference between LLM tracing and logging?
A log line records one event on its own. A trace links every step of one run with timing and parent-child order, so you can see which step caused the next and where the time went.
Does OpenTelemetry work for LLM agents?
Yes. Our agent’s spans and our Broadcast spans both use OTLP, and they landed in the same Jaeger trace once each request carried the run’s trace_id and parent_span_id.
Can I trace LLM calls without the OpenRouter Agent SDK?
Yes. Any agent loop can open a span around each tool call and model call, and the trace field with trace_id and parent_span_id works on any OpenRouter request.
Can I trace LLM calls without logging prompts?
Yes. Turn on Privacy Mode for the Broadcast destination, and we strip the prompt, the reply, and the error text while still sending tokens, cost, timing, and the provider. Keep in mind that stop sequences are still sent.
Can I send only some traces?
Yes. Each Broadcast destination has its own sampling rate, so a rate of 0.5 sends about half of your traces. When you pass a session_id, sampling keeps or drops a whole session together. You can also choose which API keys a destination receives traces from, or exclude certain keys.
Next steps
Set up a destination with the Broadcast guide . An OpenTelemetry Collector sends our spans to any OTLP backend, and a Webhook lets you handle the data yourself. Then add tool and model spans to your agent with the Agent SDK lifecycle hooks , and pass a user id on every request so you can filter both sides by customer. Once you can see what each customer costs, our Team Spend Controls setup guide shows you how to cap it.
首次收录 · 2026-12-03 · 9.95 分