Anthropic::InputSchema
Inherits JSON::Serializable < Struct < Value < Object
JSON Schema for tool input parameters
Wraps a properties hash in the required object structure for the API.
schema = InputSchema.new(
properties: {
"location" => Schema.string("City name"),
"unit" => Schema.enum("celsius", "fahrenheit"),
},
required: ["location"]
)
Constructors
Create from a Hash(String, Schema::Property) with required fields
new(pull : JSON::PullParser)
Sourcenew(properties : Hash(String, Schema::Property), required : Array(String) | Nil = nil, additional_properties : Bool = false)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceInstance methods
additional_properties?
Sourceproperties
Sourcerequired
Sourcetype
Source