-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #232 from lob/bugfix/fix-modules-names
fixing issue with module names on ruby
- Loading branch information
Showing
12 changed files
with
58 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
=begin | ||
#Lob | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
The version of the OpenAPI document: 1.3.0 | ||
Contact: [email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
=begin | ||
#Lob | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
The version of the OpenAPI document: 1.3.0 | ||
Contact: [email protected] | ||
|
@@ -13,18 +13,18 @@ | |
require 'date' | ||
require 'time' | ||
|
||
module OpenapiClient | ||
module Lob | ||
class MultipleComponents | ||
# The intended recipient, typically a person's or firm's name. | ||
attr_accessor :recipient | ||
|
||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
attr_accessor :primary_line | ||
|
||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
attr_accessor :secondary_line | ||
|
||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
attr_accessor :urbanization | ||
|
||
attr_accessor :city | ||
|
@@ -35,7 +35,7 @@ class MultipleComponents | |
# Required if `city` and `state` are not passed in. If included, must be formatted as a US ZIP or ZIP+4 (e.g. `94107`, `941072282`, `94107-2282`). | ||
attr_accessor :zip_code | ||
|
||
# ID that is returned in the response body for the verification | ||
# ID that is returned in the response body for the verification | ||
attr_accessor :transient_id | ||
|
||
# Attribute mapping from ruby-style variable name to JSON key. | ||
|
@@ -82,13 +82,13 @@ def self.openapi_nullable | |
# @param [Hash] attributes Model attributes in the form of hash | ||
def initialize(attributes = {}) | ||
if (!attributes.is_a?(Hash)) | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::MultipleComponents` initialize method" | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `Lob::MultipleComponents` initialize method" | ||
end | ||
|
||
# check to see if the attribute exists and convert string to symbol for hash key | ||
attributes = attributes.each_with_object({}) { |(k, v), h| | ||
if (!self.class.attribute_map.key?(k.to_sym)) | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::MultipleComponents`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `Lob::MultipleComponents`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
end | ||
h[k.to_sym] = v | ||
} | ||
|
@@ -359,7 +359,7 @@ def _deserialize(type, value) | |
end | ||
else # model | ||
# models (e.g. Pet) or oneOf | ||
klass = OpenapiClient.const_get(type) | ||
klass = Lob.const_get(type) | ||
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) | ||
end | ||
end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
=begin | ||
#Lob | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
The version of the OpenAPI document: 1.3.0 | ||
Contact: [email protected] | ||
|
@@ -13,30 +13,30 @@ | |
require 'date' | ||
require 'time' | ||
|
||
module OpenapiClient | ||
module Lob | ||
class UsVerification | ||
# Unique identifier prefixed with `us_ver_`. | ||
attr_accessor :id | ||
|
||
# The intended recipient, typically a person's or firm's name. | ||
attr_accessor :recipient | ||
|
||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
attr_accessor :primary_line | ||
|
||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
attr_accessor :secondary_line | ||
|
||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
attr_accessor :urbanization | ||
|
||
# Combination of the following applicable `components`: * City (`city`) * State (`state`) * ZIP code (`zip_code`) * ZIP+4 (`zip_code_plus_4`) | ||
# Combination of the following applicable `components`: * City (`city`) * State (`state`) * ZIP code (`zip_code`) * ZIP+4 (`zip_code_plus_4`) | ||
attr_accessor :last_line | ||
|
||
# Summarizes the deliverability of the `us_verification` object. For full details, see the `deliverability_analysis` field. Possible values are: * `deliverable` – The address is deliverable by the USPS. * `deliverable_unnecessary_unit` – The address is deliverable, but the secondary unit information is unnecessary. * `deliverable_incorrect_unit` – The address is deliverable to the building's default address but the secondary unit provided may not exist. There is a chance the mail will not reach the intended recipient. * `deliverable_missing_unit` – The address is deliverable to the building's default address but is missing secondary unit information. There is a chance the mail will not reach the intended recipient. * `undeliverable` – The address is not deliverable according to the USPS. | ||
# Summarizes the deliverability of the `us_verification` object. For full details, see the `deliverability_analysis` field. Possible values are: * `deliverable` – The address is deliverable by the USPS. * `deliverable_unnecessary_unit` – The address is deliverable, but the secondary unit information is unnecessary. * `deliverable_incorrect_unit` – The address is deliverable to the building's default address but the secondary unit provided may not exist. There is a chance the mail will not reach the intended recipient. * `deliverable_missing_unit` – The address is deliverable to the building's default address but is missing secondary unit information. There is a chance the mail will not reach the intended recipient. * `undeliverable` – The address is not deliverable according to the USPS. | ||
attr_accessor :deliverability | ||
|
||
# This field indicates whether an address was found in a more comprehensive address dataset that includes sources from the USPS, open source mapping data, and our proprietary mail delivery data. This field can be interpreted as a representation of whether an address is a real location or not. Additionally a valid address may contradict the deliverability field since an address can be a real valid location but the USPS may not deliver to that address. | ||
# This field indicates whether an address was found in a more comprehensive address dataset that includes sources from the USPS, open source mapping data, and our proprietary mail delivery data. This field can be interpreted as a representation of whether an address is a real location or not. Additionally a valid address may contradict the deliverability field since an address can be a real valid location but the USPS may not deliver to that address. | ||
attr_accessor :valid_address | ||
|
||
attr_accessor :components | ||
|
@@ -47,7 +47,7 @@ class UsVerification | |
|
||
attr_accessor :object | ||
|
||
# ID that is returned in the response body for the verification | ||
# ID that is returned in the response body for the verification | ||
attr_accessor :transient_id | ||
|
||
class EnumAttributeValidator | ||
|
@@ -126,13 +126,13 @@ def self.openapi_nullable | |
# @param [Hash] attributes Model attributes in the form of hash | ||
def initialize(attributes = {}) | ||
if (!attributes.is_a?(Hash)) | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::UsVerification` initialize method" | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `Lob::UsVerification` initialize method" | ||
end | ||
|
||
# check to see if the attribute exists and convert string to symbol for hash key | ||
attributes = attributes.each_with_object({}) { |(k, v), h| | ||
if (!self.class.attribute_map.key?(k.to_sym)) | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::UsVerification`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `Lob::UsVerification`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
end | ||
h[k.to_sym] = v | ||
} | ||
|
@@ -415,7 +415,7 @@ def _deserialize(type, value) | |
end | ||
else # model | ||
# models (e.g. Pet) or oneOf | ||
klass = OpenapiClient.const_get(type) | ||
klass = Lob.const_get(type) | ||
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) | ||
end | ||
end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
=begin | ||
#Lob | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
#The Lob API is organized around REST. Our API is designed to have predictable, resource-oriented URLs and uses HTTP response codes to indicate any API errors. <p> Looking for our [previous documentation](https://lob.github.io/legacy-docs/)? | ||
The version of the OpenAPI document: 1.3.0 | ||
Contact: [email protected] | ||
|
@@ -13,22 +13,22 @@ | |
require 'date' | ||
require 'time' | ||
|
||
module OpenapiClient | ||
# A model used to represent an entry in a result list where the entry can either be a us_verification or an Error. The SDK will perform necessary casting into the correct corresponding type. | ||
module Lob | ||
# A model used to represent an entry in a result list where the entry can either be a us_verification or an Error. The SDK will perform necessary casting into the correct corresponding type. | ||
class UsVerificationOrError | ||
# Unique identifier prefixed with `us_ver_`. | ||
attr_accessor :id | ||
|
||
# The intended recipient, typically a person's or firm's name. | ||
attr_accessor :recipient | ||
|
||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
# The primary delivery line (usually the street address) of the address. Combination of the following applicable `components`: * `primary_number` * `street_predirection` * `street_name` * `street_suffix` * `street_postdirection` * `secondary_designator` * `secondary_number` * `pmb_designator` * `pmb_number` | ||
attr_accessor :primary_line | ||
|
||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
# The secondary delivery line of the address. This field is typically empty but may contain information if `primary_line` is too long. | ||
attr_accessor :secondary_line | ||
|
||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
# Only present for addresses in Puerto Rico. An urbanization refers to an area, sector, or development within a city. See [USPS documentation](https://pe.usps.com/text/pub28/28api_008.htm#:~:text=I51.,-4%20Urbanizations&text=In%20Puerto%20Rico%2C%20identical%20street,placed%20before%20the%20urbanization%20name.) for clarification. | ||
attr_accessor :urbanization | ||
|
||
attr_accessor :last_line | ||
|
@@ -43,7 +43,7 @@ class UsVerificationOrError | |
|
||
attr_accessor :object | ||
|
||
# ID that is returned in the response body for the verification | ||
# ID that is returned in the response body for the verification | ||
attr_accessor :transient_id | ||
|
||
attr_accessor :error | ||
|
@@ -124,13 +124,13 @@ def self.openapi_nullable | |
# @param [Hash] attributes Model attributes in the form of hash | ||
def initialize(attributes = {}) | ||
if (!attributes.is_a?(Hash)) | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::UsVerificationOrError` initialize method" | ||
fail ArgumentError, "The input argument (attributes) must be a hash in `Lob::UsVerificationOrError` initialize method" | ||
end | ||
|
||
# check to see if the attribute exists and convert string to symbol for hash key | ||
attributes = attributes.each_with_object({}) { |(k, v), h| | ||
if (!self.class.attribute_map.key?(k.to_sym)) | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::UsVerificationOrError`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
fail ArgumentError, "`#{k}` is not a valid attribute in `Lob::UsVerificationOrError`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect | ||
end | ||
h[k.to_sym] = v | ||
} | ||
|
@@ -413,7 +413,7 @@ def _deserialize(type, value) | |
end | ||
else # model | ||
# models (e.g. Pet) or oneOf | ||
klass = OpenapiClient.const_get(type) | ||
klass = Lob.const_get(type) | ||
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) | ||
end | ||
end | ||
|
Oops, something went wrong.