Set Attribute • Rust AI Agent SDK

set_attribute: Set attribute on current span.

set_attribute

Method

</div>

This is a method of the TraceContext class in the trace module.

Set attribute on current span.

Signature

python
def set_attribute(&mut self, key: impl Into<String>, value: impl Serialize) -> ()

Parameters

ParamField impl Into&lt;String&gt;

No description available.

ParamField impl Serialize

No description available.

Returns

ResponseField ()

The result of the operation.