Skip to main content

PublishEventRequest

Struct PublishEventRequest 

Source
pub struct PublishEventRequest {
Show 28 fields pub id: Option<String>, pub project_id: String, pub session_id: Option<Option<String>>, pub actor_id: Option<String>, pub event_id: Option<String>, pub event_type: Option<EventType>, pub is_error: Option<bool>, pub error: Option<Value>, pub resource_name: Option<String>, pub duration: Option<i32>, pub input_tokens: Option<i32>, pub output_tokens: Option<i32>, pub timestamp: Option<DateTime<FixedOffset>>, pub user_intent: Option<String>, pub parameters: Option<Value>, pub response: Option<Value>, pub identify_actor_given_id: Option<String>, pub identify_actor_name: Option<String>, pub identify_data: Option<Value>, pub tags: Option<HashMap<String, String>>, pub properties: Option<Value>, pub ip_address: Option<String>, pub sdk_language: Option<String>, pub agentcat_version: Option<String>, pub server_name: Option<String>, pub server_version: Option<String>, pub client_name: Option<String>, pub client_version: Option<String>,
}

Fields§

§id: Option<String>

ID of the event, typically auto-generated by the AgentCat Agent

§project_id: String

ID of the project this event belongs to

§session_id: Option<Option<String>>

ID of the session this event belongs to. Null for stateless mode (server assigns session).

§actor_id: Option<String>

Optional actor ID

§event_id: Option<String>

Optional custom event ID (must be unique)

§event_type: Option<EventType>

Type of event (e.g., mcp:tools/call, agentcat:identify)

§is_error: Option<bool>

Whether this event represents an error

§error: Option<Value>

Error details if is_error is true

§resource_name: Option<String>

Name of the resource accessed (for resource events)

§duration: Option<i32>

Duration of the operation in milliseconds

§input_tokens: Option<i32>

Token count of the request side as measured by the SDK. When absent, the server estimates it from the stored parameters.

§output_tokens: Option<i32>

Token count of the response side as measured by the SDK. When absent, the server estimates it from the stored response. Drives the oversized-tool-response rule.

§timestamp: Option<DateTime<FixedOffset>>

Agent-provided timestamp of when the event occurred

§user_intent: Option<String>

Captured explanation of why the actor made this request

§parameters: Option<Value>

Parameters sent with the request

§response: Option<Value>

Response data from the operation

§identify_actor_given_id: Option<String>

Actor ID for agentcat:identify events

§identify_actor_name: Option<String>

Actor name for agentcat:identify events

§identify_data: Option<Value>

Additional data for agentcat:identify events

§tags: Option<HashMap<String, String>>

Custom string key-value pairs. Keys: max 32 chars, alphanumeric/underscore/period/colon/dash/dollar-sign only. Values: max 200 chars, no newlines. Max 50 entries.

§properties: Option<Value>

Custom structured data. Keys are strings, values can be string, number, boolean, array, object, or null (null values are filtered out).

§ip_address: Option<String>

IP address of the client

§sdk_language: Option<String>

Programming language of the SDK used

§agentcat_version: Option<String>

Version of AgentCat being used

§server_name: Option<String>

Name of the MCP server

§server_version: Option<String>

Version of the MCP server

§client_name: Option<String>

Name of the MCP client

§client_version: Option<String>

Version of the MCP client

Implementations§

Trait Implementations§

Source§

impl Clone for PublishEventRequest

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for PublishEventRequest

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for PublishEventRequest

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for PublishEventRequest

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for PublishEventRequest

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for PublishEventRequest

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for PublishEventRequest

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more