Class: Orb::Models::AlertCreateForSubscriptionParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/orb/models/alert_create_for_subscription_params.rb,
sig/orb/models/alert_create_for_subscription_params.rbs

Overview

See Also:

  • Orb::Resources::Alerts#create_for_subscription

Defined Under Namespace

Modules: Type Classes: PriceFilter, ThresholdOverride

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

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(subscription_id:, thresholds:, type:, currency: nil, grouping_keys: nil, metric_id: nil, price_filters: nil, threshold_overrides: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see Orb::Models::AlertCreateForSubscriptionParams for more details.

Parameters:

  • subscription_id (String)
  • thresholds (Array<Orb::Models::Threshold>)

    The thresholds that define the values at which the alert will be triggered.

  • type (Symbol, Orb::Models::AlertCreateForSubscriptionParams::Type)

    The type of alert to create. This must be a valid alert type.

  • currency (String, nil) (defaults to: nil)

    The case sensitive currency or custom pricing unit to use for grouped cost alert

  • grouping_keys (Array<String>, nil) (defaults to: nil)

    The property keys to group cost alerts by. Only applicable for cost_exceeded ale

  • metric_id (String, nil) (defaults to: nil)

    The metric to track usage for.

  • price_filters (Array<Orb::Models::AlertCreateForSubscriptionParams::PriceFilter>, nil) (defaults to: nil)

    Filters to scope which prices are included in grouped cost alert evaluation. Sup

  • threshold_overrides (Array<Orb::Models::AlertCreateForSubscriptionParams::ThresholdOverride>, nil) (defaults to: nil)

    Per-group threshold overrides. Each override maps a specific combination of grou

  • request_options (Orb::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 69

Instance Attribute Details

#currencyString?

The case sensitive currency or custom pricing unit to use for grouped cost alerts. Required when grouping_keys is set.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


32
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 32

optional :currency, String, nil?: true

#grouping_keysArray<String>?

The property keys to group cost alerts by. Only applicable for cost_exceeded alerts.

Parameters:

  • value (::Array[String], nil)

Returns:

  • (Array<String>, nil)


39
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 39

optional :grouping_keys, Orb::Internal::Type::ArrayOf[String], nil?: true

#metric_idString?

The metric to track usage for.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


45
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 45

optional :metric_id, String, nil?: true

#price_filtersArray<Orb::Models::AlertCreateForSubscriptionParams::PriceFilter>?

Filters to scope which prices are included in grouped cost alert evaluation. Supports filtering by price_id, item_id, or price_type with includes/excludes operators. Only applicable when grouping_keys is set.

Parameters:

  • value (::Array[Orb::AlertCreateForSubscriptionParams::PriceFilter], nil)

Returns:



53
54
55
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 53

optional :price_filters,
-> { Orb::Internal::Type::ArrayOf[Orb::AlertCreateForSubscriptionParams::PriceFilter] },
nil?: true

#subscription_idString

Parameters:

  • value (String)

Returns:

  • (String)


13
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 13

required :subscription_id, String

#threshold_overridesArray<Orb::Models::AlertCreateForSubscriptionParams::ThresholdOverride>?

Per-group threshold overrides. Each override maps a specific combination of grouping_keys values to a list of thresholds that fully replaces the default thresholds for that group. An empty thresholds list silences the group. Groups without an override use the default thresholds. Only applicable when grouping_keys is set.

Parameters:

  • value (::Array[Orb::AlertCreateForSubscriptionParams::ThresholdOverride], nil)

Returns:



65
66
67
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 65

optional :threshold_overrides,
-> { Orb::Internal::Type::ArrayOf[Orb::AlertCreateForSubscriptionParams::ThresholdOverride] },
nil?: true

#thresholdsArray<Orb::Models::Threshold>

The thresholds that define the values at which the alert will be triggered.

Parameters:

Returns:



19
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 19

required :thresholds, -> { Orb::Internal::Type::ArrayOf[Orb::Threshold] }

#typeSymbol, Orb::Models::AlertCreateForSubscriptionParams::Type

The type of alert to create. This must be a valid alert type.

Parameters:

  • value (Orb::Models::AlertCreateForSubscriptionParams::type_)

Returns:



25
# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 25

required :type, enum: -> { Orb::AlertCreateForSubscriptionParams::Type }

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/orb/models/alert_create_for_subscription_params.rb', line 98

Instance Method Details

#to_hash{

Returns:

  • ({)


48
# File 'sig/orb/models/alert_create_for_subscription_params.rbs', line 48

def to_hash: -> {