Class: MetronomeSDK::Models::Contract

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/metronome_sdk/models/contract.rb

Defined Under Namespace

Modules: ScheduledChargesOnUsageInvoices Classes: Amendment, CustomerBillingProviderConfiguration

Instance Attribute Summary collapse

Class Method Summary collapse

Methods inherited from Internal::Type::BaseModel

#==, ==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, #initialize, 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

This class inherits a constructor from MetronomeSDK::Internal::Type::BaseModel

Instance Attribute Details

#amendmentsArray<MetronomeSDK::Models::Contract::Amendment>



14
# File 'lib/metronome_sdk/models/contract.rb', line 14

required :amendments, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Contract::Amendment] }

#archived_atTime?

RFC 3339 timestamp indicating when the contract was archived. If not returned, the contract is not archived.

Returns:

  • (Time, nil)


36
# File 'lib/metronome_sdk/models/contract.rb', line 36

optional :archived_at, Time

#currentMetronomeSDK::Models::ContractWithoutAmendments



19
# File 'lib/metronome_sdk/models/contract.rb', line 19

required :current, -> { MetronomeSDK::ContractWithoutAmendments }

#custom_fieldsHash{Symbol=>String}?

Custom fields to be added eg. { “key1”: “value1”, “key2”: “value2” }

Returns:

  • (Hash{Symbol=>String}, nil)


42
# File 'lib/metronome_sdk/models/contract.rb', line 42

optional :custom_fields, MetronomeSDK::Internal::Type::HashOf[String]

#customer_billing_provider_configurationMetronomeSDK::Models::Contract::CustomerBillingProviderConfiguration?

The billing provider configuration associated with a contract.



48
49
# File 'lib/metronome_sdk/models/contract.rb', line 48

optional :customer_billing_provider_configuration,
-> { MetronomeSDK::Contract::CustomerBillingProviderConfiguration }

#customer_idString

Returns:

  • (String)


24
# File 'lib/metronome_sdk/models/contract.rb', line 24

required :customer_id, String

#idString

Returns:

  • (String)


9
# File 'lib/metronome_sdk/models/contract.rb', line 9

required :id, String

#initialMetronomeSDK::Models::ContractWithoutAmendments



29
# File 'lib/metronome_sdk/models/contract.rb', line 29

required :initial, -> { MetronomeSDK::ContractWithoutAmendments }

#prepaid_balance_threshold_configurationMetronomeSDK::Models::PrepaidBalanceThresholdConfiguration?



54
55
# File 'lib/metronome_sdk/models/contract.rb', line 54

optional :prepaid_balance_threshold_configuration,
-> { MetronomeSDK::PrepaidBalanceThresholdConfiguration }

#priorityFloat?

Priority of the contract.

Returns:

  • (Float, nil)


61
# File 'lib/metronome_sdk/models/contract.rb', line 61

optional :priority, Float

#scheduled_charges_on_usage_invoicesSymbol, ...

Determines which scheduled and commit charges to consolidate onto the Contract’s usage invoice. The charge’s ‘timestamp` must match the usage invoice’s ‘ending_before` date for consolidation to occur. This field cannot be modified after a Contract has been created. If this field is omitted, charges will appear on a separate invoice from usage charges.



71
72
# File 'lib/metronome_sdk/models/contract.rb', line 71

optional :scheduled_charges_on_usage_invoices,
enum: -> { MetronomeSDK::Contract::ScheduledChargesOnUsageInvoices }

#spend_threshold_configurationMetronomeSDK::Models::SpendThresholdConfiguration?



77
# File 'lib/metronome_sdk/models/contract.rb', line 77

optional :spend_threshold_configuration, -> { MetronomeSDK::SpendThresholdConfiguration }

#subscriptionsArray<MetronomeSDK::Models::Subscription>?

List of subscriptions on the contract.

Returns:



83
# File 'lib/metronome_sdk/models/contract.rb', line 83

optional :subscriptions, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Subscription] }

#uniqueness_keyString?

Prevents the creation of duplicates. If a request to create a record is made with a previously used uniqueness key, a new record will not be created and the request will fail with a 409 error.

Returns:

  • (String, nil)


91
# File 'lib/metronome_sdk/models/contract.rb', line 91

optional :uniqueness_key, String

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/metronome_sdk/models/contract.rb', line 302