pub struct AiSdkV6RunRequest {
pub thread_id: String,
pub input: String,
pub parent_thread_id: Option<String>,
pub trigger: Option<AiSdkTrigger>,
pub message_id: Option<String>,
/* private fields */
}Fields§
§thread_id: String§input: String§parent_thread_id: Option<String>§trigger: Option<AiSdkTrigger>§message_id: Option<String>Implementations§
Source§impl AiSdkV6RunRequest
impl AiSdkV6RunRequest
Sourcepub fn from_thread_input(
thread_id: impl Into<String>,
input: impl Into<String>,
) -> Self
pub fn from_thread_input( thread_id: impl Into<String>, input: impl Into<String>, ) -> Self
Build a request from explicit thread/input values (non-UI transport path).
Sourcepub fn validate(&self) -> Result<(), String>
pub fn validate(&self) -> Result<(), String>
Validate the request before processing.
Checks that:
thread_idis non-emptymessageIdis present and non-empty forregenerate-message- At least one of user input, suspension decisions, or regenerate trigger is present
Sourcepub fn has_user_input(&self) -> bool
pub fn has_user_input(&self) -> bool
Whether the incoming request includes a non-empty user input message.
Sourcepub fn has_interaction_responses(&self) -> bool
pub fn has_interaction_responses(&self) -> bool
Whether the incoming request includes any interaction responses.
Sourcepub fn has_suspension_decisions(&self) -> bool
pub fn has_suspension_decisions(&self) -> bool
Whether the incoming request includes any suspension decisions.
Sourcepub fn interaction_responses(&self) -> Vec<SuspensionResponse>
pub fn interaction_responses(&self) -> Vec<SuspensionResponse>
Suspension responses extracted from incoming UI messages.
Sourcepub fn suspension_decisions(&self) -> Vec<ToolCallDecision>
pub fn suspension_decisions(&self) -> Vec<ToolCallDecision>
Suspension decisions extracted from incoming UI messages.
Sourcepub fn into_runtime_run_request(self, agent_id: String) -> RunRequest
pub fn into_runtime_run_request(self, agent_id: String) -> RunRequest
Convert this AI SDK request to the internal runtime request.
Mapping rules:
thread_idis treated as optional when blank/whitespace.run_idis always server-assigned (not client-supplied).- Only extracted user input text is appended as runtime user message.
state,parent_run_id, andresource_idare not supplied by AI SDK v6 input.
Trait Implementations§
Source§impl Clone for AiSdkV6RunRequest
impl Clone for AiSdkV6RunRequest
Source§fn clone(&self) -> AiSdkV6RunRequest
fn clone(&self) -> AiSdkV6RunRequest
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AiSdkV6RunRequest
impl Debug for AiSdkV6RunRequest
Source§impl<'de> Deserialize<'de> for AiSdkV6RunRequest
impl<'de> Deserialize<'de> for AiSdkV6RunRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for AiSdkV6RunRequest
impl RefUnwindSafe for AiSdkV6RunRequest
impl Send for AiSdkV6RunRequest
impl Sync for AiSdkV6RunRequest
impl Unpin for AiSdkV6RunRequest
impl UnwindSafe for AiSdkV6RunRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more