Class: TerminalShop::Models::AddressAPI

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/terminal_shop/models/address.rb

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(id: , city: , country: , created: , name: , street1: , zip: , phone: nil, province: nil, street2: nil) ⇒ Object

Some parameter documentations has been truncated, see TerminalShop::Models::AddressAPI for more details.

Physical address associated with a Terminal shop user.

Parameters:

  • id (String) (defaults to: )

    Unique object identifier.

  • city (String) (defaults to: )

    City of the address.

  • country (String) (defaults to: )

    ISO 3166-1 alpha-2 country code of the address.

  • created (String) (defaults to: )

    Date the address was created.

  • name (String) (defaults to: )

    The recipient’s name.

  • street1 (String) (defaults to: )

    Street of the address.

  • zip (String) (defaults to: )

    Zip code of the address.

  • phone (String) (defaults to: nil)

    Phone number of the recipient.

  • province (String) (defaults to: nil)

    Province or state of the address.

  • street2 (String) (defaults to: nil)

    Apartment, suite, etc. of the address.



# File 'lib/terminal_shop/models/address.rb', line 66


Instance Attribute Details

#cityString

City of the address.

Returns:

  • (String)


16
# File 'lib/terminal_shop/models/address.rb', line 16

required :city, String

#countryString

ISO 3166-1 alpha-2 country code of the address.

Returns:

  • (String)


22
# File 'lib/terminal_shop/models/address.rb', line 22

required :country, String

#createdString

Date the address was created.

Returns:

  • (String)


28
# File 'lib/terminal_shop/models/address.rb', line 28

required :created, String

#idString

Unique object identifier. The format and length of IDs may change over time.

Returns:

  • (String)


10
# File 'lib/terminal_shop/models/address.rb', line 10

required :id, String

#nameString

The recipient’s name.

Returns:

  • (String)


34
# File 'lib/terminal_shop/models/address.rb', line 34

required :name, String

#phoneString?

Phone number of the recipient.

Returns:

  • (String, nil)


52
# File 'lib/terminal_shop/models/address.rb', line 52

optional :phone, String

#provinceString?

Province or state of the address.

Returns:

  • (String, nil)


58
# File 'lib/terminal_shop/models/address.rb', line 58

optional :province, String

#street1String

Street of the address.

Returns:

  • (String)


40
# File 'lib/terminal_shop/models/address.rb', line 40

required :street1, String

#street2String?

Apartment, suite, etc. of the address.

Returns:

  • (String, nil)


64
# File 'lib/terminal_shop/models/address.rb', line 64

optional :street2, String

#zipString

Zip code of the address.

Returns:

  • (String)


46
# File 'lib/terminal_shop/models/address.rb', line 46

required :zip, String