Class: Increase::Models::PhysicalCard::Shipment::Tracking::Update

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/increase/models/physical_card.rb

Defined Under Namespace

Modules: Category

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(carrier_estimated_delivery_at: , category: , city: , created_at: , postal_code: , state: ) ⇒ Object

Some parameter documentations has been truncated, see Increase::Models::PhysicalCard::Shipment::Tracking::Update for more details.

Parameters:



364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
# File 'lib/increase/models/physical_card.rb', line 364

class Update < Increase::Internal::Type::BaseModel
  # @!attribute carrier_estimated_delivery_at
  #   The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time when the
  #   carrier expects the card to be delivered.
  #
  #   @return [Time, nil]
  required :carrier_estimated_delivery_at, Time, nil?: true

  # @!attribute category
  #   The type of tracking event.
  #
  #   @return [Symbol, Increase::Models::PhysicalCard::Shipment::Tracking::Update::Category]
  required :category, enum: -> { Increase::PhysicalCard::Shipment::Tracking::Update::Category }

  # @!attribute city
  #   The city where the event took place.
  #
  #   @return [String, nil]
  required :city, String, nil?: true

  # @!attribute created_at
  #   The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
  #   the tracking event took place.
  #
  #   @return [Time]
  required :created_at, Time

  # @!attribute postal_code
  #   The postal code where the event took place.
  #
  #   @return [String, nil]
  required :postal_code, String, nil?: true

  # @!attribute state
  #   The state where the event took place.
  #
  #   @return [String, nil]
  required :state, String, nil?: true

  # @!method initialize(carrier_estimated_delivery_at:, category:, city:, created_at:, postal_code:, state:)
  #   Some parameter documentations has been truncated, see
  #   {Increase::Models::PhysicalCard::Shipment::Tracking::Update} for more details.
  #
  #   @param carrier_estimated_delivery_at [Time, nil] The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time when the ca
  #
  #   @param category [Symbol, Increase::Models::PhysicalCard::Shipment::Tracking::Update::Category] The type of tracking event.
  #
  #   @param city [String, nil] The city where the event took place.
  #
  #   @param created_at [Time] The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which th
  #
  #   @param postal_code [String, nil] The postal code where the event took place.
  #
  #   @param state [String, nil] The state where the event took place.

  # The type of tracking event.
  #
  # @see Increase::Models::PhysicalCard::Shipment::Tracking::Update#category
  module Category
    extend Increase::Internal::Type::Enum

    # The physical card is in transit.
    IN_TRANSIT = :in_transit

    # The physical card has been processed for delivery.
    PROCESSED_FOR_DELIVERY = :processed_for_delivery

    # The physical card has been delivered.
    DELIVERED = :delivered

    # Delivery failed and the physical card was returned to sender.
    RETURNED_TO_SENDER = :returned_to_sender

    # @!method self.values
    #   @return [Array<Symbol>]
  end
end

Instance Attribute Details

#carrier_estimated_delivery_atTime?

The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time when the carrier expects the card to be delivered.

Returns:

  • (Time, nil)


370
# File 'lib/increase/models/physical_card.rb', line 370

required :carrier_estimated_delivery_at, Time, nil?: true

#categorySymbol, Increase::Models::PhysicalCard::Shipment::Tracking::Update::Category

The type of tracking event.



376
# File 'lib/increase/models/physical_card.rb', line 376

required :category, enum: -> { Increase::PhysicalCard::Shipment::Tracking::Update::Category }

#cityString?

The city where the event took place.

Returns:

  • (String, nil)


382
# File 'lib/increase/models/physical_card.rb', line 382

required :city, String, nil?: true

#created_atTime

The [ISO 8601](en.wikipedia.org/wiki/ISO_8601) date and time at which the tracking event took place.

Returns:

  • (Time)


389
# File 'lib/increase/models/physical_card.rb', line 389

required :created_at, Time

#postal_codeString?

The postal code where the event took place.

Returns:

  • (String, nil)


395
# File 'lib/increase/models/physical_card.rb', line 395

required :postal_code, String, nil?: true

#stateString?

The state where the event took place.

Returns:

  • (String, nil)


401
# File 'lib/increase/models/physical_card.rb', line 401

required :state, String, nil?: true