Class: Stigg::Models::V1::CustomerCheckEntitlementResponse::Data::Credit

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/stigg/models/v1/customer_check_entitlement_response.rb

Defined Under Namespace

Modules: AccessDeniedReason Classes: Currency

Instance Attribute Summary collapse

Class Method 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(access_denied_reason:, currency:, current_usage:, is_granted:, usage_limit:, usage_updated_at:, entitlement_updated_at: nil, usage_period_end: nil, valid_until: nil, type: :CREDIT) ⇒ Object

Parameters:



# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 304

Instance Attribute Details

#access_denied_reasonSymbol, ...



249
250
251
252
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 249

required :access_denied_reason,
enum: -> { Stigg::Models::V1::CustomerCheckEntitlementResponse::Data::Credit::AccessDeniedReason },
api_name: :accessDeniedReason,
nil?: true

#currencyStigg::Models::V1::CustomerCheckEntitlementResponse::Data::Credit::Currency

The currency associated with a credit entitlement.



258
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 258

required :currency, -> { Stigg::Models::V1::CustomerCheckEntitlementResponse::Data::Credit::Currency }

#current_usageFloat

Returns:

  • (Float)


263
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 263

required :current_usage, Float, api_name: :currentUsage

#entitlement_updated_atTime?

Timestamp of the last update to the entitlement grant or configuration.

Returns:

  • (Time, nil)


290
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 290

optional :entitlement_updated_at, Time, api_name: :entitlementUpdatedAt

#is_grantedBoolean

Returns:

  • (Boolean)


268
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 268

required :is_granted, Stigg::Internal::Type::Boolean, api_name: :isGranted

#typeSymbol, :CREDIT

Returns:

  • (Symbol, :CREDIT)


273
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 273

required :type, const: :CREDIT

#usage_limitFloat

Returns:

  • (Float)


278
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 278

required :usage_limit, Float, api_name: :usageLimit

#usage_period_endTime?

The end date of the current billing period for recurring credit grants.

Returns:

  • (Time, nil)


296
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 296

optional :usage_period_end, Time, api_name: :usagePeriodEnd

#usage_updated_atTime

Timestamp of the last update to the credit usage.

Returns:

  • (Time)


284
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 284

required :usage_updated_at, Time, api_name: :usageUpdatedAt

#valid_untilTime?

The next time the entitlement should be recalculated

Returns:

  • (Time, nil)


302
# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 302

optional :valid_until, Time, api_name: :validUntil

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/stigg/models/v1/customer_check_entitlement_response.rb', line 344