Class: ClaudeAgentSDK::McpToolInfo
- Inherits:
-
Object
- Object
- ClaudeAgentSDK::McpToolInfo
- Defined in:
- lib/claude_agent_sdk/types.rb
Overview
MCP tool info (name, description, annotations)
Instance Attribute Summary collapse
-
#annotations ⇒ Object
Returns the value of attribute annotations.
-
#description ⇒ Object
Returns the value of attribute description.
-
#name ⇒ Object
Returns the value of attribute name.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name:, description: nil, annotations: nil) ⇒ McpToolInfo
constructor
A new instance of McpToolInfo.
Constructor Details
#initialize(name:, description: nil, annotations: nil) ⇒ McpToolInfo
Returns a new instance of McpToolInfo.
1459 1460 1461 1462 1463 |
# File 'lib/claude_agent_sdk/types.rb', line 1459 def initialize(name:, description: nil, annotations: nil) @name = name @description = description @annotations = annotations end |
Instance Attribute Details
#annotations ⇒ Object
Returns the value of attribute annotations.
1457 1458 1459 |
# File 'lib/claude_agent_sdk/types.rb', line 1457 def annotations @annotations end |
#description ⇒ Object
Returns the value of attribute description.
1457 1458 1459 |
# File 'lib/claude_agent_sdk/types.rb', line 1457 def description @description end |
#name ⇒ Object
Returns the value of attribute name.
1457 1458 1459 |
# File 'lib/claude_agent_sdk/types.rb', line 1457 def name @name end |
Class Method Details
.parse(data) ⇒ Object
1465 1466 1467 1468 1469 1470 1471 |
# File 'lib/claude_agent_sdk/types.rb', line 1465 def self.parse(data) new( name: data[:name], description: data[:description], annotations: McpToolAnnotations.parse(data[:annotations]) ) end |