Class: OpenAI::Models::Responses::WebSearchTool::UserLocation
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::Responses::WebSearchTool::UserLocation
- Defined in:
- lib/openai/models/responses/web_search_tool.rb,
sig/openai/models/responses/web_search_tool.rbs
Overview
Defined Under Namespace
Modules: Type
Instance Attribute Summary collapse
-
#city ⇒ String?
Free text input for the city of the user, e.g.
-
#country ⇒ String?
The two-letter ISO country code of the user, e.g.
-
#region ⇒ String?
Free text input for the region of the user, e.g.
-
#timezone ⇒ String?
The IANA timezone of the user, e.g.
-
#type ⇒ OpenAI::Models::Responses::WebSearchTool::UserLocation::type_?
The type of location approximation.
Attributes inherited from Internal::Type::BaseModel
Instance Method Summary collapse
-
#initialize(city: nil, country: nil, region: nil, timezone: nil, type: nil) ⇒ UserLocation
constructor
A new instance of UserLocation.
- #to_hash ⇒ { ?city: String?, ?country: String?, ?region: String?, ?timezone: String?, ?type: OpenAI::Models::Responses::WebSearchTool::UserLocation::type_ }
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_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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(city: nil, country: nil, region: nil, timezone: nil, type: nil) ⇒ UserLocation
Returns a new instance of UserLocation.
|
|
# File 'lib/openai/models/responses/web_search_tool.rb', line 149
|
Instance Attribute Details
#city ⇒ String?
Free text input for the city of the user, e.g. San Francisco.
121 |
# File 'lib/openai/models/responses/web_search_tool.rb', line 121 optional :city, String, nil?: true |
#country ⇒ String?
The two-letter ISO country code of
the user, e.g. US.
128 |
# File 'lib/openai/models/responses/web_search_tool.rb', line 128 optional :country, String, nil?: true |
#region ⇒ String?
Free text input for the region of the user, e.g. California.
134 |
# File 'lib/openai/models/responses/web_search_tool.rb', line 134 optional :region, String, nil?: true |
#timezone ⇒ String?
The IANA timezone of the
user, e.g. America/Los_Angeles.
141 |
# File 'lib/openai/models/responses/web_search_tool.rb', line 141 optional :timezone, String, nil?: true |
#type ⇒ OpenAI::Models::Responses::WebSearchTool::UserLocation::type_?
The type of location approximation. Always approximate.
147 |
# File 'lib/openai/models/responses/web_search_tool.rb', line 147 optional :type, enum: -> { OpenAI::Responses::WebSearchTool::UserLocation::Type } |
Instance Method Details
#to_hash ⇒ { ?city: String?, ?country: String?, ?region: String?, ?timezone: String?, ?type: OpenAI::Models::Responses::WebSearchTool::UserLocation::type_ }
170 171 172 173 174 175 176 |
# File 'sig/openai/models/responses/web_search_tool.rbs', line 170
def to_hash: -> {
?city: String?,
?country: String?,
?region: String?,
?timezone: String?,
?type: OpenAI::Models::Responses::WebSearchTool::UserLocation::type_
}
|