Class: Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block

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

Overview

See Also:

  • Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent#block

Defined Under Namespace

Modules: CreditBlockSource, Status Classes: CreditAllocation, CreditCommitment, Filter

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(id:, balance:, credit_block_source:, effective_date:, expiry_date:, filters:, maximum_initial_balance:, metadata:, per_unit_cost_basis:, status:, credit_allocation: nil, credit_commitment: nil) ⇒ Object

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

The Credit Block resource models prepaid credits within Orb.

Parameters:



# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 214

Instance Attribute Details

#balance ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


143
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 143

required :balance, String

#credit_allocation ⇒ Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditAllocation?

The credit allocation that funded a block. Extends the allocation resource serialized on prices with the catalog-item attribution of the funding price.

Parameters:

  • value (Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditAllocation, nil)

Returns:



201
202
203
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 201

optional :credit_allocation,
-> { Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditAllocation },
nil?: true

#credit_block_source ⇒ Symbol, Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditBlockSource

How this credit block was created: allocation (a subscription's recurring credit allocation), top_up (an automatic balance-threshold top-up), commitment (a subscription commitment true-up rolled forward as credit), or manual (a manual credit ledger increment, including credits voided or expired off another block).

Parameters:

  • value (Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::credit_block_source)

Returns:



153
154
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 153

required :credit_block_source,
enum: -> { Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditBlockSource }

#credit_commitment ⇒ Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditCommitment?

The subscription commitment whose true-up rolled forward into this credit block. Present only when credit_block_source is commitment.

Parameters:

  • value (Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditCommitment, nil)

Returns:



210
211
212
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 210

optional :credit_commitment,
-> { Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::CreditCommitment },
nil?: true

#effective_date ⇒ Time?

Parameters:

  • value (Time, nil)

Returns:

  • (Time, nil)


159
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 159

required :effective_date, Time, nil?: true

#expiry_date ⇒ Time?

Parameters:

  • value (Time, nil)

Returns:

  • (Time, nil)


164
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 164

required :expiry_date, Time, nil?: true

#filters ⇒ Array<Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::Filter>

Parameters:

  • value (::Array[Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::Filter])

Returns:



169
170
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 169

required :filters,
-> { Orb::Internal::Type::ArrayOf[Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::Filter] }

#id ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


138
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 138

required :id, String

#maximum_initial_balance ⇒ String?

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


175
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 175

required :maximum_initial_balance, String, nil?: true

#metadata ⇒ Hash{Symbol=>String}

User specified key-value pairs for the resource. If not present, this defaults to an empty dictionary. Individual keys can be removed by setting the value to null, and the entire metadata mapping can be cleared by setting metadata to null.

Parameters:

  • value (::Hash[Symbol, String])

Returns:

  • (Hash{Symbol=>String})


184
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 184

required :metadata, Orb::Internal::Type::HashOf[String]

#per_unit_cost_basis ⇒ String?

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


189
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 189

required :per_unit_cost_basis, String, nil?: true

#status ⇒ Symbol, Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::Status

Parameters:

  • value (Orb::Models::CreditBlockAccountingSyncSucceededWebhookEvent::Block::status)

Returns:



194
# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 194

required :status, enum: -> { Orb::CreditBlockAccountingSyncSucceededWebhookEvent::Block::Status }

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rb', line 260

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


182
# File 'sig/orb/models/credit_block_accounting_sync_succeeded_webhook_event.rbs', line 182

def to_hash: -> {