Class: ContextDev::Models::BrandRetrieveParams::Body::ByTicker

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/context_dev/models/brand_retrieve_params.rb,
sig/context_dev/models/brand_retrieve_params.rbs

Defined Under Namespace

Modules: ForceLanguage

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, 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, #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(ticker:, force_language: nil, max_age_ms: nil, max_speed: nil, ticker_exchange: nil, timeout_ms: nil, type: :by_ticker) ⇒ Object

Some parameter documentations has been truncated, see ContextDev::Models::BrandRetrieveParams::Body::ByTicker for more details.

Retrieve brand data by stock ticker. Cannot be combined with domain, name, or email.

Parameters:

  • ticker (String)

    Stock ticker symbol to retrieve brand data for (e.g., 'AAPL').

  • force_language (Symbol, ContextDev::Models::BrandRetrieveParams::Body::ByTicker::ForceLanguage) (defaults to: nil)
  • max_age_ms (Integer) (defaults to: nil)

    Maximum age in milliseconds for cached brand data before the API performs a hard

  • max_speed (Boolean) (defaults to: nil)

    Optional parameter to optimize the API call for maximum speed. When set to true,

  • ticker_exchange (String) (defaults to: nil)

    Optional stock exchange for the ticker. Defaults to NASDAQ if not specified.

  • timeout_ms (Integer) (defaults to: nil)

    Optional timeout in milliseconds for the request. If the request takes longer th

  • type (Symbol, :by_ticker) (defaults to: :by_ticker)

    Discriminator for ticker-based brand retrieval.



# File 'lib/context_dev/models/brand_retrieve_params.rb', line 676

Instance Attribute Details

#force_languageSymbol, ...



643
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 643

optional :force_language, enum: -> { ContextDev::BrandRetrieveParams::Body::ByTicker::ForceLanguage }

#max_age_msInteger?

Maximum age in milliseconds for cached brand data before the API performs a hard refresh. Defaults to 3 months (7776000000 ms). Values below 1 day (86400000 ms) are clamped to 1 day; values above 1 year (31536000000 ms) are clamped to 1 year.

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


652
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 652

optional :max_age_ms, Integer, api_name: :maxAgeMs

#max_speedBoolean?

Optional parameter to optimize the API call for maximum speed. When set to true, the API will skip time-consuming operations for faster response at the cost of less comprehensive data.

Parameters:

  • (Boolean)

Returns:

  • (Boolean, nil)


660
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 660

optional :max_speed, ContextDev::Internal::Type::Boolean, api_name: :maxSpeed

#tickerString

Stock ticker symbol to retrieve brand data for (e.g., 'AAPL').

Parameters:

  • value (String)

Returns:

  • (String)


632
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 632

required :ticker, String

#ticker_exchangeString?

Optional stock exchange for the ticker. Defaults to NASDAQ if not specified.

Parameters:

  • (String)

Returns:

  • (String, nil)


666
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 666

optional :ticker_exchange, String

#timeout_msInteger?

Optional timeout in milliseconds for the request. If the request takes longer than this value, it will be aborted with a 408 status code. Maximum allowed value is 300000ms (5 minutes).

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


674
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 674

optional :timeout_ms, Integer, api_name: :timeoutMS

#typeSymbol, :by_ticker

Discriminator for ticker-based brand retrieval.

Parameters:

  • value (:by_ticker)

Returns:

  • (Symbol, :by_ticker)


638
# File 'lib/context_dev/models/brand_retrieve_params.rb', line 638

required :type, const: :by_ticker

Instance Method Details

#to_hash{

Returns:

  • ({)


991
# File 'sig/context_dev/models/brand_retrieve_params.rbs', line 991

def to_hash: -> {