Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Searches for phone numbers that can be ordered. For US numbers, provide
at least one of the following search filters: AreaCode
, City
,
State
, or TollFreePrefix
. If you provide City
, you must also
provide State
. Numbers outside the US only support the
PhoneNumberType
filter, which you must use.
Synopsis
- data SearchAvailablePhoneNumbers = SearchAvailablePhoneNumbers' {}
- newSearchAvailablePhoneNumbers :: SearchAvailablePhoneNumbers
- searchAvailablePhoneNumbers_phoneNumberType :: Lens' SearchAvailablePhoneNumbers (Maybe PhoneNumberType)
- searchAvailablePhoneNumbers_state :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_tollFreePrefix :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_country :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_nextToken :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_city :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_areaCode :: Lens' SearchAvailablePhoneNumbers (Maybe Text)
- searchAvailablePhoneNumbers_maxResults :: Lens' SearchAvailablePhoneNumbers (Maybe Natural)
- data SearchAvailablePhoneNumbersResponse = SearchAvailablePhoneNumbersResponse' {
- e164PhoneNumbers :: Maybe [Sensitive Text]
- nextToken :: Maybe Text
- httpStatus :: Int
- newSearchAvailablePhoneNumbersResponse :: Int -> SearchAvailablePhoneNumbersResponse
- searchAvailablePhoneNumbersResponse_e164PhoneNumbers :: Lens' SearchAvailablePhoneNumbersResponse (Maybe [Text])
- searchAvailablePhoneNumbersResponse_nextToken :: Lens' SearchAvailablePhoneNumbersResponse (Maybe Text)
- searchAvailablePhoneNumbersResponse_httpStatus :: Lens' SearchAvailablePhoneNumbersResponse Int
Creating a Request
data SearchAvailablePhoneNumbers Source #
See: newSearchAvailablePhoneNumbers
smart constructor.
SearchAvailablePhoneNumbers' | |
|
Instances
newSearchAvailablePhoneNumbers :: SearchAvailablePhoneNumbers Source #
Create a value of SearchAvailablePhoneNumbers
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:phoneNumberType:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_phoneNumberType
- The phone number type used to filter results. Required for non-US
numbers.
$sel:state:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_state
- The state used to filter results. Required only if you provide City
.
Only applies to the US.
$sel:tollFreePrefix:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_tollFreePrefix
- The toll-free prefix that you use to filter results. Only applies to the
US.
$sel:country:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_country
- The country used to filter results. Defaults to the US Format: ISO
3166-1 alpha-2.
$sel:nextToken:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_nextToken
- The token used to retrieve the next page of results.
$sel:city:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_city
- The city used to filter results. Only applies to the US.
$sel:areaCode:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_areaCode
- The area code used to filter results. Only applies to the US.
$sel:maxResults:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbers_maxResults
- The maximum number of results to return in a single call.
Request Lenses
searchAvailablePhoneNumbers_phoneNumberType :: Lens' SearchAvailablePhoneNumbers (Maybe PhoneNumberType) Source #
The phone number type used to filter results. Required for non-US numbers.
searchAvailablePhoneNumbers_state :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The state used to filter results. Required only if you provide City
.
Only applies to the US.
searchAvailablePhoneNumbers_tollFreePrefix :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The toll-free prefix that you use to filter results. Only applies to the US.
searchAvailablePhoneNumbers_country :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The country used to filter results. Defaults to the US Format: ISO 3166-1 alpha-2.
searchAvailablePhoneNumbers_nextToken :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The token used to retrieve the next page of results.
searchAvailablePhoneNumbers_city :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The city used to filter results. Only applies to the US.
searchAvailablePhoneNumbers_areaCode :: Lens' SearchAvailablePhoneNumbers (Maybe Text) Source #
The area code used to filter results. Only applies to the US.
searchAvailablePhoneNumbers_maxResults :: Lens' SearchAvailablePhoneNumbers (Maybe Natural) Source #
The maximum number of results to return in a single call.
Destructuring the Response
data SearchAvailablePhoneNumbersResponse Source #
See: newSearchAvailablePhoneNumbersResponse
smart constructor.
SearchAvailablePhoneNumbersResponse' | |
|
Instances
newSearchAvailablePhoneNumbersResponse Source #
Create a value of SearchAvailablePhoneNumbersResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:e164PhoneNumbers:SearchAvailablePhoneNumbersResponse'
, searchAvailablePhoneNumbersResponse_e164PhoneNumbers
- List of phone numbers, in E.164 format.
$sel:nextToken:SearchAvailablePhoneNumbers'
, searchAvailablePhoneNumbersResponse_nextToken
- The token used to retrieve the next page of search results.
$sel:httpStatus:SearchAvailablePhoneNumbersResponse'
, searchAvailablePhoneNumbersResponse_httpStatus
- The response's http status code.
Response Lenses
searchAvailablePhoneNumbersResponse_e164PhoneNumbers :: Lens' SearchAvailablePhoneNumbersResponse (Maybe [Text]) Source #
List of phone numbers, in E.164 format.
searchAvailablePhoneNumbersResponse_nextToken :: Lens' SearchAvailablePhoneNumbersResponse (Maybe Text) Source #
The token used to retrieve the next page of search results.
searchAvailablePhoneNumbersResponse_httpStatus :: Lens' SearchAvailablePhoneNumbersResponse Int Source #
The response's http status code.