zernio-sdk 0.0.1102 → 0.0.1103

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fbe86ecb977510e2c3cdca9fb59622eda30e98eff848c898163346250c6da926
4
- data.tar.gz: 6afe7324dd81f7b854c24d266f7167e2d650c18c2effdfa1ab98b713651ab441
3
+ metadata.gz: 8e2e754806ecf770f37a43d73b8c81169d4de26bb317092a4a6606288298ce82
4
+ data.tar.gz: e9e42316a5037246e7a623a8f43b7f31b28aa191165aa0bff89627b2a70dca36
5
5
  SHA512:
6
- metadata.gz: 434cc392e7a676937e9881b6dd853f7a27b330008d8708f7b058a5c86ad6e3b860d63891d03e466f64fa8db1e58100e88a6c292fcb5ea708a96360fd1252c973
7
- data.tar.gz: cc391d0ea2f7b8633bc7fde9bb1a640ae8c1c36c6a791f1d2510c0053e7f3633921c33df0534975c253db0128499baca7c72652976fa98bb8de377f37be88e36
6
+ metadata.gz: 19ac675cee6f4386746f1daedfa3920fc0bce94174959148cc4fc0f81897ef04c770e232a2a8f26d226ee783c5b353a216235ce2607ca643304bbb76254167fc
7
+ data.tar.gz: f67d175894a1b4b7214ee78efb1eaa7869184834841e087e9150f889da2dc4775fbbaf30ddedfe9eee90fc28888de6ed4de956d429c8f026427440bb85bc4304
data/README.md CHANGED
@@ -582,6 +582,7 @@ Class | Method | HTTP request | Description
582
582
  *Zernio::PhoneNumbersApi* | [**get_phone_number**](docs/PhoneNumbersApi.md#get_phone_number) | **GET** /v1/phone-numbers/{id} | Get phone number
583
583
  *Zernio::PhoneNumbersApi* | [**get_phone_number_claim**](docs/PhoneNumbersApi.md#get_phone_number_claim) | **GET** /v1/phone-numbers/claims/{claimId} | Resolve a number claim
584
584
  *Zernio::PhoneNumbersApi* | [**get_phone_number_kyc_form**](docs/PhoneNumbersApi.md#get_phone_number_kyc_form) | **GET** /v1/phone-numbers/kyc | Get KYC form spec
585
+ *Zernio::PhoneNumbersApi* | [**get_phone_number_port_claim**](docs/PhoneNumbersApi.md#get_phone_number_port_claim) | **GET** /v1/phone-numbers/port-in/claims/{claimId} | Resolve a port claim
585
586
  *Zernio::PhoneNumbersApi* | [**get_phone_number_port_in_order_requirements**](docs/PhoneNumbersApi.md#get_phone_number_port_in_order_requirements) | **GET** /v1/phone-numbers/port-in/{id}/requirements | A port-in order's pending requirements
586
587
  *Zernio::PhoneNumbersApi* | [**get_phone_number_port_in_requirements**](docs/PhoneNumbersApi.md#get_phone_number_port_in_requirements) | **GET** /v1/phone-numbers/port-in/requirements | Country porting requirements
587
588
  *Zernio::PhoneNumbersApi* | [**get_phone_number_remediation**](docs/PhoneNumbersApi.md#get_phone_number_remediation) | **GET** /v1/phone-numbers/{id}/remediate | Get declined requirements
@@ -1711,6 +1712,7 @@ Class | Method | HTTP request | Description
1711
1712
  - [Zernio::GetPhoneNumberKycForm200ResponseReusableDetailsInner](docs/GetPhoneNumberKycForm200ResponseReusableDetailsInner.md)
1712
1713
  - [Zernio::GetPhoneNumberKycForm200ResponseReusableOptionsInner](docs/GetPhoneNumberKycForm200ResponseReusableOptionsInner.md)
1713
1714
  - [Zernio::GetPhoneNumberKycForm200ResponseReusableOptionsInnerDetailsInner](docs/GetPhoneNumberKycForm200ResponseReusableOptionsInnerDetailsInner.md)
1715
+ - [Zernio::GetPhoneNumberPortClaim200Response](docs/GetPhoneNumberPortClaim200Response.md)
1714
1716
  - [Zernio::GetPhoneNumberPortInOrderRequirements200Response](docs/GetPhoneNumberPortInOrderRequirements200Response.md)
1715
1717
  - [Zernio::GetPhoneNumberPortInOrderRequirements200ResponseRequirementsInner](docs/GetPhoneNumberPortInOrderRequirements200ResponseRequirementsInner.md)
1716
1718
  - [Zernio::GetPhoneNumberPortInRequirements200Response](docs/GetPhoneNumberPortInRequirements200Response.md)
@@ -7,10 +7,14 @@
7
7
  | **phone_number** | **String** | | [optional] |
8
8
  | **portable** | **Boolean** | | [optional] |
9
9
  | **fast_portable** | **Boolean** | Qualifies for the carrier's accelerated FastPort lane. | [optional] |
10
- | **line_type** | **String** | Line type when known (mobile, landline, voip…). A US/CA mobile number requires the transfer PIN at submit. | [optional] |
10
+ | **messaging_capable** | **Boolean** | Whether texting can be enabled on the number once ported; null when the carrier does not say. | [optional] |
11
+ | **line_type** | **String** | Line type when known (mobile, landline, voip, toll-free, unknown). US/CA portable numbers only. A US/CA mobile number requires the transfer PIN at submit. | [optional] |
12
+ | **carrier_name** | **String** | The number's current carrier, when the lookup knows it. US/CA portable numbers only. | [optional] |
11
13
  | **country_code** | **String** | ISO country of the number. Pass it to GET /v1/phone-numbers/port-in/requirements for international numbers. | [optional] |
12
- | **phone_number_type** | **String** | Carrier number-type classification (local, mobile, national, toll_free…), the numberType for the requirements endpoint. | [optional] |
14
+ | **phone_number_type** | **String** | Carrier number-type classification (local, mobile, national, toll_free...), the numberType for the requirements endpoint. | [optional] |
13
15
  | **not_portable_reason** | **String** | Carrier reason when not portable; null when portable. | [optional] |
16
+ | **claim_id** | **String** | Keyless calls and claimLinks=true only, on portable results. Resolve it with GET /v1/phone-numbers/port-in/claims/{claimId}. Expires after 7 days. | [optional] |
17
+ | **claim_url** | **String** | Keyless calls and claimLinks=true only, on portable results. A signup link that lands on the dashboard's port form with this number filled in. | [optional] |
14
18
 
15
19
  ## Example
16
20
 
@@ -21,10 +25,14 @@ instance = Zernio::CheckPhoneNumberPortability200ResponseResultsInner.new(
21
25
  phone_number: null,
22
26
  portable: null,
23
27
  fast_portable: null,
28
+ messaging_capable: null,
24
29
  line_type: null,
30
+ carrier_name: null,
25
31
  country_code: null,
26
32
  phone_number_type: null,
27
- not_portable_reason: null
33
+ not_portable_reason: null,
34
+ claim_id: null,
35
+ claim_url: null
28
36
  )
29
37
  ```
30
38
 
@@ -4,7 +4,8 @@
4
4
 
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
- | **phone_numbers** | **Array<String>** | E.164 numbers to check, e.g. +13035550000. | |
7
+ | **phone_numbers** | **Array<String>** | E.164 numbers to check, e.g. +13035550000. At most one without an API key. | |
8
+ | **claim_links** | **Boolean** | true adds `claimId` and `claimUrl` to portable results even when you send an API key, e.g. to hand a user a signup link that opens the port form with their number. | [optional] |
8
9
 
9
10
  ## Example
10
11
 
@@ -12,7 +13,8 @@
12
13
  require 'zernio-sdk'
13
14
 
14
15
  instance = Zernio::CheckPhoneNumberPortabilityRequest.new(
15
- phone_numbers: null
16
+ phone_numbers: null,
17
+ claim_links: null
16
18
  )
17
19
  ```
18
20
 
@@ -0,0 +1,20 @@
1
+ # Zernio::GetPhoneNumberPortClaim200Response
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **phone_number** | **String** | E.164. | [optional] |
8
+ | **country_code** | **String** | ISO country of the number. | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'zernio-sdk'
14
+
15
+ instance = Zernio::GetPhoneNumberPortClaim200Response.new(
16
+ phone_number: null,
17
+ country_code: null
18
+ )
19
+ ```
20
+
@@ -14,6 +14,7 @@ All URIs are relative to *https://zernio.com/api*
14
14
  | [**get_phone_number**](PhoneNumbersApi.md#get_phone_number) | **GET** /v1/phone-numbers/{id} | Get phone number |
15
15
  | [**get_phone_number_claim**](PhoneNumbersApi.md#get_phone_number_claim) | **GET** /v1/phone-numbers/claims/{claimId} | Resolve a number claim |
16
16
  | [**get_phone_number_kyc_form**](PhoneNumbersApi.md#get_phone_number_kyc_form) | **GET** /v1/phone-numbers/kyc | Get KYC form spec |
17
+ | [**get_phone_number_port_claim**](PhoneNumbersApi.md#get_phone_number_port_claim) | **GET** /v1/phone-numbers/port-in/claims/{claimId} | Resolve a port claim |
17
18
  | [**get_phone_number_port_in_order_requirements**](PhoneNumbersApi.md#get_phone_number_port_in_order_requirements) | **GET** /v1/phone-numbers/port-in/{id}/requirements | A port-in order's pending requirements |
18
19
  | [**get_phone_number_port_in_requirements**](PhoneNumbersApi.md#get_phone_number_port_in_requirements) | **GET** /v1/phone-numbers/port-in/requirements | Country porting requirements |
19
20
  | [**get_phone_number_remediation**](PhoneNumbersApi.md#get_phone_number_remediation) | **GET** /v1/phone-numbers/{id}/remediate | Get declined requirements |
@@ -185,7 +186,7 @@ end
185
186
 
186
187
  Check portability
187
188
 
188
- Pre-flight portability check: whether each number can be ported in and whether it qualifies for FastPort, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing.
189
+ Pre-flight portability check: whether each number can be ported in, whether it qualifies for FastPort, and its current carrier and line type where the carrier lookup knows them, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing. Works without an API key for one number per request. Keyless calls are what the checker at https://zernio.com/port-your-number makes: they must come from that page (a browser bot check rejects scripted callers with 401), are limited per IP (3 a minute, 10 a day) and by a shared daily budget (429 once spent), because each check runs a paid carrier lookup. Each portable keyless result carries a `claimId` and a `claimUrl`: a signup link that opens the dashboard's port form with the number filled in. Send an API key to check up to 50 numbers without those limits.
189
190
 
190
191
  ### Examples
191
192
 
@@ -733,6 +734,75 @@ end
733
734
  - **Accept**: application/json
734
735
 
735
736
 
737
+ ## get_phone_number_port_claim
738
+
739
+ > <GetPhoneNumberPortClaim200Response> get_phone_number_port_claim(claim_id)
740
+
741
+ Resolve a port claim
742
+
743
+ Resolves a `claimId` from a keyless portability check into the number it carries. The dashboard calls it when a person lands from a port `claimUrl`, to open the port form with that number filled in. It does not start a port.
744
+
745
+ ### Examples
746
+
747
+ ```ruby
748
+ require 'time'
749
+ require 'zernio-sdk'
750
+ # setup authorization
751
+ Zernio.configure do |config|
752
+ # Configure Bearer authorization (JWT): bearerAuth
753
+ config.access_token = 'YOUR_BEARER_TOKEN'
754
+ end
755
+
756
+ api_instance = Zernio::PhoneNumbersApi.new
757
+ claim_id = 'claim_id_example' # String |
758
+
759
+ begin
760
+ # Resolve a port claim
761
+ result = api_instance.get_phone_number_port_claim(claim_id)
762
+ p result
763
+ rescue Zernio::ApiError => e
764
+ puts "Error when calling PhoneNumbersApi->get_phone_number_port_claim: #{e}"
765
+ end
766
+ ```
767
+
768
+ #### Using the get_phone_number_port_claim_with_http_info variant
769
+
770
+ This returns an Array which contains the response data, status code and headers.
771
+
772
+ > <Array(<GetPhoneNumberPortClaim200Response>, Integer, Hash)> get_phone_number_port_claim_with_http_info(claim_id)
773
+
774
+ ```ruby
775
+ begin
776
+ # Resolve a port claim
777
+ data, status_code, headers = api_instance.get_phone_number_port_claim_with_http_info(claim_id)
778
+ p status_code # => 2xx
779
+ p headers # => { ... }
780
+ p data # => <GetPhoneNumberPortClaim200Response>
781
+ rescue Zernio::ApiError => e
782
+ puts "Error when calling PhoneNumbersApi->get_phone_number_port_claim_with_http_info: #{e}"
783
+ end
784
+ ```
785
+
786
+ ### Parameters
787
+
788
+ | Name | Type | Description | Notes |
789
+ | ---- | ---- | ----------- | ----- |
790
+ | **claim_id** | **String** | | |
791
+
792
+ ### Return type
793
+
794
+ [**GetPhoneNumberPortClaim200Response**](GetPhoneNumberPortClaim200Response.md)
795
+
796
+ ### Authorization
797
+
798
+ [bearerAuth](../README.md#bearerAuth)
799
+
800
+ ### HTTP request headers
801
+
802
+ - **Content-Type**: Not defined
803
+ - **Accept**: application/json
804
+
805
+
736
806
  ## get_phone_number_port_in_order_requirements
737
807
 
738
808
  > <GetPhoneNumberPortInOrderRequirements200Response> get_phone_number_port_in_order_requirements(id)
@@ -157,7 +157,7 @@ module Zernio
157
157
  end
158
158
 
159
159
  # Check portability
160
- # Pre-flight portability check: whether each number can be ported in and whether it qualifies for FastPort, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing.
160
+ # Pre-flight portability check: whether each number can be ported in, whether it qualifies for FastPort, and its current carrier and line type where the carrier lookup knows them, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing. Works without an API key for one number per request. Keyless calls are what the checker at https://zernio.com/port-your-number makes: they must come from that page (a browser bot check rejects scripted callers with 401), are limited per IP (3 a minute, 10 a day) and by a shared daily budget (429 once spent), because each check runs a paid carrier lookup. Each portable keyless result carries a `claimId` and a `claimUrl`: a signup link that opens the dashboard's port form with the number filled in. Send an API key to check up to 50 numbers without those limits.
161
161
  # @param check_phone_number_portability_request [CheckPhoneNumberPortabilityRequest]
162
162
  # @param [Hash] opts the optional parameters
163
163
  # @return [CheckPhoneNumberPortability200Response]
@@ -167,7 +167,7 @@ module Zernio
167
167
  end
168
168
 
169
169
  # Check portability
170
- # Pre-flight portability check: whether each number can be ported in and whether it qualifies for FastPort, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing.
170
+ # Pre-flight portability check: whether each number can be ported in, whether it qualifies for FastPort, and its current carrier and line type where the carrier lookup knows them, BEFORE the user commits to a port order (LOA, invoice, service address). Read-only; creates no order and bills nothing. Works without an API key for one number per request. Keyless calls are what the checker at https://zernio.com/port-your-number makes: they must come from that page (a browser bot check rejects scripted callers with 401), are limited per IP (3 a minute, 10 a day) and by a shared daily budget (429 once spent), because each check runs a paid carrier lookup. Each portable keyless result carries a &#x60;claimId&#x60; and a &#x60;claimUrl&#x60;: a signup link that opens the dashboard&#39;s port form with the number filled in. Send an API key to check up to 50 numbers without those limits.
171
171
  # @param check_phone_number_portability_request [CheckPhoneNumberPortabilityRequest]
172
172
  # @param [Hash] opts the optional parameters
173
173
  # @return [Array<(CheckPhoneNumberPortability200Response, Integer, Hash)>] CheckPhoneNumberPortability200Response data, response status code and response headers
@@ -686,6 +686,69 @@ module Zernio
686
686
  return data, status_code, headers
687
687
  end
688
688
 
689
+ # Resolve a port claim
690
+ # Resolves a `claimId` from a keyless portability check into the number it carries. The dashboard calls it when a person lands from a port `claimUrl`, to open the port form with that number filled in. It does not start a port.
691
+ # @param claim_id [String]
692
+ # @param [Hash] opts the optional parameters
693
+ # @return [GetPhoneNumberPortClaim200Response]
694
+ def get_phone_number_port_claim(claim_id, opts = {})
695
+ data, _status_code, _headers = get_phone_number_port_claim_with_http_info(claim_id, opts)
696
+ data
697
+ end
698
+
699
+ # Resolve a port claim
700
+ # Resolves a &#x60;claimId&#x60; from a keyless portability check into the number it carries. The dashboard calls it when a person lands from a port &#x60;claimUrl&#x60;, to open the port form with that number filled in. It does not start a port.
701
+ # @param claim_id [String]
702
+ # @param [Hash] opts the optional parameters
703
+ # @return [Array<(GetPhoneNumberPortClaim200Response, Integer, Hash)>] GetPhoneNumberPortClaim200Response data, response status code and response headers
704
+ def get_phone_number_port_claim_with_http_info(claim_id, opts = {})
705
+ if @api_client.config.debugging
706
+ @api_client.config.logger.debug 'Calling API: PhoneNumbersApi.get_phone_number_port_claim ...'
707
+ end
708
+ # verify the required parameter 'claim_id' is set
709
+ if @api_client.config.client_side_validation && claim_id.nil?
710
+ fail ArgumentError, "Missing the required parameter 'claim_id' when calling PhoneNumbersApi.get_phone_number_port_claim"
711
+ end
712
+ # resource path
713
+ local_var_path = '/v1/phone-numbers/port-in/claims/{claimId}'.sub('{' + 'claimId' + '}', CGI.escape(claim_id.to_s))
714
+
715
+ # query parameters
716
+ query_params = opts[:query_params] || {}
717
+
718
+ # header parameters
719
+ header_params = opts[:header_params] || {}
720
+ # HTTP header 'Accept' (if needed)
721
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
722
+
723
+ # form parameters
724
+ form_params = opts[:form_params] || {}
725
+
726
+ # http body (model)
727
+ post_body = opts[:debug_body]
728
+
729
+ # return_type
730
+ return_type = opts[:debug_return_type] || 'GetPhoneNumberPortClaim200Response'
731
+
732
+ # auth_names
733
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
734
+
735
+ new_options = opts.merge(
736
+ :operation => :"PhoneNumbersApi.get_phone_number_port_claim",
737
+ :header_params => header_params,
738
+ :query_params => query_params,
739
+ :form_params => form_params,
740
+ :body => post_body,
741
+ :auth_names => auth_names,
742
+ :return_type => return_type
743
+ )
744
+
745
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
746
+ if @api_client.config.debugging
747
+ @api_client.config.logger.debug "API called: PhoneNumbersApi#get_phone_number_port_claim\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
748
+ end
749
+ return data, status_code, headers
750
+ end
751
+
689
752
  # A port-in order's pending requirements
690
753
  # The live requirements on an EXISTING porting order: which are filled, which are still pending, and which bounced on review (`requirement-info-exception`). Use it to fix and resubmit a rejected international port. Same field shape as the country-level requirements endpoint, plus per-requirement status.
691
754
  # @param id [String] Porting order ID (from the port-in list).
@@ -22,28 +22,44 @@ module Zernio
22
22
  # Qualifies for the carrier's accelerated FastPort lane.
23
23
  attr_accessor :fast_portable
24
24
 
25
- # Line type when known (mobile, landline, voip…). A US/CA mobile number requires the transfer PIN at submit.
25
+ # Whether texting can be enabled on the number once ported; null when the carrier does not say.
26
+ attr_accessor :messaging_capable
27
+
28
+ # Line type when known (mobile, landline, voip, toll-free, unknown). US/CA portable numbers only. A US/CA mobile number requires the transfer PIN at submit.
26
29
  attr_accessor :line_type
27
30
 
31
+ # The number's current carrier, when the lookup knows it. US/CA portable numbers only.
32
+ attr_accessor :carrier_name
33
+
28
34
  # ISO country of the number. Pass it to GET /v1/phone-numbers/port-in/requirements for international numbers.
29
35
  attr_accessor :country_code
30
36
 
31
- # Carrier number-type classification (local, mobile, national, toll_free…), the numberType for the requirements endpoint.
37
+ # Carrier number-type classification (local, mobile, national, toll_free...), the numberType for the requirements endpoint.
32
38
  attr_accessor :phone_number_type
33
39
 
34
40
  # Carrier reason when not portable; null when portable.
35
41
  attr_accessor :not_portable_reason
36
42
 
43
+ # Keyless calls and claimLinks=true only, on portable results. Resolve it with GET /v1/phone-numbers/port-in/claims/{claimId}. Expires after 7 days.
44
+ attr_accessor :claim_id
45
+
46
+ # Keyless calls and claimLinks=true only, on portable results. A signup link that lands on the dashboard's port form with this number filled in.
47
+ attr_accessor :claim_url
48
+
37
49
  # Attribute mapping from ruby-style variable name to JSON key.
38
50
  def self.attribute_map
39
51
  {
40
52
  :'phone_number' => :'phoneNumber',
41
53
  :'portable' => :'portable',
42
54
  :'fast_portable' => :'fastPortable',
55
+ :'messaging_capable' => :'messagingCapable',
43
56
  :'line_type' => :'lineType',
57
+ :'carrier_name' => :'carrierName',
44
58
  :'country_code' => :'countryCode',
45
59
  :'phone_number_type' => :'phoneNumberType',
46
- :'not_portable_reason' => :'notPortableReason'
60
+ :'not_portable_reason' => :'notPortableReason',
61
+ :'claim_id' => :'claimId',
62
+ :'claim_url' => :'claimUrl'
47
63
  }
48
64
  end
49
65
 
@@ -63,20 +79,26 @@ module Zernio
63
79
  :'phone_number' => :'String',
64
80
  :'portable' => :'Boolean',
65
81
  :'fast_portable' => :'Boolean',
82
+ :'messaging_capable' => :'Boolean',
66
83
  :'line_type' => :'String',
84
+ :'carrier_name' => :'String',
67
85
  :'country_code' => :'String',
68
86
  :'phone_number_type' => :'String',
69
- :'not_portable_reason' => :'String'
87
+ :'not_portable_reason' => :'String',
88
+ :'claim_id' => :'String',
89
+ :'claim_url' => :'String'
70
90
  }
71
91
  end
72
92
 
73
93
  # List of attributes with nullable: true
74
94
  def self.openapi_nullable
75
95
  Set.new([
96
+ :'messaging_capable',
76
97
  :'line_type',
98
+ :'carrier_name',
77
99
  :'country_code',
78
100
  :'phone_number_type',
79
- :'not_portable_reason'
101
+ :'not_portable_reason',
80
102
  ])
81
103
  end
82
104
 
@@ -108,10 +130,18 @@ module Zernio
108
130
  self.fast_portable = attributes[:'fast_portable']
109
131
  end
110
132
 
133
+ if attributes.key?(:'messaging_capable')
134
+ self.messaging_capable = attributes[:'messaging_capable']
135
+ end
136
+
111
137
  if attributes.key?(:'line_type')
112
138
  self.line_type = attributes[:'line_type']
113
139
  end
114
140
 
141
+ if attributes.key?(:'carrier_name')
142
+ self.carrier_name = attributes[:'carrier_name']
143
+ end
144
+
115
145
  if attributes.key?(:'country_code')
116
146
  self.country_code = attributes[:'country_code']
117
147
  end
@@ -123,6 +153,14 @@ module Zernio
123
153
  if attributes.key?(:'not_portable_reason')
124
154
  self.not_portable_reason = attributes[:'not_portable_reason']
125
155
  end
156
+
157
+ if attributes.key?(:'claim_id')
158
+ self.claim_id = attributes[:'claim_id']
159
+ end
160
+
161
+ if attributes.key?(:'claim_url')
162
+ self.claim_url = attributes[:'claim_url']
163
+ end
126
164
  end
127
165
 
128
166
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -148,10 +186,14 @@ module Zernio
148
186
  phone_number == o.phone_number &&
149
187
  portable == o.portable &&
150
188
  fast_portable == o.fast_portable &&
189
+ messaging_capable == o.messaging_capable &&
151
190
  line_type == o.line_type &&
191
+ carrier_name == o.carrier_name &&
152
192
  country_code == o.country_code &&
153
193
  phone_number_type == o.phone_number_type &&
154
- not_portable_reason == o.not_portable_reason
194
+ not_portable_reason == o.not_portable_reason &&
195
+ claim_id == o.claim_id &&
196
+ claim_url == o.claim_url
155
197
  end
156
198
 
157
199
  # @see the `==` method
@@ -163,7 +205,7 @@ module Zernio
163
205
  # Calculates hash code according to all attributes.
164
206
  # @return [Integer] Hash code
165
207
  def hash
166
- [phone_number, portable, fast_portable, line_type, country_code, phone_number_type, not_portable_reason].hash
208
+ [phone_number, portable, fast_portable, messaging_capable, line_type, carrier_name, country_code, phone_number_type, not_portable_reason, claim_id, claim_url].hash
167
209
  end
168
210
 
169
211
  # Builds the object from hash
@@ -15,13 +15,17 @@ require 'time'
15
15
 
16
16
  module Zernio
17
17
  class CheckPhoneNumberPortabilityRequest < ApiModelBase
18
- # E.164 numbers to check, e.g. +13035550000.
18
+ # E.164 numbers to check, e.g. +13035550000. At most one without an API key.
19
19
  attr_accessor :phone_numbers
20
20
 
21
+ # true adds `claimId` and `claimUrl` to portable results even when you send an API key, e.g. to hand a user a signup link that opens the port form with their number.
22
+ attr_accessor :claim_links
23
+
21
24
  # Attribute mapping from ruby-style variable name to JSON key.
22
25
  def self.attribute_map
23
26
  {
24
- :'phone_numbers' => :'phoneNumbers'
27
+ :'phone_numbers' => :'phoneNumbers',
28
+ :'claim_links' => :'claimLinks'
25
29
  }
26
30
  end
27
31
 
@@ -38,7 +42,8 @@ module Zernio
38
42
  # Attribute type mapping.
39
43
  def self.openapi_types
40
44
  {
41
- :'phone_numbers' => :'Array<String>'
45
+ :'phone_numbers' => :'Array<String>',
46
+ :'claim_links' => :'Boolean'
42
47
  }
43
48
  end
44
49
 
@@ -71,6 +76,10 @@ module Zernio
71
76
  else
72
77
  self.phone_numbers = nil
73
78
  end
79
+
80
+ if attributes.key?(:'claim_links')
81
+ self.claim_links = attributes[:'claim_links']
82
+ end
74
83
  end
75
84
 
76
85
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -126,7 +135,8 @@ module Zernio
126
135
  def ==(o)
127
136
  return true if self.equal?(o)
128
137
  self.class == o.class &&
129
- phone_numbers == o.phone_numbers
138
+ phone_numbers == o.phone_numbers &&
139
+ claim_links == o.claim_links
130
140
  end
131
141
 
132
142
  # @see the `==` method
@@ -138,7 +148,7 @@ module Zernio
138
148
  # Calculates hash code according to all attributes.
139
149
  # @return [Integer] Hash code
140
150
  def hash
141
- [phone_numbers].hash
151
+ [phone_numbers, claim_links].hash
142
152
  end
143
153
 
144
154
  # Builds the object from hash
@@ -0,0 +1,159 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema). Request ids: responses carry an X-Request-Id header with the id we log the request under. Quote it when reporting a problem. A valid x-request-id you send is reused as that id.
5
+
6
+ The version of the OpenAPI document: 1.93.0
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class GetPhoneNumberPortClaim200Response < ApiModelBase
18
+ # E.164.
19
+ attr_accessor :phone_number
20
+
21
+ # ISO country of the number.
22
+ attr_accessor :country_code
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'phone_number' => :'phoneNumber',
28
+ :'country_code' => :'countryCode'
29
+ }
30
+ end
31
+
32
+ # Returns attribute mapping this model knows about
33
+ def self.acceptable_attribute_map
34
+ attribute_map
35
+ end
36
+
37
+ # Returns all the JSON keys this model knows about
38
+ def self.acceptable_attributes
39
+ acceptable_attribute_map.values
40
+ end
41
+
42
+ # Attribute type mapping.
43
+ def self.openapi_types
44
+ {
45
+ :'phone_number' => :'String',
46
+ :'country_code' => :'String'
47
+ }
48
+ end
49
+
50
+ # List of attributes with nullable: true
51
+ def self.openapi_nullable
52
+ Set.new([
53
+ :'country_code'
54
+ ])
55
+ end
56
+
57
+ # Initializes the object
58
+ # @param [Hash] attributes Model attributes in the form of hash
59
+ def initialize(attributes = {})
60
+ if (!attributes.is_a?(Hash))
61
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::GetPhoneNumberPortClaim200Response` initialize method"
62
+ end
63
+
64
+ # check to see if the attribute exists and convert string to symbol for hash key
65
+ acceptable_attribute_map = self.class.acceptable_attribute_map
66
+ attributes = attributes.each_with_object({}) { |(k, v), h|
67
+ if (!acceptable_attribute_map.key?(k.to_sym))
68
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::GetPhoneNumberPortClaim200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
69
+ end
70
+ h[k.to_sym] = v
71
+ }
72
+
73
+ if attributes.key?(:'phone_number')
74
+ self.phone_number = attributes[:'phone_number']
75
+ end
76
+
77
+ if attributes.key?(:'country_code')
78
+ self.country_code = attributes[:'country_code']
79
+ end
80
+ end
81
+
82
+ # Show invalid properties with the reasons. Usually used together with valid?
83
+ # @return Array for valid properties with the reasons
84
+ def list_invalid_properties
85
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
86
+ invalid_properties = Array.new
87
+ invalid_properties
88
+ end
89
+
90
+ # Check to see if the all the properties in the model are valid
91
+ # @return true if the model is valid
92
+ def valid?
93
+ warn '[DEPRECATED] the `valid?` method is obsolete'
94
+ true
95
+ end
96
+
97
+ # Checks equality by comparing each attribute.
98
+ # @param [Object] Object to be compared
99
+ def ==(o)
100
+ return true if self.equal?(o)
101
+ self.class == o.class &&
102
+ phone_number == o.phone_number &&
103
+ country_code == o.country_code
104
+ end
105
+
106
+ # @see the `==` method
107
+ # @param [Object] Object to be compared
108
+ def eql?(o)
109
+ self == o
110
+ end
111
+
112
+ # Calculates hash code according to all attributes.
113
+ # @return [Integer] Hash code
114
+ def hash
115
+ [phone_number, country_code].hash
116
+ end
117
+
118
+ # Builds the object from hash
119
+ # @param [Hash] attributes Model attributes in the form of hash
120
+ # @return [Object] Returns the model itself
121
+ def self.build_from_hash(attributes)
122
+ return nil unless attributes.is_a?(Hash)
123
+ attributes = attributes.transform_keys(&:to_sym)
124
+ transformed_hash = {}
125
+ openapi_types.each_pair do |key, type|
126
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
127
+ transformed_hash["#{key}"] = nil
128
+ elsif type =~ /\AArray<(.*)>/i
129
+ # check to ensure the input is an array given that the attribute
130
+ # is documented as an array but the input is not
131
+ if attributes[attribute_map[key]].is_a?(Array)
132
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
133
+ end
134
+ elsif !attributes[attribute_map[key]].nil?
135
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
136
+ end
137
+ end
138
+ new(transformed_hash)
139
+ end
140
+
141
+ # Returns the object in the form of hash
142
+ # @return [Hash] Returns the object in the form of hash
143
+ def to_hash
144
+ hash = {}
145
+ self.class.attribute_map.each_pair do |attr, param|
146
+ value = self.send(attr)
147
+ if value.nil?
148
+ is_nullable = self.class.openapi_nullable.include?(attr)
149
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
150
+ end
151
+
152
+ hash[param] = _to_hash(value)
153
+ end
154
+ hash
155
+ end
156
+
157
+ end
158
+
159
+ end
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.1102'
14
+ VERSION = '0.0.1103'
15
15
  end
data/lib/zernio-sdk.rb CHANGED
@@ -869,6 +869,7 @@ require 'zernio-sdk/models/get_phone_number_kyc_form200_response_reusable'
869
869
  require 'zernio-sdk/models/get_phone_number_kyc_form200_response_reusable_details_inner'
870
870
  require 'zernio-sdk/models/get_phone_number_kyc_form200_response_reusable_options_inner'
871
871
  require 'zernio-sdk/models/get_phone_number_kyc_form200_response_reusable_options_inner_details_inner'
872
+ require 'zernio-sdk/models/get_phone_number_port_claim200_response'
872
873
  require 'zernio-sdk/models/get_phone_number_port_in_order_requirements200_response'
873
874
  require 'zernio-sdk/models/get_phone_number_port_in_order_requirements200_response_requirements_inner'
874
875
  require 'zernio-sdk/models/get_phone_number_port_in_requirements200_response'