Class: OpenAI::Models::Beta::AgentToolParam::Mcp
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::Beta::AgentToolParam::Mcp
- Defined in:
- lib/openai/models/beta/agent_tool_param.rb,
sig/openai/models/beta/agent_tool_param.rbs
Defined Under Namespace
Modules: ConnectionOrigin
Instance Attribute Summary collapse
-
#allowed_tools ⇒ Array<String>?
The MCP tools the agent may call.
-
#connection_origin ⇒ Symbol, ...
Where outbound MCP HTTP connections originate.
-
#credential_id ⇒ String?
The attached vault credential used to authenticate this MCP server.
-
#request_metadata ⇒ Hash{Symbol=>Object}?
Metadata included with requests to this MCP server.
-
#required ⇒ Boolean?
Whether this MCP server must initialize before the first turn.
-
#server_label ⇒ String
A label used to identify the MCP server in tool calls.
-
#transport ⇒ OpenAI::Models::Beta::McpTransportParam::HTTP, OpenAI::Models::Beta::McpTransportParam::Stdio
The transport used to connect to the MCP server.
-
#type ⇒ Symbol, :mcp
The type of the object.
Attributes inherited from Internal::Type::BaseModel
Instance Method Summary collapse
-
#initialize(server_label:, transport:, allowed_tools: nil, connection_origin: nil, credential_id: nil, request_metadata: nil, required: nil, type: :mcp) ⇒ Object
constructor
Tools provided by a remote MCP server.
- #to_hash ⇒ {
Methods inherited from Internal::Type::BaseModel
==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, fields, hash, #hash, inherited, #inspect, inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, coerce_with_error, dump, #dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(server_label:, transport:, allowed_tools: nil, connection_origin: nil, credential_id: nil, request_metadata: nil, required: nil, type: :mcp) ⇒ Object
Tools provided by a remote MCP server.
|
|
# File 'lib/openai/models/beta/agent_tool_param.rb', line 177
|
Instance Attribute Details
#allowed_tools ⇒ Array<String>?
The MCP tools the agent may call. All server tools are allowed when omitted.
139 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 139 optional :allowed_tools, OpenAI::Internal::Type::ArrayOf[String], nil?: true |
#connection_origin ⇒ Symbol, ...
Where outbound MCP HTTP connections originate.
145 146 147 148 149 150 151 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 145 optional( :connection_origin, enum: -> { OpenAI::Beta::AgentToolParam::Mcp::ConnectionOrigin }, nil?: true ) |
#credential_id ⇒ String?
The attached vault credential used to authenticate this MCP server. Optional when exactly one attached credential matches the server URL.
158 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 158 optional :credential_id, String, nil?: true |
#request_metadata ⇒ Hash{Symbol=>Object}?
Metadata included with requests to this MCP server.
164 165 166 167 168 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 164 optional( :request_metadata, OpenAI::Internal::Type::HashOf[OpenAI::Internal::Type::Unknown], nil?: true ) |
#required ⇒ Boolean?
Whether this MCP server must initialize before the first turn. Defaults to
false.
175 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 175 optional :required, OpenAI::Internal::Type::Boolean |
#server_label ⇒ String
A label used to identify the MCP server in tool calls.
121 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 121 required :server_label, String |
#transport ⇒ OpenAI::Models::Beta::McpTransportParam::HTTP, OpenAI::Models::Beta::McpTransportParam::Stdio
The transport used to connect to the MCP server.
127 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 127 required :transport, union: -> { OpenAI::Beta::McpTransportParam } |
#type ⇒ Symbol, :mcp
The type of the object. Always mcp.
133 |
# File 'lib/openai/models/beta/agent_tool_param.rb', line 133 required :type, const: :mcp |
Instance Method Details
#to_hash ⇒ {
123 |
# File 'sig/openai/models/beta/agent_tool_param.rbs', line 123
def to_hash: -> {
|