pub struct ToolChoiceMcp {
pub name: Option<String>,
pub server_label: String,
pub type_: ToolChoiceMcpType,
}Expand description
Use this option to force the model to call a specific tool on a remote MCP server.
JSON schema
{
"title": "MCP tool",
"description": "Use this option to force the model to call a specific tool on a remote MCP server.\n",
"type": "object",
"required": [
"server_label",
"type"
],
"properties": {
"name": {
"anyOf": [
{
"description": "The name of the tool to call on the server.\n",
"type": "string"
}
]
},
"server_label": {
"description": "The label of the MCP server to use.\n",
"type": "string"
},
"type": {
"description": "For MCP tools, the type is always `mcp`.",
"type": "string",
"enum": [
"mcp"
],
"x-stainless-const": true
}
}
}Fields§
§name: Option<String>§server_label: StringThe label of the MCP server to use.
type_: ToolChoiceMcpTypeFor MCP tools, the type is always mcp.
Trait Implementations§
Source§impl Clone for ToolChoiceMcp
impl Clone for ToolChoiceMcp
Source§fn clone(&self) -> ToolChoiceMcp
fn clone(&self) -> ToolChoiceMcp
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ToolChoiceMcp
impl Debug for ToolChoiceMcp
Source§impl<'de> Deserialize<'de> for ToolChoiceMcp
impl<'de> Deserialize<'de> for ToolChoiceMcp
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
Source§impl From<ToolChoiceMcp> for RealtimeBetaResponseCreateParamsToolChoice
impl From<ToolChoiceMcp> for RealtimeBetaResponseCreateParamsToolChoice
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceMcp> for RealtimeResponseCreateParamsToolChoice
impl From<ToolChoiceMcp> for RealtimeResponseCreateParamsToolChoice
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceMcp> for RealtimeSessionCreateRequestGaToolChoice
impl From<ToolChoiceMcp> for RealtimeSessionCreateRequestGaToolChoice
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceMcp> for RealtimeSessionCreateResponseGaToolChoice
impl From<ToolChoiceMcp> for RealtimeSessionCreateResponseGaToolChoice
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Source§impl From<ToolChoiceMcp> for ToolChoiceParam
impl From<ToolChoiceMcp> for ToolChoiceParam
Source§fn from(value: ToolChoiceMcp) -> Self
fn from(value: ToolChoiceMcp) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ToolChoiceMcp
impl RefUnwindSafe for ToolChoiceMcp
impl Send for ToolChoiceMcp
impl Sync for ToolChoiceMcp
impl Unpin for ToolChoiceMcp
impl UnsafeUnpin for ToolChoiceMcp
impl UnwindSafe for ToolChoiceMcp
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