pub struct FinalBody(/* private fields */);Expand description
The merged request body. Its field is private to this module, so only
request_params builds one, and nothing writes to it afterwards.
Serialize is for wires that hand their SDK the body as bytes.
Implementations§
Source§impl FinalBody
impl FinalBody
Sourcepub fn into_body(self) -> Body
pub fn into_body(self) -> Body
The request bytes of an HTTP completion wire: the body as compact JSON.
Sourcepub fn deserialize<T>(&self) -> Result<T, Error>where
T: DeserializeOwned,
pub fn deserialize<T>(&self) -> Result<T, Error>where
T: DeserializeOwned,
The body read as T: an SDK-backed wire’s request type, or a local
runtime’s generation settings.
§Errors
When the body is not a T.
Trait Implementations§
Source§impl Serialize for FinalBody
impl Serialize for FinalBody
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for FinalBody
Auto Trait Implementations§
impl Freeze for FinalBody
impl RefUnwindSafe for FinalBody
impl Send for FinalBody
impl Sync for FinalBody
impl Unpin for FinalBody
impl UnsafeUnpin for FinalBody
impl UnwindSafe for FinalBody
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoToolOutput for Twhere
T: Serialize + 'static,
impl<T> IntoToolOutput for Twhere
T: Serialize + 'static,
Source§fn into_tool_output(self) -> Result<ToolOutput, ToolExecutionError>
fn into_tool_output(self) -> Result<ToolOutput, ToolExecutionError>
Convert this value without routing structured data through a string.