bandwidth-sdk 16.2.2 → 17.0.0
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 +4 -4
- data/Gemfile.lock +8 -8
- data/README.md +20 -7
- data/bandwidth.yml +551 -277
- data/coverage/.last_run.json +1 -1
- data/coverage/.resultset.json +197 -94
- data/coverage/index.html +2425 -1307
- data/docs/AsyncLookupRequest.md +18 -0
- data/docs/{LookupRequest.md → CompletedLookupStatusEnum.md} +2 -5
- data/docs/CreateAsyncBulkLookupResponse.md +22 -0
- data/docs/{CreateLookupResponse.md → CreateAsyncBulkLookupResponseData.md} +4 -4
- data/docs/CreateSyncLookupResponse.md +22 -0
- data/docs/CreateSyncLookupResponseData.md +22 -0
- data/docs/DeactivationEventEnum.md +15 -0
- data/docs/GetAsyncBulkLookupResponse.md +22 -0
- data/docs/GetAsyncBulkLookupResponseData.md +22 -0
- data/docs/InProgressLookupStatusEnum.md +15 -0
- data/docs/LatestMessageDeliveryStatusEnum.md +15 -0
- data/docs/{LookupStatusEnum.md → LineTypeEnum.md} +2 -2
- data/docs/LinkSchema.md +22 -0
- data/docs/LookupErrorResponse.md +22 -0
- data/docs/LookupErrorSchema.md +24 -0
- data/docs/LookupErrorSchemaMeta.md +22 -0
- data/docs/LookupResult.md +22 -18
- data/docs/PhoneNumberLookupApi.md +111 -38
- data/docs/RbmActionBase.md +1 -1
- data/docs/RbmSuggestionResponse.md +1 -1
- data/docs/SyncLookupRequest.md +18 -0
- data/lib/bandwidth-sdk/api/phone_number_lookup_api.rb +117 -47
- data/lib/bandwidth-sdk/configuration.rb +10 -4
- data/lib/bandwidth-sdk/models/async_lookup_request.rb +232 -0
- data/lib/bandwidth-sdk/models/completed_lookup_status_enum.rb +41 -0
- data/lib/bandwidth-sdk/models/create_async_bulk_lookup_response.rb +235 -0
- data/lib/bandwidth-sdk/models/{create_lookup_response.rb → create_async_bulk_lookup_response_data.rb} +5 -5
- data/lib/bandwidth-sdk/models/create_sync_lookup_response.rb +234 -0
- data/lib/bandwidth-sdk/models/{lookup_status.rb → create_sync_lookup_response_data.rb} +15 -27
- data/lib/bandwidth-sdk/models/deactivation_event_enum.rb +39 -0
- data/lib/bandwidth-sdk/models/get_async_bulk_lookup_response.rb +234 -0
- data/lib/bandwidth-sdk/models/get_async_bulk_lookup_response_data.rb +257 -0
- data/lib/bandwidth-sdk/models/{lookup_status_enum.rb → in_progress_lookup_status_enum.rb} +3 -3
- data/lib/bandwidth-sdk/models/latest_message_delivery_status_enum.rb +41 -0
- data/lib/bandwidth-sdk/models/line_type_enum.rb +42 -0
- data/lib/bandwidth-sdk/models/{lookup_request.rb → link_schema.rb} +31 -20
- data/lib/bandwidth-sdk/models/lookup_error_response.rb +235 -0
- data/lib/bandwidth-sdk/models/lookup_error_schema.rb +242 -0
- data/lib/bandwidth-sdk/models/{tn_lookup_request_error.rb → lookup_error_schema_meta.rb} +29 -8
- data/lib/bandwidth-sdk/models/lookup_result.rb +102 -63
- data/lib/bandwidth-sdk/models/sync_lookup_request.rb +232 -0
- data/lib/bandwidth-sdk/version.rb +1 -1
- data/lib/bandwidth-sdk.rb +17 -5
- data/spec/smoke/multi_channel_api_spec.rb +1 -1
- data/spec/smoke/phone_number_lookup_api_spec.rb +65 -70
- data/spec/unit/api/phone_number_lookup_api_spec.rb +71 -56
- metadata +36 -12
- data/docs/LookupStatus.md +0 -24
- data/docs/TnLookupRequestError.md +0 -18
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Bandwidth::AsyncLookupRequest
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **phone_numbers** | **Array<String>** | Telephone numbers in E.164 format. | |
|
|
8
|
+
|
|
9
|
+
## Example
|
|
10
|
+
|
|
11
|
+
```ruby
|
|
12
|
+
require 'bandwidth-sdk'
|
|
13
|
+
|
|
14
|
+
instance = Bandwidth::AsyncLookupRequest.new(
|
|
15
|
+
phone_numbers: null
|
|
16
|
+
)
|
|
17
|
+
```
|
|
18
|
+
|
|
@@ -1,18 +1,15 @@
|
|
|
1
|
-
# Bandwidth::
|
|
1
|
+
# Bandwidth::CompletedLookupStatusEnum
|
|
2
2
|
|
|
3
3
|
## Properties
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **tns** | **Array<String>** | | |
|
|
8
7
|
|
|
9
8
|
## Example
|
|
10
9
|
|
|
11
10
|
```ruby
|
|
12
11
|
require 'bandwidth-sdk'
|
|
13
12
|
|
|
14
|
-
instance = Bandwidth::
|
|
15
|
-
tns: null
|
|
16
|
-
)
|
|
13
|
+
instance = Bandwidth::CompletedLookupStatusEnum.new()
|
|
17
14
|
```
|
|
18
15
|
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::CreateAsyncBulkLookupResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **links** | [**Array<LinkSchema>**](LinkSchema.md) | Links for pagination (if applicable) | [optional] |
|
|
8
|
+
| **data** | [**CreateAsyncBulkLookupResponseData**](CreateAsyncBulkLookupResponseData.md) | | [optional] |
|
|
9
|
+
| **errors** | [**Array<LookupErrorSchema>**](LookupErrorSchema.md) | | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::CreateAsyncBulkLookupResponse.new(
|
|
17
|
+
links: null,
|
|
18
|
+
data: null,
|
|
19
|
+
errors: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
# Bandwidth::
|
|
1
|
+
# Bandwidth::CreateAsyncBulkLookupResponseData
|
|
2
2
|
|
|
3
3
|
## Properties
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **request_id** | **String** | The phone number lookup request ID from Bandwidth. | [optional] |
|
|
8
|
-
| **status** | [**
|
|
8
|
+
| **status** | [**InProgressLookupStatusEnum**](InProgressLookupStatusEnum.md) | | [optional] |
|
|
9
9
|
|
|
10
10
|
## Example
|
|
11
11
|
|
|
12
12
|
```ruby
|
|
13
13
|
require 'bandwidth-sdk'
|
|
14
14
|
|
|
15
|
-
instance = Bandwidth::
|
|
16
|
-
request_id:
|
|
15
|
+
instance = Bandwidth::CreateAsyncBulkLookupResponseData.new(
|
|
16
|
+
request_id: 004223a0-8b17-41b1-bf81-20732adf5590,
|
|
17
17
|
status: null
|
|
18
18
|
)
|
|
19
19
|
```
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::CreateSyncLookupResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **links** | [**Array<LinkSchema>**](LinkSchema.md) | | [optional] |
|
|
8
|
+
| **data** | [**CreateSyncLookupResponseData**](CreateSyncLookupResponseData.md) | | [optional] |
|
|
9
|
+
| **errors** | [**Array<LookupErrorSchema>**](LookupErrorSchema.md) | | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::CreateSyncLookupResponse.new(
|
|
17
|
+
links: [],
|
|
18
|
+
data: null,
|
|
19
|
+
errors: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::CreateSyncLookupResponseData
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **request_id** | **String** | The phone number lookup request ID from Bandwidth. | [optional] |
|
|
8
|
+
| **status** | [**CompletedLookupStatusEnum**](CompletedLookupStatusEnum.md) | | [optional] |
|
|
9
|
+
| **results** | [**Array<LookupResult>**](LookupResult.md) | The carrier information results for the specified telephone numbers. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::CreateSyncLookupResponseData.new(
|
|
17
|
+
request_id: 004223a0-8b17-41b1-bf81-20732adf5590,
|
|
18
|
+
status: null,
|
|
19
|
+
results: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Bandwidth::DeactivationEventEnum
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
|
|
10
|
+
```ruby
|
|
11
|
+
require 'bandwidth-sdk'
|
|
12
|
+
|
|
13
|
+
instance = Bandwidth::DeactivationEventEnum.new()
|
|
14
|
+
```
|
|
15
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::GetAsyncBulkLookupResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **links** | [**Array<LinkSchema>**](LinkSchema.md) | | [optional] |
|
|
8
|
+
| **data** | [**GetAsyncBulkLookupResponseData**](GetAsyncBulkLookupResponseData.md) | | [optional] |
|
|
9
|
+
| **errors** | [**Array<LookupErrorSchema>**](LookupErrorSchema.md) | | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::GetAsyncBulkLookupResponse.new(
|
|
17
|
+
links: [],
|
|
18
|
+
data: null,
|
|
19
|
+
errors: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::GetAsyncBulkLookupResponseData
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **request_id** | **String** | The phone number lookup request ID from Bandwidth. | [optional] |
|
|
8
|
+
| **status** | [**InProgressLookupStatusEnum**](InProgressLookupStatusEnum.md) | | [optional] |
|
|
9
|
+
| **results** | [**Array<LookupResult>**](LookupResult.md) | The carrier information results for the specified telephone number. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::GetAsyncBulkLookupResponseData.new(
|
|
17
|
+
request_id: 004223a0-8b17-41b1-bf81-20732adf5590,
|
|
18
|
+
status: null,
|
|
19
|
+
results: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Bandwidth::InProgressLookupStatusEnum
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
|
|
10
|
+
```ruby
|
|
11
|
+
require 'bandwidth-sdk'
|
|
12
|
+
|
|
13
|
+
instance = Bandwidth::InProgressLookupStatusEnum.new()
|
|
14
|
+
```
|
|
15
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Bandwidth::LatestMessageDeliveryStatusEnum
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
|
|
8
|
+
## Example
|
|
9
|
+
|
|
10
|
+
```ruby
|
|
11
|
+
require 'bandwidth-sdk'
|
|
12
|
+
|
|
13
|
+
instance = Bandwidth::LatestMessageDeliveryStatusEnum.new()
|
|
14
|
+
```
|
|
15
|
+
|
data/docs/LinkSchema.md
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::LinkSchema
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **href** | **String** | URI of the link. | [optional] |
|
|
8
|
+
| **rel** | **String** | Specifies the relationship between this link and the resource. | [optional] |
|
|
9
|
+
| **method** | **String** | HTTP method to be used. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::LinkSchema.new(
|
|
17
|
+
href: /relative/uri,
|
|
18
|
+
rel: aRelatedResource,
|
|
19
|
+
method: GET
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::LookupErrorResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **links** | [**Array<LinkSchema>**](LinkSchema.md) | | [optional] |
|
|
8
|
+
| **data** | **Object** | The phone number lookup response data | [optional] |
|
|
9
|
+
| **errors** | [**Array<LookupErrorSchema>**](LookupErrorSchema.md) | | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::LookupErrorResponse.new(
|
|
17
|
+
links: [],
|
|
18
|
+
data: null,
|
|
19
|
+
errors: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Bandwidth::LookupErrorSchema
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Validation error code | [optional] |
|
|
8
|
+
| **description** | **String** | Description of validation error | [optional] |
|
|
9
|
+
| **type** | **String** | Type of validation error | [optional] |
|
|
10
|
+
| **meta** | [**LookupErrorSchemaMeta**](LookupErrorSchemaMeta.md) | | [optional] |
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'bandwidth-sdk'
|
|
16
|
+
|
|
17
|
+
instance = Bandwidth::LookupErrorSchema.new(
|
|
18
|
+
code: NO-MATCH,
|
|
19
|
+
description: Example error description,
|
|
20
|
+
type: NumberInventory,
|
|
21
|
+
meta: null
|
|
22
|
+
)
|
|
23
|
+
```
|
|
24
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Bandwidth::LookupErrorSchemaMeta
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **phone_numbers** | **Array<String>** | | [optional] |
|
|
8
|
+
| **message** | **String** | Message describing the error | [optional] |
|
|
9
|
+
| **code** | **Integer** | Error code associated with the message | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'bandwidth-sdk'
|
|
15
|
+
|
|
16
|
+
instance = Bandwidth::LookupErrorSchemaMeta.new(
|
|
17
|
+
phone_numbers: ["+13992077164","+19196104424"],
|
|
18
|
+
message: Invalid TNs,
|
|
19
|
+
code: 1001
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
data/docs/LookupResult.md
CHANGED
|
@@ -4,15 +4,17 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **
|
|
8
|
-
| **
|
|
9
|
-
| **
|
|
10
|
-
| **
|
|
11
|
-
| **
|
|
12
|
-
| **
|
|
13
|
-
| **
|
|
14
|
-
| **
|
|
15
|
-
| **
|
|
7
|
+
| **phone_number** | **String** | The telephone number in E.164 format. | [optional] |
|
|
8
|
+
| **line_type** | [**LineTypeEnum**](LineTypeEnum.md) | | [optional] |
|
|
9
|
+
| **messaging_provider** | **String** | The messaging service provider of the telephone number. | [optional] |
|
|
10
|
+
| **voice_provider** | **String** | The voice service provider of the telephone number. | [optional] |
|
|
11
|
+
| **country_code_a3** | **String** | The country code of the telephone number in ISO 3166-1 alpha-3 format. | [optional] |
|
|
12
|
+
| **deactivation_reporter** | **String** | [DNI-Only](#section/DNI-Only). The carrier that reported a deactivation event for this phone number. | [optional] |
|
|
13
|
+
| **deactivation_date** | **String** | [DNI-Only](#section/DNI-Only). The datetime the carrier reported a deactivation event. | [optional] |
|
|
14
|
+
| **deactivation_event** | [**DeactivationEventEnum**](DeactivationEventEnum.md) | | [optional] |
|
|
15
|
+
| **latest_message_delivery_status** | [**LatestMessageDeliveryStatusEnum**](LatestMessageDeliveryStatusEnum.md) | | [optional] |
|
|
16
|
+
| **initial_message_delivery_status_date** | **Date** | [DNI-Only](#section/DNI-Only). The date the phone number entered the status described in `latestMessageDeliveryStatus`. Think of this as the \"start time\" for that status. Value resets every time the `latestMessageDeliveryStatus` changes. | [optional] |
|
|
17
|
+
| **latest_message_delivery_status_date** | **Date** | [DNI-Only](#section/DNI-Only). The date bandwidth last received delivery status information for this phone number. Use this field to understand how up-to-date the `latestMessageDeliveryStatus` is. Value resets every time the `latestMessageDeliveryStatus` changes. | [optional] |
|
|
16
18
|
|
|
17
19
|
## Example
|
|
18
20
|
|
|
@@ -20,15 +22,17 @@
|
|
|
20
22
|
require 'bandwidth-sdk'
|
|
21
23
|
|
|
22
24
|
instance = Bandwidth::LookupResult.new(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
25
|
+
phone_number: +10072904498,
|
|
26
|
+
line_type: null,
|
|
27
|
+
messaging_provider: Verizon Wireless,
|
|
28
|
+
voice_provider: Verizon Wireless,
|
|
29
|
+
country_code_a3: USA,
|
|
30
|
+
deactivation_reporter: null,
|
|
31
|
+
deactivation_date: 2025-06-20 18:35,
|
|
32
|
+
deactivation_event: null,
|
|
33
|
+
latest_message_delivery_status: null,
|
|
34
|
+
initial_message_delivery_status_date: Thu Jun 19 20:00:00 EDT 2025,
|
|
35
|
+
latest_message_delivery_status_date: Fri Jun 20 20:00:00 EDT 2025
|
|
32
36
|
)
|
|
33
37
|
```
|
|
34
38
|
|
|
@@ -4,17 +4,18 @@ All URIs are relative to *http://localhost*
|
|
|
4
4
|
|
|
5
5
|
| Method | HTTP request | Description |
|
|
6
6
|
| ------ | ------------ | ----------- |
|
|
7
|
-
| [**
|
|
8
|
-
| [**
|
|
7
|
+
| [**create_async_bulk_lookup**](PhoneNumberLookupApi.md#create_async_bulk_lookup) | **POST** /accounts/{accountId}/phoneNumberLookup/bulk | Create Asynchronous Bulk Number Lookup |
|
|
8
|
+
| [**create_sync_lookup**](PhoneNumberLookupApi.md#create_sync_lookup) | **POST** /accounts/{accountId}/phoneNumberLookup | Create Synchronous Number Lookup |
|
|
9
|
+
| [**get_async_bulk_lookup**](PhoneNumberLookupApi.md#get_async_bulk_lookup) | **GET** /accounts/{accountId}/phoneNumberLookup/bulk/{requestId} | Get Asynchronous Bulk Number Lookup |
|
|
9
10
|
|
|
10
11
|
|
|
11
|
-
##
|
|
12
|
+
## create_async_bulk_lookup
|
|
12
13
|
|
|
13
|
-
> <
|
|
14
|
+
> <CreateAsyncBulkLookupResponse> create_async_bulk_lookup(account_id, async_lookup_request)
|
|
14
15
|
|
|
15
|
-
Create Lookup
|
|
16
|
+
Create Asynchronous Bulk Number Lookup
|
|
16
17
|
|
|
17
|
-
|
|
18
|
+
Creates an asynchronous bulk phone number lookup request. Maximum of 15,000 telephone numbers per request. Use the [Get Asynchronous Bulk Number Lookup](#tag/Phone-Number-Lookup/operation/getAsyncBulkLookup) endpoint to check the status of the request and view the results.
|
|
18
19
|
|
|
19
20
|
### Examples
|
|
20
21
|
|
|
@@ -29,33 +30,33 @@ Bandwidth.configure do |config|
|
|
|
29
30
|
end
|
|
30
31
|
|
|
31
32
|
api_instance = Bandwidth::PhoneNumberLookupApi.new
|
|
32
|
-
account_id = '9900000' # String |
|
|
33
|
-
|
|
33
|
+
account_id = '9900000' # String |
|
|
34
|
+
async_lookup_request = Bandwidth::AsyncLookupRequest.new({phone_numbers: ['phone_numbers_example']}) # AsyncLookupRequest | Asynchronous bulk phone number lookup request.
|
|
34
35
|
|
|
35
36
|
begin
|
|
36
|
-
# Create Lookup
|
|
37
|
-
result = api_instance.
|
|
37
|
+
# Create Asynchronous Bulk Number Lookup
|
|
38
|
+
result = api_instance.create_async_bulk_lookup(account_id, async_lookup_request)
|
|
38
39
|
p result
|
|
39
40
|
rescue Bandwidth::ApiError => e
|
|
40
|
-
puts "Error when calling PhoneNumberLookupApi->
|
|
41
|
+
puts "Error when calling PhoneNumberLookupApi->create_async_bulk_lookup: #{e}"
|
|
41
42
|
end
|
|
42
43
|
```
|
|
43
44
|
|
|
44
|
-
#### Using the
|
|
45
|
+
#### Using the create_async_bulk_lookup_with_http_info variant
|
|
45
46
|
|
|
46
47
|
This returns an Array which contains the response data, status code and headers.
|
|
47
48
|
|
|
48
|
-
> <Array(<
|
|
49
|
+
> <Array(<CreateAsyncBulkLookupResponse>, Integer, Hash)> create_async_bulk_lookup_with_http_info(account_id, async_lookup_request)
|
|
49
50
|
|
|
50
51
|
```ruby
|
|
51
52
|
begin
|
|
52
|
-
# Create Lookup
|
|
53
|
-
data, status_code, headers = api_instance.
|
|
53
|
+
# Create Asynchronous Bulk Number Lookup
|
|
54
|
+
data, status_code, headers = api_instance.create_async_bulk_lookup_with_http_info(account_id, async_lookup_request)
|
|
54
55
|
p status_code # => 2xx
|
|
55
56
|
p headers # => { ... }
|
|
56
|
-
p data # => <
|
|
57
|
+
p data # => <CreateAsyncBulkLookupResponse>
|
|
57
58
|
rescue Bandwidth::ApiError => e
|
|
58
|
-
puts "Error when calling PhoneNumberLookupApi->
|
|
59
|
+
puts "Error when calling PhoneNumberLookupApi->create_async_bulk_lookup_with_http_info: #{e}"
|
|
59
60
|
end
|
|
60
61
|
```
|
|
61
62
|
|
|
@@ -63,12 +64,12 @@ end
|
|
|
63
64
|
|
|
64
65
|
| Name | Type | Description | Notes |
|
|
65
66
|
| ---- | ---- | ----------- | ----- |
|
|
66
|
-
| **account_id** | **String** |
|
|
67
|
-
| **
|
|
67
|
+
| **account_id** | **String** | | |
|
|
68
|
+
| **async_lookup_request** | [**AsyncLookupRequest**](AsyncLookupRequest.md) | Asynchronous bulk phone number lookup request. | |
|
|
68
69
|
|
|
69
70
|
### Return type
|
|
70
71
|
|
|
71
|
-
[**
|
|
72
|
+
[**CreateAsyncBulkLookupResponse**](CreateAsyncBulkLookupResponse.md)
|
|
72
73
|
|
|
73
74
|
### Authorization
|
|
74
75
|
|
|
@@ -80,13 +81,13 @@ end
|
|
|
80
81
|
- **Accept**: application/json
|
|
81
82
|
|
|
82
83
|
|
|
83
|
-
##
|
|
84
|
+
## create_sync_lookup
|
|
84
85
|
|
|
85
|
-
> <
|
|
86
|
+
> <CreateSyncLookupResponse> create_sync_lookup(account_id, sync_lookup_request)
|
|
86
87
|
|
|
87
|
-
|
|
88
|
+
Create Synchronous Number Lookup
|
|
88
89
|
|
|
89
|
-
|
|
90
|
+
Creates a synchronous phone number lookup request. Maximum of 100 telephone numbers per request.
|
|
90
91
|
|
|
91
92
|
### Examples
|
|
92
93
|
|
|
@@ -101,33 +102,33 @@ Bandwidth.configure do |config|
|
|
|
101
102
|
end
|
|
102
103
|
|
|
103
104
|
api_instance = Bandwidth::PhoneNumberLookupApi.new
|
|
104
|
-
account_id = '9900000' # String |
|
|
105
|
-
|
|
105
|
+
account_id = '9900000' # String |
|
|
106
|
+
sync_lookup_request = Bandwidth::SyncLookupRequest.new({phone_numbers: ['phone_numbers_example']}) # SyncLookupRequest | Synchronous phone number lookup request.
|
|
106
107
|
|
|
107
108
|
begin
|
|
108
|
-
#
|
|
109
|
-
result = api_instance.
|
|
109
|
+
# Create Synchronous Number Lookup
|
|
110
|
+
result = api_instance.create_sync_lookup(account_id, sync_lookup_request)
|
|
110
111
|
p result
|
|
111
112
|
rescue Bandwidth::ApiError => e
|
|
112
|
-
puts "Error when calling PhoneNumberLookupApi->
|
|
113
|
+
puts "Error when calling PhoneNumberLookupApi->create_sync_lookup: #{e}"
|
|
113
114
|
end
|
|
114
115
|
```
|
|
115
116
|
|
|
116
|
-
#### Using the
|
|
117
|
+
#### Using the create_sync_lookup_with_http_info variant
|
|
117
118
|
|
|
118
119
|
This returns an Array which contains the response data, status code and headers.
|
|
119
120
|
|
|
120
|
-
> <Array(<
|
|
121
|
+
> <Array(<CreateSyncLookupResponse>, Integer, Hash)> create_sync_lookup_with_http_info(account_id, sync_lookup_request)
|
|
121
122
|
|
|
122
123
|
```ruby
|
|
123
124
|
begin
|
|
124
|
-
#
|
|
125
|
-
data, status_code, headers = api_instance.
|
|
125
|
+
# Create Synchronous Number Lookup
|
|
126
|
+
data, status_code, headers = api_instance.create_sync_lookup_with_http_info(account_id, sync_lookup_request)
|
|
126
127
|
p status_code # => 2xx
|
|
127
128
|
p headers # => { ... }
|
|
128
|
-
p data # => <
|
|
129
|
+
p data # => <CreateSyncLookupResponse>
|
|
129
130
|
rescue Bandwidth::ApiError => e
|
|
130
|
-
puts "Error when calling PhoneNumberLookupApi->
|
|
131
|
+
puts "Error when calling PhoneNumberLookupApi->create_sync_lookup_with_http_info: #{e}"
|
|
131
132
|
end
|
|
132
133
|
```
|
|
133
134
|
|
|
@@ -135,12 +136,84 @@ end
|
|
|
135
136
|
|
|
136
137
|
| Name | Type | Description | Notes |
|
|
137
138
|
| ---- | ---- | ----------- | ----- |
|
|
138
|
-
| **account_id** | **String** |
|
|
139
|
-
| **
|
|
139
|
+
| **account_id** | **String** | | |
|
|
140
|
+
| **sync_lookup_request** | [**SyncLookupRequest**](SyncLookupRequest.md) | Synchronous phone number lookup request. | |
|
|
140
141
|
|
|
141
142
|
### Return type
|
|
142
143
|
|
|
143
|
-
[**
|
|
144
|
+
[**CreateSyncLookupResponse**](CreateSyncLookupResponse.md)
|
|
145
|
+
|
|
146
|
+
### Authorization
|
|
147
|
+
|
|
148
|
+
[Basic](../README.md#Basic)
|
|
149
|
+
|
|
150
|
+
### HTTP request headers
|
|
151
|
+
|
|
152
|
+
- **Content-Type**: application/json
|
|
153
|
+
- **Accept**: application/json
|
|
154
|
+
|
|
155
|
+
|
|
156
|
+
## get_async_bulk_lookup
|
|
157
|
+
|
|
158
|
+
> <GetAsyncBulkLookupResponse> get_async_bulk_lookup(account_id, request_id)
|
|
159
|
+
|
|
160
|
+
Get Asynchronous Bulk Number Lookup
|
|
161
|
+
|
|
162
|
+
Get an existing [Asynchronous Bulk Number Lookup](#tag/Phone-Number-Lookup/operation/createAsyncBulkLookup). Use this endpoint to check the status of the request and view the results.
|
|
163
|
+
|
|
164
|
+
### Examples
|
|
165
|
+
|
|
166
|
+
```ruby
|
|
167
|
+
require 'time'
|
|
168
|
+
require 'bandwidth-sdk'
|
|
169
|
+
# setup authorization
|
|
170
|
+
Bandwidth.configure do |config|
|
|
171
|
+
# Configure HTTP basic authorization: Basic
|
|
172
|
+
config.username = 'YOUR USERNAME'
|
|
173
|
+
config.password = 'YOUR PASSWORD'
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
api_instance = Bandwidth::PhoneNumberLookupApi.new
|
|
177
|
+
account_id = '9900000' # String |
|
|
178
|
+
request_id = '004223a0-8b17-41b1-bf81-20732adf5590' # String |
|
|
179
|
+
|
|
180
|
+
begin
|
|
181
|
+
# Get Asynchronous Bulk Number Lookup
|
|
182
|
+
result = api_instance.get_async_bulk_lookup(account_id, request_id)
|
|
183
|
+
p result
|
|
184
|
+
rescue Bandwidth::ApiError => e
|
|
185
|
+
puts "Error when calling PhoneNumberLookupApi->get_async_bulk_lookup: #{e}"
|
|
186
|
+
end
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
#### Using the get_async_bulk_lookup_with_http_info variant
|
|
190
|
+
|
|
191
|
+
This returns an Array which contains the response data, status code and headers.
|
|
192
|
+
|
|
193
|
+
> <Array(<GetAsyncBulkLookupResponse>, Integer, Hash)> get_async_bulk_lookup_with_http_info(account_id, request_id)
|
|
194
|
+
|
|
195
|
+
```ruby
|
|
196
|
+
begin
|
|
197
|
+
# Get Asynchronous Bulk Number Lookup
|
|
198
|
+
data, status_code, headers = api_instance.get_async_bulk_lookup_with_http_info(account_id, request_id)
|
|
199
|
+
p status_code # => 2xx
|
|
200
|
+
p headers # => { ... }
|
|
201
|
+
p data # => <GetAsyncBulkLookupResponse>
|
|
202
|
+
rescue Bandwidth::ApiError => e
|
|
203
|
+
puts "Error when calling PhoneNumberLookupApi->get_async_bulk_lookup_with_http_info: #{e}"
|
|
204
|
+
end
|
|
205
|
+
```
|
|
206
|
+
|
|
207
|
+
### Parameters
|
|
208
|
+
|
|
209
|
+
| Name | Type | Description | Notes |
|
|
210
|
+
| ---- | ---- | ----------- | ----- |
|
|
211
|
+
| **account_id** | **String** | | |
|
|
212
|
+
| **request_id** | **String** | | |
|
|
213
|
+
|
|
214
|
+
### Return type
|
|
215
|
+
|
|
216
|
+
[**GetAsyncBulkLookupResponse**](GetAsyncBulkLookupResponse.md)
|
|
144
217
|
|
|
145
218
|
### Authorization
|
|
146
219
|
|
data/docs/RbmActionBase.md
CHANGED