Class: Twilio::REST::Numbers::V1::PortingPortInList::NumbersV1PortingAddress

Inherits:
Object
  • Object
show all
Defined in:
lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(payload) ⇒ NumbersV1PortingAddress

Returns a new instance of NumbersV1PortingAddress.



30
31
32
33
34
35
36
37
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 30

def initialize(payload)
        @street = payload["street"]
        @street_2 = payload["street_2"]
        @city = payload["city"]
        @state = payload["state"]
        @zip = payload["zip"]
        @country = payload["country"]
end

Instance Attribute Details

#cityObject

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def city
  @city
end

#countryObject

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def country
  @country
end

#stateObject

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def state
  @state
end

#streetObject

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def street
  @street
end

#street_2Object

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def street_2
  @street_2
end

#zipObject

Parameters:

  • : (street)
    String

    The street address, ex: 101 Spear St

  • : (street_2)
    String

    The building information, ex : 5th floor.

  • : (city)
    String

    The city name, ex: San Francisco.

  • : (state)
    String

    The state name, ex: CA or California. Note this should match the losing carrier’s information exactly. So if they spell out the entire state’s name instead of abbreviating it, please do so.

  • : (zip)
    String

    The zip code, ex: 94105.

  • : (country)
    String

    The country, ex: USA.



29
30
31
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 29

def zip
  @zip
end

Instance Method Details

#to_json(options = {}) ⇒ Object



38
39
40
41
42
43
44
45
46
47
# File 'lib/twilio-ruby/rest/numbers/v1/porting_port_in.rb', line 38

def to_json(options = {})
{
        "street": @street,
        "street_2": @street_2,
        "city": @city,
        "state": @state,
        "zip": @zip,
        "country": @country,
}.to_json(options)
end