From 73b66d65bd3eca9741bc467c34b55dc738bf3fcd Mon Sep 17 00:00:00 2001 From: pavelprystinka <30868871+pavelprystinka@users.noreply.github.com> Date: Thu, 4 Mar 2021 10:52:22 -0800 Subject: [PATCH] [Communication] - PhoneNumbers - Update to GA swagger (#18876) * Update to GA swagger * Remove old samples * Update swagger plus some test update * Update swagger, test records, sanitizer * update test records * remove nullable and update readme * rename sample class * Update test records * Fix readme links * Update changelog * Move generated client code to written * Address PR feedback * Update genereted code * make generated clinet internal * Moce ctor and updated public api * Updated public api --- .../CHANGELOG.md | 8 +- .../README.md | 141 +- ...mmunication.PhoneNumbers.netstandard2.0.cs | 576 +--- .../samples/README.md | 6 +- ...Sample2_PhoneNumberAdministrationClient.md | 200 -- ...e2_PhoneNumberAdministrationClientAsync.md | 176 -- .../samples/Sample_PhoneNumbersClient.md | 88 + .../samples/Sample_PhoneNumbersClientAsync.md | 69 + .../Azure.Communication.PhoneNumbers.csproj | 1 - .../src/ClientDiagnostics.cs | 61 + .../Generated/InternalPhoneNumbersClient.cs | 466 +++ .../InternalPhoneNumbersRestClient.cs | 722 +++++ .../AcquiredPhoneNumber.Serialization.cs | 66 +- .../Generated/Models/AcquiredPhoneNumber.cs | 85 +- .../AcquiredPhoneNumbers.Serialization.cs | 9 +- .../Generated/Models/AcquiredPhoneNumbers.cs | 20 +- .../src/Generated/Models/ActivationState.cs | 60 - .../Models/AreaCodes.Serialization.cs | 62 - .../src/Generated/Models/AreaCodes.cs | 41 - .../src/Generated/Models/AssignmentStatus.cs | 63 - .../src/Generated/Models/BillingFrequency.cs | 48 + .../Models/CapabilitiesUpdateStatus.cs | 57 - .../Models/CarrierDetails.Serialization.cs | 35 - .../src/Generated/Models/CarrierDetails.cs | 32 - .../CommunicationError.Serialization.cs | 69 + .../Generated/Models/CommunicationError.cs | 63 + ...mmunicationErrorResponse.Serialization.cs} | 12 +- .../Models/CommunicationErrorResponse.cs | 31 + .../CreateReservationOptions.Serialization.cs | 49 - .../Models/CreateReservationOptions.cs | 63 - .../Models/CreateReservationResponse.cs | 28 - .../src/Generated/Models/CurrencyType.cs | 48 - .../Models/ErrorBody.Serialization.cs | 35 - .../src/Generated/Models/ErrorBody.cs | 32 - .../Models/ErrorResponse.Serialization.cs | 34 - .../src/Generated/Models/ErrorResponse.cs | 28 - .../Models/LocationOptions.Serialization.cs | 78 - .../src/Generated/Models/LocationOptions.cs | 40 - .../LocationOptionsDetails.Serialization.cs | 78 - .../Models/LocationOptionsDetails.cs | 40 - .../LocationOptionsQueries.Serialization.cs | 31 - .../Models/LocationOptionsQueries.cs | 25 - .../Generated/Models/LocationOptionsQuery.cs | 23 - .../LocationOptionsResponse.Serialization.cs | 34 - .../Models/LocationOptionsResponse.cs | 28 - .../src/Generated/Models/LocationType.cs | 54 - .../NumberConfiguration.Serialization.cs | 25 - .../Generated/Models/NumberConfiguration.cs | 39 - .../Models/NumberConfigurationPhoneNumber.cs | 31 - ...mberConfigurationResponse.Serialization.cs | 29 - .../Models/NumberConfigurationResponse.cs | 31 - .../NumberUpdateCapabilities.Serialization.cs | 82 - .../Models/NumberUpdateCapabilities.cs | 37 - .../Models/PhoneNumberAssignmentType.cs | 51 + .../PhoneNumberCapabilities.Serialization.cs | 45 + .../Models/PhoneNumberCapabilities.cs | 27 + ...umberCapabilitiesRequest.Serialization.cs} | 14 +- .../Models/PhoneNumberCapabilitiesRequest.cs | 23 + .../Generated/Models/PhoneNumberCapability.cs | 117 - .../Models/PhoneNumberCapabilityType.cs | 57 + .../Models/PhoneNumberCost.Serialization.cs | 41 + .../src/Generated/Models/PhoneNumberCost.cs | 37 + .../PhoneNumberCountries.Serialization.cs | 46 - .../Generated/Models/PhoneNumberCountries.cs | 36 - .../PhoneNumberCountry.Serialization.cs | 35 - .../Generated/Models/PhoneNumberCountry.cs | 39 - .../PhoneNumberEntities.Serialization.cs | 46 - .../Generated/Models/PhoneNumberEntities.cs | 36 - .../Models/PhoneNumberEntity.Serialization.cs | 86 - .../src/Generated/Models/PhoneNumberEntity.cs | 54 - .../PhoneNumberOperation.Serialization.cs | 76 + .../Generated/Models/PhoneNumberOperation.cs | 68 + .../Models/PhoneNumberOperationStatus.cs | 57 + .../Models/PhoneNumberOperationType.cs | 57 + ...oneNumberPurchaseRequest.Serialization.cs} | 9 +- .../Models/PhoneNumberPurchaseRequest.cs | 21 + .../PhoneNumberRelease.Serialization.cs | 75 - .../Generated/Models/PhoneNumberRelease.cs | 49 - ...PhoneNumberReleaseDetails.Serialization.cs | 45 - .../Models/PhoneNumberReleaseDetails.cs | 32 - ...honeNumberReleaseResponse.Serialization.cs | 29 - .../Models/PhoneNumberReleaseResponse.cs | 31 - .../Models/PhoneNumberReleaseStatus.cs | 57 - .../PhoneNumberReservation.Serialization.cs | 152 - .../Models/PhoneNumberReservation.cs | 76 - .../PhoneNumberSearchRequest.Serialization.cs | 37 + .../Models/PhoneNumberSearchRequest.cs | 43 + .../PhoneNumberSearchResult.Serialization.cs | 72 + .../Models/PhoneNumberSearchResult.cs | 86 + .../src/Generated/Models/PhoneNumberType.cs | 16 +- .../Models/PhonePlan.Serialization.cs | 85 - .../src/Generated/Models/PhonePlan.cs | 70 - .../Models/PhonePlanGroup.Serialization.cs | 74 - .../src/Generated/Models/PhonePlanGroup.cs | 70 - .../Models/PhonePlanGroups.Serialization.cs | 46 - .../src/Generated/Models/PhonePlanGroups.cs | 36 - .../PhonePlansResponse.Serialization.cs | 46 - .../Generated/Models/PhonePlansResponse.cs | 36 - .../Models/PstnConfiguration.Serialization.cs | 48 - .../src/Generated/Models/PstnConfiguration.cs | 42 - .../Models/RateInformation.Serialization.cs | 51 - .../src/Generated/Models/RateInformation.cs | 36 - .../Models/ReleaseRequest.Serialization.cs | 28 - .../src/Generated/Models/ReleaseRequest.cs | 33 - .../src/Generated/Models/ReleaseStatus.cs | 60 - .../src/Generated/Models/ReservationStatus.cs | 84 - ...NumberCapabilitiesRequest.Serialization.cs | 29 - .../Models/UpdateNumberCapabilitiesRequest.cs | 32 - ...umberCapabilitiesResponse.Serialization.cs | 29 - .../UpdateNumberCapabilitiesResponse.cs | 31 - ...umberCapabilitiesResponse.Serialization.cs | 69 - .../UpdatePhoneNumberCapabilitiesResponse.cs | 45 - .../PhoneNumberAdministrationRestClient.cs | 1935 ------------ .../Generated/PhoneNumbersClientOptions.cs | 37 + .../PhoneNumbersGetOperationHeaders.cs | 23 + ...PhoneNumbersPurchasePhoneNumbersHeaders.cs | 27 + .../PhoneNumbersReleasePhoneNumberHeaders.cs | 27 + ...mbersSearchAvailablePhoneNumbersHeaders.cs | 29 + .../PhoneNumbersUpdateCapabilitiesHeaders.cs | 29 + .../PurchasePhoneNumbersOperation.cs | 56 + .../Generated/ReleasePhoneNumberOperation.cs | 56 + .../SearchAvailablePhoneNumbersOperation.cs | 60 + .../UpdatePhoneNumberCapabilitiesOperation.cs | 60 + .../src/Models/AdministrationModelFactory.cs | 228 -- ...onePlanGroups.cs => CommunicationError.cs} | 2 +- .../src/Models/CreateReservationResponse.cs | 15 - ...tions.cs => InternalPhoneNumbersClient.cs} | 4 +- .../src/Models/PhoneNumberCost.cs | 14 + .../src/Models/PhoneNumberCountries.cs | 9 - ...rCapability.cs => PhoneNumberOperation.cs} | 4 +- .../src/Models/PhoneNumberReleaseResponse.cs | 12 - .../src/Models/PhoneNumberReservation.cs | 15 - .../Models/PhoneNumberReservationOperation.cs | 200 -- ...PhoneNumberReservationPurchaseOperation.cs | 183 -- ...ntities.cs => PhoneNumberSearchRequest.cs} | 5 +- .../src/Models/PhoneNumberSearchResult.cs | 15 + .../src/Models/PhoneNumbersModelFactory.cs | 35 + .../src/Models/PhonePlans.cs | 9 - .../src/Models/ReleasePhoneNumberOperation.cs | 194 -- .../src/Models/ReservationStatus.cs | 12 - .../src/PhoneNumberAdministrationClient.cs | 1003 ------ .../PhoneNumberAdministrationClientOptions.cs | 56 - .../src/PhoneNumberSearchOptions.cs | 19 + .../src/PhoneNumbersClient.cs | 419 +++ .../PhoneNumbersClientsGetOperationHeaders.cs | 12 + ...PhoneNumbersPurchasePhoneNumbersHeaders.cs | 12 + .../PhoneNumbersReleasePhoneNumberHeaders.cs | 12 + ...mbersSearchAvailablePhoneNumbersHeaders.cs | 12 + .../PhoneNumbersUpdateCapabilitiesHeaders.cs | 12 + .../src/PurchasePhoneNumbersOperation.cs | 25 + .../src/ReleasePhoneNumberOperation.cs | 25 + .../SearchAvailablePhoneNumbersOperation.cs | 26 + .../UpdatePhoneNumberCapabilitiesOperation.cs | 26 + .../src/autorest.md | 7 +- ...re.Communication.PhoneNumbers.Tests.csproj | 5 +- ...e.cs => PhoneNumbersClientLiveTestBase.cs} | 24 +- ...PhoneNumbersClientRecordedTestSanitizer.cs | 19 + ...s => PhoneNumbersClientTestEnvironment.cs} | 2 +- ...honeNumberAdministrationClientLiveTests.cs | 349 -- .../PhoneNumbersClientLiveTests.cs | 68 + ...reateGeographicalReservation(%en-US%).json | 2039 ------------ ...GeographicalReservation(%en-US%)Async.json | 2039 ------------ .../CreateGeographicalReservation(null).json | 1997 ------------ ...ateGeographicalReservation(null)Async.json | 2039 ------------ .../CreateReservation(%en-US%).json | 494 --- .../CreateReservation(%en-US%)Async.json | 987 ------ .../CreateReservation(null).json | 455 --- .../CreateReservation(null)Async.json | 455 --- .../CreateReservationErrorState(%en-US%).json | 519 --- ...teReservationErrorState(%en-US%)Async.json | 519 --- .../CreateReservationErrorState(null).json | 481 --- ...reateReservationErrorState(null)Async.json | 481 --- ...PhoneNumberClientUsingTokenCredential.json | 38 - ...NumberClientUsingTokenCredentialAsync.json | 38 - .../GetAllPhoneNumbers.json | 40 - .../GetAllPhoneNumbersAsync.json | 40 - .../GetAllReservations.json | 509 --- .../GetAllReservationsAsync.json | 523 --- .../GetAllSupportedCountries.json | 45 - .../GetAllSupportedCountriesAsync.json | 45 - .../GetAllSupportedCountriesEnUsLocale.json | 45 - ...tAllSupportedCountriesEnUsLocaleAsync.json | 45 - .../GetAreaCodesForPlan(%en-US%).json | 1716 ---------- .../GetAreaCodesForPlan(%en-US%)Async.json | 1716 ---------- .../GetAreaCodesForPlan(null).json | 1716 ---------- .../GetAreaCodesForPlan(null)Async.json | 1716 ---------- .../GetPhonePlans(%en-US%).json | 110 - .../GetPhonePlans(%en-US%)Async.json | 110 - .../GetPhonePlans(null).json | 110 - .../GetPhonePlans(null)Async.json | 110 - .../GetPlanGroups(%en-US%,False).json | 53 - .../GetPlanGroups(%en-US%,False)Async.json | 53 - .../GetPlanGroups(%en-US%,True).json | 63 - .../GetPlanGroups(%en-US%,True)Async.json | 63 - .../GetPlanGroups(%en-US%,null).json | 53 - .../GetPlanGroups(%en-US%,null)Async.json | 53 - .../GetPlanGroups(null,null).json | 53 - .../GetPlanGroups(null,null)Async.json | 53 - .../CreateSearchErrorState(%en-US%).json | 60 + .../CreateSearchErrorState(%en-US%)Async.json | 60 + .../CreateSearchErrorState(null).json | 60 + .../CreateSearchErrorState(null)Async.json | 60 + .../ListPhoneNumbersAsync.json | 125 + .../ListPhoneNumbersAsyncAsync.json | 125 + .../CreatePhoneNumberWithTokenCredential.json | 38 - ...tePhoneNumberWithTokenCredentialAsync.json | 38 - .../GeographicalAreaCodes.json | 1711 ---------- .../GeographicalAreaCodesAsyncAsync.json | 1711 ---------- .../GetAllSupportedCountries.json | 44 - .../GetAllSupportedCountriesAsyncAsync.json | 44 - .../GetPhonePlanLocationOptions.json | 1664 ---------- ...GetPhonePlanLocationOptionsAsyncAsync.json | 1664 ---------- .../PurchaseAndRelease.json | 1865 ----------- .../PurchaseAndReleaseAsyncAsync.json | 2793 ----------------- .../TollFreePlanAreaCodes.json | 215 -- .../TollFreePlanAreaCodesAsyncAsync.json | 215 -- .../PurchaseAndRelease.json | 1111 +++++++ .../PurchaseAndReleaseAsyncAsync.json | 1251 ++++++++ ...Sample2_PhoneNumberAdministrationClient.cs | 518 --- .../samples/Sample_PhoneNumbersClient.cs | 205 ++ 220 files changed, 6971 insertions(+), 42902 deletions(-) delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClient.md delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClientAsync.md create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClient.md create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClientAsync.md create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/ClientDiagnostics.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersClient.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersRestClient.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ActivationState.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AssignmentStatus.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/BillingFrequency.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CapabilitiesUpdateStatus.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/{CreateReservationResponse.Serialization.cs => CommunicationErrorResponse.Serialization.cs} (50%) create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CurrencyType.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationType.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberAssignmentType.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/{LocationOptionsQuery.Serialization.cs => PhoneNumberCapabilitiesRequest.Serialization.cs} (53%) create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapability.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilityType.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationStatus.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationType.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/{NumberConfigurationPhoneNumber.Serialization.cs => PhoneNumberPurchaseRequest.Serialization.cs} (61%) create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseStatus.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.Serialization.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseStatus.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReservationStatus.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.Serialization.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumberAdministrationRestClient.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersClientOptions.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersGetOperationHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersPurchasePhoneNumbersHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersReleasePhoneNumberHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersUpdateCapabilitiesHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PurchasePhoneNumbersOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/ReleasePhoneNumberOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/SearchAvailablePhoneNumbersOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/UpdatePhoneNumberCapabilitiesOperation.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/AdministrationModelFactory.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Models/{PhonePlanGroups.cs => CommunicationError.cs} (78%) delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationResponse.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Models/{CreateReservationOptions.cs => InternalPhoneNumbersClient.cs} (66%) create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCost.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCountries.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Models/{PhoneNumberCapability.cs => PhoneNumberOperation.cs} (67%) delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReleaseResponse.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservation.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationOperation.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationPurchaseOperation.cs rename sdk/communication/Azure.Communication.PhoneNumbers/src/Models/{PhoneNumberEntities.cs => PhoneNumberSearchRequest.cs} (71%) create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchResult.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumbersModelFactory.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlans.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReleasePhoneNumberOperation.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReservationStatus.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClient.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClientOptions.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberSearchOptions.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClient.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClientsGetOperationHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersPurchasePhoneNumbersHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersReleasePhoneNumberHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersUpdateCapabilitiesHeaders.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/PurchasePhoneNumbersOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/ReleasePhoneNumberOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/SearchAvailablePhoneNumbersOperation.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/src/UpdatePhoneNumberCapabilitiesOperation.cs rename sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/{PhoneNumberAdministrationClientLiveTestBase.cs => PhoneNumbersClientLiveTestBase.cs} (52%) rename sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/{PhoneNumberAdministrationClientTestEnvironment.cs => PhoneNumbersClientTestEnvironment.cs} (67%) delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumberAdministrationClient/PhoneNumberAdministrationClientLiveTests.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumbersClient/PhoneNumbersClientLiveTests.cs delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredential.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredentialAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbers.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbersAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservations.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservationsAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountries.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocale.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocaleAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null)Async.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null).json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null)Async.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%).json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%)Async.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null).json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null)Async.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsync.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredential.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredentialAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodes.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodesAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountries.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountriesAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptions.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptionsAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndRelease.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndReleaseAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodes.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodesAsyncAsync.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndRelease.json create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndReleaseAsyncAsync.json delete mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample2_PhoneNumberAdministrationClient.cs create mode 100644 sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample_PhoneNumbersClient.cs diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/CHANGELOG.md b/sdk/communication/Azure.Communication.PhoneNumbers/CHANGELOG.md index cd51cde076a9b..4fec01ef8fad7 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/CHANGELOG.md +++ b/sdk/communication/Azure.Communication.PhoneNumbers/CHANGELOG.md @@ -5,10 +5,14 @@ ### Added - Added PhoneNumberAdministrationClient (originally was part of the Azure.Communication.Administration package). - Added support to create PhoneNumberAdministrationClient with AzureKeyCredential. -- Added support to create PhoneNumberAdministrationClient with TokenCredential +- Added support to create PhoneNumberAdministrationClient with TokenCredential. +- Added support for long running operations. ### Fixed -- Issue with paging results not pulling next pages +- Issue with paging results not pulling next pages. + +### Breaking Changes +- PhoneNumberAdministrationClient was replaced with PhoneNumbersClient. [read_me]: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/README.md diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/README.md b/sdk/communication/Azure.Communication.PhoneNumbers/README.md index 473aca01cee11..ffa23a2f9d704 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/README.md +++ b/sdk/communication/Azure.Communication.PhoneNumbers/README.md @@ -1,10 +1,10 @@ -# Azure Communication PhoneNumbers client library for .NET +# Azure Communication Phone Numbers client library for .NET > Server Version: > Phone number client: 2020-07-20-preview1 -Azure Communication PhoneNumbers is managing phone numbers for Azure Communication Services. +Azure Communication Phone Numbers is managing phone numbers for Azure Communication Services. [Source code][source] | [Product documentation][product_docs] | [Samples][source_samples] @@ -12,7 +12,7 @@ Azure Communication PhoneNumbers is managing phone numbers for Azure Communicati ### Install the package -Install the Azure Communication PhoneNumbers client library for .NET with [NuGet][nuget]: +Install the Azure Communication Phone Numbers client library for .NET with [NuGet][nuget]: ```Powershell dotnet add package Azure.Communication.PhoneNumbers --version 1.0.0-beta.3 @@ -42,28 +42,28 @@ All geographic phone plans within the same country are grouped into a phone plan Phone Number clients can be authenticated using connection string acquired from an Azure Communication Resources in the [Azure Portal][azure_portal]. -```C# Snippet:CreatePhoneNumberAdministrationClient +```C# Snippet:CreatePhoneNumbersClient // Get a connection string to our Azure Communication resource. var connectionString = ""; -var client = new PhoneNumberAdministrationClient(connectionString); +var client = new PhoneNumbersClient(connectionString); ``` Phone Number clients also have the option to authenticate with Azure Active Directory Authentication. With this option, `AZURE_CLIENT_SECRET`, `AZURE_CLIENT_ID` and `AZURE_TENANT_ID` environment variables need to be set up for authentication. -```C# Snippet:CreatePhoneNumberWithTokenCredential -var endpoint = ""; +```C# Snippet:CreatePhoneNumbersClientWithTokenCredential +// Get an endpoint to our Azure Communication resource. +var endpoint = new Uri(""); TokenCredential tokenCredential = new DefaultAzureCredential(); -var client = new PhoneNumberAdministrationClient(new Uri(endpoint), tokenCredential); +client = new PhoneNumbersClient(endpoint, tokenCredential); ``` -### Reserving and acquiring numbers +### Phone number types overview +Phone numbers come in two types: Geographic and Toll-Free. Geographic phone plans are phone plans associated with a location, whose phone numbers' area codes are associated with the area code of a geographic location. Toll-Free phone plans are phone plans not associated location. For example, in the US, toll-free numbers can come with area codes such as 800 or 888. -Phone numbers reservation can be performed through the reservation creation API by providing a phone plan id, an area code and quantity of phone numbers. The provided quantity of phone numbers will be reserved for ten minutes. This reservation of phone numbers can either be cancelled or purchased. If the reservation is cancelled, then the phone numbers will become available to others. If the reservation is purchased, then the phone numbers are acquired for the Azure resources. +### Searching, purchasing and releasing phone numbers -### Configuring / Assigning numbers - -Phone numbers can be assigned to a callback URL via the configure number API. As part of the configuration, you will need an acquired phone number, callback URL and application id. +Phone numbers can be searched through the search creation API by providing an area code, quantity of phone numbers, application type, phone number type, and capabilities. The provided quantity of phone numbers will be reserved for ten minutes and can be purchased within this time. If the search is not purchased, the phone numbers will become available to others after ten minutes. If the search is purchased, then the phone numbers are acquired for the Azure resources. ### Thread safety We guarantee that all client instance methods are thread-safe and independent of each other ([guideline](https://azure.github.io/azure-sdk/dotnet_introduction.html#dotnet-service-methods-thread-safety)). This ensures that the recommendation of reusing client instances is always safe, even across threads. @@ -81,117 +81,62 @@ We guarantee that all client instance methods are thread-safe and independent of ## Examples -### Get list of the countries that are supported by the service -```C# -string connectionString = ""; -PhoneNumberAdministrationClient client = new PhoneNumberAdministrationClient(connectionString); -Pageable countries = client.GetAllSupportedCountries(); +## Creating a PhoneNumbersClient -foreach (var country in countries) -{ - Console.WriteLine($"Country code {country.CountryCode}, Country name: {country.LocalizedName}"); -} -``` +To create a new `PhoneNumbersClient` you need a connection string to the Azure Communication Services resource that you can get from the Azure Portal once you have created the resource. -### Get phone plan groups +You can set `connectionString` based on an environment variable, a configuration setting, or any way that works for your application. -Phone plan groups come in two types, Geographic and Toll-Free. - -```C# -var phonePlanGroups = client.GetPhonePlanGroups(countryCode); - -foreach (var group in phonePlanGroups) -{ - Console.WriteLine($"PhonePlanGroupId {group.PhonePlanGroupId}, Name: {group.LocalizedName}, PhoneNumberType: {group.PhoneNumberType}"); -} +```C# Snippet:CreatePhoneNumbersClient +// Get a connection string to our Azure Communication resource. +var connectionString = ""; +var client = new PhoneNumbersClient(connectionString); ``` -### Get phone plans +## Search phone numbers -Unlike Toll-Free phone plans, area codes for Geographic Phone Plans are empty. Area codes are found in the Area Codes API. +Phone numbers need to be searched before they can be purchased. Search is a long running operation that can be started by `StartSearchAvailablePhoneNumbers` function that returns an `SearchAvailablePhoneNumbersOperation` object. `SearchAvailablePhoneNumbersOperation` can be used to update status of the operation and to check for completeness. -```C# -var phonePlans = client.GetPhonePlans(countryCode, planGroupId); +```C# Snippet:SearchPhoneNumbersAsync +var capabilities = new PhoneNumberCapabilities(calling:PhoneNumberCapabilityType.None, sms:PhoneNumberCapabilityType.Outbound); -foreach (var plan in phonePlans) -{ - Console.WriteLine($"PhonePlanId {plan.PhonePlanId}, Name: {plan.LocalizedName}"); - Console.WriteLine("Top 10 area codes"); - foreach (var areaCode in plan.AreaCodes.Take(10).ToList()) - { - Console.WriteLine($"Area code: {areaCode}"); - } -} +var searchOperation = await client.StartSearchAvailablePhoneNumbersAsync(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Application, capabilities); +await searchOperation.WaitForCompletionAsync(); ``` -### Get location options - -For Geographic phone plans, you can query the available geographic locations. The locations options are structured like the geographic hierarchy of a country. For example, the US has states and within each state are cities. +## Purchase phone numbers -```C# -var locationOptionsResponse = client.GetPhonePlanLocationOptions(countryCode, phonePlanGroupId, phonePlanId); -var locationOprions = locationOptionsResponse.Value.LocationOptions; +Phone numbers can be acquired through purchasing a search. -Console.WriteLine($"LabelId: {locationOprions.LabelId}, LabelName: {locationOprions.LabelName}"); -foreach(var locationOption in locationOprions.Options) -{ - Console.WriteLine($"Name: {locationOption.Name}, Value: {locationOption.Value}"); -} +```C# Snippet:StartPurchaseSearchAsync +var purchaseOperation = await client.StartPurchasePhoneNumbersAsync(searchOperation.Value.SearchId); +await purchaseOperation.WaitForCompletionAsync(); ``` -### Get area codes - -Fetching area codes for geographic phone plans will require that the location options queries be set. You must include the chain of geographic locations which traverse down the location options returned by the `GetLocationOptions` API. +## Listing acquired phone numbers -```C# -var areaCodesResponse = client.GetAllAreaCodes(locationType, countryCode, planId, locationOptionsQueries); -var areaCodes = areaCodesResponse.Value; +Fetching area codes for geographic phone plans will require the the location options queries set. You must include the chain of geographic locations traversing down the location options object returned by the GetLocationOptions API. -foreach(var primaryAreaCode in areaCodes.PrimaryAreaCodes) -{ - Console.WriteLine("Primary area code" + primaryAreaCode); -} +```C# Snippet:ListAcquiredPhoneNumbersAsync +var acquiredPhoneNumbers = client.GetPhoneNumbersAsync(); -foreach (var secondaryAreaCode in areaCodes.SecondaryAreaCodes) +await foreach (var phoneNumber in acquiredPhoneNumbers) { - Console.WriteLine("Secondary area code" + secondaryAreaCode); + Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, monthly cost: {phoneNumber.Cost}"); } ``` -### Create reservation - -```C# -var reservationOptions = new CreateReservationOptions(displayName, description, plans, areaCode) { Quantity = 1 }; -var reservationOperation = await client.StartReservationAsync(reservationOptions).ConfigureAwait(false); -var reservationResponse = await reservationOperation.WaitForCompletionAsync().ConfigureAwait(false); - -Console.WriteLine($"ReservationId: {reservationResponse.Value.ReservationId}, Status {reservationResponse.Value.Status}"); -``` +## Release phone numbers -### Purchase reservation +If you no longer need a phone number you can release it. -```C# -var reservationPurchaseOperation = await client.StartPurchaseReservationAsync(reservationId).ConfigureAwait(false); -await reservationPurchaseOperation.WaitForCompletionAsync().ConfigureAwait(false); +```C# Snippet:ReleasePhoneNumbersAsync +var acquiredPhoneNumber = ""; +var releaseOperation = client.StartReleasePhoneNumber(acquiredPhoneNumber); +await releaseOperation.WaitForCompletionAsync(); ``` -### Configure phone number - -```C# -var pstnConfiguration = new PstnConfiguration(""); -var phoneNumber = new PhoneNumber(""); -client.ConfigureNumber(pstnConfiguration, phoneNumber); -``` - -### Release phone numbers - -```C# -var releasePhoneNumberOperation = await client.StartReleasePhoneNumbersAsync(numbers).ConfigureAwait(false); -await releasePhoneNumberOperation.WaitForCompletionAsync().ConfigureAwait(false); - -Console.WriteLine($"ReleaseId: {releasePhoneNumberOperation.Value.ReleaseId}, Status: {releasePhoneNumberOperation.Value.Status}"); -``` ## Troubleshooting ## Next steps diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/api/Azure.Communication.PhoneNumbers.netstandard2.0.cs b/sdk/communication/Azure.Communication.PhoneNumbers/api/Azure.Communication.PhoneNumbers.netstandard2.0.cs index 769b5ea4a195c..8af35e7e75a86 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/api/Azure.Communication.PhoneNumbers.netstandard2.0.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/api/Azure.Communication.PhoneNumbers.netstandard2.0.cs @@ -1,390 +1,229 @@ namespace Azure.Communication.PhoneNumbers { - public partial class PhoneNumberAdministrationClient - { - protected PhoneNumberAdministrationClient() { } - public PhoneNumberAdministrationClient(string connectionString) { } - public PhoneNumberAdministrationClient(string connectionString, Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions options) { } - public PhoneNumberAdministrationClient(System.Uri endpoint, Azure.AzureKeyCredential keyCredential, Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions? options = null) { } - public PhoneNumberAdministrationClient(System.Uri endpoint, Azure.Core.TokenCredential tokenCredential, Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions? options = null) { } - public virtual Azure.Response CancelReservation(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task CancelReservationAsync(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response ConfigureNumber(Azure.Communication.PhoneNumbers.Models.PstnConfiguration pstnConfiguration, Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task ConfigureNumberAsync(Azure.Communication.PhoneNumbers.Models.PstnConfiguration pstnConfiguration, Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetAllAreaCodes(string locationType, string countryCode, string phonePlanId, System.Collections.Generic.IEnumerable locationOptions, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetAllAreaCodesAsync(string locationType, string countryCode, string phonePlanId, System.Collections.Generic.IEnumerable locationOptions, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetAllPhoneNumbers(string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetAllPhoneNumbersAsync(string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetAllReleases(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetAllReleasesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetAllReservations(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetAllReservationsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetAllSupportedCountries(string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetAllSupportedCountriesAsync(string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetCapabilitiesUpdate(string capabilitiesUpdateId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetCapabilitiesUpdateAsync(string capabilitiesUpdateId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetNumberConfiguration(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetNumberConfigurationAsync(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetPhonePlanGroups(string countryCode, string? locale = null, bool? includeRateInformation = default(bool?), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetPhonePlanGroupsAsync(string countryCode, string? locale = null, bool? includeRateInformation = default(bool?), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetPhonePlanLocationOptions(string countryCode, string phonePlanGroupId, string phonePlanId, string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetPhonePlanLocationOptionsAsync(string countryCode, string phonePlanGroupId, string phonePlanId, string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetPhonePlans(string countryCode, string phonePlanGroupId, string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetPhonePlansAsync(string countryCode, string phonePlanGroupId, string? locale = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetReleaseById(string releaseId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetReleaseByIdAsync(string releaseId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetReservationById(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetReservationByIdAsync(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Communication.PhoneNumbers.Models.PhoneNumberReservationPurchaseOperation StartPurchaseReservation(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task StartPurchaseReservationAsync(string reservationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Communication.PhoneNumbers.Models.ReleasePhoneNumberOperation StartReleasePhoneNumber(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task StartReleasePhoneNumberAsync(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Communication.PhoneNumbers.Models.ReleasePhoneNumberOperation StartReleasePhoneNumbers(System.Collections.Generic.IEnumerable phoneNumbers, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task StartReleasePhoneNumbersAsync(System.Collections.Generic.IEnumerable phoneNumbers, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Communication.PhoneNumbers.Models.PhoneNumberReservationOperation StartReservation(Azure.Communication.PhoneNumbers.Models.CreateReservationOptions body, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task StartReservationAsync(Azure.Communication.PhoneNumbers.Models.CreateReservationOptions body, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response UnconfigureNumber(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task UnconfigureNumberAsync(Azure.Communication.PhoneNumberIdentifier phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response UpdateCapabilities(System.Collections.Generic.IDictionary phoneNumberUpdateCapabilities, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> UpdateCapabilitiesAsync(System.Collections.Generic.IDictionary phoneNumberUpdateCapabilities, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - } - public partial class PhoneNumberAdministrationClientOptions : Azure.Core.ClientOptions - { - public const Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions.ServiceVersion LatestVersion = Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions.ServiceVersion.V1; - public PhoneNumberAdministrationClientOptions(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions.ServiceVersion version = Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClientOptions.ServiceVersion.V1, Azure.Core.RetryOptions? retryOptions = null, Azure.Core.Pipeline.HttpPipelineTransport? transport = null) { } + public partial class PhoneNumbersClient + { + protected PhoneNumbersClient() { } + public PhoneNumbersClient(string connectionString) { } + public PhoneNumbersClient(string connectionString, Azure.Communication.PhoneNumbers.PhoneNumbersClientOptions options) { } + public PhoneNumbersClient(System.Uri endpoint, Azure.AzureKeyCredential keyCredential, Azure.Communication.PhoneNumbers.PhoneNumbersClientOptions options = null) { } + public PhoneNumbersClient(System.Uri endpoint, Azure.Core.TokenCredential tokenCredential, Azure.Communication.PhoneNumbers.PhoneNumbersClientOptions options = null) { } + public virtual Azure.Response GetPhoneNumber(string phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetPhoneNumberAsync(string phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetPhoneNumbers(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetPhoneNumbersAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Communication.PhoneNumbers.PurchasePhoneNumbersOperation StartPurchasePhoneNumbers(string searchId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task StartPurchasePhoneNumbersAsync(string searchId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Communication.PhoneNumbers.ReleasePhoneNumberOperation StartReleasePhoneNumber(string phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task StartReleasePhoneNumberAsync(string phoneNumber, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Communication.PhoneNumbers.SearchAvailablePhoneNumbersOperation StartSearchAvailablePhoneNumbers(string threeLetterISOCountryName, Azure.Communication.PhoneNumbers.Models.PhoneNumberType phoneNumberType, Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType phoneNumberAssignmentType, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilities capabilities, Azure.Communication.PhoneNumbers.PhoneNumberSearchOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task StartSearchAvailablePhoneNumbersAsync(string threeLetterISOCountryName, Azure.Communication.PhoneNumbers.Models.PhoneNumberType phoneNumberType, Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType phoneNumberAssignmentType, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilities capabilities, Azure.Communication.PhoneNumbers.PhoneNumberSearchOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Communication.PhoneNumbers.UpdatePhoneNumberCapabilitiesOperation StartUpdateCapabilities(string phoneNumber, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType? calling = default(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType?), Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType? sms = default(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType?), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task StartUpdateCapabilitiesAsync(string phoneNumber, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType? calling = default(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType?), Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType? sms = default(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType?), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } + public partial class PhoneNumbersClientOptions : Azure.Core.ClientOptions + { + public PhoneNumbersClientOptions(Azure.Communication.PhoneNumbers.PhoneNumbersClientOptions.ServiceVersion version = Azure.Communication.PhoneNumbers.PhoneNumbersClientOptions.ServiceVersion.V2021_03_07) { } public enum ServiceVersion { - V1 = 1, + V2021_03_07 = 1, } } -} -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class AcquiredPhoneNumber + public partial class PhoneNumberSearchOptions { - internal AcquiredPhoneNumber() { } - public System.Collections.Generic.IReadOnlyList AcquiredCapabilities { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.ActivationState? ActivationState { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.AssignmentStatus? AssignmentStatus { get { throw null; } } - public System.Collections.Generic.IReadOnlyList AvailableCapabilities { get { throw null; } } - public string PhoneNumber { get { throw null; } } - public string PlaceName { get { throw null; } } + public PhoneNumberSearchOptions() { } + public string AreaCode { get { throw null; } set { } } + public int? Quantity { get { throw null; } set { } } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct ActivationState : System.IEquatable + public partial class PurchasePhoneNumbersOperation : Azure.Operation { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public ActivationState(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.ActivationState Activated { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ActivationState AssignmentFailed { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ActivationState AssignmentPending { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ActivationState UpdateFailed { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ActivationState UpdatePending { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.ActivationState other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.ActivationState left, Azure.Communication.PhoneNumbers.Models.ActivationState right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.ActivationState (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.ActivationState left, Azure.Communication.PhoneNumbers.Models.ActivationState right) { throw null; } - public override string ToString() { throw null; } + internal PurchasePhoneNumbersOperation() { } + public override bool HasCompleted { get { throw null; } } + public override bool HasValue { get { throw null; } } + public override string Id { get { throw null; } } + public override Azure.Response Value { get { throw null; } } + public override Azure.Response GetRawResponse() { throw null; } + public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } - public static partial class AdministrationModelFactory + public partial class ReleasePhoneNumberOperation : Azure.Operation { - public static Azure.Communication.PhoneNumbers.Models.AcquiredPhoneNumber AcquiredPhoneNumber(string phoneNumber, System.Collections.Generic.IEnumerable acquiredCapabilities, System.Collections.Generic.IEnumerable availableCapabilities) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.AreaCodes AreaCodes(System.Collections.Generic.IReadOnlyList primaryAreaCodes, System.Collections.Generic.IReadOnlyList secondaryAreaCodes, string nextLink) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.CarrierDetails CarrierDetails(string name, string localizedName) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.LocationOptions LocationOptions(string labelId, string labelName, System.Collections.Generic.IList options) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.LocationOptionsDetails LocationOptionsDetails(string name, string value, System.Collections.Generic.IList locationOptions) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.LocationOptionsResponse LocationOptionsResponse(Azure.Communication.PhoneNumbers.Models.LocationOptions locationOptions) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.NumberConfigurationResponse NumberConfigurationResponse(Azure.Communication.PhoneNumbers.Models.PstnConfiguration pstnConfiguration) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.NumberUpdateCapabilities NumberUpdateCapabilities(System.Collections.Generic.IList add, System.Collections.Generic.IList remove) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCountry PhoneNumberCountry(string localizedName, string countryCode) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberEntity PhoneNumberEntity(string id, System.DateTimeOffset? createdAt, string displayName, int? quantity, int? quantityObtained, string status, System.DateTimeOffset? focDate) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberRelease PhoneNumberRelease(string releaseId, System.DateTimeOffset? createdAt, Azure.Communication.PhoneNumbers.Models.ReleaseStatus? status, string errorMessage, System.Collections.Generic.IReadOnlyDictionary phoneNumberReleaseStatusDetails) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseDetails PhoneNumberReleaseDetails(Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus? status, int? errorCode) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReservation PhoneNumberReservation(string reservationId, string displayName, System.DateTimeOffset? createdAt, string description, System.Collections.Generic.IReadOnlyList phonePlanIds, string areaCode, int? quantity, System.Collections.Generic.IReadOnlyList locationOptions, Azure.Communication.PhoneNumbers.Models.ReservationStatus? status, System.Collections.Generic.IReadOnlyList phoneNumbers, System.DateTimeOffset? reservationExpiryDate, int? errorCode) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReservationOperation PhoneNumberReservationOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string reservationId) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReservationPurchaseOperation PhoneNumberReservationPurchaseOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string reservationId) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhonePlan PhonePlan(string phonePlanId, string localizedName, Azure.Communication.PhoneNumbers.Models.LocationType locationType) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhonePlanGroup PhonePlanGroup(string phonePlanGroupId, string localizedName, string localizedDescription) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.RateInformation RateInformation(double? monthlyRate, Azure.Communication.PhoneNumbers.Models.CurrencyType? currencyType, string rateErrorMessage) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.ReleasePhoneNumberOperation ReleasePhoneNumberOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string releaseId) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.UpdateNumberCapabilitiesResponse UpdateNumberCapabilitiesResponse(string capabilitiesUpdateId) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.UpdatePhoneNumberCapabilitiesResponse UpdatePhoneNumberCapabilitiesResponse(string capabilitiesUpdateId, System.DateTimeOffset? createdAt, Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus? capabilitiesUpdateStatus, System.Collections.Generic.IReadOnlyDictionary phoneNumberCapabilitiesUpdates) { throw null; } + internal ReleasePhoneNumberOperation() { } + public override bool HasCompleted { get { throw null; } } + public override bool HasValue { get { throw null; } } + public override string Id { get { throw null; } } + public override Azure.Response Value { get { throw null; } } + public override Azure.Response GetRawResponse() { throw null; } + public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } - public partial class AreaCodes + public partial class SearchAvailablePhoneNumbersOperation : Azure.Operation { - internal AreaCodes() { } - public string NextLink { get { throw null; } } - public System.Collections.Generic.IReadOnlyList PrimaryAreaCodes { get { throw null; } } - public System.Collections.Generic.IReadOnlyList SecondaryAreaCodes { get { throw null; } } + internal SearchAvailablePhoneNumbersOperation() { } + public override bool HasCompleted { get { throw null; } } + public override bool HasValue { get { throw null; } } + public override string Id { get { throw null; } } + public override Azure.Communication.PhoneNumbers.Models.PhoneNumberSearchResult Value { get { throw null; } } + public override Azure.Response GetRawResponse() { throw null; } + public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct AssignmentStatus : System.IEquatable + public partial class UpdatePhoneNumberCapabilitiesOperation : Azure.Operation { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public AssignmentStatus(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus ConferenceAssigned { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus FirstPartyAppAssigned { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus ThirdPartyAppAssigned { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus Unassigned { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus Unknown { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.AssignmentStatus UserAssigned { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.AssignmentStatus other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.AssignmentStatus left, Azure.Communication.PhoneNumbers.Models.AssignmentStatus right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.AssignmentStatus (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.AssignmentStatus left, Azure.Communication.PhoneNumbers.Models.AssignmentStatus right) { throw null; } - public override string ToString() { throw null; } + internal UpdatePhoneNumberCapabilitiesOperation() { } + public override bool HasCompleted { get { throw null; } } + public override bool HasValue { get { throw null; } } + public override string Id { get { throw null; } } + public override Azure.Communication.PhoneNumbers.Models.AcquiredPhoneNumber Value { get { throw null; } } + public override Azure.Response GetRawResponse() { throw null; } + public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } +} +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class AcquiredPhoneNumber + { + internal AcquiredPhoneNumber() { } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType AssignmentType { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilities Capabilities { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCost Cost { get { throw null; } } + public string CountryCode { get { throw null; } } + public string Id { get { throw null; } } + public string PhoneNumber { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberType PhoneNumberType { get { throw null; } } + public System.DateTimeOffset PurchaseDate { get { throw null; } } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct CapabilitiesUpdateStatus : System.IEquatable + public readonly partial struct BillingFrequency : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public CapabilitiesUpdateStatus(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus Complete { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus Error { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus InProgress { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus Pending { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus other) { throw null; } + public BillingFrequency(string value) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.BillingFrequency Monthly { get { throw null; } } + public bool Equals(Azure.Communication.PhoneNumbers.Models.BillingFrequency other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus left, Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus left, Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus right) { throw null; } + public static bool operator ==(Azure.Communication.PhoneNumbers.Models.BillingFrequency left, Azure.Communication.PhoneNumbers.Models.BillingFrequency right) { throw null; } + public static implicit operator Azure.Communication.PhoneNumbers.Models.BillingFrequency (string value) { throw null; } + public static bool operator !=(Azure.Communication.PhoneNumbers.Models.BillingFrequency left, Azure.Communication.PhoneNumbers.Models.BillingFrequency right) { throw null; } public override string ToString() { throw null; } } - public partial class CarrierDetails - { - internal CarrierDetails() { } - public string LocalizedName { get { throw null; } } - public string Name { get { throw null; } } - } - public partial class CreateReservationOptions - { - public CreateReservationOptions(string displayName, string description, System.Collections.Generic.IEnumerable phonePlanIds, string areaCode) { } - public string AreaCode { get { throw null; } } - public string Description { get { throw null; } } - public string DisplayName { get { throw null; } } - public System.Collections.Generic.IList LocationOptions { get { throw null; } } - public System.Collections.Generic.IList PhonePlanIds { get { throw null; } } - public int? Quantity { get { throw null; } set { } } - } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct CurrencyType : System.IEquatable + public readonly partial struct PhoneNumberAssignmentType : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public CurrencyType(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.CurrencyType USD { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.CurrencyType other) { throw null; } + public PhoneNumberAssignmentType(string value) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType Application { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType Person { get { throw null; } } + public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.CurrencyType left, Azure.Communication.PhoneNumbers.Models.CurrencyType right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.CurrencyType (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.CurrencyType left, Azure.Communication.PhoneNumbers.Models.CurrencyType right) { throw null; } + public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType right) { throw null; } + public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType (string value) { throw null; } + public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType right) { throw null; } public override string ToString() { throw null; } } - public partial class LocationOptions - { - public LocationOptions() { } - public string LabelId { get { throw null; } set { } } - public string LabelName { get { throw null; } set { } } - public System.Collections.Generic.IList Options { get { throw null; } } - } - public partial class LocationOptionsDetails - { - public LocationOptionsDetails() { } - public System.Collections.Generic.IList LocationOptions { get { throw null; } } - public string Name { get { throw null; } set { } } - public string Value { get { throw null; } set { } } - } - public partial class LocationOptionsQuery + public partial class PhoneNumberCapabilities { - public LocationOptionsQuery() { } - public string LabelId { get { throw null; } set { } } - public string OptionsValue { get { throw null; } set { } } - } - public partial class LocationOptionsResponse - { - internal LocationOptionsResponse() { } - public Azure.Communication.PhoneNumbers.Models.LocationOptions LocationOptions { get { throw null; } } + public PhoneNumberCapabilities(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType calling, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType sms) { } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType Calling { get { throw null; } set { } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType Sms { get { throw null; } set { } } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct LocationType : System.IEquatable + public readonly partial struct PhoneNumberCapabilityType : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public LocationType(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.LocationType CivicAddress { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.LocationType NotRequired { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.LocationType Selection { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.LocationType other) { throw null; } + public PhoneNumberCapabilityType(string value) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType Inbound { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType InboundOutbound { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType None { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType Outbound { get { throw null; } } + public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.LocationType left, Azure.Communication.PhoneNumbers.Models.LocationType right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.LocationType (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.LocationType left, Azure.Communication.PhoneNumbers.Models.LocationType right) { throw null; } + public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType right) { throw null; } + public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType (string value) { throw null; } + public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilityType right) { throw null; } public override string ToString() { throw null; } } - public partial class NumberConfigurationResponse + public partial class PhoneNumberCost { - internal NumberConfigurationResponse() { } - public Azure.Communication.PhoneNumbers.Models.PstnConfiguration PstnConfiguration { get { throw null; } } - } - public partial class NumberUpdateCapabilities - { - public NumberUpdateCapabilities() { } - public System.Collections.Generic.IList Add { get { throw null; } } - public System.Collections.Generic.IList Remove { get { throw null; } } + internal PhoneNumberCost() { } + public double Amount { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.BillingFrequency BillingFrequency { get { throw null; } } + public string ISOCurrencySymbol { get { throw null; } } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct PhoneNumberCapability : System.IEquatable + public readonly partial struct PhoneNumberOperationStatus : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public PhoneNumberCapability(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability A2PSmsCapable { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability A2PSmsEnabled { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability Azure { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability Calling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability ConferenceAssignment { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability FirstPartyAppAssignment { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability FirstPartyVoiceAppAssignment { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability Geographic { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability InboundA2PSms { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability InboundCalling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability InboundP2PSms { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability NonGeographic { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability Office365 { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability OutboundA2PSms { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability OutboundCalling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability OutboundP2PSms { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability P2PSmsCapable { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability P2PSmsEnabled { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability Premium { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability ThirdPartyAppAssignment { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability TollCalling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability TollFree { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability TollFreeCalling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability UserAssignment { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability other) { throw null; } + public PhoneNumberOperationStatus(string value) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus Failed { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus NotStarted { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus Running { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus Succeeded { get { throw null; } } + public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability left, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability left, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapability right) { throw null; } + public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus left, Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus right) { throw null; } + public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus (string value) { throw null; } + public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus left, Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationStatus right) { throw null; } public override string ToString() { throw null; } } - public partial class PhoneNumberCountry - { - internal PhoneNumberCountry() { } - public string CountryCode { get { throw null; } } - public string LocalizedName { get { throw null; } } - } - public partial class PhoneNumberEntity - { - internal PhoneNumberEntity() { } - public System.DateTimeOffset? CreatedAt { get { throw null; } } - public string DisplayName { get { throw null; } } - public System.DateTimeOffset? FocDate { get { throw null; } } - public string Id { get { throw null; } } - public int? Quantity { get { throw null; } } - public int? QuantityObtained { get { throw null; } } - public string Status { get { throw null; } } - } - public partial class PhoneNumberRelease - { - internal PhoneNumberRelease() { } - public System.DateTimeOffset? CreatedAt { get { throw null; } } - public string ErrorMessage { get { throw null; } } - public System.Collections.Generic.IReadOnlyDictionary PhoneNumberReleaseStatusDetails { get { throw null; } } - public string ReleaseId { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.ReleaseStatus? Status { get { throw null; } } - } - public partial class PhoneNumberReleaseDetails - { - internal PhoneNumberReleaseDetails() { } - public int? ErrorCode { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus? Status { get { throw null; } } - } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct PhoneNumberReleaseStatus : System.IEquatable + public readonly partial struct PhoneNumberOperationType : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public PhoneNumberReleaseStatus(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus Error { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus InProgress { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus Pending { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus Success { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus other) { throw null; } + public PhoneNumberOperationType(string value) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType Purchase { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType ReleasePhoneNumber { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType Search { get { throw null; } } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType UpdatePhoneNumberCapabilities { get { throw null; } } + public bool Equals(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus left, Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus left, Azure.Communication.PhoneNumbers.Models.PhoneNumberReleaseStatus right) { throw null; } + public static bool operator ==(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType right) { throw null; } + public static implicit operator Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType (string value) { throw null; } + public static bool operator !=(Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType left, Azure.Communication.PhoneNumbers.Models.PhoneNumberOperationType right) { throw null; } public override string ToString() { throw null; } } - public partial class PhoneNumberReservation + public partial class PhoneNumberSearchResult { - internal PhoneNumberReservation() { } - public string AreaCode { get { throw null; } } - public System.DateTimeOffset? CreatedAt { get { throw null; } } - public string Description { get { throw null; } } - public string DisplayName { get { throw null; } } - public int? ErrorCode { get { throw null; } } - public System.Collections.Generic.IReadOnlyList LocationOptions { get { throw null; } } + internal PhoneNumberSearchResult() { } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType AssignmentType { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilities Capabilities { get { throw null; } } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberCost Cost { get { throw null; } } public System.Collections.Generic.IReadOnlyList PhoneNumbers { get { throw null; } } - public System.Collections.Generic.IReadOnlyList PhonePlanIds { get { throw null; } } - public int? Quantity { get { throw null; } } - public System.DateTimeOffset? ReservationExpiryDate { get { throw null; } } - public string ReservationId { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.ReservationStatus? Status { get { throw null; } } - } - public partial class PhoneNumberReservationOperation : Azure.Operation - { - public PhoneNumberReservationOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string id, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { } - public override bool HasCompleted { get { throw null; } } - public override bool HasValue { get { throw null; } } - public override string Id { get { throw null; } } - public override Azure.Communication.PhoneNumbers.Models.PhoneNumberReservation Value { get { throw null; } } - public override Azure.Response GetRawResponse() { throw null; } - public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken) { throw null; } + public Azure.Communication.PhoneNumbers.Models.PhoneNumberType PhoneNumberType { get { throw null; } } + public System.DateTimeOffset SearchExpiresOn { get { throw null; } } + public string SearchId { get { throw null; } } } - public partial class PhoneNumberReservationPurchaseOperation : Azure.Operation + public static partial class PhoneNumbersModelFactory { - public PhoneNumberReservationPurchaseOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string id, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { } - public override bool HasCompleted { get { throw null; } } - public override bool HasValue { get { throw null; } } - public override string Id { get { throw null; } } - public override Azure.Communication.PhoneNumbers.Models.ReservationStatus Value { get { throw null; } } - public override Azure.Response GetRawResponse() { throw null; } - public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.AcquiredPhoneNumber AcquiredPhoneNumber(string id, string phoneNumber, string countryCode, Azure.Communication.PhoneNumbers.Models.PhoneNumberType phoneNumberType, Azure.Communication.PhoneNumbers.Models.PhoneNumberCapabilities capabilities, Azure.Communication.PhoneNumbers.Models.PhoneNumberAssignmentType assignmentType, System.DateTimeOffset purchaseDate, Azure.Communication.PhoneNumbers.Models.PhoneNumberCost cost) { throw null; } + public static Azure.Communication.PhoneNumbers.Models.PhoneNumberCost PhoneNumberCost(double amount, string currencyCode, string billingFrequency) { throw null; } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct PhoneNumberType : System.IEquatable @@ -393,9 +232,7 @@ public partial class PhoneNumberReservationPurchaseOperation : Azure.Operation AreaCodes { get { throw null; } } - public System.Collections.Generic.IReadOnlyList Capabilities { get { throw null; } } - public string LocalizedName { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.LocationType LocationType { get { throw null; } } - public int? MaximumSearchSize { get { throw null; } } - public string PhonePlanId { get { throw null; } } - } - public partial class PhonePlanGroup - { - internal PhonePlanGroup() { } - public Azure.Communication.PhoneNumbers.Models.CarrierDetails CarrierDetails { get { throw null; } } - public string LocalizedDescription { get { throw null; } } - public string LocalizedName { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.PhoneNumberType? PhoneNumberType { get { throw null; } } - public string PhonePlanGroupId { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.RateInformation RateInformation { get { throw null; } } - } - public partial class PstnConfiguration - { - public PstnConfiguration(string callbackUrl) { } - public string ApplicationId { get { throw null; } set { } } - public string CallbackUrl { get { throw null; } set { } } - } - public partial class RateInformation - { - internal RateInformation() { } - public Azure.Communication.PhoneNumbers.Models.CurrencyType? CurrencyType { get { throw null; } } - public double? MonthlyRate { get { throw null; } } - public string RateErrorMessage { get { throw null; } } - } - public partial class ReleasePhoneNumberOperation : Azure.Operation - { - public ReleasePhoneNumberOperation(Azure.Communication.PhoneNumbers.PhoneNumberAdministrationClient client, string id, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { } - public override bool HasCompleted { get { throw null; } } - public override bool HasValue { get { throw null; } } - public override string Id { get { throw null; } } - public override Azure.Communication.PhoneNumbers.Models.PhoneNumberRelease Value { get { throw null; } } - public override Azure.Response GetRawResponse() { throw null; } - public override Azure.Response UpdateStatus(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask UpdateStatusAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public override System.Threading.Tasks.ValueTask> WaitForCompletionAsync(System.TimeSpan pollingInterval, System.Threading.CancellationToken cancellationToken) { throw null; } - } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct ReleaseStatus : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public ReleaseStatus(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.ReleaseStatus Complete { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReleaseStatus Expired { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReleaseStatus Failed { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReleaseStatus InProgress { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReleaseStatus Pending { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.ReleaseStatus other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.ReleaseStatus left, Azure.Communication.PhoneNumbers.Models.ReleaseStatus right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.ReleaseStatus (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.ReleaseStatus left, Azure.Communication.PhoneNumbers.Models.ReleaseStatus right) { throw null; } - public override string ToString() { throw null; } - } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct ReservationStatus : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public ReservationStatus(string value) { throw null; } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Cancelled { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Cancelling { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Completing { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Error { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Expired { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Expiring { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus InProgress { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Manual { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Pending { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus PurchasePending { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Refreshing { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Reserved { get { throw null; } } - public static Azure.Communication.PhoneNumbers.Models.ReservationStatus Success { get { throw null; } } - public bool Equals(Azure.Communication.PhoneNumbers.Models.ReservationStatus other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.Communication.PhoneNumbers.Models.ReservationStatus left, Azure.Communication.PhoneNumbers.Models.ReservationStatus right) { throw null; } - public static implicit operator Azure.Communication.PhoneNumbers.Models.ReservationStatus (string value) { throw null; } - public static bool operator !=(Azure.Communication.PhoneNumbers.Models.ReservationStatus left, Azure.Communication.PhoneNumbers.Models.ReservationStatus right) { throw null; } - public override string ToString() { throw null; } - } - public partial class UpdateNumberCapabilitiesResponse - { - internal UpdateNumberCapabilitiesResponse() { } - public string CapabilitiesUpdateId { get { throw null; } } - } - public partial class UpdatePhoneNumberCapabilitiesResponse - { - internal UpdatePhoneNumberCapabilitiesResponse() { } - public string CapabilitiesUpdateId { get { throw null; } } - public Azure.Communication.PhoneNumbers.Models.CapabilitiesUpdateStatus? CapabilitiesUpdateStatus { get { throw null; } } - public System.DateTimeOffset? CreatedAt { get { throw null; } } - public System.Collections.Generic.IReadOnlyDictionary PhoneNumberCapabilitiesUpdates { get { throw null; } } - } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/samples/README.md b/sdk/communication/Azure.Communication.PhoneNumbers/samples/README.md index da1ed0f1d0d2d..532fa31f25371 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/samples/README.md +++ b/sdk/communication/Azure.Communication.PhoneNumbers/samples/README.md @@ -6,7 +6,7 @@ products: - azure - azure-communication name: Azure Communication Phone Number samples for .NET -description: Samples for the Azure.Communication.PhoneNumber client library +description: Samples for the Azure.Communication.PhoneNumbers client library --- # Azure Communication Phone Number SDK samples @@ -21,5 +21,5 @@ This client library allows to do following operations: - Manage phone numbers [synchronously][sample_phonenumbers] or [asynchronously][sample_phonenumbers_async] -[sample_phonenumbers]: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClient.md -[sample_phonenumbers_async]: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClientAsync.md +[sample_phonenumbers]: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClient.md +[sample_phonenumbers_async]: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClientAsync.md diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClient.md b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClient.md deleted file mode 100644 index 2f04cdb87766e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClient.md +++ /dev/null @@ -1,200 +0,0 @@ -# Searching, reserving, purchasing, releasing phone numbers - -This sample demonstrates how to search, reserve, purchase and release phone numbers in Azure Communication Services. -To get started, you'll need a URI to an Azure Communication Services. See the [README](https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/README.md) for links and instructions. - -## Creating a PhoneNumberAdministrationClient - -To create a new `PhoneNumberAdministrationClient` you need a connection string to the Azure Communication Services resource that you can get from the Azure Portal once you have created the resource. - -You can set `connectionString` based on an environment variable, a configuration setting, or any way that works for your application. - -```C# Snippet:CreatePhoneNumberAdministrationClient -// Get a connection string to our Azure Communication resource. -var connectionString = ""; -var client = new PhoneNumberAdministrationClient(connectionString); -``` - -## Listing all supported countries - -In order to acquire a phone number you will need to know if Azure Communication Services are available in a particular country. You can find out by retrieving a list of supported countries. - -```C# Snippet:GetAllSupportedCountries -var supportedCountries = client.GetAllSupportedCountries(locale); -foreach (var country in supportedCountries) -{ - Console.WriteLine($"Supported country code: {country.CountryCode}, name: {country.LocalizedName}"); -} -``` - -## Listing phone plan groups - -Phone plan groups come in two types, Geographic and Toll-Free. - -```C# Snippet:GetPhonePlanGroups -var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - -foreach (var phonePlanGroup in phonePlanGroups) -{ - Console.WriteLine($"Plan group: {phonePlanGroup.LocalizedName}, type: {phonePlanGroup.PhoneNumberType}"); -} -``` - -## Listing phone plans - -Unlike Toll-Free phone plans, area codes for Geographic phone plans are empty. Area codes are found in the Area Codes API. - -```C# Snippet:GetPhonePlans -var phonePlans = client.GetPhonePlans(countryCode, phonePlanGroupId, locale); -foreach (var phonePlan in phonePlans) -{ - Console.WriteLine($"Plan: {phonePlan.LocalizedName}, {phonePlan.LocationType}"); -} -``` - -## Get location options - -For Geographic phone plans, you can query the available geographic locations. The locations options are structured like the geographic hierarchy of a country. For example, the US has states and within each state are cities. - -```C# Snippet:GetPhonePlanLocationOptions -var locationOptionsResponse = client.GetPhonePlanLocationOptions(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, phonePlanId); - -void PrintLocationOption(LocationOptions locationOptions) -{ - Console.WriteLine($"LabelId: {locationOptions.LabelId}, LabelName: {locationOptions.LabelName}"); - - foreach (var locationOption in locationOptions.Options) - { - Console.WriteLine($"Name: {locationOption.Name}, Value: {locationOption.Value}"); - - foreach (var subLocationOption in locationOption.LocationOptions) - PrintLocationOption(subLocationOption); - } -} -PrintLocationOption(locationOptionsResponse.Value.LocationOptions); -``` - -## Get area codes - -Fetching area codes for geographic phone plans will require the location options queries set. You must include the chain of geographic locations traversing down the location options object returned by the `GetPhonePlanLocationOptions`. - -```C# Snippet:GeographicalAreaCodes -var locationOptionsResponse = client.GetPhonePlanLocationOptions(countryCode, geographicPhonePlanGroupId, geographicPhonePlanId); -var state = locationOptionsResponse.Value.LocationOptions.Options.First(); - -var locationOptionsQueries = new List -{ - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = state.Value - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = state.LocationOptions.First().Options.First().Value - } -}; - -var areaCodes = client.GetAllAreaCodes(geographicPhonePlan.LocationType.ToString(), countryCode, geographicPhonePlan.PhonePlanId, locationOptionsQueries); - -foreach (var areaCode in areaCodes.Value.PrimaryAreaCodes) -{ - Console.WriteLine($"Primary area code: {areaCode}"); -} -``` - -Area codes for toll-free phone plans can be found in the plan. - -```C# Snippet:TollFreePlanAreaCodes -var phonePlans = client.GetPhonePlans(countryCode, tollFreePhonePlanGroupId, locale); -var tollFreePhonePlan = phonePlans.First(); - -foreach (var areaCode in tollFreePhonePlan.AreaCodes) -{ - Console.WriteLine($"Area code: {areaCode}"); -} -``` - -## Reserve phone numbers - -Phone numbers need to be reserved before they can be purchased. Reservation is a long running operation that can be started by `CreateReservationOptions` function that returns an `PhoneNumberReservationOperation` object. `PhoneNumberReservationOperation` can be used to update status of the operation and to check for completeness. - -```C# Snippet:ReservePhoneNumbers -var reservationName = "My reservation"; -var reservationDescription = "reservation description"; -var reservationOptions = new CreateReservationOptions(reservationName, reservationDescription, new[] { phonePlanId }, areaCode); -reservationOptions.Quantity = 1; - -var reserveOperation = client.StartReservation(reservationOptions); - -while (!reserveOperation.HasCompleted) -{ - Thread.Sleep(2000); - - reserveOperation.UpdateStatus(); -} -``` - -## Persist reserve phone numbers operation - -You can persist the operation Id of the phone number reservation so that you can come back and check the operation status later. - -```C# Snippet:PersistReservePhoneNumbersOperation -var reservationId = reserveOperation.Id; - -// persist reservationId and then continue with a new operation - -var reserveOperation = new PhoneNumberReservationOperation(client, reservationId); - -while (!reserveOperation.HasCompleted) -{ - Thread.Sleep(2000); - - reserveOperation.UpdateStatus(); -} -``` - -## Purchase phone numbers - -Phone numbers can be acquired through purchasing a reservation. - -```C# Snippet:StartPurchaseReservation -var purchaseOperation = client.StartPurchaseReservation(reservationId); - -while (!purchaseOperation.HasCompleted) -{ - Thread.Sleep(2000); - - purchaseOperation.UpdateStatus(); -} -``` - -## Listing acquired phone numbers - -You can list all phone numbers that have been acquired for your resource. - -```C# Snippet:ListAcquiredPhoneNumbers -var acquiredPhoneNumbers = client.GetAllPhoneNumbers(locale); - -foreach (var phoneNumber in acquiredPhoneNumbers) -{ - Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, activation state: {phoneNumber.ActivationState}"); -} -``` - -## Release phone numbers - -If you no longer need a phone number you can release it. - -```C# Snippet:ReleasePhoneNumbers -var acquiredPhoneNumber = ""; -var releaseOperation = client.StartReleasePhoneNumber(new PhoneNumberIdentifier(acquiredPhoneNumber)); - -while (!releaseOperation.HasCompleted) -{ - Thread.Sleep(2000); - - releaseOperation.UpdateStatus(); -} -``` diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClientAsync.md b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClientAsync.md deleted file mode 100644 index c66611c5172c2..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample2_PhoneNumberAdministrationClientAsync.md +++ /dev/null @@ -1,176 +0,0 @@ -# Searching, reserving, purchasing, releasing phone numbers (Async) - -This sample demonstrates how to search, reserve, purchase and release phone numbers in Azure Communication Services. -To get started, you'll need a URI to an Azure Communication Services. See the [README](https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/README.md) for links and instructions. - -## Creating a PhoneNumberAdministrationClient - -To create a new `PhoneNumberAdministrationClient` you need a connection string to the Azure Communication Services resource that you can get from the Azure Portal once you have created the resource. - -You can set `connectionString` based on an environment variable, a configuration setting, or any way that works for your application. - -```C# Snippet:CreatePhoneNumberAdministrationClient -// Get a connection string to our Azure Communication resource. -var connectionString = ""; -var client = new PhoneNumberAdministrationClient(connectionString); -``` - -## Listing all supported countries - -In order to acquire a phone number you will need to know if Azure Communication Services are available in a particular country. You can find out by retrieving a list of supported countries. - -```C# Snippet:GetAllSupportedCountriesAsync -var supportedCountries = client.GetAllSupportedCountriesAsync(locale); -await foreach (var country in supportedCountries) -{ - Console.WriteLine($"Supported country code: {country.CountryCode}, name: {country.LocalizedName}"); -} -``` - -## Listing phone plan groups - -Phone plan groups come in two types, Geographic and Toll-Free. - -```C# Snippet:GetPhonePlanGroupsAsync -var phonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - -await foreach (var phonePlanGroup in phonePlanGroups) -{ - Console.WriteLine($"Plan group: {phonePlanGroup.LocalizedName}, type: {phonePlanGroup.PhoneNumberType}"); -} -``` - -## Listing phone plans - -Unlike Toll-Free phone plans, area codes for Geographic phone plans are empty. Area codes are found in the Area Codes API. - -```C# Snippet:GetPhonePlansAsync -var phonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); -await foreach (var phonePlan in phonePlans) -{ - Console.WriteLine($"Plan: {phonePlan.LocalizedName}, {phonePlan.LocationType}"); -} -``` - -## Get location options - -For Geographic phone plans, you can query the available geographic locations. The locations options are structured like the geographic hierarchy of a country. For example, the US has states and within each state are cities. - -```C# Snippet:GetPhonePlanLocationOptionsAsync -var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, geographicPhonePlanGroupId, phonePlanId); - -void PrintLocationOption(LocationOptions locationOptions) -{ - Console.WriteLine($"LabelId: {locationOptions.LabelId}, LabelName: {locationOptions.LabelName}"); - - foreach (var locationOption in locationOptions.Options) - { - Console.WriteLine($"Name: {locationOption.Name}, Value: {locationOption.Value}"); - - foreach (var subLocationOption in locationOption.LocationOptions) - PrintLocationOption(subLocationOption); - } -} -PrintLocationOption(locationOptionsResponse.Value.LocationOptions); -``` - -## Get area codes - -Fetching area codes for geographic phone plans will require the location options queries set. You must include the chain of geographic locations traversing down the location options object returned by the `GetPhonePlanLocationOptions`. - -```C# Snippet:GeographicalAreaCodesAsync -var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, geographicPhonePlanGroupId, geographicPhonePlanId); -var state = locationOptionsResponse.Value.LocationOptions.Options.First(); - -var locationOptionsQueries = new List -{ - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = state.Value - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = state.LocationOptions.First().Options.First().Value - } -}; - -var areaCodes = await client.GetAllAreaCodesAsync(geographicPhonePlan.LocationType.ToString(), countryCode, geographicPhonePlan.PhonePlanId, locationOptionsQueries); - -foreach (var areaCode in areaCodes.Value.PrimaryAreaCodes) -{ - Console.WriteLine($"Primary area code: {areaCode}"); -} -``` - -Area codes for toll-free phone plans can be found in the plan. - -```C# Snippet:TollFreePlanAreaCodesAsync -var phonePlans = client.GetPhonePlansAsync(countryCode, tollFreePhonePlanGroup.PhonePlanGroupId, locale); -var tollFreePhonePlan = (await phonePlans.ToEnumerableAsync()).First(); - -foreach (var areaCode in tollFreePhonePlan.AreaCodes) -{ - Console.WriteLine($"Area code: {areaCode}"); -} -``` - -## Reserve phone numbers - -Phone numbers need to be reserved before they can be purchased. Reservation is a long running operation that can be started by `CreateReservationOptions` function that returns an `PhoneNumberReservationOperation` object. `PhoneNumberReservationOperation` can be used to update status of the operation and to check for completeness. - -```C# Snippet:ReservePhoneNumbersAsync -var reservationName = "My reservation"; -var reservationDescription = "reservation description"; -var reservationOptions = new CreateReservationOptions(reservationName, reservationDescription, new[] { phonePlanId }, areaCode); -reservationOptions.Quantity = 1; - -var reserveOperation = await client.StartReservationAsync(reservationOptions); -await reserveOperation.WaitForCompletionAsync(); -``` - -## Persist reserve phone numbers operation - -You can persist the operation Id of the phone number reservation so that you can come back and check the operation status later. - -```C# Snippet:PersistReservePhoneNumbersOperationAsync -var reservationId = reserveOperation.Id; - -// persist reservationId and then continue with a new operation - -var reserveOperation = new PhoneNumberReservationOperation(client, reservationId); -await reserveOperation.WaitForCompletionAsync(); -``` - -## Purchase phone numbers - -Phone numbers can be acquired through purchasing a reservation. - -```C# Snippet:StartPurchaseReservationAsync -var purchaseOperation = await client.StartPurchaseReservationAsync(reservationId); -await purchaseOperation.WaitForCompletionAsync(); -``` - -## Listing acquired phone numbers - -You can list all phone numbers that have been acquired for your resource. - -```C# Snippet:ListAcquiredPhoneNumbersAsync -var acquiredPhoneNumbers = client.GetAllPhoneNumbersAsync(locale); - -await foreach (var phoneNumber in acquiredPhoneNumbers) -{ - Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, activation state: {phoneNumber.ActivationState}"); -} -``` - -## Release phone numbers - -If you no longer need a phone number you can release it. - -```C# Snippet:ReleasePhoneNumbersAsync -var acquiredPhoneNumber = ""; -var releaseOperation = client.StartReleasePhoneNumber(new PhoneNumberIdentifier(acquiredPhoneNumber)); -await releaseOperation.WaitForCompletionAsync(); -``` diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClient.md b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClient.md new file mode 100644 index 0000000000000..8fc00af0c5917 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClient.md @@ -0,0 +1,88 @@ +# Searching, reserving, purchasing, releasing phone numbers + +This sample demonstrates how to search, reserve, purchase and release phone numbers in Azure Communication Services. +To get started, you'll need a URI to an Azure Communication Services. See the [README](https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/README.md) for links and instructions. + +## Creating a PhoneNumbersClient + +To create a new `PhoneNumbersClient` you need a connection string to the Azure Communication Services resource that you can get from the Azure Portal once you have created the resource. + +You can set `connectionString` based on an environment variable, a configuration setting, or any way that works for your application. + +```C# Snippet:CreatePhoneNumbersClient +// Get a connection string to our Azure Communication resource. +var connectionString = ""; +var client = new PhoneNumbersClient(connectionString); +``` + +## Search phone numbers + +Phone numbers need to be searched before they can be purchased. Search is a long running operation that can be started by `StartSearchAvailablePhoneNumbers` function that returns an `SearchAvailablePhoneNumbersOperation` object. `SearchAvailablePhoneNumbersOperation` can be used to update status of the operation and to check for completeness. + +```C# Snippet:SearchPhoneNumbers +var capabilities = new PhoneNumberCapabilities(calling:PhoneNumberCapabilityType.None, sms:PhoneNumberCapabilityType.Outbound); + +var searchOperation = client.StartSearchAvailablePhoneNumbers(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Application, capabilities); + +while (!searchOperation.HasCompleted) +{ + Thread.Sleep(2000); + searchOperation.UpdateStatus(); +} +``` + +## Purchase phone numbers + +Phone numbers can be acquired through purchasing a reservation. + +```C# Snippet:StartPurchaseSearch +var purchaseOperation = client.StartPurchasePhoneNumbers(searchOperation.Value.SearchId); + +while (!purchaseOperation.HasCompleted) +{ + Thread.Sleep(2000); + purchaseOperation.UpdateStatus(); +} +``` + +## Listing acquired phone numbers + +You can list all phone numbers that have been acquired for your resource. + +```C# Snippet:ListAcquiredPhoneNumbers +var acquiredPhoneNumbers = client.GetPhoneNumbers(); + +foreach (var phoneNumber in acquiredPhoneNumbers) +{ + Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, monthly cost: {phoneNumber.Cost}"); +} +``` + +## Update phone number capabilities + +Phone number's capabilities can be updated by started by `StartUpdateCapabilities` function. + +```C# Snippet:UpdateCapabilitiesNumbers +var updateCapabilitiesOperation = client.StartUpdateCapabilities(acquiredPhoneNumber, calling:PhoneNumberCapabilityType.Outbound, sms:PhoneNumberCapabilityType.InboundOutbound); + +while (!updateCapabilitiesOperation.HasCompleted) +{ + Thread.Sleep(2000); + updateCapabilitiesOperation.UpdateStatus(); +} +``` + +## Release phone numbers + +If you no longer need a phone number you can release it. + +```C# Snippet:ReleasePhoneNumbers +var acquiredPhoneNumber = ""; +var releaseOperation = client.StartReleasePhoneNumber(acquiredPhoneNumber); + +while (!releaseOperation.HasCompleted) +{ + Thread.Sleep(2000); + releaseOperation.UpdateStatus(); +} +``` diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClientAsync.md b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClientAsync.md new file mode 100644 index 0000000000000..7df554feff020 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/samples/Sample_PhoneNumbersClientAsync.md @@ -0,0 +1,69 @@ +# Searching, reserving, purchasing, releasing phone numbers (Async) + +This sample demonstrates how to search, reserve, purchase and release phone numbers in Azure Communication Services. +To get started, you'll need a URI to an Azure Communication Services. See the [README](https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/communication/Azure.Communication.PhoneNumbers/README.md) for links and instructions. + +## Creating a PhoneNumbersClient + +To create a new `PhoneNumbersClient` you need a connection string to the Azure Communication Services resource that you can get from the Azure Portal once you have created the resource. + +You can set `connectionString` based on an environment variable, a configuration setting, or any way that works for your application. + +```C# Snippet:CreatePhoneNumbersClient +// Get a connection string to our Azure Communication resource. +var connectionString = ""; +var client = new PhoneNumbersClient(connectionString); +``` + +## Search phone numbers + +Phone numbers need to be searched before they can be purchased. Search is a long running operation that can be started by `StartSearchAvailablePhoneNumbers` function that returns an `SearchAvailablePhoneNumbersOperation` object. `SearchAvailablePhoneNumbersOperation` can be used to update status of the operation and to check for completeness. + +```C# Snippet:SearchPhoneNumbersAsync +var capabilities = new PhoneNumberCapabilities(calling:PhoneNumberCapabilityType.None, sms:PhoneNumberCapabilityType.Outbound); + +var searchOperation = await client.StartSearchAvailablePhoneNumbersAsync(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Application, capabilities); +await searchOperation.WaitForCompletionAsync(); +``` + +## Purchase phone numbers + +Phone numbers can be acquired through purchasing a reservation. + +```C# Snippet:StartPurchaseSearchAsync +var purchaseOperation = await client.StartPurchasePhoneNumbersAsync(searchOperation.Value.SearchId); +await purchaseOperation.WaitForCompletionAsync(); +``` + +## Listing acquired phone numbers + +You can list all phone numbers that have been acquired for your resource. + +```C# Snippet:ListAcquiredPhoneNumbersAsync +var acquiredPhoneNumbers = client.GetPhoneNumbersAsync(); + +await foreach (var phoneNumber in acquiredPhoneNumbers) +{ + Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, monthly cost: {phoneNumber.Cost}"); +} +``` + +## Update phone number capabilities + +Phone number's capabilities can be updated by started by `StartUpdateCapabilities` function. + +```C# Snippet:UpdateCapabilitiesNumbersAsync +var updateCapabilitiesOperation = client.StartUpdateCapabilities(acquiredPhoneNumber, calling: PhoneNumberCapabilityType.Outbound, sms: PhoneNumberCapabilityType.InboundOutbound); + +await updateCapabilitiesOperation.WaitForCompletionAsync(); +``` + +## Release phone numbers + +If you no longer need a phone number you can release it. + +```C# Snippet:ReleasePhoneNumbersAsync +var acquiredPhoneNumber = ""; +var releaseOperation = client.StartReleasePhoneNumber(acquiredPhoneNumber); +await releaseOperation.WaitForCompletionAsync(); +``` diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Azure.Communication.PhoneNumbers.csproj b/sdk/communication/Azure.Communication.PhoneNumbers/src/Azure.Communication.PhoneNumbers.csproj index 1342563dec4ae..57a5af4431fad 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Azure.Communication.PhoneNumbers.csproj +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Azure.Communication.PhoneNumbers.csproj @@ -9,7 +9,6 @@ Microsoft Azure Communication Phone Numbers Service;Microsoft;Azure;Azure Communication Service;Azure Communication Phone Numbers Service;Phone Numbers;Communication;$(PackageCommonTags) $(RequiredTargetFrameworks) false - enable diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/ClientDiagnostics.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/ClientDiagnostics.cs new file mode 100644 index 0000000000000..f6db393bd197b --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/ClientDiagnostics.cs @@ -0,0 +1,61 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; + +namespace Azure.Core.Pipeline +{ + internal partial class ClientDiagnostics + { + /// + /// Partial method that can optionally be defined to extract the error + /// message, code, and details in a service specific manner. + /// + /// The error content. + /// The response headers. + /// The error message. + /// The error code. + /// Additional error details. +#pragma warning disable CA1822 // Mark members as static + partial void ExtractFailureContent( +#pragma warning restore CA1822 // Mark members as static + string content, +#pragma warning disable CA1801 // Review unused parameters + ResponseHeaders responseHeaders, + ref string message, + ref string errorCode, + ref IDictionary additionalInfo +#pragma warning restore CA1801 // Review unused parameters + ) + { + if (string.IsNullOrEmpty(content)) + { + return; + } + + try + { + using var document = JsonDocument.Parse(content); + + foreach (var property in document.RootElement.EnumerateObject()) + { + if (property.NameEquals("error")) + { + var communicationError = CommunicationError.DeserializeCommunicationError(property.Value); + errorCode = communicationError.Code; + message = communicationError.Message; + additionalInfo = new Dictionary() { ["target"] = communicationError.Target }; + break; + } + } + } + catch + { } + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersClient.cs new file mode 100644 index 0000000000000..4c2a72e626e2c --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersClient.cs @@ -0,0 +1,466 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Communication.PhoneNumbers; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The InternalPhoneNumbers service client. + internal partial class InternalPhoneNumbersClient + { + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + internal InternalPhoneNumbersRestClient RestClient { get; } + + /// Initializes a new instance of InternalPhoneNumbersClient for mocking. + protected InternalPhoneNumbersClient() + { + } + + /// Initializes a new instance of InternalPhoneNumbersClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The communication resource, for example https://resourcename.communication.azure.com. + /// Api Version. + internal InternalPhoneNumbersClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2021-03-07") + { + RestClient = new InternalPhoneNumbersRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + /// Gets a phone number search result by search id. + /// The search Id. + /// The cancellation token to use. + public virtual async Task> GetSearchResultAsync(string searchId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetSearchResult"); + scope.Start(); + try + { + return await RestClient.GetSearchResultAsync(searchId, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets a phone number search result by search id. + /// The search Id. + /// The cancellation token to use. + public virtual Response GetSearchResult(string searchId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetSearchResult"); + scope.Start(); + try + { + return RestClient.GetSearchResult(searchId, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + public virtual async Task> GetOperationAsync(string operationId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetOperation"); + scope.Start(); + try + { + return await RestClient.GetOperationAsync(operationId, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + public virtual Response GetOperation(string operationId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetOperation"); + scope.Start(); + try + { + return RestClient.GetOperation(operationId, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Cancels an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + public virtual async Task CancelOperationAsync(string operationId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.CancelOperation"); + scope.Start(); + try + { + return await RestClient.CancelOperationAsync(operationId, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Cancels an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + public virtual Response CancelOperation(string operationId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.CancelOperation"); + scope.Start(); + try + { + return RestClient.CancelOperation(operationId, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + public virtual async Task> GetByNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetByNumber"); + scope.Start(); + try + { + return await RestClient.GetByNumberAsync(phoneNumber, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + public virtual Response GetByNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.GetByNumber"); + scope.Start(); + try + { + return RestClient.GetByNumber(phoneNumber, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the list of all acquired phone numbers. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + public virtual AsyncPageable ListPhoneNumbersAsync(int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + async Task> FirstPageFunc(int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.ListPhoneNumbers"); + scope.Start(); + try + { + var response = await RestClient.ListPhoneNumbersAsync(skip, top, cancellationToken).ConfigureAwait(false); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + async Task> NextPageFunc(string nextLink, int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.ListPhoneNumbers"); + scope.Start(); + try + { + var response = await RestClient.ListPhoneNumbersNextPageAsync(nextLink, skip, top, cancellationToken).ConfigureAwait(false); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + return PageableHelpers.CreateAsyncEnumerable(FirstPageFunc, NextPageFunc); + } + + /// Gets the list of all acquired phone numbers. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + public virtual Pageable ListPhoneNumbers(int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + Page FirstPageFunc(int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.ListPhoneNumbers"); + scope.Start(); + try + { + var response = RestClient.ListPhoneNumbers(skip, top, cancellationToken); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + Page NextPageFunc(string nextLink, int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.ListPhoneNumbers"); + scope.Start(); + try + { + var response = RestClient.ListPhoneNumbersNextPage(nextLink, skip, top, cancellationToken); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + return PageableHelpers.CreateEnumerable(FirstPageFunc, NextPageFunc); + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The phone number search request. + /// The cancellation token to use. + /// or is null. + public virtual async Task StartSearchAvailablePhoneNumbersAsync(string countryCode, PhoneNumberSearchRequest body, CancellationToken cancellationToken = default) + { + if (countryCode == null) + { + throw new ArgumentNullException(nameof(countryCode)); + } + if (body == null) + { + throw new ArgumentNullException(nameof(body)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartSearchAvailablePhoneNumbers"); + scope.Start(); + try + { + var originalResponse = await RestClient.SearchAvailablePhoneNumbersAsync(countryCode, body, cancellationToken).ConfigureAwait(false); + return new SearchAvailablePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreateSearchAvailablePhoneNumbersRequest(countryCode, body).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The phone number search request. + /// The cancellation token to use. + /// or is null. + public virtual SearchAvailablePhoneNumbersOperation StartSearchAvailablePhoneNumbers(string countryCode, PhoneNumberSearchRequest body, CancellationToken cancellationToken = default) + { + if (countryCode == null) + { + throw new ArgumentNullException(nameof(countryCode)); + } + if (body == null) + { + throw new ArgumentNullException(nameof(body)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartSearchAvailablePhoneNumbers"); + scope.Start(); + try + { + var originalResponse = RestClient.SearchAvailablePhoneNumbers(countryCode, body, cancellationToken); + return new SearchAvailablePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreateSearchAvailablePhoneNumbersRequest(countryCode, body).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public virtual async Task StartPurchasePhoneNumbersAsync(string searchId = null, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartPurchasePhoneNumbers"); + scope.Start(); + try + { + var originalResponse = await RestClient.PurchasePhoneNumbersAsync(searchId, cancellationToken).ConfigureAwait(false); + return new PurchasePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreatePurchasePhoneNumbersRequest(searchId).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public virtual PurchasePhoneNumbersOperation StartPurchasePhoneNumbers(string searchId = null, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartPurchasePhoneNumbers"); + scope.Start(); + try + { + var originalResponse = RestClient.PurchasePhoneNumbers(searchId, cancellationToken); + return new PurchasePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreatePurchasePhoneNumbersRequest(searchId).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public virtual async Task StartReleasePhoneNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartReleasePhoneNumber"); + scope.Start(); + try + { + var originalResponse = await RestClient.ReleasePhoneNumberAsync(phoneNumber, cancellationToken).ConfigureAwait(false); + return new ReleasePhoneNumberOperation(_clientDiagnostics, _pipeline, RestClient.CreateReleasePhoneNumberRequest(phoneNumber).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public virtual ReleasePhoneNumberOperation StartReleasePhoneNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartReleasePhoneNumber"); + scope.Start(); + try + { + var originalResponse = RestClient.ReleasePhoneNumber(phoneNumber, cancellationToken); + return new ReleasePhoneNumberOperation(_clientDiagnostics, _pipeline, RestClient.CreateReleasePhoneNumberRequest(phoneNumber).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public virtual async Task StartUpdateCapabilitiesAsync(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartUpdateCapabilities"); + scope.Start(); + try + { + var originalResponse = await RestClient.UpdateCapabilitiesAsync(phoneNumber, calling, sms, cancellationToken).ConfigureAwait(false); + return new UpdatePhoneNumberCapabilitiesOperation(_clientDiagnostics, _pipeline, RestClient.CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public virtual UpdatePhoneNumberCapabilitiesOperation StartUpdateCapabilities(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var scope = _clientDiagnostics.CreateScope("InternalPhoneNumbersClient.StartUpdateCapabilities"); + scope.Start(); + try + { + var originalResponse = RestClient.UpdateCapabilities(phoneNumber, calling, sms, cancellationToken); + return new UpdatePhoneNumberCapabilitiesOperation(_clientDiagnostics, _pipeline, RestClient.CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersRestClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersRestClient.cs new file mode 100644 index 0000000000000..c0b92004ff83d --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/InternalPhoneNumbersRestClient.cs @@ -0,0 +1,722 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class InternalPhoneNumbersRestClient + { + private string endpoint; + private string apiVersion; + private ClientDiagnostics _clientDiagnostics; + private HttpPipeline _pipeline; + + /// Initializes a new instance of InternalPhoneNumbersRestClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The communication resource, for example https://resourcename.communication.azure.com. + /// Api Version. + /// or is null. + public InternalPhoneNumbersRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2021-03-07") + { + if (endpoint == null) + { + throw new ArgumentNullException(nameof(endpoint)); + } + if (apiVersion == null) + { + throw new ArgumentNullException(nameof(apiVersion)); + } + + this.endpoint = endpoint; + this.apiVersion = apiVersion; + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + internal HttpMessage CreateSearchAvailablePhoneNumbersRequest(string countryCode, PhoneNumberSearchRequest body) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/availablePhoneNumbers/countries/", false); + uri.AppendPath(countryCode, true); + uri.AppendPath("/:search", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(body); + request.Content = content; + return message; + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The phone number search request. + /// The cancellation token to use. + /// or is null. + public async Task> SearchAvailablePhoneNumbersAsync(string countryCode, PhoneNumberSearchRequest body, CancellationToken cancellationToken = default) + { + if (countryCode == null) + { + throw new ArgumentNullException(nameof(countryCode)); + } + if (body == null) + { + throw new ArgumentNullException(nameof(body)); + } + + using var message = CreateSearchAvailablePhoneNumbersRequest(countryCode, body); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + var headers = new PhoneNumbersSearchAvailablePhoneNumbersHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The phone number search request. + /// The cancellation token to use. + /// or is null. + public ResponseWithHeaders SearchAvailablePhoneNumbers(string countryCode, PhoneNumberSearchRequest body, CancellationToken cancellationToken = default) + { + if (countryCode == null) + { + throw new ArgumentNullException(nameof(countryCode)); + } + if (body == null) + { + throw new ArgumentNullException(nameof(body)); + } + + using var message = CreateSearchAvailablePhoneNumbersRequest(countryCode, body); + _pipeline.Send(message, cancellationToken); + var headers = new PhoneNumbersSearchAvailablePhoneNumbersHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetSearchResultRequest(string searchId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/availablePhoneNumbers/searchResults/", false); + uri.AppendPath(searchId, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Gets a phone number search result by search id. + /// The search Id. + /// The cancellation token to use. + /// is null. + public async Task> GetSearchResultAsync(string searchId, CancellationToken cancellationToken = default) + { + if (searchId == null) + { + throw new ArgumentNullException(nameof(searchId)); + } + + using var message = CreateGetSearchResultRequest(searchId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + PhoneNumberSearchResult value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = PhoneNumberSearchResult.DeserializePhoneNumberSearchResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Gets a phone number search result by search id. + /// The search Id. + /// The cancellation token to use. + /// is null. + public Response GetSearchResult(string searchId, CancellationToken cancellationToken = default) + { + if (searchId == null) + { + throw new ArgumentNullException(nameof(searchId)); + } + + using var message = CreateGetSearchResultRequest(searchId); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + PhoneNumberSearchResult value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = PhoneNumberSearchResult.DeserializePhoneNumberSearchResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreatePurchasePhoneNumbersRequest(string searchId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/availablePhoneNumbers/:purchase", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var model = new PhoneNumberPurchaseRequest() + { + SearchId = searchId + }; + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(model); + request.Content = content; + return message; + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public async Task> PurchasePhoneNumbersAsync(string searchId = null, CancellationToken cancellationToken = default) + { + using var message = CreatePurchasePhoneNumbersRequest(searchId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + var headers = new PhoneNumbersPurchasePhoneNumbersHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public ResponseWithHeaders PurchasePhoneNumbers(string searchId = null, CancellationToken cancellationToken = default) + { + using var message = CreatePurchasePhoneNumbersRequest(searchId); + _pipeline.Send(message, cancellationToken); + var headers = new PhoneNumbersPurchasePhoneNumbersHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetOperationRequest(string operationId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers/operations/", false); + uri.AppendPath(operationId, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Gets an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + /// is null. + public async Task> GetOperationAsync(string operationId, CancellationToken cancellationToken = default) + { + if (operationId == null) + { + throw new ArgumentNullException(nameof(operationId)); + } + + using var message = CreateGetOperationRequest(operationId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + var headers = new PhoneNumbersGetOperationHeaders(message.Response); + switch (message.Response.Status) + { + case 200: + { + PhoneNumberOperation value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = PhoneNumberOperation.DeserializePhoneNumberOperation(document.RootElement); + return ResponseWithHeaders.FromValue(value, headers, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Gets an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + /// is null. + public ResponseWithHeaders GetOperation(string operationId, CancellationToken cancellationToken = default) + { + if (operationId == null) + { + throw new ArgumentNullException(nameof(operationId)); + } + + using var message = CreateGetOperationRequest(operationId); + _pipeline.Send(message, cancellationToken); + var headers = new PhoneNumbersGetOperationHeaders(message.Response); + switch (message.Response.Status) + { + case 200: + { + PhoneNumberOperation value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = PhoneNumberOperation.DeserializePhoneNumberOperation(document.RootElement); + return ResponseWithHeaders.FromValue(value, headers, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateCancelOperationRequest(string operationId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers/operations/", false); + uri.AppendPath(operationId, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Cancels an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + /// is null. + public async Task CancelOperationAsync(string operationId, CancellationToken cancellationToken = default) + { + if (operationId == null) + { + throw new ArgumentNullException(nameof(operationId)); + } + + using var message = CreateCancelOperationRequest(operationId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 204: + return message.Response; + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Cancels an operation by its id. + /// The id of the operation. + /// The cancellation token to use. + /// is null. + public Response CancelOperation(string operationId, CancellationToken cancellationToken = default) + { + if (operationId == null) + { + throw new ArgumentNullException(nameof(operationId)); + } + + using var message = CreateCancelOperationRequest(operationId); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 204: + return message.Response; + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateGetByNumberRequest(string phoneNumber) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers/", false); + uri.AppendPath(phoneNumber, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public async Task> GetByNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateGetByNumberRequest(phoneNumber); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumber value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = AcquiredPhoneNumber.DeserializeAcquiredPhoneNumber(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public Response GetByNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateGetByNumberRequest(phoneNumber); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumber value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = AcquiredPhoneNumber.DeserializeAcquiredPhoneNumber(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateReleasePhoneNumberRequest(string phoneNumber) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers/", false); + uri.AppendPath(phoneNumber, true); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public async Task> ReleasePhoneNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateReleasePhoneNumberRequest(phoneNumber); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + var headers = new PhoneNumbersReleasePhoneNumberHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public ResponseWithHeaders ReleasePhoneNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateReleasePhoneNumberRequest(phoneNumber); + _pipeline.Send(message, cancellationToken); + var headers = new PhoneNumbersReleasePhoneNumberHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateListPhoneNumbersRequest(int? skip, int? top) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers", false); + if (skip != null) + { + uri.AppendQuery("skip", skip.Value, true); + } + if (top != null) + { + uri.AppendQuery("top", top.Value, true); + } + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Gets the list of all acquired phone numbers. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + public async Task> ListPhoneNumbersAsync(int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + using var message = CreateListPhoneNumbersRequest(skip, top); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumbers value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Gets the list of all acquired phone numbers. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + public Response ListPhoneNumbers(int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + using var message = CreateListPhoneNumbersRequest(skip, top); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumbers value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateUpdateCapabilitiesRequest(string phoneNumber, PhoneNumberCapabilityType? calling, PhoneNumberCapabilityType? sms) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Patch; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendPath("/phoneNumbers/", false); + uri.AppendPath(phoneNumber, true); + uri.AppendPath("/capabilities", false); + uri.AppendQuery("api-version", apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/merge-patch+json"); + var model = new PhoneNumberCapabilitiesRequest() + { + Calling = calling, + Sms = sms + }; + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(model); + request.Content = content; + return message; + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public async Task> UpdateCapabilitiesAsync(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + var headers = new PhoneNumbersUpdateCapabilitiesHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public ResponseWithHeaders UpdateCapabilities(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + if (phoneNumber == null) + { + throw new ArgumentNullException(nameof(phoneNumber)); + } + + using var message = CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms); + _pipeline.Send(message, cancellationToken); + var headers = new PhoneNumbersUpdateCapabilitiesHeaders(message.Response); + switch (message.Response.Status) + { + case 202: + return ResponseWithHeaders.FromValue(headers, message.Response); + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + + internal HttpMessage CreateListPhoneNumbersNextPageRequest(string nextLink, int? skip, int? top) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.AppendRaw(endpoint, false); + uri.AppendRawNextLink(nextLink, false); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + return message; + } + + /// Gets the list of all acquired phone numbers. + /// The URL to the next page of results. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + /// is null. + public async Task> ListPhoneNumbersNextPageAsync(string nextLink, int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + if (nextLink == null) + { + throw new ArgumentNullException(nameof(nextLink)); + } + + using var message = CreateListPhoneNumbersNextPageRequest(nextLink, skip, top); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumbers value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); + value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); + } + } + + /// Gets the list of all acquired phone numbers. + /// The URL to the next page of results. + /// An optional parameter for how many entries to skip, for pagination purposes. The default value is 0. + /// An optional parameter for how many entries to return, for pagination purposes. The default value is 100. + /// The cancellation token to use. + /// is null. + public Response ListPhoneNumbersNextPage(string nextLink, int? skip = null, int? top = null, CancellationToken cancellationToken = default) + { + if (nextLink == null) + { + throw new ArgumentNullException(nameof(nextLink)); + } + + using var message = CreateListPhoneNumbersNextPageRequest(nextLink, skip, top); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + AcquiredPhoneNumbers value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream); + value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw _clientDiagnostics.CreateRequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.Serialization.cs index d9a8198f8ff3d..6653c0f86deaa 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.Serialization.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.Serialization.cs @@ -5,7 +5,7 @@ #nullable disable -using System.Collections.Generic; +using System; using System.Text.Json; using Azure.Core; @@ -15,66 +15,58 @@ public partial class AcquiredPhoneNumber { internal static AcquiredPhoneNumber DeserializeAcquiredPhoneNumber(JsonElement element) { + string id = default; string phoneNumber = default; - IReadOnlyList acquiredCapabilities = default; - IReadOnlyList availableCapabilities = default; - Optional assignmentStatus = default; - Optional placeName = default; - Optional activationState = default; + string countryCode = default; + PhoneNumberType phoneNumberType = default; + PhoneNumberCapabilities capabilities = default; + PhoneNumberAssignmentType assignmentType = default; + DateTimeOffset purchaseDate = default; + PhoneNumberCost cost = default; foreach (var property in element.EnumerateObject()) { + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } if (property.NameEquals("phoneNumber")) { phoneNumber = property.Value.GetString(); continue; } - if (property.NameEquals("acquiredCapabilities")) + if (property.NameEquals("countryCode")) + { + countryCode = property.Value.GetString(); + continue; + } + if (property.NameEquals("phoneNumberType")) { - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(new PhoneNumberCapability(item.GetString())); - } - acquiredCapabilities = array; + phoneNumberType = new PhoneNumberType(property.Value.GetString()); continue; } - if (property.NameEquals("availableCapabilities")) + if (property.NameEquals("capabilities")) { - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(new PhoneNumberCapability(item.GetString())); - } - availableCapabilities = array; + capabilities = PhoneNumberCapabilities.DeserializePhoneNumberCapabilities(property.Value); continue; } - if (property.NameEquals("assignmentStatus")) + if (property.NameEquals("assignmentType")) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - assignmentStatus = new AssignmentStatus(property.Value.GetString()); + assignmentType = new PhoneNumberAssignmentType(property.Value.GetString()); continue; } - if (property.NameEquals("placeName")) + if (property.NameEquals("purchaseDate")) { - placeName = property.Value.GetString(); + purchaseDate = property.Value.GetDateTimeOffset("O"); continue; } - if (property.NameEquals("activationState")) + if (property.NameEquals("cost")) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - activationState = new ActivationState(property.Value.GetString()); + cost = PhoneNumberCost.DeserializePhoneNumberCost(property.Value); continue; } } - return new AcquiredPhoneNumber(phoneNumber, acquiredCapabilities, availableCapabilities, Optional.ToNullable(assignmentStatus), placeName.Value, Optional.ToNullable(activationState)); + return new AcquiredPhoneNumber(id, phoneNumber, countryCode, phoneNumberType, capabilities, assignmentType, purchaseDate, cost); } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.cs index 11e211fa08cb7..2ce3199bbad20 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumber.cs @@ -6,8 +6,6 @@ #nullable disable using System; -using System.Collections.Generic; -using System.Linq; namespace Azure.Communication.PhoneNumbers.Models { @@ -15,58 +13,63 @@ namespace Azure.Communication.PhoneNumbers.Models public partial class AcquiredPhoneNumber { /// Initializes a new instance of AcquiredPhoneNumber. - /// String of the E.164 format of the phone number. - /// The set of all acquired capabilities of the phone number. - /// The set of all available capabilities that can be acquired for this phone number. - /// , , or is null. - internal AcquiredPhoneNumber(string phoneNumber, IEnumerable acquiredCapabilities, IEnumerable availableCapabilities) + /// The id of the phone number, e.g. 11234567890. + /// String of the E.164 format of the phone number, e.g. +11234567890. + /// The ISO 3166-2 code of the phone number's country, e.g. US. + /// The phone number's type, e.g. Geographic, TollFree. + /// Capabilities of a phone number. + /// The assignment type of the phone number. A phone number can be assigned to a person, or to an application. + /// The date and time that the phone number was purchased. + /// The incurred cost for a single phone number. + /// , , , , or is null. + internal AcquiredPhoneNumber(string id, string phoneNumber, string countryCode, PhoneNumberType phoneNumberType, PhoneNumberCapabilities capabilities, PhoneNumberAssignmentType assignmentType, DateTimeOffset purchaseDate, PhoneNumberCost cost) { + if (id == null) + { + throw new ArgumentNullException(nameof(id)); + } if (phoneNumber == null) { throw new ArgumentNullException(nameof(phoneNumber)); } - if (acquiredCapabilities == null) + if (countryCode == null) { - throw new ArgumentNullException(nameof(acquiredCapabilities)); + throw new ArgumentNullException(nameof(countryCode)); } - if (availableCapabilities == null) + if (capabilities == null) { - throw new ArgumentNullException(nameof(availableCapabilities)); + throw new ArgumentNullException(nameof(capabilities)); + } + if (cost == null) + { + throw new ArgumentNullException(nameof(cost)); } + Id = id; PhoneNumber = phoneNumber; - AcquiredCapabilities = acquiredCapabilities.ToList(); - AvailableCapabilities = availableCapabilities.ToList(); - } - - /// Initializes a new instance of AcquiredPhoneNumber. - /// String of the E.164 format of the phone number. - /// The set of all acquired capabilities of the phone number. - /// The set of all available capabilities that can be acquired for this phone number. - /// The assignment status of the phone number. Conveys what type of entity the number is assigned to. - /// The name of the place of the phone number. - /// The activation state of the phone number. Can be "Activated", "AssignmentPending", "AssignmentFailed", "UpdatePending", "UpdateFailed". - internal AcquiredPhoneNumber(string phoneNumber, IReadOnlyList acquiredCapabilities, IReadOnlyList availableCapabilities, AssignmentStatus? assignmentStatus, string placeName, ActivationState? activationState) - { - PhoneNumber = phoneNumber; - AcquiredCapabilities = acquiredCapabilities; - AvailableCapabilities = availableCapabilities; - AssignmentStatus = assignmentStatus; - PlaceName = placeName; - ActivationState = activationState; + CountryCode = countryCode; + PhoneNumberType = phoneNumberType; + Capabilities = capabilities; + AssignmentType = assignmentType; + PurchaseDate = purchaseDate; + Cost = cost; } - /// String of the E.164 format of the phone number. + /// The id of the phone number, e.g. 11234567890. + public string Id { get; } + /// String of the E.164 format of the phone number, e.g. +11234567890. public string PhoneNumber { get; } - /// The set of all acquired capabilities of the phone number. - public IReadOnlyList AcquiredCapabilities { get; } - /// The set of all available capabilities that can be acquired for this phone number. - public IReadOnlyList AvailableCapabilities { get; } - /// The assignment status of the phone number. Conveys what type of entity the number is assigned to. - public AssignmentStatus? AssignmentStatus { get; } - /// The name of the place of the phone number. - public string PlaceName { get; } - /// The activation state of the phone number. Can be "Activated", "AssignmentPending", "AssignmentFailed", "UpdatePending", "UpdateFailed". - public ActivationState? ActivationState { get; } + /// The ISO 3166-2 code of the phone number's country, e.g. US. + public string CountryCode { get; } + /// The phone number's type, e.g. Geographic, TollFree. + public PhoneNumberType PhoneNumberType { get; } + /// Capabilities of a phone number. + public PhoneNumberCapabilities Capabilities { get; } + /// The assignment type of the phone number. A phone number can be assigned to a person, or to an application. + public PhoneNumberAssignmentType AssignmentType { get; } + /// The date and time that the phone number was purchased. + public DateTimeOffset PurchaseDate { get; } + /// The incurred cost for a single phone number. + public PhoneNumberCost Cost { get; } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.Serialization.cs index aca7e262eb8f1..5453ba4acc320 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.Serialization.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.Serialization.cs @@ -15,17 +15,12 @@ internal partial class AcquiredPhoneNumbers { internal static AcquiredPhoneNumbers DeserializeAcquiredPhoneNumbers(JsonElement element) { - Optional> phoneNumbers = default; + IReadOnlyList phoneNumbers = default; Optional nextLink = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("phoneNumbers")) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -40,7 +35,7 @@ internal static AcquiredPhoneNumbers DeserializeAcquiredPhoneNumbers(JsonElement continue; } } - return new AcquiredPhoneNumbers(Optional.ToList(phoneNumbers), nextLink.Value); + return new AcquiredPhoneNumbers(phoneNumbers, nextLink.Value); } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.cs index b90e5f6f88187..61d0b7152ff3a 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AcquiredPhoneNumbers.cs @@ -5,23 +5,31 @@ #nullable disable +using System; using System.Collections.Generic; -using Azure.Core; +using System.Linq; namespace Azure.Communication.PhoneNumbers.Models { - /// A wrapper of list of phone numbers. + /// The list of acquired phone numbers. internal partial class AcquiredPhoneNumbers { /// Initializes a new instance of AcquiredPhoneNumbers. - internal AcquiredPhoneNumbers() + /// Represents a list of phone numbers. + /// is null. + internal AcquiredPhoneNumbers(IEnumerable phoneNumbers) { - PhoneNumbers = new ChangeTrackingList(); + if (phoneNumbers == null) + { + throw new ArgumentNullException(nameof(phoneNumbers)); + } + + PhoneNumbers = phoneNumbers.ToList(); } /// Initializes a new instance of AcquiredPhoneNumbers. /// Represents a list of phone numbers. - /// Represents the URL link to the next page. + /// Represents the URL link to the next page of phone number results. internal AcquiredPhoneNumbers(IReadOnlyList phoneNumbers, string nextLink) { PhoneNumbers = phoneNumbers; @@ -30,7 +38,7 @@ internal AcquiredPhoneNumbers(IReadOnlyList phoneNumbers, s /// Represents a list of phone numbers. public IReadOnlyList PhoneNumbers { get; } - /// Represents the URL link to the next page. + /// Represents the URL link to the next page of phone number results. public string NextLink { get; } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ActivationState.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ActivationState.cs deleted file mode 100644 index 8f3bdc93528ba..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ActivationState.cs +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The activation state of the phone number. Can be "Activated", "AssignmentPending", "AssignmentFailed", "UpdatePending", "UpdateFailed". - public readonly partial struct ActivationState : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public ActivationState(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string ActivatedValue = "Activated"; - private const string AssignmentPendingValue = "AssignmentPending"; - private const string AssignmentFailedValue = "AssignmentFailed"; - private const string UpdatePendingValue = "UpdatePending"; - private const string UpdateFailedValue = "UpdateFailed"; - - /// Activated. - public static ActivationState Activated { get; } = new ActivationState(ActivatedValue); - /// AssignmentPending. - public static ActivationState AssignmentPending { get; } = new ActivationState(AssignmentPendingValue); - /// AssignmentFailed. - public static ActivationState AssignmentFailed { get; } = new ActivationState(AssignmentFailedValue); - /// UpdatePending. - public static ActivationState UpdatePending { get; } = new ActivationState(UpdatePendingValue); - /// UpdateFailed. - public static ActivationState UpdateFailed { get; } = new ActivationState(UpdateFailedValue); - /// Determines if two values are the same. - public static bool operator ==(ActivationState left, ActivationState right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(ActivationState left, ActivationState right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator ActivationState(string value) => new ActivationState(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is ActivationState other && Equals(other); - /// - public bool Equals(ActivationState other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.Serialization.cs deleted file mode 100644 index bfbd528e54294..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.Serialization.cs +++ /dev/null @@ -1,62 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class AreaCodes - { - internal static AreaCodes DeserializeAreaCodes(JsonElement element) - { - Optional> primaryAreaCodes = default; - Optional> secondaryAreaCodes = default; - Optional nextLink = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("primaryAreaCodes")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(item.GetString()); - } - primaryAreaCodes = array; - continue; - } - if (property.NameEquals("secondaryAreaCodes")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(item.GetString()); - } - secondaryAreaCodes = array; - continue; - } - if (property.NameEquals("nextLink")) - { - nextLink = property.Value.GetString(); - continue; - } - } - return new AreaCodes(Optional.ToList(primaryAreaCodes), Optional.ToList(secondaryAreaCodes), nextLink.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.cs deleted file mode 100644 index 2523bea730813..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AreaCodes.cs +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a list of area codes. - public partial class AreaCodes - { - /// Initializes a new instance of AreaCodes. - internal AreaCodes() - { - PrimaryAreaCodes = new ChangeTrackingList(); - SecondaryAreaCodes = new ChangeTrackingList(); - } - - /// Initializes a new instance of AreaCodes. - /// Represents the list of primary area codes. - /// Represents the list of secondary area codes. - /// Represents the URL link to the next page. - internal AreaCodes(IReadOnlyList primaryAreaCodes, IReadOnlyList secondaryAreaCodes, string nextLink) - { - PrimaryAreaCodes = primaryAreaCodes; - SecondaryAreaCodes = secondaryAreaCodes; - NextLink = nextLink; - } - - /// Represents the list of primary area codes. - public IReadOnlyList PrimaryAreaCodes { get; } - /// Represents the list of secondary area codes. - public IReadOnlyList SecondaryAreaCodes { get; } - /// Represents the URL link to the next page. - public string NextLink { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AssignmentStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AssignmentStatus.cs deleted file mode 100644 index fb7a58645246e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/AssignmentStatus.cs +++ /dev/null @@ -1,63 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The assignment status of the phone number. Conveys what type of entity the number is assigned to. - public readonly partial struct AssignmentStatus : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public AssignmentStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string UnassignedValue = "Unassigned"; - private const string UnknownValue = "Unknown"; - private const string UserAssignedValue = "UserAssigned"; - private const string ConferenceAssignedValue = "ConferenceAssigned"; - private const string FirstPartyAppAssignedValue = "FirstPartyAppAssigned"; - private const string ThirdPartyAppAssignedValue = "ThirdPartyAppAssigned"; - - /// Unassigned. - public static AssignmentStatus Unassigned { get; } = new AssignmentStatus(UnassignedValue); - /// Unknown. - public static AssignmentStatus Unknown { get; } = new AssignmentStatus(UnknownValue); - /// UserAssigned. - public static AssignmentStatus UserAssigned { get; } = new AssignmentStatus(UserAssignedValue); - /// ConferenceAssigned. - public static AssignmentStatus ConferenceAssigned { get; } = new AssignmentStatus(ConferenceAssignedValue); - /// FirstPartyAppAssigned. - public static AssignmentStatus FirstPartyAppAssigned { get; } = new AssignmentStatus(FirstPartyAppAssignedValue); - /// ThirdPartyAppAssigned. - public static AssignmentStatus ThirdPartyAppAssigned { get; } = new AssignmentStatus(ThirdPartyAppAssignedValue); - /// Determines if two values are the same. - public static bool operator ==(AssignmentStatus left, AssignmentStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(AssignmentStatus left, AssignmentStatus right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator AssignmentStatus(string value) => new AssignmentStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is AssignmentStatus other && Equals(other); - /// - public bool Equals(AssignmentStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/BillingFrequency.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/BillingFrequency.cs new file mode 100644 index 0000000000000..5ce74749b1cc8 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/BillingFrequency.cs @@ -0,0 +1,48 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The frequency with which the cost gets billed. + public readonly partial struct BillingFrequency : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public BillingFrequency(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string MonthlyValue = "monthly"; + + /// monthly. + public static BillingFrequency Monthly { get; } = new BillingFrequency(MonthlyValue); + /// Determines if two values are the same. + public static bool operator ==(BillingFrequency left, BillingFrequency right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(BillingFrequency left, BillingFrequency right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator BillingFrequency(string value) => new BillingFrequency(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is BillingFrequency other && Equals(other); + /// + public bool Equals(BillingFrequency other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CapabilitiesUpdateStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CapabilitiesUpdateStatus.cs deleted file mode 100644 index 1a317b4cc0126..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CapabilitiesUpdateStatus.cs +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Status of the capabilities update. - public readonly partial struct CapabilitiesUpdateStatus : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public CapabilitiesUpdateStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string PendingValue = "Pending"; - private const string InProgressValue = "InProgress"; - private const string CompleteValue = "Complete"; - private const string ErrorValue = "Error"; - - /// Pending. - public static CapabilitiesUpdateStatus Pending { get; } = new CapabilitiesUpdateStatus(PendingValue); - /// InProgress. - public static CapabilitiesUpdateStatus InProgress { get; } = new CapabilitiesUpdateStatus(InProgressValue); - /// Complete. - public static CapabilitiesUpdateStatus Complete { get; } = new CapabilitiesUpdateStatus(CompleteValue); - /// Error. - public static CapabilitiesUpdateStatus Error { get; } = new CapabilitiesUpdateStatus(ErrorValue); - /// Determines if two values are the same. - public static bool operator ==(CapabilitiesUpdateStatus left, CapabilitiesUpdateStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(CapabilitiesUpdateStatus left, CapabilitiesUpdateStatus right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator CapabilitiesUpdateStatus(string value) => new CapabilitiesUpdateStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is CapabilitiesUpdateStatus other && Equals(other); - /// - public bool Equals(CapabilitiesUpdateStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.Serialization.cs deleted file mode 100644 index 2fbfdf9250075..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.Serialization.cs +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class CarrierDetails - { - internal static CarrierDetails DeserializeCarrierDetails(JsonElement element) - { - Optional name = default; - Optional localizedName = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("name")) - { - name = property.Value.GetString(); - continue; - } - if (property.NameEquals("localizedName")) - { - localizedName = property.Value.GetString(); - continue; - } - } - return new CarrierDetails(name.Value, localizedName.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.cs deleted file mode 100644 index f6e7682c8d575..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CarrierDetails.cs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents carrier details. - public partial class CarrierDetails - { - /// Initializes a new instance of CarrierDetails. - internal CarrierDetails() - { - } - - /// Initializes a new instance of CarrierDetails. - /// Name of carrier details. - /// Display name of carrier details. - internal CarrierDetails(string name, string localizedName) - { - Name = name; - LocalizedName = localizedName; - } - - /// Name of carrier details. - public string Name { get; } - /// Display name of carrier details. - public string LocalizedName { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.Serialization.cs new file mode 100644 index 0000000000000..399943e9ba7cc --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.Serialization.cs @@ -0,0 +1,69 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + internal partial class CommunicationError + { + internal static CommunicationError DeserializeCommunicationError(JsonElement element) + { + string code = default; + string message = default; + Optional target = default; + Optional> details = default; + Optional innererror = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("code")) + { + code = property.Value.GetString(); + continue; + } + if (property.NameEquals("message")) + { + message = property.Value.GetString(); + continue; + } + if (property.NameEquals("target")) + { + target = property.Value.GetString(); + continue; + } + if (property.NameEquals("details")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(DeserializeCommunicationError(item)); + } + details = array; + continue; + } + if (property.NameEquals("innererror")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + innererror = DeserializeCommunicationError(property.Value); + continue; + } + } + return new CommunicationError(code, message, target.Value, Optional.ToList(details), innererror.Value); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.cs new file mode 100644 index 0000000000000..05065b04f99ca --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationError.cs @@ -0,0 +1,63 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The Communication Services error. + internal partial class CommunicationError + { + /// Initializes a new instance of CommunicationError. + /// The error code. + /// The error message. + /// or is null. + internal CommunicationError(string code, string message) + { + if (code == null) + { + throw new ArgumentNullException(nameof(code)); + } + if (message == null) + { + throw new ArgumentNullException(nameof(message)); + } + + Code = code; + Message = message; + Details = new ChangeTrackingList(); + } + + /// Initializes a new instance of CommunicationError. + /// The error code. + /// The error message. + /// The error target. + /// Further details about specific errors that led to this error. + /// The inner error if any. + internal CommunicationError(string code, string message, string target, IReadOnlyList details, CommunicationError innerError) + { + Code = code; + Message = message; + Target = target; + Details = details; + InnerError = innerError; + } + + /// The error code. + public string Code { get; } + /// The error message. + public string Message { get; } + /// The error target. + public string Target { get; } + /// Further details about specific errors that led to this error. + public IReadOnlyList Details { get; } + /// The inner error if any. + public CommunicationError InnerError { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.Serialization.cs similarity index 50% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.Serialization.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.Serialization.cs index 9c2415e84cd27..9a317bf83ab65 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.Serialization.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.Serialization.cs @@ -10,20 +10,20 @@ namespace Azure.Communication.PhoneNumbers.Models { - internal partial class CreateReservationResponse + internal partial class CommunicationErrorResponse { - internal static CreateReservationResponse DeserializeCreateReservationResponse(JsonElement element) + internal static CommunicationErrorResponse DeserializeCommunicationErrorResponse(JsonElement element) { - string searchId = default; + CommunicationError error = default; foreach (var property in element.EnumerateObject()) { - if (property.NameEquals("searchId")) + if (property.NameEquals("error")) { - searchId = property.Value.GetString(); + error = CommunicationError.DeserializeCommunicationError(property.Value); continue; } } - return new CreateReservationResponse(searchId); + return new CommunicationErrorResponse(error); } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.cs new file mode 100644 index 0000000000000..ca83e46ef67a1 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CommunicationErrorResponse.cs @@ -0,0 +1,31 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The Communication Services error. + internal partial class CommunicationErrorResponse + { + /// Initializes a new instance of CommunicationErrorResponse. + /// The Communication Services error. + /// is null. + internal CommunicationErrorResponse(CommunicationError error) + { + if (error == null) + { + throw new ArgumentNullException(nameof(error)); + } + + Error = error; + } + + /// The Communication Services error. + public CommunicationError Error { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.Serialization.cs deleted file mode 100644 index a664daab777ba..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.Serialization.cs +++ /dev/null @@ -1,49 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class CreateReservationOptions : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - writer.WritePropertyName("displayName"); - writer.WriteStringValue(DisplayName); - writer.WritePropertyName("description"); - writer.WriteStringValue(Description); - writer.WritePropertyName("phonePlanIds"); - writer.WriteStartArray(); - foreach (var item in PhonePlanIds) - { - writer.WriteStringValue(item); - } - writer.WriteEndArray(); - writer.WritePropertyName("areaCode"); - writer.WriteStringValue(AreaCode); - if (Optional.IsDefined(Quantity)) - { - writer.WritePropertyName("quantity"); - writer.WriteNumberValue(Quantity.Value); - } - if (Optional.IsCollectionDefined(LocationOptions)) - { - writer.WritePropertyName("locationOptions"); - writer.WriteStartArray(); - foreach (var item in LocationOptions) - { - writer.WriteObjectValue(item); - } - writer.WriteEndArray(); - } - writer.WriteEndObject(); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.cs deleted file mode 100644 index c1bb50e6a8c23..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationOptions.cs +++ /dev/null @@ -1,63 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Linq; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a search creation option. - public partial class CreateReservationOptions - { - /// Initializes a new instance of CreateReservationOptions. - /// Display name of the search. - /// Description of the search. - /// The plan subtype ids from which to create the search. - /// The area code from which to create the search. - /// , , , or is null. - public CreateReservationOptions(string displayName, string description, IEnumerable phonePlanIds, string areaCode) - { - if (displayName == null) - { - throw new ArgumentNullException(nameof(displayName)); - } - if (description == null) - { - throw new ArgumentNullException(nameof(description)); - } - if (phonePlanIds == null) - { - throw new ArgumentNullException(nameof(phonePlanIds)); - } - if (areaCode == null) - { - throw new ArgumentNullException(nameof(areaCode)); - } - - DisplayName = displayName; - Description = description; - PhonePlanIds = phonePlanIds.ToList(); - AreaCode = areaCode; - LocationOptions = new ChangeTrackingList(); - } - - /// Display name of the search. - public string DisplayName { get; } - /// Description of the search. - public string Description { get; } - /// The plan subtype ids from which to create the search. - public IList PhonePlanIds { get; } - /// The area code from which to create the search. - public string AreaCode { get; } - /// The quantity of phone numbers to request. - public int? Quantity { get; set; } - /// The location options of the search. - public IList LocationOptions { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.cs deleted file mode 100644 index b704ca266232d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CreateReservationResponse.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a search creation response. - internal partial class CreateReservationResponse - { - /// Initializes a new instance of CreateReservationResponse. - /// The search id of the search that was created. - /// is null. - internal CreateReservationResponse(string reservationId) - { - if (reservationId == null) - { - throw new ArgumentNullException(nameof(reservationId)); - } - - ReservationId = reservationId; - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CurrencyType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CurrencyType.cs deleted file mode 100644 index e376795b02124..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/CurrencyType.cs +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The currency of a phone plan group. - public readonly partial struct CurrencyType : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public CurrencyType(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string USDValue = "USD"; - - /// USD. - public static CurrencyType USD { get; } = new CurrencyType(USDValue); - /// Determines if two values are the same. - public static bool operator ==(CurrencyType left, CurrencyType right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(CurrencyType left, CurrencyType right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator CurrencyType(string value) => new CurrencyType(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is CurrencyType other && Equals(other); - /// - public bool Equals(CurrencyType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.Serialization.cs deleted file mode 100644 index bfdf70d675a41..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.Serialization.cs +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class ErrorBody - { - internal static ErrorBody DeserializeErrorBody(JsonElement element) - { - Optional code = default; - Optional message = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("code")) - { - code = property.Value.GetString(); - continue; - } - if (property.NameEquals("message")) - { - message = property.Value.GetString(); - continue; - } - } - return new ErrorBody(code.Value, message.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.cs deleted file mode 100644 index b25f65f40432a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorBody.cs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a service error response body. - internal partial class ErrorBody - { - /// Initializes a new instance of ErrorBody. - internal ErrorBody() - { - } - - /// Initializes a new instance of ErrorBody. - /// The error code in the error response. - /// The error message in the error response. - internal ErrorBody(string code, string message) - { - Code = code; - Message = message; - } - - /// The error code in the error response. - public string Code { get; } - /// The error message in the error response. - public string Message { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.Serialization.cs deleted file mode 100644 index e3b155bdce71a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.Serialization.cs +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class ErrorResponse - { - internal static ErrorResponse DeserializeErrorResponse(JsonElement element) - { - Optional error = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("error")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - error = ErrorBody.DeserializeErrorBody(property.Value); - continue; - } - } - return new ErrorResponse(error.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.cs deleted file mode 100644 index 671912c7af010..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ErrorResponse.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a service error response. - internal partial class ErrorResponse - { - /// Initializes a new instance of ErrorResponse. - internal ErrorResponse() - { - } - - /// Initializes a new instance of ErrorResponse. - /// Represents a service error response body. - internal ErrorResponse(ErrorBody error) - { - Error = error; - } - - /// Represents a service error response body. - public ErrorBody Error { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.Serialization.cs deleted file mode 100644 index 49f080f27adb3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.Serialization.cs +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class LocationOptions : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - if (Optional.IsDefined(LabelId)) - { - writer.WritePropertyName("labelId"); - writer.WriteStringValue(LabelId); - } - if (Optional.IsDefined(LabelName)) - { - writer.WritePropertyName("labelName"); - writer.WriteStringValue(LabelName); - } - if (Optional.IsCollectionDefined(Options)) - { - writer.WritePropertyName("options"); - writer.WriteStartArray(); - foreach (var item in Options) - { - writer.WriteObjectValue(item); - } - writer.WriteEndArray(); - } - writer.WriteEndObject(); - } - - internal static LocationOptions DeserializeLocationOptions(JsonElement element) - { - Optional labelId = default; - Optional labelName = default; - Optional> options = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("labelId")) - { - labelId = property.Value.GetString(); - continue; - } - if (property.NameEquals("labelName")) - { - labelName = property.Value.GetString(); - continue; - } - if (property.NameEquals("options")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(LocationOptionsDetails.DeserializeLocationOptionsDetails(item)); - } - options = array; - continue; - } - } - return new LocationOptions(labelId.Value, labelName.Value, Optional.ToList(options)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.cs deleted file mode 100644 index eb67908bbe733..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptions.cs +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a location options. - public partial class LocationOptions - { - /// Initializes a new instance of LocationOptions. - public LocationOptions() - { - Options = new ChangeTrackingList(); - } - - /// Initializes a new instance of LocationOptions. - /// The label id of the location. - /// The display name of the location. - /// The underlying location option details. - internal LocationOptions(string labelId, string labelName, IList options) - { - LabelId = labelId; - LabelName = labelName; - Options = options; - } - - /// The label id of the location. - public string LabelId { get; set; } - /// The display name of the location. - public string LabelName { get; set; } - /// The underlying location option details. - public IList Options { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.Serialization.cs deleted file mode 100644 index 4d99f9a45ec48..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.Serialization.cs +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class LocationOptionsDetails : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - if (Optional.IsDefined(Name)) - { - writer.WritePropertyName("name"); - writer.WriteStringValue(Name); - } - if (Optional.IsDefined(Value)) - { - writer.WritePropertyName("value"); - writer.WriteStringValue(Value); - } - if (Optional.IsCollectionDefined(LocationOptions)) - { - writer.WritePropertyName("locationOptions"); - writer.WriteStartArray(); - foreach (var item in LocationOptions) - { - writer.WriteObjectValue(item); - } - writer.WriteEndArray(); - } - writer.WriteEndObject(); - } - - internal static LocationOptionsDetails DeserializeLocationOptionsDetails(JsonElement element) - { - Optional name = default; - Optional value = default; - Optional> locationOptions = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("name")) - { - name = property.Value.GetString(); - continue; - } - if (property.NameEquals("value")) - { - value = property.Value.GetString(); - continue; - } - if (property.NameEquals("locationOptions")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(Models.LocationOptions.DeserializeLocationOptions(item)); - } - locationOptions = array; - continue; - } - } - return new LocationOptionsDetails(name.Value, value.Value, Optional.ToList(locationOptions)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.cs deleted file mode 100644 index 13e0da7753328..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsDetails.cs +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents location options details. - public partial class LocationOptionsDetails - { - /// Initializes a new instance of LocationOptionsDetails. - public LocationOptionsDetails() - { - LocationOptions = new ChangeTrackingList(); - } - - /// Initializes a new instance of LocationOptionsDetails. - /// The name of the location options. - /// The abbreviated name of the location options. - /// The underlying location options. - internal LocationOptionsDetails(string name, string value, IList locationOptions) - { - Name = name; - Value = value; - LocationOptions = locationOptions; - } - - /// The name of the location options. - public string Name { get; set; } - /// The abbreviated name of the location options. - public string Value { get; set; } - /// The underlying location options. - public IList LocationOptions { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.Serialization.cs deleted file mode 100644 index 5b729dad4f577..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.Serialization.cs +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class LocationOptionsQueries : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - if (Optional.IsCollectionDefined(LocationOptions)) - { - writer.WritePropertyName("locationOptions"); - writer.WriteStartArray(); - foreach (var item in LocationOptions) - { - writer.WriteObjectValue(item); - } - writer.WriteEndArray(); - } - writer.WriteEndObject(); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.cs deleted file mode 100644 index 43bc8af39e639..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQueries.cs +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a list of location option queries, used for fetching area codes. - internal partial class LocationOptionsQueries - { - /// Initializes a new instance of LocationOptionsQueries. - public LocationOptionsQueries() - { - LocationOptions = new ChangeTrackingList(); - } - - /// Represents the underlying list of countries. - public IList LocationOptions { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.cs deleted file mode 100644 index 9c5eea57c7b04..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.cs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a location options parameter, used for fetching area codes. - public partial class LocationOptionsQuery - { - /// Initializes a new instance of LocationOptionsQuery. - public LocationOptionsQuery() - { - } - - /// Represents the location option label id, returned from the GetLocationOptions API. - public string LabelId { get; set; } - /// Represents the location options value, returned from the GetLocationOptions API. - public string OptionsValue { get; set; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.Serialization.cs deleted file mode 100644 index 0a3e84471bb4a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.Serialization.cs +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class LocationOptionsResponse - { - internal static LocationOptionsResponse DeserializeLocationOptionsResponse(JsonElement element) - { - Optional locationOptions = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("locationOptions")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - locationOptions = LocationOptions.DeserializeLocationOptions(property.Value); - continue; - } - } - return new LocationOptionsResponse(locationOptions.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.cs deleted file mode 100644 index 2f32a83b9f834..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsResponse.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a wrapper around a list of location options. - public partial class LocationOptionsResponse - { - /// Initializes a new instance of LocationOptionsResponse. - internal LocationOptionsResponse() - { - } - - /// Initializes a new instance of LocationOptionsResponse. - /// Represents a location options. - internal LocationOptionsResponse(LocationOptions locationOptions) - { - LocationOptions = locationOptions; - } - - /// Represents a location options. - public LocationOptions LocationOptions { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationType.cs deleted file mode 100644 index 6669db09fb277..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationType.cs +++ /dev/null @@ -1,54 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The location type of the phone plan. - public readonly partial struct LocationType : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public LocationType(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string CivicAddressValue = "CivicAddress"; - private const string NotRequiredValue = "NotRequired"; - private const string SelectionValue = "Selection"; - - /// CivicAddress. - public static LocationType CivicAddress { get; } = new LocationType(CivicAddressValue); - /// NotRequired. - public static LocationType NotRequired { get; } = new LocationType(NotRequiredValue); - /// Selection. - public static LocationType Selection { get; } = new LocationType(SelectionValue); - /// Determines if two values are the same. - public static bool operator ==(LocationType left, LocationType right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(LocationType left, LocationType right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator LocationType(string value) => new LocationType(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is LocationType other && Equals(other); - /// - public bool Equals(LocationType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.Serialization.cs deleted file mode 100644 index 574bb052e7469..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.Serialization.cs +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class NumberConfiguration : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - writer.WritePropertyName("pstnConfiguration"); - writer.WriteObjectValue(PstnConfiguration); - writer.WritePropertyName("phoneNumber"); - writer.WriteStringValue(PhoneNumber); - writer.WriteEndObject(); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.cs deleted file mode 100644 index 57cd2e4b992fc..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfiguration.cs +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Definition for number configuration. - internal partial class NumberConfiguration - { - /// Initializes a new instance of NumberConfiguration. - /// Definition for pstn number configuration. - /// The phone number to configure. - /// or is null. - public NumberConfiguration(PstnConfiguration pstnConfiguration, string phoneNumber) - { - if (pstnConfiguration == null) - { - throw new ArgumentNullException(nameof(pstnConfiguration)); - } - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - PstnConfiguration = pstnConfiguration; - PhoneNumber = phoneNumber; - } - - /// Definition for pstn number configuration. - public PstnConfiguration PstnConfiguration { get; } - /// The phone number to configure. - public string PhoneNumber { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.cs deleted file mode 100644 index 2e482f9dd5ab9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.cs +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The phone number wrapper representing a number configuration request. - internal partial class NumberConfigurationPhoneNumber - { - /// Initializes a new instance of NumberConfigurationPhoneNumber. - /// The phone number in the E.164 format. - /// is null. - public NumberConfigurationPhoneNumber(string phoneNumber) - { - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - PhoneNumber = phoneNumber; - } - - /// The phone number in the E.164 format. - public string PhoneNumber { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.Serialization.cs deleted file mode 100644 index 554a3827ac4a8..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.Serialization.cs +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class NumberConfigurationResponse - { - internal static NumberConfigurationResponse DeserializeNumberConfigurationResponse(JsonElement element) - { - PstnConfiguration pstnConfiguration = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("pstnConfiguration")) - { - pstnConfiguration = PstnConfiguration.DeserializePstnConfiguration(property.Value); - continue; - } - } - return new NumberConfigurationResponse(pstnConfiguration); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.cs deleted file mode 100644 index 4c4a327fea3dc..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationResponse.cs +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Definition for number configuration. - public partial class NumberConfigurationResponse - { - /// Initializes a new instance of NumberConfigurationResponse. - /// Definition for pstn number configuration. - /// is null. - internal NumberConfigurationResponse(PstnConfiguration pstnConfiguration) - { - if (pstnConfiguration == null) - { - throw new ArgumentNullException(nameof(pstnConfiguration)); - } - - PstnConfiguration = pstnConfiguration; - } - - /// Definition for pstn number configuration. - public PstnConfiguration PstnConfiguration { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.Serialization.cs deleted file mode 100644 index 300689adf8fa3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.Serialization.cs +++ /dev/null @@ -1,82 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class NumberUpdateCapabilities : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - if (Optional.IsCollectionDefined(Add)) - { - writer.WritePropertyName("add"); - writer.WriteStartArray(); - foreach (var item in Add) - { - writer.WriteStringValue(item.ToString()); - } - writer.WriteEndArray(); - } - if (Optional.IsCollectionDefined(Remove)) - { - writer.WritePropertyName("remove"); - writer.WriteStartArray(); - foreach (var item in Remove) - { - writer.WriteStringValue(item.ToString()); - } - writer.WriteEndArray(); - } - writer.WriteEndObject(); - } - - internal static NumberUpdateCapabilities DeserializeNumberUpdateCapabilities(JsonElement element) - { - Optional> @add = default; - Optional> @remove = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("add")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(new PhoneNumberCapability(item.GetString())); - } - @add = array; - continue; - } - if (property.NameEquals("remove")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(new PhoneNumberCapability(item.GetString())); - } - @remove = array; - continue; - } - } - return new NumberUpdateCapabilities(Optional.ToList(@add), Optional.ToList(@remove)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.cs deleted file mode 100644 index 42ab1aa289e5b..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberUpdateCapabilities.cs +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents an individual number capabilities update request. - public partial class NumberUpdateCapabilities - { - /// Initializes a new instance of NumberUpdateCapabilities. - public NumberUpdateCapabilities() - { - Add = new ChangeTrackingList(); - Remove = new ChangeTrackingList(); - } - - /// Initializes a new instance of NumberUpdateCapabilities. - /// Capabilities to be added to a phone number. - /// Capabilities to be removed from a phone number. - internal NumberUpdateCapabilities(IList @add, IList @remove) - { - Add = @add; - Remove = @remove; - } - - /// Capabilities to be added to a phone number. - public IList Add { get; } - /// Capabilities to be removed from a phone number. - public IList Remove { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberAssignmentType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberAssignmentType.cs new file mode 100644 index 0000000000000..4f54e28dbd7d1 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberAssignmentType.cs @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The assignment type of the phone numbers to search for. A phone number can be assigned to a person, or to an application. + public readonly partial struct PhoneNumberAssignmentType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public PhoneNumberAssignmentType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string PersonValue = "person"; + private const string ApplicationValue = "application"; + + /// person. + public static PhoneNumberAssignmentType Person { get; } = new PhoneNumberAssignmentType(PersonValue); + /// application. + public static PhoneNumberAssignmentType Application { get; } = new PhoneNumberAssignmentType(ApplicationValue); + /// Determines if two values are the same. + public static bool operator ==(PhoneNumberAssignmentType left, PhoneNumberAssignmentType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(PhoneNumberAssignmentType left, PhoneNumberAssignmentType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator PhoneNumberAssignmentType(string value) => new PhoneNumberAssignmentType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is PhoneNumberAssignmentType other && Equals(other); + /// + public bool Equals(PhoneNumberAssignmentType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.Serialization.cs new file mode 100644 index 0000000000000..1479c2ddbb947 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.Serialization.cs @@ -0,0 +1,45 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class PhoneNumberCapabilities : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("calling"); + writer.WriteStringValue(Calling.ToString()); + writer.WritePropertyName("sms"); + writer.WriteStringValue(Sms.ToString()); + writer.WriteEndObject(); + } + + internal static PhoneNumberCapabilities DeserializePhoneNumberCapabilities(JsonElement element) + { + PhoneNumberCapabilityType calling = default; + PhoneNumberCapabilityType sms = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("calling")) + { + calling = new PhoneNumberCapabilityType(property.Value.GetString()); + continue; + } + if (property.NameEquals("sms")) + { + sms = new PhoneNumberCapabilityType(property.Value.GetString()); + continue; + } + } + return new PhoneNumberCapabilities(calling, sms); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.cs new file mode 100644 index 0000000000000..405984f04d25d --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilities.cs @@ -0,0 +1,27 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Capabilities of a phone number. + public partial class PhoneNumberCapabilities + { + /// Initializes a new instance of PhoneNumberCapabilities. + /// Capability value for calling. + /// Capability value for SMS. + public PhoneNumberCapabilities(PhoneNumberCapabilityType calling, PhoneNumberCapabilityType sms) + { + Calling = calling; + Sms = sms; + } + + /// Capability value for calling. + public PhoneNumberCapabilityType Calling { get; set; } + /// Capability value for SMS. + public PhoneNumberCapabilityType Sms { get; set; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.Serialization.cs similarity index 53% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.Serialization.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.Serialization.cs index 1e4d51799faa2..c87b8f732d4ff 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/LocationOptionsQuery.Serialization.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.Serialization.cs @@ -10,20 +10,20 @@ namespace Azure.Communication.PhoneNumbers.Models { - public partial class LocationOptionsQuery : IUtf8JsonSerializable + internal partial class PhoneNumberCapabilitiesRequest : IUtf8JsonSerializable { void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) { writer.WriteStartObject(); - if (Optional.IsDefined(LabelId)) + if (Optional.IsDefined(Calling)) { - writer.WritePropertyName("labelId"); - writer.WriteStringValue(LabelId); + writer.WritePropertyName("calling"); + writer.WriteStringValue(Calling.Value.ToString()); } - if (Optional.IsDefined(OptionsValue)) + if (Optional.IsDefined(Sms)) { - writer.WritePropertyName("optionsValue"); - writer.WriteStringValue(OptionsValue); + writer.WritePropertyName("sms"); + writer.WriteStringValue(Sms.Value.ToString()); } writer.WriteEndObject(); } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.cs new file mode 100644 index 0000000000000..b7c1f1bb65b0d --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilitiesRequest.cs @@ -0,0 +1,23 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Capabilities of a phone number. + internal partial class PhoneNumberCapabilitiesRequest + { + /// Initializes a new instance of PhoneNumberCapabilitiesRequest. + public PhoneNumberCapabilitiesRequest() + { + } + + /// Capability value for calling. + public PhoneNumberCapabilityType? Calling { get; set; } + /// Capability value for SMS. + public PhoneNumberCapabilityType? Sms { get; set; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapability.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapability.cs deleted file mode 100644 index 348a59dba5a52..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapability.cs +++ /dev/null @@ -1,117 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents the capabilities of a phone number. - public readonly partial struct PhoneNumberCapability : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public PhoneNumberCapability(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string UserAssignmentValue = "UserAssignment"; - private const string FirstPartyVoiceAppAssignmentValue = "FirstPartyVoiceAppAssignment"; - private const string ConferenceAssignmentValue = "ConferenceAssignment"; - private const string P2PSmsEnabledValue = "P2PSmsEnabled"; - private const string GeographicValue = "Geographic"; - private const string NonGeographicValue = "NonGeographic"; - private const string TollCallingValue = "TollCalling"; - private const string TollFreeCallingValue = "TollFreeCalling"; - private const string PremiumValue = "Premium"; - private const string P2PSmsCapableValue = "P2PSmsCapable"; - private const string A2PSmsCapableValue = "A2PSmsCapable"; - private const string A2PSmsEnabledValue = "A2PSmsEnabled"; - private const string CallingValue = "Calling"; - private const string TollFreeValue = "TollFree"; - private const string FirstPartyAppAssignmentValue = "FirstPartyAppAssignment"; - private const string ThirdPartyAppAssignmentValue = "ThirdPartyAppAssignment"; - private const string AzureValue = "Azure"; - private const string Office365Value = "Office365"; - private const string InboundCallingValue = "InboundCalling"; - private const string OutboundCallingValue = "OutboundCalling"; - private const string InboundA2PSmsValue = "InboundA2PSms"; - private const string OutboundA2PSmsValue = "OutboundA2PSms"; - private const string InboundP2PSmsValue = "InboundP2PSms"; - private const string OutboundP2PSmsValue = "OutboundP2PSms"; - - /// UserAssignment. - public static PhoneNumberCapability UserAssignment { get; } = new PhoneNumberCapability(UserAssignmentValue); - /// FirstPartyVoiceAppAssignment. - public static PhoneNumberCapability FirstPartyVoiceAppAssignment { get; } = new PhoneNumberCapability(FirstPartyVoiceAppAssignmentValue); - /// ConferenceAssignment. - public static PhoneNumberCapability ConferenceAssignment { get; } = new PhoneNumberCapability(ConferenceAssignmentValue); - /// P2PSmsEnabled. - public static PhoneNumberCapability P2PSmsEnabled { get; } = new PhoneNumberCapability(P2PSmsEnabledValue); - /// Geographic. - public static PhoneNumberCapability Geographic { get; } = new PhoneNumberCapability(GeographicValue); - /// NonGeographic. - public static PhoneNumberCapability NonGeographic { get; } = new PhoneNumberCapability(NonGeographicValue); - /// TollCalling. - public static PhoneNumberCapability TollCalling { get; } = new PhoneNumberCapability(TollCallingValue); - /// TollFreeCalling. - public static PhoneNumberCapability TollFreeCalling { get; } = new PhoneNumberCapability(TollFreeCallingValue); - /// Premium. - public static PhoneNumberCapability Premium { get; } = new PhoneNumberCapability(PremiumValue); - /// P2PSmsCapable. - public static PhoneNumberCapability P2PSmsCapable { get; } = new PhoneNumberCapability(P2PSmsCapableValue); - /// A2PSmsCapable. - public static PhoneNumberCapability A2PSmsCapable { get; } = new PhoneNumberCapability(A2PSmsCapableValue); - /// A2PSmsEnabled. - public static PhoneNumberCapability A2PSmsEnabled { get; } = new PhoneNumberCapability(A2PSmsEnabledValue); - /// Calling. - public static PhoneNumberCapability Calling { get; } = new PhoneNumberCapability(CallingValue); - /// TollFree. - public static PhoneNumberCapability TollFree { get; } = new PhoneNumberCapability(TollFreeValue); - /// FirstPartyAppAssignment. - public static PhoneNumberCapability FirstPartyAppAssignment { get; } = new PhoneNumberCapability(FirstPartyAppAssignmentValue); - /// ThirdPartyAppAssignment. - public static PhoneNumberCapability ThirdPartyAppAssignment { get; } = new PhoneNumberCapability(ThirdPartyAppAssignmentValue); - /// Azure. - public static PhoneNumberCapability Azure { get; } = new PhoneNumberCapability(AzureValue); - /// Office365. - public static PhoneNumberCapability Office365 { get; } = new PhoneNumberCapability(Office365Value); - /// InboundCalling. - public static PhoneNumberCapability InboundCalling { get; } = new PhoneNumberCapability(InboundCallingValue); - /// OutboundCalling. - public static PhoneNumberCapability OutboundCalling { get; } = new PhoneNumberCapability(OutboundCallingValue); - /// InboundA2PSms. - public static PhoneNumberCapability InboundA2PSms { get; } = new PhoneNumberCapability(InboundA2PSmsValue); - /// OutboundA2PSms. - public static PhoneNumberCapability OutboundA2PSms { get; } = new PhoneNumberCapability(OutboundA2PSmsValue); - /// InboundP2PSms. - public static PhoneNumberCapability InboundP2PSms { get; } = new PhoneNumberCapability(InboundP2PSmsValue); - /// OutboundP2PSms. - public static PhoneNumberCapability OutboundP2PSms { get; } = new PhoneNumberCapability(OutboundP2PSmsValue); - /// Determines if two values are the same. - public static bool operator ==(PhoneNumberCapability left, PhoneNumberCapability right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(PhoneNumberCapability left, PhoneNumberCapability right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator PhoneNumberCapability(string value) => new PhoneNumberCapability(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is PhoneNumberCapability other && Equals(other); - /// - public bool Equals(PhoneNumberCapability other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilityType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilityType.cs new file mode 100644 index 0000000000000..7f765f7af9612 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCapabilityType.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Capability value for calling. + public readonly partial struct PhoneNumberCapabilityType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public PhoneNumberCapabilityType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string NoneValue = "none"; + private const string InboundValue = "inbound"; + private const string OutboundValue = "outbound"; + private const string InboundOutboundValue = "inbound+outbound"; + + /// none. + public static PhoneNumberCapabilityType None { get; } = new PhoneNumberCapabilityType(NoneValue); + /// inbound. + public static PhoneNumberCapabilityType Inbound { get; } = new PhoneNumberCapabilityType(InboundValue); + /// outbound. + public static PhoneNumberCapabilityType Outbound { get; } = new PhoneNumberCapabilityType(OutboundValue); + /// inbound+outbound. + public static PhoneNumberCapabilityType InboundOutbound { get; } = new PhoneNumberCapabilityType(InboundOutboundValue); + /// Determines if two values are the same. + public static bool operator ==(PhoneNumberCapabilityType left, PhoneNumberCapabilityType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(PhoneNumberCapabilityType left, PhoneNumberCapabilityType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator PhoneNumberCapabilityType(string value) => new PhoneNumberCapabilityType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is PhoneNumberCapabilityType other && Equals(other); + /// + public bool Equals(PhoneNumberCapabilityType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.Serialization.cs new file mode 100644 index 0000000000000..6cb9b40d73e1f --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.Serialization.cs @@ -0,0 +1,41 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class PhoneNumberCost + { + internal static PhoneNumberCost DeserializePhoneNumberCost(JsonElement element) + { + double amount = default; + string currencyCode = default; + BillingFrequency billingFrequency = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("amount")) + { + amount = property.Value.GetDouble(); + continue; + } + if (property.NameEquals("currencyCode")) + { + currencyCode = property.Value.GetString(); + continue; + } + if (property.NameEquals("billingFrequency")) + { + billingFrequency = new BillingFrequency(property.Value.GetString()); + continue; + } + } + return new PhoneNumberCost(amount, currencyCode, billingFrequency); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.cs new file mode 100644 index 0000000000000..ee9067ace507c --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCost.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The incurred cost for a single phone number. + public partial class PhoneNumberCost + { + /// Initializes a new instance of PhoneNumberCost. + /// The cost amount. + /// The ISO 4217 currency code for the cost amount, e.g. USD. + /// The frequency with which the cost gets billed. + /// is null. + internal PhoneNumberCost(double amount, string iSOCurrencySymbol, BillingFrequency billingFrequency) + { + if (iSOCurrencySymbol == null) + { + throw new ArgumentNullException(nameof(iSOCurrencySymbol)); + } + + Amount = amount; + ISOCurrencySymbol = iSOCurrencySymbol; + BillingFrequency = billingFrequency; + } + + /// The cost amount. + public double Amount { get; } + /// The frequency with which the cost gets billed. + public BillingFrequency BillingFrequency { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.Serialization.cs deleted file mode 100644 index 77d969dc9843f..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.Serialization.cs +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhoneNumberCountries - { - internal static PhoneNumberCountries DeserializePhoneNumberCountries(JsonElement element) - { - Optional> countries = default; - Optional nextLink = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("countries")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(PhoneNumberCountry.DeserializePhoneNumberCountry(item)); - } - countries = array; - continue; - } - if (property.NameEquals("nextLink")) - { - nextLink = property.Value.GetString(); - continue; - } - } - return new PhoneNumberCountries(Optional.ToList(countries), nextLink.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.cs deleted file mode 100644 index 1994ae4a0a48b..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountries.cs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a wrapper around a list of countries. - internal partial class PhoneNumberCountries - { - /// Initializes a new instance of PhoneNumberCountries. - internal PhoneNumberCountries() - { - Countries = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhoneNumberCountries. - /// Represents the underlying list of countries. - /// Represents the URL link to the next page. - internal PhoneNumberCountries(IReadOnlyList countries, string nextLink) - { - Countries = countries; - NextLink = nextLink; - } - - /// Represents the underlying list of countries. - public IReadOnlyList Countries { get; } - /// Represents the URL link to the next page. - public string NextLink { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.Serialization.cs deleted file mode 100644 index 08a891a82e10e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.Serialization.cs +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhoneNumberCountry - { - internal static PhoneNumberCountry DeserializePhoneNumberCountry(JsonElement element) - { - string localizedName = default; - string countryCode = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("localizedName")) - { - localizedName = property.Value.GetString(); - continue; - } - if (property.NameEquals("countryCode")) - { - countryCode = property.Value.GetString(); - continue; - } - } - return new PhoneNumberCountry(localizedName, countryCode); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.cs deleted file mode 100644 index f21a1c3d28815..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberCountry.cs +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a country. - public partial class PhoneNumberCountry - { - /// Initializes a new instance of PhoneNumberCountry. - /// Represents the name of the country. - /// Represents the abbreviated name of the country. - /// or is null. - internal PhoneNumberCountry(string localizedName, string countryCode) - { - if (localizedName == null) - { - throw new ArgumentNullException(nameof(localizedName)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - - LocalizedName = localizedName; - CountryCode = countryCode; - } - - /// Represents the name of the country. - public string LocalizedName { get; } - /// Represents the abbreviated name of the country. - public string CountryCode { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.Serialization.cs deleted file mode 100644 index 87e1c32a05705..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.Serialization.cs +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhoneNumberEntities - { - internal static PhoneNumberEntities DeserializePhoneNumberEntities(JsonElement element) - { - Optional> entities = default; - Optional nextLink = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("entities")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(PhoneNumberEntity.DeserializePhoneNumberEntity(item)); - } - entities = array; - continue; - } - if (property.NameEquals("nextLink")) - { - nextLink = property.Value.GetString(); - continue; - } - } - return new PhoneNumberEntities(Optional.ToList(entities), nextLink.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.cs deleted file mode 100644 index 5a4cf46ef4ed1..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntities.cs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a list of searches or releases, as part of the response when fetching all searches or releases. - internal partial class PhoneNumberEntities - { - /// Initializes a new instance of PhoneNumberEntities. - internal PhoneNumberEntities() - { - Entities = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhoneNumberEntities. - /// The underlying list of entities. - /// Represents the URL link to the next page. - internal PhoneNumberEntities(IReadOnlyList entities, string nextLink) - { - Entities = entities; - NextLink = nextLink; - } - - /// The underlying list of entities. - public IReadOnlyList Entities { get; } - /// Represents the URL link to the next page. - public string NextLink { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.Serialization.cs deleted file mode 100644 index e594d5cc3c792..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.Serialization.cs +++ /dev/null @@ -1,86 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhoneNumberEntity - { - internal static PhoneNumberEntity DeserializePhoneNumberEntity(JsonElement element) - { - Optional id = default; - Optional createdAt = default; - Optional displayName = default; - Optional quantity = default; - Optional quantityObtained = default; - Optional status = default; - Optional focDate = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("id")) - { - id = property.Value.GetString(); - continue; - } - if (property.NameEquals("createdAt")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - createdAt = property.Value.GetDateTimeOffset("O"); - continue; - } - if (property.NameEquals("displayName")) - { - displayName = property.Value.GetString(); - continue; - } - if (property.NameEquals("quantity")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - quantity = property.Value.GetInt32(); - continue; - } - if (property.NameEquals("quantityObtained")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - quantityObtained = property.Value.GetInt32(); - continue; - } - if (property.NameEquals("status")) - { - status = property.Value.GetString(); - continue; - } - if (property.NameEquals("focDate")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - focDate = property.Value.GetDateTimeOffset("O"); - continue; - } - } - return new PhoneNumberEntity(id.Value, Optional.ToNullable(createdAt), displayName.Value, Optional.ToNullable(quantity), Optional.ToNullable(quantityObtained), status.Value, Optional.ToNullable(focDate)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.cs deleted file mode 100644 index 3566c8fcb152c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberEntity.cs +++ /dev/null @@ -1,54 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a phone number entity, as part of the response when calling get all searches or releases. - public partial class PhoneNumberEntity - { - /// Initializes a new instance of PhoneNumberEntity. - internal PhoneNumberEntity() - { - } - - /// Initializes a new instance of PhoneNumberEntity. - /// The id of the entity. It is the search id of a search. It is the release id of a release. - /// Date and time the entity is created. - /// Name of the entity. - /// Quantity of requested phone numbers in the entity. - /// Quantity of acquired phone numbers in the entity. - /// Status of the entity. - /// The Firm Order Confirmation date of the phone number entity. - internal PhoneNumberEntity(string id, DateTimeOffset? createdAt, string displayName, int? quantity, int? quantityObtained, string status, DateTimeOffset? focDate) - { - Id = id; - CreatedAt = createdAt; - DisplayName = displayName; - Quantity = quantity; - QuantityObtained = quantityObtained; - Status = status; - FocDate = focDate; - } - - /// The id of the entity. It is the search id of a search. It is the release id of a release. - public string Id { get; } - /// Date and time the entity is created. - public DateTimeOffset? CreatedAt { get; } - /// Name of the entity. - public string DisplayName { get; } - /// Quantity of requested phone numbers in the entity. - public int? Quantity { get; } - /// Quantity of acquired phone numbers in the entity. - public int? QuantityObtained { get; } - /// Status of the entity. - public string Status { get; } - /// The Firm Order Confirmation date of the phone number entity. - public DateTimeOffset? FocDate { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.Serialization.cs new file mode 100644 index 0000000000000..2cbb3639c64ad --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.Serialization.cs @@ -0,0 +1,76 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + internal partial class PhoneNumberOperation + { + internal static PhoneNumberOperation DeserializePhoneNumberOperation(JsonElement element) + { + PhoneNumberOperationStatus status = default; + Optional resourceLocation = default; + DateTimeOffset createdDateTime = default; + Optional error = default; + string id = default; + PhoneNumberOperationType operationType = default; + Optional lastActionDateTime = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("status")) + { + status = new PhoneNumberOperationStatus(property.Value.GetString()); + continue; + } + if (property.NameEquals("resourceLocation")) + { + resourceLocation = property.Value.GetString(); + continue; + } + if (property.NameEquals("createdDateTime")) + { + createdDateTime = property.Value.GetDateTimeOffset("O"); + continue; + } + if (property.NameEquals("error")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + error = CommunicationError.DeserializeCommunicationError(property.Value); + continue; + } + if (property.NameEquals("id")) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("operationType")) + { + operationType = new PhoneNumberOperationType(property.Value.GetString()); + continue; + } + if (property.NameEquals("lastActionDateTime")) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + property.ThrowNonNullablePropertyIsNull(); + continue; + } + lastActionDateTime = property.Value.GetDateTimeOffset("O"); + continue; + } + } + return new PhoneNumberOperation(status, resourceLocation.Value, createdDateTime, error.Value, id, operationType, Optional.ToNullable(lastActionDateTime)); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.cs new file mode 100644 index 0000000000000..783fb1ea02fab --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperation.cs @@ -0,0 +1,68 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Long running operation. + internal partial class PhoneNumberOperation + { + /// Initializes a new instance of PhoneNumberOperation. + /// Status of operation. + /// The date that the operation was created. + /// Id of operation. + /// The type of operation, e.g. Search. + /// is null. + internal PhoneNumberOperation(PhoneNumberOperationStatus status, DateTimeOffset createdDateTime, string id, PhoneNumberOperationType operationType) + { + if (id == null) + { + throw new ArgumentNullException(nameof(id)); + } + + Status = status; + CreatedDateTime = createdDateTime; + Id = id; + OperationType = operationType; + } + + /// Initializes a new instance of PhoneNumberOperation. + /// Status of operation. + /// URL for retrieving the result of the operation, if any. + /// The date that the operation was created. + /// The Communication Services error. + /// Id of operation. + /// The type of operation, e.g. Search. + /// The most recent date that the operation was changed. + internal PhoneNumberOperation(PhoneNumberOperationStatus status, string resourceLocation, DateTimeOffset createdDateTime, CommunicationError error, string id, PhoneNumberOperationType operationType, DateTimeOffset? lastActionDateTime) + { + Status = status; + ResourceLocation = resourceLocation; + CreatedDateTime = createdDateTime; + Error = error; + Id = id; + OperationType = operationType; + LastActionDateTime = lastActionDateTime; + } + + /// Status of operation. + public PhoneNumberOperationStatus Status { get; } + /// URL for retrieving the result of the operation, if any. + public string ResourceLocation { get; } + /// The date that the operation was created. + public DateTimeOffset CreatedDateTime { get; } + /// The Communication Services error. + public CommunicationError Error { get; } + /// Id of operation. + public string Id { get; } + /// The type of operation, e.g. Search. + public PhoneNumberOperationType OperationType { get; } + /// The most recent date that the operation was changed. + public DateTimeOffset? LastActionDateTime { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationStatus.cs new file mode 100644 index 0000000000000..540acd774f101 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationStatus.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Status of operation. + public readonly partial struct PhoneNumberOperationStatus : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public PhoneNumberOperationStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string NotStartedValue = "notStarted"; + private const string RunningValue = "running"; + private const string SucceededValue = "succeeded"; + private const string FailedValue = "failed"; + + /// notStarted. + public static PhoneNumberOperationStatus NotStarted { get; } = new PhoneNumberOperationStatus(NotStartedValue); + /// running. + public static PhoneNumberOperationStatus Running { get; } = new PhoneNumberOperationStatus(RunningValue); + /// succeeded. + public static PhoneNumberOperationStatus Succeeded { get; } = new PhoneNumberOperationStatus(SucceededValue); + /// failed. + public static PhoneNumberOperationStatus Failed { get; } = new PhoneNumberOperationStatus(FailedValue); + /// Determines if two values are the same. + public static bool operator ==(PhoneNumberOperationStatus left, PhoneNumberOperationStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(PhoneNumberOperationStatus left, PhoneNumberOperationStatus right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator PhoneNumberOperationStatus(string value) => new PhoneNumberOperationStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is PhoneNumberOperationStatus other && Equals(other); + /// + public bool Equals(PhoneNumberOperationStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationType.cs new file mode 100644 index 0000000000000..c244602b20bc5 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberOperationType.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The type of operation, e.g. Search. + public readonly partial struct PhoneNumberOperationType : IEquatable + { + private readonly string _value; + + /// Determines if two values are the same. + /// is null. + public PhoneNumberOperationType(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string PurchaseValue = "purchase"; + private const string ReleasePhoneNumberValue = "releasePhoneNumber"; + private const string SearchValue = "search"; + private const string UpdatePhoneNumberCapabilitiesValue = "updatePhoneNumberCapabilities"; + + /// purchase. + public static PhoneNumberOperationType Purchase { get; } = new PhoneNumberOperationType(PurchaseValue); + /// releasePhoneNumber. + public static PhoneNumberOperationType ReleasePhoneNumber { get; } = new PhoneNumberOperationType(ReleasePhoneNumberValue); + /// search. + public static PhoneNumberOperationType Search { get; } = new PhoneNumberOperationType(SearchValue); + /// updatePhoneNumberCapabilities. + public static PhoneNumberOperationType UpdatePhoneNumberCapabilities { get; } = new PhoneNumberOperationType(UpdatePhoneNumberCapabilitiesValue); + /// Determines if two values are the same. + public static bool operator ==(PhoneNumberOperationType left, PhoneNumberOperationType right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(PhoneNumberOperationType left, PhoneNumberOperationType right) => !left.Equals(right); + /// Converts a string to a . + public static implicit operator PhoneNumberOperationType(string value) => new PhoneNumberOperationType(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is PhoneNumberOperationType other && Equals(other); + /// + public bool Equals(PhoneNumberOperationType other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value?.GetHashCode() ?? 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.Serialization.cs similarity index 61% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.Serialization.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.Serialization.cs index 9445c15739249..52d366508f7dc 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/NumberConfigurationPhoneNumber.Serialization.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.Serialization.cs @@ -10,13 +10,16 @@ namespace Azure.Communication.PhoneNumbers.Models { - internal partial class NumberConfigurationPhoneNumber : IUtf8JsonSerializable + internal partial class PhoneNumberPurchaseRequest : IUtf8JsonSerializable { void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) { writer.WriteStartObject(); - writer.WritePropertyName("phoneNumber"); - writer.WriteStringValue(PhoneNumber); + if (Optional.IsDefined(SearchId)) + { + writer.WritePropertyName("searchId"); + writer.WriteStringValue(SearchId); + } writer.WriteEndObject(); } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.cs new file mode 100644 index 0000000000000..873c0365f8389 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberPurchaseRequest.cs @@ -0,0 +1,21 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The phone number search purchase request. + internal partial class PhoneNumberPurchaseRequest + { + /// Initializes a new instance of PhoneNumberPurchaseRequest. + public PhoneNumberPurchaseRequest() + { + } + + /// The search id. + public string SearchId { get; set; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.Serialization.cs deleted file mode 100644 index 4d59b15c83f8d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.Serialization.cs +++ /dev/null @@ -1,75 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhoneNumberRelease - { - internal static PhoneNumberRelease DeserializePhoneNumberRelease(JsonElement element) - { - Optional releaseId = default; - Optional createdAt = default; - Optional status = default; - Optional errorMessage = default; - Optional> phoneNumberReleaseStatusDetails = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("releaseId")) - { - releaseId = property.Value.GetString(); - continue; - } - if (property.NameEquals("createdAt")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - createdAt = property.Value.GetDateTimeOffset("O"); - continue; - } - if (property.NameEquals("status")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - status = new ReleaseStatus(property.Value.GetString()); - continue; - } - if (property.NameEquals("errorMessage")) - { - errorMessage = property.Value.GetString(); - continue; - } - if (property.NameEquals("phoneNumberReleaseStatusDetails")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - Dictionary dictionary = new Dictionary(); - foreach (var property0 in property.Value.EnumerateObject()) - { - dictionary.Add(property0.Name, PhoneNumberReleaseDetails.DeserializePhoneNumberReleaseDetails(property0.Value)); - } - phoneNumberReleaseStatusDetails = dictionary; - continue; - } - } - return new PhoneNumberRelease(releaseId.Value, Optional.ToNullable(createdAt), Optional.ToNullable(status), errorMessage.Value, Optional.ToDictionary(phoneNumberReleaseStatusDetails)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.cs deleted file mode 100644 index 3a9ba58fe7728..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberRelease.cs +++ /dev/null @@ -1,49 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a release. - public partial class PhoneNumberRelease - { - /// Initializes a new instance of PhoneNumberRelease. - internal PhoneNumberRelease() - { - PhoneNumberReleaseStatusDetails = new ChangeTrackingDictionary(); - } - - /// Initializes a new instance of PhoneNumberRelease. - /// The id of the release. - /// The creation time of the release. - /// The release status. - /// The underlying error message of a release. - /// The list of phone numbers in the release, mapped to its individual statuses. - internal PhoneNumberRelease(string releaseId, DateTimeOffset? createdAt, ReleaseStatus? status, string errorMessage, IReadOnlyDictionary phoneNumberReleaseStatusDetails) - { - ReleaseId = releaseId; - CreatedAt = createdAt; - Status = status; - ErrorMessage = errorMessage; - PhoneNumberReleaseStatusDetails = phoneNumberReleaseStatusDetails; - } - - /// The id of the release. - public string ReleaseId { get; } - /// The creation time of the release. - public DateTimeOffset? CreatedAt { get; } - /// The release status. - public ReleaseStatus? Status { get; } - /// The underlying error message of a release. - public string ErrorMessage { get; } - /// The list of phone numbers in the release, mapped to its individual statuses. - public IReadOnlyDictionary PhoneNumberReleaseStatusDetails { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.Serialization.cs deleted file mode 100644 index f6872c85591a9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.Serialization.cs +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhoneNumberReleaseDetails - { - internal static PhoneNumberReleaseDetails DeserializePhoneNumberReleaseDetails(JsonElement element) - { - Optional status = default; - Optional errorCode = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("status")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - status = new PhoneNumberReleaseStatus(property.Value.GetString()); - continue; - } - if (property.NameEquals("errorCode")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - errorCode = property.Value.GetInt32(); - continue; - } - } - return new PhoneNumberReleaseDetails(Optional.ToNullable(status), Optional.ToNullable(errorCode)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.cs deleted file mode 100644 index 7674e3cdd77d1..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseDetails.cs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The PhoneNumberReleaseDetails. - public partial class PhoneNumberReleaseDetails - { - /// Initializes a new instance of PhoneNumberReleaseDetails. - internal PhoneNumberReleaseDetails() - { - } - - /// Initializes a new instance of PhoneNumberReleaseDetails. - /// The release status of a phone number. - /// The error code in the case the status is error. - internal PhoneNumberReleaseDetails(PhoneNumberReleaseStatus? status, int? errorCode) - { - Status = status; - ErrorCode = errorCode; - } - - /// The release status of a phone number. - public PhoneNumberReleaseStatus? Status { get; } - /// The error code in the case the status is error. - public int? ErrorCode { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.Serialization.cs deleted file mode 100644 index dbd6ceec53b91..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.Serialization.cs +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhoneNumberReleaseResponse - { - internal static PhoneNumberReleaseResponse DeserializePhoneNumberReleaseResponse(JsonElement element) - { - string releaseId = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("releaseId")) - { - releaseId = property.Value.GetString(); - continue; - } - } - return new PhoneNumberReleaseResponse(releaseId); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.cs deleted file mode 100644 index bd63ec416707a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseResponse.cs +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a release response. - internal partial class PhoneNumberReleaseResponse - { - /// Initializes a new instance of PhoneNumberReleaseResponse. - /// The release id of a created release. - /// is null. - internal PhoneNumberReleaseResponse(string releaseId) - { - if (releaseId == null) - { - throw new ArgumentNullException(nameof(releaseId)); - } - - ReleaseId = releaseId; - } - - /// The release id of a created release. - public string ReleaseId { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseStatus.cs deleted file mode 100644 index 3d03e7c24619d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReleaseStatus.cs +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The release status of a phone number. - public readonly partial struct PhoneNumberReleaseStatus : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public PhoneNumberReleaseStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string PendingValue = "Pending"; - private const string SuccessValue = "Success"; - private const string ErrorValue = "Error"; - private const string InProgressValue = "InProgress"; - - /// Pending. - public static PhoneNumberReleaseStatus Pending { get; } = new PhoneNumberReleaseStatus(PendingValue); - /// Success. - public static PhoneNumberReleaseStatus Success { get; } = new PhoneNumberReleaseStatus(SuccessValue); - /// Error. - public static PhoneNumberReleaseStatus Error { get; } = new PhoneNumberReleaseStatus(ErrorValue); - /// InProgress. - public static PhoneNumberReleaseStatus InProgress { get; } = new PhoneNumberReleaseStatus(InProgressValue); - /// Determines if two values are the same. - public static bool operator ==(PhoneNumberReleaseStatus left, PhoneNumberReleaseStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(PhoneNumberReleaseStatus left, PhoneNumberReleaseStatus right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator PhoneNumberReleaseStatus(string value) => new PhoneNumberReleaseStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is PhoneNumberReleaseStatus other && Equals(other); - /// - public bool Equals(PhoneNumberReleaseStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.Serialization.cs deleted file mode 100644 index 0144bd86fe9f9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.Serialization.cs +++ /dev/null @@ -1,152 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhoneNumberReservation - { - internal static PhoneNumberReservation DeserializePhoneNumberReservation(JsonElement element) - { - Optional searchId = default; - Optional displayName = default; - Optional createdAt = default; - Optional description = default; - Optional> phonePlanIds = default; - Optional areaCode = default; - Optional quantity = default; - Optional> locationOptions = default; - Optional status = default; - Optional> phoneNumbers = default; - Optional reservationExpiryDate = default; - Optional errorCode = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("searchId")) - { - searchId = property.Value.GetString(); - continue; - } - if (property.NameEquals("displayName")) - { - displayName = property.Value.GetString(); - continue; - } - if (property.NameEquals("createdAt")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - createdAt = property.Value.GetDateTimeOffset("O"); - continue; - } - if (property.NameEquals("description")) - { - description = property.Value.GetString(); - continue; - } - if (property.NameEquals("phonePlanIds")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(item.GetString()); - } - phonePlanIds = array; - continue; - } - if (property.NameEquals("areaCode")) - { - areaCode = property.Value.GetString(); - continue; - } - if (property.NameEquals("quantity")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - quantity = property.Value.GetInt32(); - continue; - } - if (property.NameEquals("locationOptions")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(LocationOptionsDetails.DeserializeLocationOptionsDetails(item)); - } - locationOptions = array; - continue; - } - if (property.NameEquals("status")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - status = new ReservationStatus(property.Value.GetString()); - continue; - } - if (property.NameEquals("phoneNumbers")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(item.GetString()); - } - phoneNumbers = array; - continue; - } - if (property.NameEquals("reservationExpiryDate")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - reservationExpiryDate = property.Value.GetDateTimeOffset("O"); - continue; - } - if (property.NameEquals("errorCode")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - errorCode = property.Value.GetInt32(); - continue; - } - } - return new PhoneNumberReservation(searchId.Value, displayName.Value, Optional.ToNullable(createdAt), description.Value, Optional.ToList(phonePlanIds), areaCode.Value, Optional.ToNullable(quantity), Optional.ToList(locationOptions), Optional.ToNullable(status), Optional.ToList(phoneNumbers), Optional.ToNullable(reservationExpiryDate), Optional.ToNullable(errorCode)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.cs deleted file mode 100644 index b631bfb41505f..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberReservation.cs +++ /dev/null @@ -1,76 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a phone number search. - public partial class PhoneNumberReservation - { - /// Initializes a new instance of PhoneNumberReservation. - internal PhoneNumberReservation() - { - PhonePlanIds = new ChangeTrackingList(); - LocationOptions = new ChangeTrackingList(); - PhoneNumbers = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhoneNumberReservation. - /// The id of the search. - /// The name of the search. - /// The creation time of the search. - /// The description of the search. - /// The phone plan ids of the search. - /// The area code of the search. - /// The quantity of phone numbers in the search. - /// The location options of the search. - /// The status of the search. - /// The list of phone numbers in the search, in the case the status is reserved or success. - /// The date that search expires and the numbers become available. - /// The error code of the search. - internal PhoneNumberReservation(string reservationId, string displayName, DateTimeOffset? createdAt, string description, IReadOnlyList phonePlanIds, string areaCode, int? quantity, IReadOnlyList locationOptions, ReservationStatus? status, IReadOnlyList phoneNumbers, DateTimeOffset? reservationExpiryDate, int? errorCode) - { - ReservationId = reservationId; - DisplayName = displayName; - CreatedAt = createdAt; - Description = description; - PhonePlanIds = phonePlanIds; - AreaCode = areaCode; - Quantity = quantity; - LocationOptions = locationOptions; - Status = status; - PhoneNumbers = phoneNumbers; - ReservationExpiryDate = reservationExpiryDate; - ErrorCode = errorCode; - } - /// The name of the search. - public string DisplayName { get; } - /// The creation time of the search. - public DateTimeOffset? CreatedAt { get; } - /// The description of the search. - public string Description { get; } - /// The phone plan ids of the search. - public IReadOnlyList PhonePlanIds { get; } - /// The area code of the search. - public string AreaCode { get; } - /// The quantity of phone numbers in the search. - public int? Quantity { get; } - /// The location options of the search. - public IReadOnlyList LocationOptions { get; } - /// The status of the search. - public ReservationStatus? Status { get; } - /// The list of phone numbers in the search, in the case the status is reserved or success. - public IReadOnlyList PhoneNumbers { get; } - /// The date that search expires and the numbers become available. - public DateTimeOffset? ReservationExpiryDate { get; } - /// The error code of the search. - public int? ErrorCode { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.Serialization.cs new file mode 100644 index 0000000000000..a7c24b730d51d --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.Serialization.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + internal partial class PhoneNumberSearchRequest : IUtf8JsonSerializable + { + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) + { + writer.WriteStartObject(); + writer.WritePropertyName("phoneNumberType"); + writer.WriteStringValue(PhoneNumberType.ToString()); + writer.WritePropertyName("assignmentType"); + writer.WriteStringValue(AssignmentType.ToString()); + writer.WritePropertyName("capabilities"); + writer.WriteObjectValue(Capabilities); + if (Optional.IsDefined(AreaCode)) + { + writer.WritePropertyName("areaCode"); + writer.WriteStringValue(AreaCode); + } + if (Optional.IsDefined(Quantity)) + { + writer.WritePropertyName("quantity"); + writer.WriteNumberValue(Quantity.Value); + } + writer.WriteEndObject(); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.cs new file mode 100644 index 0000000000000..c4a96b6065bc6 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchRequest.cs @@ -0,0 +1,43 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// Represents a phone number search request to find phone numbers. Found phone numbers are temporarily held for a following purchase. + internal partial class PhoneNumberSearchRequest + { + /// Initializes a new instance of PhoneNumberSearchRequest. + /// The type of phone numbers to search for, e.g. geographic, or tollFree. + /// The assignment type of the phone numbers to search for. A phone number can be assigned to a person, or to an application. + /// Capabilities of a phone number. + /// is null. + public PhoneNumberSearchRequest(PhoneNumberType phoneNumberType, PhoneNumberAssignmentType assignmentType, PhoneNumberCapabilities capabilities) + { + if (capabilities == null) + { + throw new ArgumentNullException(nameof(capabilities)); + } + + PhoneNumberType = phoneNumberType; + AssignmentType = assignmentType; + Capabilities = capabilities; + } + + /// The type of phone numbers to search for, e.g. geographic, or tollFree. + public PhoneNumberType PhoneNumberType { get; } + /// The assignment type of the phone numbers to search for. A phone number can be assigned to a person, or to an application. + public PhoneNumberAssignmentType AssignmentType { get; } + /// Capabilities of a phone number. + public PhoneNumberCapabilities Capabilities { get; } + /// The area code of the desired phone number, e.g. 425. + public string AreaCode { get; set; } + /// The quantity of desired phone numbers. The default value is 1. + public int? Quantity { get; set; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.Serialization.cs new file mode 100644 index 0000000000000..26f9c9e0cb9d6 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.Serialization.cs @@ -0,0 +1,72 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class PhoneNumberSearchResult + { + internal static PhoneNumberSearchResult DeserializePhoneNumberSearchResult(JsonElement element) + { + string searchId = default; + IReadOnlyList phoneNumbers = default; + PhoneNumberType phoneNumberType = default; + PhoneNumberAssignmentType assignmentType = default; + PhoneNumberCapabilities capabilities = default; + PhoneNumberCost cost = default; + DateTimeOffset searchExpiresBy = default; + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("searchId")) + { + searchId = property.Value.GetString(); + continue; + } + if (property.NameEquals("phoneNumbers")) + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(item.GetString()); + } + phoneNumbers = array; + continue; + } + if (property.NameEquals("phoneNumberType")) + { + phoneNumberType = new PhoneNumberType(property.Value.GetString()); + continue; + } + if (property.NameEquals("assignmentType")) + { + assignmentType = new PhoneNumberAssignmentType(property.Value.GetString()); + continue; + } + if (property.NameEquals("capabilities")) + { + capabilities = PhoneNumberCapabilities.DeserializePhoneNumberCapabilities(property.Value); + continue; + } + if (property.NameEquals("cost")) + { + cost = PhoneNumberCost.DeserializePhoneNumberCost(property.Value); + continue; + } + if (property.NameEquals("searchExpiresBy")) + { + searchExpiresBy = property.Value.GetDateTimeOffset("O"); + continue; + } + } + return new PhoneNumberSearchResult(searchId, phoneNumbers, phoneNumberType, assignmentType, capabilities, cost, searchExpiresBy); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.cs new file mode 100644 index 0000000000000..a1dab1a21d95f --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberSearchResult.cs @@ -0,0 +1,86 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// The result of a phone number search operation. + public partial class PhoneNumberSearchResult + { + /// Initializes a new instance of PhoneNumberSearchResult. + /// The search id. + /// The phone numbers that are available. Can be fewer than the desired search quantity. + /// The phone number's type, e.g. geographic, or tollFree. + /// Phone number's assignment type. + /// Capabilities of a phone number. + /// The incurred cost for a single phone number. + /// The date that this search result expires and phone numbers are no longer on hold. A search result expires in less than 15min, e.g. 2020-11-19T16:31:49.048Z. + /// , , , or is null. + internal PhoneNumberSearchResult(string searchId, IEnumerable phoneNumbers, PhoneNumberType phoneNumberType, PhoneNumberAssignmentType assignmentType, PhoneNumberCapabilities capabilities, PhoneNumberCost cost, DateTimeOffset searchExpiresOn) + { + if (searchId == null) + { + throw new ArgumentNullException(nameof(searchId)); + } + if (phoneNumbers == null) + { + throw new ArgumentNullException(nameof(phoneNumbers)); + } + if (capabilities == null) + { + throw new ArgumentNullException(nameof(capabilities)); + } + if (cost == null) + { + throw new ArgumentNullException(nameof(cost)); + } + + SearchId = searchId; + PhoneNumbers = phoneNumbers.ToList(); + PhoneNumberType = phoneNumberType; + AssignmentType = assignmentType; + Capabilities = capabilities; + Cost = cost; + SearchExpiresOn = searchExpiresOn; + } + + /// Initializes a new instance of PhoneNumberSearchResult. + /// The search id. + /// The phone numbers that are available. Can be fewer than the desired search quantity. + /// The phone number's type, e.g. geographic, or tollFree. + /// Phone number's assignment type. + /// Capabilities of a phone number. + /// The incurred cost for a single phone number. + /// The date that this search result expires and phone numbers are no longer on hold. A search result expires in less than 15min, e.g. 2020-11-19T16:31:49.048Z. + internal PhoneNumberSearchResult(string searchId, IReadOnlyList phoneNumbers, PhoneNumberType phoneNumberType, PhoneNumberAssignmentType assignmentType, PhoneNumberCapabilities capabilities, PhoneNumberCost cost, DateTimeOffset searchExpiresOn) + { + SearchId = searchId; + PhoneNumbers = phoneNumbers; + PhoneNumberType = phoneNumberType; + AssignmentType = assignmentType; + Capabilities = capabilities; + Cost = cost; + SearchExpiresOn = searchExpiresOn; + } + + /// The search id. + public string SearchId { get; } + /// The phone numbers that are available. Can be fewer than the desired search quantity. + public IReadOnlyList PhoneNumbers { get; } + /// The phone number's type, e.g. geographic, or tollFree. + public PhoneNumberType PhoneNumberType { get; } + /// Phone number's assignment type. + public PhoneNumberAssignmentType AssignmentType { get; } + /// Capabilities of a phone number. + public PhoneNumberCapabilities Capabilities { get; } + /// The incurred cost for a single phone number. + public PhoneNumberCost Cost { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberType.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberType.cs index 01de801ede182..5c846ef8ef9fd 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberType.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhoneNumberType.cs @@ -10,7 +10,7 @@ namespace Azure.Communication.PhoneNumbers.Models { - /// The phone number type of the plan group. + /// The type of phone numbers to search for, e.g. geographic, or tollFree. public readonly partial struct PhoneNumberType : IEquatable { private readonly string _value; @@ -22,19 +22,13 @@ public PhoneNumberType(string value) _value = value ?? throw new ArgumentNullException(nameof(value)); } - private const string UnknownValue = "Unknown"; - private const string GeographicValue = "Geographic"; - private const string TollFreeValue = "TollFree"; - private const string IndirectValue = "Indirect"; + private const string GeographicValue = "geographic"; + private const string TollFreeValue = "tollFree"; - /// Unknown. - public static PhoneNumberType Unknown { get; } = new PhoneNumberType(UnknownValue); - /// Geographic. + /// geographic. public static PhoneNumberType Geographic { get; } = new PhoneNumberType(GeographicValue); - /// TollFree. + /// tollFree. public static PhoneNumberType TollFree { get; } = new PhoneNumberType(TollFreeValue); - /// Indirect. - public static PhoneNumberType Indirect { get; } = new PhoneNumberType(IndirectValue); /// Determines if two values are the same. public static bool operator ==(PhoneNumberType left, PhoneNumberType right) => left.Equals(right); /// Determines if two values are not the same. diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.Serialization.cs deleted file mode 100644 index db67a87be4b61..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.Serialization.cs +++ /dev/null @@ -1,85 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhonePlan - { - internal static PhonePlan DeserializePhonePlan(JsonElement element) - { - string phonePlanId = default; - string localizedName = default; - LocationType locationType = default; - Optional> areaCodes = default; - Optional> capabilities = default; - Optional maximumSearchSize = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("phonePlanId")) - { - phonePlanId = property.Value.GetString(); - continue; - } - if (property.NameEquals("localizedName")) - { - localizedName = property.Value.GetString(); - continue; - } - if (property.NameEquals("locationType")) - { - locationType = new LocationType(property.Value.GetString()); - continue; - } - if (property.NameEquals("areaCodes")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(item.GetString()); - } - areaCodes = array; - continue; - } - if (property.NameEquals("capabilities")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(new PhoneNumberCapability(item.GetString())); - } - capabilities = array; - continue; - } - if (property.NameEquals("maximumSearchSize")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - maximumSearchSize = property.Value.GetInt32(); - continue; - } - } - return new PhonePlan(phonePlanId, localizedName, locationType, Optional.ToList(areaCodes), Optional.ToList(capabilities), Optional.ToNullable(maximumSearchSize)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.cs deleted file mode 100644 index 1df386d8a15de..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlan.cs +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a phone plan. - public partial class PhonePlan - { - /// Initializes a new instance of PhonePlan. - /// The phone plan id. - /// The name of the phone plan. - /// The location type of the phone plan. - /// or is null. - internal PhonePlan(string phonePlanId, string localizedName, LocationType locationType) - { - if (phonePlanId == null) - { - throw new ArgumentNullException(nameof(phonePlanId)); - } - if (localizedName == null) - { - throw new ArgumentNullException(nameof(localizedName)); - } - - PhonePlanId = phonePlanId; - LocalizedName = localizedName; - LocationType = locationType; - AreaCodes = new ChangeTrackingList(); - Capabilities = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhonePlan. - /// The phone plan id. - /// The name of the phone plan. - /// The location type of the phone plan. - /// The list of available area codes in the phone plan. - /// Capabilities of the phone plan. - /// The maximum number of phone numbers one can acquire in a search in this phone plan. - internal PhonePlan(string phonePlanId, string localizedName, LocationType locationType, IReadOnlyList areaCodes, IReadOnlyList capabilities, int? maximumSearchSize) - { - PhonePlanId = phonePlanId; - LocalizedName = localizedName; - LocationType = locationType; - AreaCodes = areaCodes; - Capabilities = capabilities; - MaximumSearchSize = maximumSearchSize; - } - - /// The phone plan id. - public string PhonePlanId { get; } - /// The name of the phone plan. - public string LocalizedName { get; } - /// The location type of the phone plan. - public LocationType LocationType { get; } - /// The list of available area codes in the phone plan. - public IReadOnlyList AreaCodes { get; } - /// Capabilities of the phone plan. - public IReadOnlyList Capabilities { get; } - /// The maximum number of phone numbers one can acquire in a search in this phone plan. - public int? MaximumSearchSize { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.Serialization.cs deleted file mode 100644 index 0a26176e7d930..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.Serialization.cs +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PhonePlanGroup - { - internal static PhonePlanGroup DeserializePhonePlanGroup(JsonElement element) - { - string phonePlanGroupId = default; - Optional phoneNumberType = default; - string localizedName = default; - string localizedDescription = default; - Optional carrierDetails = default; - Optional rateInformation = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("phonePlanGroupId")) - { - phonePlanGroupId = property.Value.GetString(); - continue; - } - if (property.NameEquals("phoneNumberType")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - phoneNumberType = new PhoneNumberType(property.Value.GetString()); - continue; - } - if (property.NameEquals("localizedName")) - { - localizedName = property.Value.GetString(); - continue; - } - if (property.NameEquals("localizedDescription")) - { - localizedDescription = property.Value.GetString(); - continue; - } - if (property.NameEquals("carrierDetails")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - carrierDetails = CarrierDetails.DeserializeCarrierDetails(property.Value); - continue; - } - if (property.NameEquals("rateInformation")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - rateInformation = RateInformation.DeserializeRateInformation(property.Value); - continue; - } - } - return new PhonePlanGroup(phonePlanGroupId, Optional.ToNullable(phoneNumberType), localizedName, localizedDescription, carrierDetails.Value, rateInformation.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.cs deleted file mode 100644 index bb1a32d81b6d2..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroup.cs +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a plan group. - public partial class PhonePlanGroup - { - /// Initializes a new instance of PhonePlanGroup. - /// The id of the plan group. - /// The name of the plan group. - /// The description of the plan group. - /// , , or is null. - internal PhonePlanGroup(string phonePlanGroupId, string localizedName, string localizedDescription) - { - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - if (localizedName == null) - { - throw new ArgumentNullException(nameof(localizedName)); - } - if (localizedDescription == null) - { - throw new ArgumentNullException(nameof(localizedDescription)); - } - - PhonePlanGroupId = phonePlanGroupId; - LocalizedName = localizedName; - LocalizedDescription = localizedDescription; - } - - /// Initializes a new instance of PhonePlanGroup. - /// The id of the plan group. - /// The phone number type of the plan group. - /// The name of the plan group. - /// The description of the plan group. - /// Represents carrier details. - /// Represents a wrapper of rate information. - internal PhonePlanGroup(string phonePlanGroupId, PhoneNumberType? phoneNumberType, string localizedName, string localizedDescription, CarrierDetails carrierDetails, RateInformation rateInformation) - { - PhonePlanGroupId = phonePlanGroupId; - PhoneNumberType = phoneNumberType; - LocalizedName = localizedName; - LocalizedDescription = localizedDescription; - CarrierDetails = carrierDetails; - RateInformation = rateInformation; - } - - /// The id of the plan group. - public string PhonePlanGroupId { get; } - /// The phone number type of the plan group. - public PhoneNumberType? PhoneNumberType { get; } - /// The name of the plan group. - public string LocalizedName { get; } - /// The description of the plan group. - public string LocalizedDescription { get; } - /// Represents carrier details. - public CarrierDetails CarrierDetails { get; } - /// Represents a wrapper of rate information. - public RateInformation RateInformation { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.Serialization.cs deleted file mode 100644 index 3a2d763bd33bf..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.Serialization.cs +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhonePlanGroups - { - internal static PhonePlanGroups DeserializePhonePlanGroups(JsonElement element) - { - Optional> phonePlanGroups = default; - Optional nextLink = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("phonePlanGroups")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(PhonePlanGroup.DeserializePhonePlanGroup(item)); - } - phonePlanGroups = array; - continue; - } - if (property.NameEquals("nextLink")) - { - nextLink = property.Value.GetString(); - continue; - } - } - return new PhonePlanGroups(Optional.ToList(phonePlanGroups), nextLink.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.cs deleted file mode 100644 index 72b38a775121a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlanGroups.cs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a wrapper of list of plan groups. - internal partial class PhonePlanGroups - { - /// Initializes a new instance of PhonePlanGroups. - internal PhonePlanGroups() - { - PhonePlanGroupsValue = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhonePlanGroups. - /// The underlying list of phone plan groups. - /// Represents the URL link to the next page. - internal PhonePlanGroups(IReadOnlyList phonePlanGroupsValue, string nextLink) - { - PhonePlanGroupsValue = phonePlanGroupsValue; - NextLink = nextLink; - } - - /// The underlying list of phone plan groups. - public IReadOnlyList PhonePlanGroupsValue { get; } - /// Represents the URL link to the next page. - public string NextLink { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.Serialization.cs deleted file mode 100644 index 854aa89f22627..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.Serialization.cs +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhonePlansResponse - { - internal static PhonePlansResponse DeserializePhonePlansResponse(JsonElement element) - { - Optional> phonePlans = default; - Optional nextLink = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("phonePlans")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - List array = new List(); - foreach (var item in property.Value.EnumerateArray()) - { - array.Add(PhonePlan.DeserializePhonePlan(item)); - } - phonePlans = array; - continue; - } - if (property.NameEquals("nextLink")) - { - nextLink = property.Value.GetString(); - continue; - } - } - return new PhonePlansResponse(Optional.ToList(phonePlans), nextLink.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.cs deleted file mode 100644 index 849e230824c65..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PhonePlansResponse.cs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a wrapper around a list of countries. - internal partial class PhonePlansResponse - { - /// Initializes a new instance of PhonePlansResponse. - internal PhonePlansResponse() - { - PhonePlans = new ChangeTrackingList(); - } - - /// Initializes a new instance of PhonePlansResponse. - /// Represents the underlying list of phone plans. - /// Represents the URL link to the next page. - internal PhonePlansResponse(IReadOnlyList phonePlans, string nextLink) - { - PhonePlans = phonePlans; - NextLink = nextLink; - } - - /// Represents the underlying list of phone plans. - public IReadOnlyList PhonePlans { get; } - /// Represents the URL link to the next page. - public string NextLink { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.Serialization.cs deleted file mode 100644 index 8b3d1b7c63116..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.Serialization.cs +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class PstnConfiguration : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - writer.WritePropertyName("callbackUrl"); - writer.WriteStringValue(CallbackUrl); - if (Optional.IsDefined(ApplicationId)) - { - writer.WritePropertyName("applicationId"); - writer.WriteStringValue(ApplicationId); - } - writer.WriteEndObject(); - } - - internal static PstnConfiguration DeserializePstnConfiguration(JsonElement element) - { - string callbackUrl = default; - Optional applicationId = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("callbackUrl")) - { - callbackUrl = property.Value.GetString(); - continue; - } - if (property.NameEquals("applicationId")) - { - applicationId = property.Value.GetString(); - continue; - } - } - return new PstnConfiguration(callbackUrl, applicationId.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.cs deleted file mode 100644 index ad3c18d415156..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/PstnConfiguration.cs +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Definition for pstn number configuration. - public partial class PstnConfiguration - { - /// Initializes a new instance of PstnConfiguration. - /// The webhook URL on the phone number configuration. - /// is null. - public PstnConfiguration(string callbackUrl) - { - if (callbackUrl == null) - { - throw new ArgumentNullException(nameof(callbackUrl)); - } - - CallbackUrl = callbackUrl; - } - - /// Initializes a new instance of PstnConfiguration. - /// The webhook URL on the phone number configuration. - /// The application id of the application to which to configure. - internal PstnConfiguration(string callbackUrl, string applicationId) - { - CallbackUrl = callbackUrl; - ApplicationId = applicationId; - } - - /// The webhook URL on the phone number configuration. - public string CallbackUrl { get; set; } - /// The application id of the application to which to configure. - public string ApplicationId { get; set; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.Serialization.cs deleted file mode 100644 index d4b201de46ae9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.Serialization.cs +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class RateInformation - { - internal static RateInformation DeserializeRateInformation(JsonElement element) - { - Optional monthlyRate = default; - Optional currencyType = default; - Optional rateErrorMessage = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("monthlyRate")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - monthlyRate = property.Value.GetDouble(); - continue; - } - if (property.NameEquals("currencyType")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - currencyType = new CurrencyType(property.Value.GetString()); - continue; - } - if (property.NameEquals("rateErrorMessage")) - { - rateErrorMessage = property.Value.GetString(); - continue; - } - } - return new RateInformation(Optional.ToNullable(monthlyRate), Optional.ToNullable(currencyType), rateErrorMessage.Value); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.cs deleted file mode 100644 index 80a4b342419a4..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/RateInformation.cs +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a wrapper of rate information. - public partial class RateInformation - { - /// Initializes a new instance of RateInformation. - internal RateInformation() - { - } - - /// Initializes a new instance of RateInformation. - /// The monthly rate of a phone plan group. - /// The currency of a phone plan group. - /// The error code of a phone plan group. - internal RateInformation(double? monthlyRate, CurrencyType? currencyType, string rateErrorMessage) - { - MonthlyRate = monthlyRate; - CurrencyType = currencyType; - RateErrorMessage = rateErrorMessage; - } - - /// The monthly rate of a phone plan group. - public double? MonthlyRate { get; } - /// The currency of a phone plan group. - public CurrencyType? CurrencyType { get; } - /// The error code of a phone plan group. - public string RateErrorMessage { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.Serialization.cs deleted file mode 100644 index 23adb41c869a8..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.Serialization.cs +++ /dev/null @@ -1,28 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class ReleaseRequest : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - writer.WritePropertyName("phoneNumbers"); - writer.WriteStartArray(); - foreach (var item in PhoneNumbers) - { - writer.WriteStringValue(item); - } - writer.WriteEndArray(); - writer.WriteEndObject(); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.cs deleted file mode 100644 index 36dffc89aa110..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseRequest.cs +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Linq; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a release request. - internal partial class ReleaseRequest - { - /// Initializes a new instance of ReleaseRequest. - /// The list of phone numbers in the release request. - /// is null. - public ReleaseRequest(IEnumerable phoneNumbers) - { - if (phoneNumbers == null) - { - throw new ArgumentNullException(nameof(phoneNumbers)); - } - - PhoneNumbers = phoneNumbers.ToList(); - } - - /// The list of phone numbers in the release request. - public IList PhoneNumbers { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseStatus.cs deleted file mode 100644 index 63d6700002c9c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReleaseStatus.cs +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The release status. - public readonly partial struct ReleaseStatus : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public ReleaseStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string PendingValue = "Pending"; - private const string InProgressValue = "InProgress"; - private const string CompleteValue = "Complete"; - private const string FailedValue = "Failed"; - private const string ExpiredValue = "Expired"; - - /// Pending. - public static ReleaseStatus Pending { get; } = new ReleaseStatus(PendingValue); - /// InProgress. - public static ReleaseStatus InProgress { get; } = new ReleaseStatus(InProgressValue); - /// Complete. - public static ReleaseStatus Complete { get; } = new ReleaseStatus(CompleteValue); - /// Failed. - public static ReleaseStatus Failed { get; } = new ReleaseStatus(FailedValue); - /// Expired. - public static ReleaseStatus Expired { get; } = new ReleaseStatus(ExpiredValue); - /// Determines if two values are the same. - public static bool operator ==(ReleaseStatus left, ReleaseStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(ReleaseStatus left, ReleaseStatus right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator ReleaseStatus(string value) => new ReleaseStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is ReleaseStatus other && Equals(other); - /// - public bool Equals(ReleaseStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReservationStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReservationStatus.cs deleted file mode 100644 index c52b020d8408d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/ReservationStatus.cs +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// The status of the search. - public readonly partial struct ReservationStatus : IEquatable - { - private readonly string _value; - - /// Determines if two values are the same. - /// is null. - public ReservationStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string PendingValue = "Pending"; - private const string InProgressValue = "InProgress"; - private const string ReservedValue = "Reserved"; - private const string ExpiredValue = "Expired"; - private const string ExpiringValue = "Expiring"; - private const string CompletingValue = "Completing"; - private const string RefreshingValue = "Refreshing"; - private const string SuccessValue = "Success"; - private const string ManualValue = "Manual"; - private const string CancelledValue = "Cancelled"; - private const string CancellingValue = "Cancelling"; - private const string ErrorValue = "Error"; - private const string PurchasePendingValue = "PurchasePending"; - - /// Pending. - public static ReservationStatus Pending { get; } = new ReservationStatus(PendingValue); - /// InProgress. - public static ReservationStatus InProgress { get; } = new ReservationStatus(InProgressValue); - /// Reserved. - public static ReservationStatus Reserved { get; } = new ReservationStatus(ReservedValue); - /// Expired. - public static ReservationStatus Expired { get; } = new ReservationStatus(ExpiredValue); - /// Expiring. - public static ReservationStatus Expiring { get; } = new ReservationStatus(ExpiringValue); - /// Completing. - public static ReservationStatus Completing { get; } = new ReservationStatus(CompletingValue); - /// Refreshing. - public static ReservationStatus Refreshing { get; } = new ReservationStatus(RefreshingValue); - /// Success. - public static ReservationStatus Success { get; } = new ReservationStatus(SuccessValue); - /// Manual. - public static ReservationStatus Manual { get; } = new ReservationStatus(ManualValue); - /// Cancelled. - public static ReservationStatus Cancelled { get; } = new ReservationStatus(CancelledValue); - /// Cancelling. - public static ReservationStatus Cancelling { get; } = new ReservationStatus(CancellingValue); - /// Error. - public static ReservationStatus Error { get; } = new ReservationStatus(ErrorValue); - /// PurchasePending. - public static ReservationStatus PurchasePending { get; } = new ReservationStatus(PurchasePendingValue); - /// Determines if two values are the same. - public static bool operator ==(ReservationStatus left, ReservationStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(ReservationStatus left, ReservationStatus right) => !left.Equals(right); - /// Converts a string to a . - public static implicit operator ReservationStatus(string value) => new ReservationStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is ReservationStatus other && Equals(other); - /// - public bool Equals(ReservationStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value?.GetHashCode() ?? 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.Serialization.cs deleted file mode 100644 index 16d81874ac01f..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.Serialization.cs +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class UpdateNumberCapabilitiesRequest : IUtf8JsonSerializable - { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) - { - writer.WriteStartObject(); - writer.WritePropertyName("phoneNumberCapabilitiesUpdate"); - writer.WriteStartObject(); - foreach (var item in PhoneNumberCapabilitiesUpdate) - { - writer.WritePropertyName(item.Key); - writer.WriteObjectValue(item.Value); - } - writer.WriteEndObject(); - writer.WriteEndObject(); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.cs deleted file mode 100644 index 5a0694d7a540a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesRequest.cs +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a numbers capabilities update request. - internal partial class UpdateNumberCapabilitiesRequest - { - /// Initializes a new instance of UpdateNumberCapabilitiesRequest. - /// The map of phone numbers to the capabilities update applied to the phone number. - /// is null. - public UpdateNumberCapabilitiesRequest(IDictionary phoneNumberCapabilitiesUpdate) - { - if (phoneNumberCapabilitiesUpdate == null) - { - throw new ArgumentNullException(nameof(phoneNumberCapabilitiesUpdate)); - } - - PhoneNumberCapabilitiesUpdate = phoneNumberCapabilitiesUpdate; - } - - /// The map of phone numbers to the capabilities update applied to the phone number. - public IDictionary PhoneNumberCapabilitiesUpdate { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.Serialization.cs deleted file mode 100644 index bede12ac0ddae..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.Serialization.cs +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class UpdateNumberCapabilitiesResponse - { - internal static UpdateNumberCapabilitiesResponse DeserializeUpdateNumberCapabilitiesResponse(JsonElement element) - { - string capabilitiesUpdateId = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("capabilitiesUpdateId")) - { - capabilitiesUpdateId = property.Value.GetString(); - continue; - } - } - return new UpdateNumberCapabilitiesResponse(capabilitiesUpdateId); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.cs deleted file mode 100644 index 52f48221690bc..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdateNumberCapabilitiesResponse.cs +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Represents a number capability update response. - public partial class UpdateNumberCapabilitiesResponse - { - /// Initializes a new instance of UpdateNumberCapabilitiesResponse. - /// The capabilities id. - /// is null. - internal UpdateNumberCapabilitiesResponse(string capabilitiesUpdateId) - { - if (capabilitiesUpdateId == null) - { - throw new ArgumentNullException(nameof(capabilitiesUpdateId)); - } - - CapabilitiesUpdateId = capabilitiesUpdateId; - } - - /// The capabilities id. - public string CapabilitiesUpdateId { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.Serialization.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.Serialization.cs deleted file mode 100644 index f1f2fe5459e51..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.Serialization.cs +++ /dev/null @@ -1,69 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Text.Json; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - public partial class UpdatePhoneNumberCapabilitiesResponse - { - internal static UpdatePhoneNumberCapabilitiesResponse DeserializeUpdatePhoneNumberCapabilitiesResponse(JsonElement element) - { - Optional capabilitiesUpdateId = default; - Optional createdAt = default; - Optional capabilitiesUpdateStatus = default; - Optional> phoneNumberCapabilitiesUpdates = default; - foreach (var property in element.EnumerateObject()) - { - if (property.NameEquals("capabilitiesUpdateId")) - { - capabilitiesUpdateId = property.Value.GetString(); - continue; - } - if (property.NameEquals("createdAt")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - createdAt = property.Value.GetDateTimeOffset("O"); - continue; - } - if (property.NameEquals("capabilitiesUpdateStatus")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - capabilitiesUpdateStatus = new CapabilitiesUpdateStatus(property.Value.GetString()); - continue; - } - if (property.NameEquals("phoneNumberCapabilitiesUpdates")) - { - if (property.Value.ValueKind == JsonValueKind.Null) - { - property.ThrowNonNullablePropertyIsNull(); - continue; - } - Dictionary dictionary = new Dictionary(); - foreach (var property0 in property.Value.EnumerateObject()) - { - dictionary.Add(property0.Name, NumberUpdateCapabilities.DeserializeNumberUpdateCapabilities(property0.Value)); - } - phoneNumberCapabilitiesUpdates = dictionary; - continue; - } - } - return new UpdatePhoneNumberCapabilitiesResponse(capabilitiesUpdateId.Value, Optional.ToNullable(createdAt), Optional.ToNullable(capabilitiesUpdateStatus), Optional.ToDictionary(phoneNumberCapabilitiesUpdates)); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.cs deleted file mode 100644 index 875ad5aff848c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/Models/UpdatePhoneNumberCapabilitiesResponse.cs +++ /dev/null @@ -1,45 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// Response for getting a phone number update capabilities. - public partial class UpdatePhoneNumberCapabilitiesResponse - { - /// Initializes a new instance of UpdatePhoneNumberCapabilitiesResponse. - internal UpdatePhoneNumberCapabilitiesResponse() - { - PhoneNumberCapabilitiesUpdates = new ChangeTrackingDictionary(); - } - - /// Initializes a new instance of UpdatePhoneNumberCapabilitiesResponse. - /// The id of the phone number capabilities update. - /// The time the capabilities update was created. - /// Status of the capabilities update. - /// The capabilities update for each of a set of phone numbers. - internal UpdatePhoneNumberCapabilitiesResponse(string capabilitiesUpdateId, DateTimeOffset? createdAt, CapabilitiesUpdateStatus? capabilitiesUpdateStatus, IReadOnlyDictionary phoneNumberCapabilitiesUpdates) - { - CapabilitiesUpdateId = capabilitiesUpdateId; - CreatedAt = createdAt; - CapabilitiesUpdateStatus = capabilitiesUpdateStatus; - PhoneNumberCapabilitiesUpdates = phoneNumberCapabilitiesUpdates; - } - - /// The id of the phone number capabilities update. - public string CapabilitiesUpdateId { get; } - /// The time the capabilities update was created. - public DateTimeOffset? CreatedAt { get; } - /// Status of the capabilities update. - public CapabilitiesUpdateStatus? CapabilitiesUpdateStatus { get; } - /// The capabilities update for each of a set of phone numbers. - public IReadOnlyDictionary PhoneNumberCapabilitiesUpdates { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumberAdministrationRestClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumberAdministrationRestClient.cs deleted file mode 100644 index e16d217a37153..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumberAdministrationRestClient.cs +++ /dev/null @@ -1,1935 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.Collections.Generic; -using System.Text.Json; -using System.Threading; -using System.Threading.Tasks; -using Azure; -using Azure.Communication.PhoneNumbers.Models; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers -{ - internal partial class PhoneNumberAdministrationRestClient - { - private string endpoint; - private string apiVersion; - private ClientDiagnostics _clientDiagnostics; - private HttpPipeline _pipeline; - - /// Initializes a new instance of PhoneNumberAdministrationRestClient. - /// The handler for diagnostic messaging in the client. - /// The HTTP pipeline for sending and receiving REST requests and responses. - /// The endpoint of the Azure Communication resource. - /// Api Version. - /// or is null. - public PhoneNumberAdministrationRestClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2020-07-20-preview1") - { - if (endpoint == null) - { - throw new ArgumentNullException(nameof(endpoint)); - } - if (apiVersion == null) - { - throw new ArgumentNullException(nameof(apiVersion)); - } - - this.endpoint = endpoint; - this.apiVersion = apiVersion; - _clientDiagnostics = clientDiagnostics; - _pipeline = pipeline; - } - - internal HttpMessage CreateGetAllPhoneNumbersRequest(string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/phonenumbers", false); - if (locale != null) - { - uri.AppendQuery("locale", locale, true); - } - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets the list of the acquired phone numbers. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public async Task> GetAllPhoneNumbersAsync(string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllPhoneNumbersRequest(locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - AcquiredPhoneNumbers value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets the list of the acquired phone numbers. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public Response GetAllPhoneNumbers(string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllPhoneNumbersRequest(locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - AcquiredPhoneNumbers value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllAreaCodesRequest(string locationType, string countryCode, string phonePlanId, IEnumerable locationOptions) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/countries/", false); - uri.AppendPath(countryCode, true); - uri.AppendPath("/areacodes", false); - uri.AppendQuery("locationType", locationType, true); - uri.AppendQuery("phonePlanId", phonePlanId, true); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - LocationOptionsQueries locationOptionsQueries = new LocationOptionsQueries(); - foreach (var value in locationOptions) - { - locationOptionsQueries.LocationOptions.Add(value); - } - var model = locationOptionsQueries; - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Gets a list of the supported area codes. - /// The type of location information required by the plan. - /// The ISO 3166-2 country code. - /// The plan id from which to search area codes. - /// Represents the underlying list of countries. - /// The cancellation token to use. - /// , , or is null. - public async Task> GetAllAreaCodesAsync(string locationType, string countryCode, string phonePlanId, IEnumerable locationOptions = null, CancellationToken cancellationToken = default) - { - if (locationType == null) - { - throw new ArgumentNullException(nameof(locationType)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanId == null) - { - throw new ArgumentNullException(nameof(phonePlanId)); - } - - using var message = CreateGetAllAreaCodesRequest(locationType, countryCode, phonePlanId, locationOptions); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - AreaCodes value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = AreaCodes.DeserializeAreaCodes(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of the supported area codes. - /// The type of location information required by the plan. - /// The ISO 3166-2 country code. - /// The plan id from which to search area codes. - /// Represents the underlying list of countries. - /// The cancellation token to use. - /// , , or is null. - public Response GetAllAreaCodes(string locationType, string countryCode, string phonePlanId, IEnumerable locationOptions = null, CancellationToken cancellationToken = default) - { - if (locationType == null) - { - throw new ArgumentNullException(nameof(locationType)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanId == null) - { - throw new ArgumentNullException(nameof(phonePlanId)); - } - - using var message = CreateGetAllAreaCodesRequest(locationType, countryCode, phonePlanId, locationOptions); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - AreaCodes value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = AreaCodes.DeserializeAreaCodes(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetCapabilitiesUpdateRequest(string capabilitiesUpdateId) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/capabilities/", false); - uri.AppendPath(capabilitiesUpdateId, true); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Get capabilities by capabilities update id. - /// The String to use. - /// The cancellation token to use. - /// is null. - public async Task> GetCapabilitiesUpdateAsync(string capabilitiesUpdateId, CancellationToken cancellationToken = default) - { - if (capabilitiesUpdateId == null) - { - throw new ArgumentNullException(nameof(capabilitiesUpdateId)); - } - - using var message = CreateGetCapabilitiesUpdateRequest(capabilitiesUpdateId); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - UpdatePhoneNumberCapabilitiesResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = UpdatePhoneNumberCapabilitiesResponse.DeserializeUpdatePhoneNumberCapabilitiesResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Get capabilities by capabilities update id. - /// The String to use. - /// The cancellation token to use. - /// is null. - public Response GetCapabilitiesUpdate(string capabilitiesUpdateId, CancellationToken cancellationToken = default) - { - if (capabilitiesUpdateId == null) - { - throw new ArgumentNullException(nameof(capabilitiesUpdateId)); - } - - using var message = CreateGetCapabilitiesUpdateRequest(capabilitiesUpdateId); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - UpdatePhoneNumberCapabilitiesResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = UpdatePhoneNumberCapabilitiesResponse.DeserializeUpdatePhoneNumberCapabilitiesResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateUpdateCapabilitiesRequest(IDictionary phoneNumberCapabilitiesUpdate) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/capabilities", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var model = new UpdateNumberCapabilitiesRequest(phoneNumberCapabilitiesUpdate); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Adds or removes phone number capabilities. - /// The map of phone numbers to the capabilities update applied to the phone number. - /// The cancellation token to use. - /// is null. - public async Task> UpdateCapabilitiesAsync(IDictionary phoneNumberCapabilitiesUpdate, CancellationToken cancellationToken = default) - { - if (phoneNumberCapabilitiesUpdate == null) - { - throw new ArgumentNullException(nameof(phoneNumberCapabilitiesUpdate)); - } - - using var message = CreateUpdateCapabilitiesRequest(phoneNumberCapabilitiesUpdate); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - UpdateNumberCapabilitiesResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = UpdateNumberCapabilitiesResponse.DeserializeUpdateNumberCapabilitiesResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Adds or removes phone number capabilities. - /// The map of phone numbers to the capabilities update applied to the phone number. - /// The cancellation token to use. - /// is null. - public Response UpdateCapabilities(IDictionary phoneNumberCapabilitiesUpdate, CancellationToken cancellationToken = default) - { - if (phoneNumberCapabilitiesUpdate == null) - { - throw new ArgumentNullException(nameof(phoneNumberCapabilitiesUpdate)); - } - - using var message = CreateUpdateCapabilitiesRequest(phoneNumberCapabilitiesUpdate); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - UpdateNumberCapabilitiesResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = UpdateNumberCapabilitiesResponse.DeserializeUpdateNumberCapabilitiesResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllSupportedCountriesRequest(string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/countries", false); - if (locale != null) - { - uri.AppendQuery("locale", locale, true); - } - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of supported countries. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public async Task> GetAllSupportedCountriesAsync(string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllSupportedCountriesRequest(locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberCountries value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberCountries.DeserializePhoneNumberCountries(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of supported countries. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public Response GetAllSupportedCountries(string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllSupportedCountriesRequest(locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberCountries value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberCountries.DeserializePhoneNumberCountries(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetNumberConfigurationRequest(string phoneNumber) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/numberconfiguration", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var model = new NumberConfigurationPhoneNumber(phoneNumber); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Endpoint for getting number configurations. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// is null. - public async Task> GetNumberConfigurationAsync(string phoneNumber, CancellationToken cancellationToken = default) - { - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateGetNumberConfigurationRequest(phoneNumber); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - NumberConfigurationResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = NumberConfigurationResponse.DeserializeNumberConfigurationResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Endpoint for getting number configurations. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// is null. - public Response GetNumberConfiguration(string phoneNumber, CancellationToken cancellationToken = default) - { - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateGetNumberConfigurationRequest(phoneNumber); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - NumberConfigurationResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = NumberConfigurationResponse.DeserializeNumberConfigurationResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateConfigureNumberRequest(PstnConfiguration pstnConfiguration, string phoneNumber) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Patch; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/numberconfiguration/configure", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var model = new NumberConfiguration(pstnConfiguration, phoneNumber); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Endpoint for configuring a pstn number. - /// Definition for pstn number configuration. - /// The phone number to configure. - /// The cancellation token to use. - /// or is null. - public async Task ConfigureNumberAsync(PstnConfiguration pstnConfiguration, string phoneNumber, CancellationToken cancellationToken = default) - { - if (pstnConfiguration == null) - { - throw new ArgumentNullException(nameof(pstnConfiguration)); - } - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateConfigureNumberRequest(pstnConfiguration, phoneNumber); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - return message.Response; - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Endpoint for configuring a pstn number. - /// Definition for pstn number configuration. - /// The phone number to configure. - /// The cancellation token to use. - /// or is null. - public Response ConfigureNumber(PstnConfiguration pstnConfiguration, string phoneNumber, CancellationToken cancellationToken = default) - { - if (pstnConfiguration == null) - { - throw new ArgumentNullException(nameof(pstnConfiguration)); - } - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateConfigureNumberRequest(pstnConfiguration, phoneNumber); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - return message.Response; - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateUnconfigureNumberRequest(string phoneNumber) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Patch; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/numberconfiguration/unconfigure", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var model = new NumberConfigurationPhoneNumber(phoneNumber); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Endpoint for unconfiguring a pstn number by removing the configuration. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// is null. - public async Task UnconfigureNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) - { - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateUnconfigureNumberRequest(phoneNumber); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - return message.Response; - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Endpoint for unconfiguring a pstn number by removing the configuration. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// is null. - public Response UnconfigureNumber(string phoneNumber, CancellationToken cancellationToken = default) - { - if (phoneNumber == null) - { - throw new ArgumentNullException(nameof(phoneNumber)); - } - - using var message = CreateUnconfigureNumberRequest(phoneNumber); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - return message.Response; - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetPhonePlanGroupsRequest(string countryCode, string locale, bool? includeRateInformation, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/countries/", false); - uri.AppendPath(countryCode, true); - uri.AppendPath("/phoneplangroups", false); - if (locale != null) - { - uri.AppendQuery("locale", locale, true); - } - if (includeRateInformation != null) - { - uri.AppendQuery("includeRateInformation", includeRateInformation.Value, true); - } - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of phone plan groups for the given country. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localize the names of countries. - /// The Boolean to use. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public async Task> GetPhonePlanGroupsAsync(string countryCode, string locale = null, bool? includeRateInformation = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - - using var message = CreateGetPhonePlanGroupsRequest(countryCode, locale, includeRateInformation, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhonePlanGroups value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhonePlanGroups.DeserializePhonePlanGroups(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of phone plan groups for the given country. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localize the names of countries. - /// The Boolean to use. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public Response GetPhonePlanGroups(string countryCode, string locale = null, bool? includeRateInformation = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - - using var message = CreateGetPhonePlanGroupsRequest(countryCode, locale, includeRateInformation, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhonePlanGroups value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhonePlanGroups.DeserializePhonePlanGroups(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetPhonePlansRequest(string countryCode, string phonePlanGroupId, string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/countries/", false); - uri.AppendPath(countryCode, true); - uri.AppendPath("/phoneplangroups/", false); - uri.AppendPath(phonePlanGroupId, true); - uri.AppendPath("/phoneplans", false); - if (locale != null) - { - uri.AppendQuery("locale", locale, true); - } - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of phone plans for a phone plan group. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// or is null. - public async Task> GetPhonePlansAsync(string countryCode, string phonePlanGroupId, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - - using var message = CreateGetPhonePlansRequest(countryCode, phonePlanGroupId, locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhonePlansResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhonePlansResponse.DeserializePhonePlansResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of phone plans for a phone plan group. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// or is null. - public Response GetPhonePlans(string countryCode, string phonePlanGroupId, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - - using var message = CreateGetPhonePlansRequest(countryCode, phonePlanGroupId, locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhonePlansResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhonePlansResponse.DeserializePhonePlansResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetPhonePlanLocationOptionsRequest(string countryCode, string phonePlanGroupId, string phonePlanId, string locale) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/countries/", false); - uri.AppendPath(countryCode, true); - uri.AppendPath("/phoneplangroups/", false); - uri.AppendPath(phonePlanGroupId, true); - uri.AppendPath("/phoneplans/", false); - uri.AppendPath(phonePlanId, true); - uri.AppendPath("/locationoptions", false); - if (locale != null) - { - uri.AppendQuery("locale", locale, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of location options for a phone plan. - /// The ISO 3166-2 country code. - /// The String to use. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// The cancellation token to use. - /// , , or is null. - public async Task> GetPhonePlanLocationOptionsAsync(string countryCode, string phonePlanGroupId, string phonePlanId, string locale = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - if (phonePlanId == null) - { - throw new ArgumentNullException(nameof(phonePlanId)); - } - - using var message = CreateGetPhonePlanLocationOptionsRequest(countryCode, phonePlanGroupId, phonePlanId, locale); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - LocationOptionsResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = LocationOptionsResponse.DeserializeLocationOptionsResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of location options for a phone plan. - /// The ISO 3166-2 country code. - /// The String to use. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// The cancellation token to use. - /// , , or is null. - public Response GetPhonePlanLocationOptions(string countryCode, string phonePlanGroupId, string phonePlanId, string locale = null, CancellationToken cancellationToken = default) - { - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - if (phonePlanId == null) - { - throw new ArgumentNullException(nameof(phonePlanId)); - } - - using var message = CreateGetPhonePlanLocationOptionsRequest(countryCode, phonePlanGroupId, phonePlanId, locale); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - LocationOptionsResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = LocationOptionsResponse.DeserializeLocationOptionsResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetReleaseByIdRequest(string releaseId) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/releases/", false); - uri.AppendPath(releaseId, true); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a release by a release id. - /// Represents the release id. - /// The cancellation token to use. - /// is null. - public async Task> GetReleaseByIdAsync(string releaseId, CancellationToken cancellationToken = default) - { - if (releaseId == null) - { - throw new ArgumentNullException(nameof(releaseId)); - } - - using var message = CreateGetReleaseByIdRequest(releaseId); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberRelease value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberRelease.DeserializePhoneNumberRelease(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a release by a release id. - /// Represents the release id. - /// The cancellation token to use. - /// is null. - public Response GetReleaseById(string releaseId, CancellationToken cancellationToken = default) - { - if (releaseId == null) - { - throw new ArgumentNullException(nameof(releaseId)); - } - - using var message = CreateGetReleaseByIdRequest(releaseId); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberRelease value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberRelease.DeserializePhoneNumberRelease(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateReleasePhoneNumbersRequest(IEnumerable phoneNumbers) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/releases", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var model = new ReleaseRequest(phoneNumbers); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(model); - request.Content = content; - return message; - } - - /// Creates a release for the given phone numbers. - /// The list of phone numbers in the release request. - /// The cancellation token to use. - /// is null. - public async Task> ReleasePhoneNumbersAsync(IEnumerable phoneNumbers, CancellationToken cancellationToken = default) - { - if (phoneNumbers == null) - { - throw new ArgumentNullException(nameof(phoneNumbers)); - } - - using var message = CreateReleasePhoneNumbersRequest(phoneNumbers); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberReleaseResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberReleaseResponse.DeserializePhoneNumberReleaseResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Creates a release for the given phone numbers. - /// The list of phone numbers in the release request. - /// The cancellation token to use. - /// is null. - public Response ReleasePhoneNumbers(IEnumerable phoneNumbers, CancellationToken cancellationToken = default) - { - if (phoneNumbers == null) - { - throw new ArgumentNullException(nameof(phoneNumbers)); - } - - using var message = CreateReleasePhoneNumbersRequest(phoneNumbers); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberReleaseResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberReleaseResponse.DeserializePhoneNumberReleaseResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllReleasesRequest(int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/releases", false); - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of all releases. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public async Task> GetAllReleasesAsync(int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllReleasesRequest(skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of all releases. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public Response GetAllReleases(int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllReleasesRequest(skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetSearchByIdRequest(string searchId) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/searches/", false); - uri.AppendPath(searchId, true); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Get search by search id. - /// The search id to be searched for. - /// The cancellation token to use. - /// is null. - public async Task> GetSearchByIdAsync(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreateGetSearchByIdRequest(searchId); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberReservation value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberReservation.DeserializePhoneNumberReservation(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Get search by search id. - /// The search id to be searched for. - /// The cancellation token to use. - /// is null. - public Response GetSearchById(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreateGetSearchByIdRequest(searchId); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberReservation value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberReservation.DeserializePhoneNumberReservation(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateCreateSearchRequest(CreateReservationOptions body) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/searches", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - if (body != null) - { - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(body); - request.Content = content; - } - return message; - } - - /// Creates a phone number search. - /// Defines the search options. - /// The cancellation token to use. - public async Task> CreateSearchAsync(CreateReservationOptions body = null, CancellationToken cancellationToken = default) - { - using var message = CreateCreateSearchRequest(body); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 201: - { - CreateReservationResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = CreateReservationResponse.DeserializeCreateReservationResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Creates a phone number search. - /// Defines the search options. - /// The cancellation token to use. - public Response CreateSearch(CreateReservationOptions body = null, CancellationToken cancellationToken = default) - { - using var message = CreateCreateSearchRequest(body); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 201: - { - CreateReservationResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = CreateReservationResponse.DeserializeCreateReservationResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllSearchesRequest(int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/searches", false); - if (skip != null) - { - uri.AppendQuery("skip", skip.Value, true); - } - if (take != null) - { - uri.AppendQuery("take", take.Value, true); - } - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of all searches. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public async Task> GetAllSearchesAsync(int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllSearchesRequest(skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of all searches. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - public Response GetAllSearches(int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - using var message = CreateGetAllSearchesRequest(skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateCancelSearchRequest(string searchId) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/searches/", false); - uri.AppendPath(searchId, true); - uri.AppendPath("/cancel", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Cancels the search. This means existing numbers in the search will be made available. - /// The search id to be canceled. - /// The cancellation token to use. - /// is null. - public async Task CancelSearchAsync(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreateCancelSearchRequest(searchId); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 202: - return message.Response; - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Cancels the search. This means existing numbers in the search will be made available. - /// The search id to be canceled. - /// The cancellation token to use. - /// is null. - public Response CancelSearch(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreateCancelSearchRequest(searchId); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 202: - return message.Response; - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreatePurchaseSearchRequest(string searchId) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Post; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendPath("/administration/phonenumbers/searches/", false); - uri.AppendPath(searchId, true); - uri.AppendPath("/purchase", false); - uri.AppendQuery("api-version", apiVersion, true); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Purchases the phone number search. - /// The search id to be purchased. - /// The cancellation token to use. - /// is null. - public async Task PurchaseSearchAsync(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreatePurchaseSearchRequest(searchId); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 202: - return message.Response; - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Purchases the phone number search. - /// The search id to be purchased. - /// The cancellation token to use. - /// is null. - public Response PurchaseSearch(string searchId, CancellationToken cancellationToken = default) - { - if (searchId == null) - { - throw new ArgumentNullException(nameof(searchId)); - } - - using var message = CreatePurchaseSearchRequest(searchId); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 202: - return message.Response; - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllPhoneNumbersNextPageRequest(string nextLink, string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets the list of the acquired phone numbers. - /// The URL to the next page of results. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public async Task> GetAllPhoneNumbersNextPageAsync(string nextLink, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllPhoneNumbersNextPageRequest(nextLink, locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - AcquiredPhoneNumbers value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets the list of the acquired phone numbers. - /// The URL to the next page of results. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public Response GetAllPhoneNumbersNextPage(string nextLink, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllPhoneNumbersNextPageRequest(nextLink, locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - AcquiredPhoneNumbers value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = AcquiredPhoneNumbers.DeserializeAcquiredPhoneNumbers(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllSupportedCountriesNextPageRequest(string nextLink, string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of supported countries. - /// The URL to the next page of results. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public async Task> GetAllSupportedCountriesNextPageAsync(string nextLink, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllSupportedCountriesNextPageRequest(nextLink, locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberCountries value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberCountries.DeserializePhoneNumberCountries(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of supported countries. - /// The URL to the next page of results. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public Response GetAllSupportedCountriesNextPage(string nextLink, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllSupportedCountriesNextPageRequest(nextLink, locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberCountries value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberCountries.DeserializePhoneNumberCountries(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetPhonePlanGroupsNextPageRequest(string nextLink, string countryCode, string locale, bool? includeRateInformation, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of phone plan groups for the given country. - /// The URL to the next page of results. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localize the names of countries. - /// The Boolean to use. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// or is null. - public async Task> GetPhonePlanGroupsNextPageAsync(string nextLink, string countryCode, string locale = null, bool? includeRateInformation = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - - using var message = CreateGetPhonePlanGroupsNextPageRequest(nextLink, countryCode, locale, includeRateInformation, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhonePlanGroups value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhonePlanGroups.DeserializePhonePlanGroups(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of phone plan groups for the given country. - /// The URL to the next page of results. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localize the names of countries. - /// The Boolean to use. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// or is null. - public Response GetPhonePlanGroupsNextPage(string nextLink, string countryCode, string locale = null, bool? includeRateInformation = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - - using var message = CreateGetPhonePlanGroupsNextPageRequest(nextLink, countryCode, locale, includeRateInformation, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhonePlanGroups value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhonePlanGroups.DeserializePhonePlanGroups(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetPhonePlansNextPageRequest(string nextLink, string countryCode, string phonePlanGroupId, string locale, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of phone plans for a phone plan group. - /// The URL to the next page of results. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// , , or is null. - public async Task> GetPhonePlansNextPageAsync(string nextLink, string countryCode, string phonePlanGroupId, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - - using var message = CreateGetPhonePlansNextPageRequest(nextLink, countryCode, phonePlanGroupId, locale, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhonePlansResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhonePlansResponse.DeserializePhonePlansResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of phone plans for a phone plan group. - /// The URL to the next page of results. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localize the names of countries. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// , , or is null. - public Response GetPhonePlansNextPage(string nextLink, string countryCode, string phonePlanGroupId, string locale = null, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - if (countryCode == null) - { - throw new ArgumentNullException(nameof(countryCode)); - } - if (phonePlanGroupId == null) - { - throw new ArgumentNullException(nameof(phonePlanGroupId)); - } - - using var message = CreateGetPhonePlansNextPageRequest(nextLink, countryCode, phonePlanGroupId, locale, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhonePlansResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhonePlansResponse.DeserializePhonePlansResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllReleasesNextPageRequest(string nextLink, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of all releases. - /// The URL to the next page of results. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public async Task> GetAllReleasesNextPageAsync(string nextLink, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllReleasesNextPageRequest(nextLink, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of all releases. - /// The URL to the next page of results. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public Response GetAllReleasesNextPage(string nextLink, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllReleasesNextPageRequest(nextLink, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - - internal HttpMessage CreateGetAllSearchesNextPageRequest(string nextLink, int? skip, int? take) - { - var message = _pipeline.CreateMessage(); - var request = message.Request; - request.Method = RequestMethod.Get; - var uri = new RawRequestUriBuilder(); - uri.AppendRaw(endpoint, false); - uri.AppendRawNextLink(nextLink, false); - request.Uri = uri; - request.Headers.Add("Accept", "application/json"); - return message; - } - - /// Gets a list of all searches. - /// The URL to the next page of results. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public async Task> GetAllSearchesNextPageAsync(string nextLink, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllSearchesNextPageRequest(nextLink, skip, take); - await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, default, cancellationToken).ConfigureAwait(false); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw await _clientDiagnostics.CreateRequestFailedExceptionAsync(message.Response).ConfigureAwait(false); - } - } - - /// Gets a list of all searches. - /// The URL to the next page of results. - /// An optional parameter for how many entries to skip, for pagination purposes. - /// An optional parameter for how many entries to return, for pagination purposes. - /// The cancellation token to use. - /// is null. - public Response GetAllSearchesNextPage(string nextLink, int? skip = null, int? take = null, CancellationToken cancellationToken = default) - { - if (nextLink == null) - { - throw new ArgumentNullException(nameof(nextLink)); - } - - using var message = CreateGetAllSearchesNextPageRequest(nextLink, skip, take); - _pipeline.Send(message, cancellationToken); - switch (message.Response.Status) - { - case 200: - { - PhoneNumberEntities value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream); - value = PhoneNumberEntities.DeserializePhoneNumberEntities(document.RootElement); - return Response.FromValue(value, message.Response); - } - default: - throw _clientDiagnostics.CreateRequestFailedException(message.Response); - } - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersClientOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersClientOptions.cs new file mode 100644 index 0000000000000..2e7050307157e --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersClientOptions.cs @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + /// Client options for PhoneNumbersClient. + public partial class PhoneNumbersClientOptions : ClientOptions + { + private const ServiceVersion LatestVersion = ServiceVersion.V2021_03_07; + + /// The version of the service to use. + public enum ServiceVersion + { + /// Service version "2021-03-07". + V2021_03_07 = 1, + } + + internal string Version { get; } + + /// Initializes new instance of PhoneNumbersClientOptions. + public PhoneNumbersClientOptions(ServiceVersion version = LatestVersion) + { + Version = version switch + { + ServiceVersion.V2021_03_07 => "2021-03-07", + _ => throw new NotSupportedException() + }; + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersGetOperationHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersGetOperationHeaders.cs new file mode 100644 index 0000000000000..65dff9feb9890 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersGetOperationHeaders.cs @@ -0,0 +1,23 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using Azure; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class PhoneNumbersGetOperationHeaders + { + private readonly Response _response; + public PhoneNumbersGetOperationHeaders(Response response) + { + _response = response; + } + /// Url to retrieve the final result after operation completes. + public string Location => _response.Headers.TryGetValue("Location", out string value) ? value : null; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersPurchasePhoneNumbersHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersPurchasePhoneNumbersHeaders.cs new file mode 100644 index 0000000000000..cad92ccabb2dd --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersPurchasePhoneNumbersHeaders.cs @@ -0,0 +1,27 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using Azure; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class PhoneNumbersPurchasePhoneNumbersHeaders + { + private readonly Response _response; + public PhoneNumbersPurchasePhoneNumbersHeaders(Response response) + { + _response = response; + } + /// URL to query for status of the operation. + public string OperationLocation => _response.Headers.TryGetValue("Operation-Location", out string value) ? value : null; + /// The operation id. + public string OperationId => _response.Headers.TryGetValue("operation-id", out string value) ? value : null; + /// The purchase operation id. + public string PurchaseId => _response.Headers.TryGetValue("purchase-id", out string value) ? value : null; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersReleasePhoneNumberHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersReleasePhoneNumberHeaders.cs new file mode 100644 index 0000000000000..1e0803504eca8 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersReleasePhoneNumberHeaders.cs @@ -0,0 +1,27 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using Azure; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class PhoneNumbersReleasePhoneNumberHeaders + { + private readonly Response _response; + public PhoneNumbersReleasePhoneNumberHeaders(Response response) + { + _response = response; + } + /// URL to query for status of the operation. + public string OperationLocation => _response.Headers.TryGetValue("Operation-Location", out string value) ? value : null; + /// The operation id. + public string OperationId => _response.Headers.TryGetValue("operation-id", out string value) ? value : null; + /// The release operation id. + public string ReleaseId => _response.Headers.TryGetValue("release-id", out string value) ? value : null; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs new file mode 100644 index 0000000000000..0c78070c27f2a --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs @@ -0,0 +1,29 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using Azure; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class PhoneNumbersSearchAvailablePhoneNumbersHeaders + { + private readonly Response _response; + public PhoneNumbersSearchAvailablePhoneNumbersHeaders(Response response) + { + _response = response; + } + /// URL to retrieve the final result after operation completes. + public string Location => _response.Headers.TryGetValue("Location", out string value) ? value : null; + /// URL to query for status of the operation. + public string OperationLocation => _response.Headers.TryGetValue("Operation-Location", out string value) ? value : null; + /// The operation id. + public string OperationId => _response.Headers.TryGetValue("operation-id", out string value) ? value : null; + /// The search operation id. + public string SearchId => _response.Headers.TryGetValue("search-id", out string value) ? value : null; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersUpdateCapabilitiesHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersUpdateCapabilitiesHeaders.cs new file mode 100644 index 0000000000000..1661e84046068 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PhoneNumbersUpdateCapabilitiesHeaders.cs @@ -0,0 +1,29 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using Azure; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + internal partial class PhoneNumbersUpdateCapabilitiesHeaders + { + private readonly Response _response; + public PhoneNumbersUpdateCapabilitiesHeaders(Response response) + { + _response = response; + } + /// URL to retrieve the final result after operation completes. + public string Location => _response.Headers.TryGetValue("Location", out string value) ? value : null; + /// URL to query for status of the operation. + public string OperationLocation => _response.Headers.TryGetValue("Operation-Location", out string value) ? value : null; + /// The operation id. + public string OperationId => _response.Headers.TryGetValue("operation-id", out string value) ? value : null; + /// The capabilities operation id. + public string CapabilitiesId => _response.Headers.TryGetValue("capabilities-id", out string value) ? value : null; + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PurchasePhoneNumbersOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PurchasePhoneNumbersOperation.cs new file mode 100644 index 0000000000000..88790a2a0aeff --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/PurchasePhoneNumbersOperation.cs @@ -0,0 +1,56 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + /// Purchases phone numbers. + public partial class PurchasePhoneNumbersOperation : Operation, IOperationSource + { + private readonly ArmOperationHelpers _operation; + + /// + public override Response Value => _operation.Value; + + /// + public override bool HasCompleted => _operation.HasCompleted; + + /// + public override bool HasValue => _operation.HasValue; + + /// + public override Response GetRawResponse() => _operation.GetRawResponse(); + + /// + public override Response UpdateStatus(CancellationToken cancellationToken = default) => _operation.UpdateStatus(cancellationToken); + + /// + public override ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) => _operation.UpdateStatusAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(pollingInterval, cancellationToken); + + Response IOperationSource.CreateResult(Response response, CancellationToken cancellationToken) + { + return response; + } + + async ValueTask IOperationSource.CreateResultAsync(Response response, CancellationToken cancellationToken) + { + return await new ValueTask(response).ConfigureAwait(false); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/ReleasePhoneNumberOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/ReleasePhoneNumberOperation.cs new file mode 100644 index 0000000000000..fa1ede4946696 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/ReleasePhoneNumberOperation.cs @@ -0,0 +1,56 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + /// Releases an acquired phone number. + public partial class ReleasePhoneNumberOperation : Operation, IOperationSource + { + private readonly ArmOperationHelpers _operation; + + /// + public override Response Value => _operation.Value; + + /// + public override bool HasCompleted => _operation.HasCompleted; + + /// + public override bool HasValue => _operation.HasValue; + + /// + public override Response GetRawResponse() => _operation.GetRawResponse(); + + /// + public override Response UpdateStatus(CancellationToken cancellationToken = default) => _operation.UpdateStatus(cancellationToken); + + /// + public override ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) => _operation.UpdateStatusAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(pollingInterval, cancellationToken); + + Response IOperationSource.CreateResult(Response response, CancellationToken cancellationToken) + { + return response; + } + + async ValueTask IOperationSource.CreateResultAsync(Response response, CancellationToken cancellationToken) + { + return await new ValueTask(response).ConfigureAwait(false); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/SearchAvailablePhoneNumbersOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/SearchAvailablePhoneNumbersOperation.cs new file mode 100644 index 0000000000000..ddb1ea7b5be68 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/SearchAvailablePhoneNumbersOperation.cs @@ -0,0 +1,60 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + /// Search for available phone numbers to purchase. + public partial class SearchAvailablePhoneNumbersOperation : Operation, IOperationSource + { + private readonly ArmOperationHelpers _operation; + + /// + public override PhoneNumberSearchResult Value => _operation.Value; + + /// + public override bool HasCompleted => _operation.HasCompleted; + + /// + public override bool HasValue => _operation.HasValue; + + /// + public override Response GetRawResponse() => _operation.GetRawResponse(); + + /// + public override Response UpdateStatus(CancellationToken cancellationToken = default) => _operation.UpdateStatus(cancellationToken); + + /// + public override ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) => _operation.UpdateStatusAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(pollingInterval, cancellationToken); + + PhoneNumberSearchResult IOperationSource.CreateResult(Response response, CancellationToken cancellationToken) + { + using var document = JsonDocument.Parse(response.ContentStream); + return PhoneNumberSearchResult.DeserializePhoneNumberSearchResult(document.RootElement); + } + + async ValueTask IOperationSource.CreateResultAsync(Response response, CancellationToken cancellationToken) + { + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + return PhoneNumberSearchResult.DeserializePhoneNumberSearchResult(document.RootElement); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/UpdatePhoneNumberCapabilitiesOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/UpdatePhoneNumberCapabilitiesOperation.cs new file mode 100644 index 0000000000000..639740a43e124 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Generated/UpdatePhoneNumberCapabilitiesOperation.cs @@ -0,0 +1,60 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + /// Updates the capabilities of a phone number. + public partial class UpdatePhoneNumberCapabilitiesOperation : Operation, IOperationSource + { + private readonly ArmOperationHelpers _operation; + + /// + public override AcquiredPhoneNumber Value => _operation.Value; + + /// + public override bool HasCompleted => _operation.HasCompleted; + + /// + public override bool HasValue => _operation.HasValue; + + /// + public override Response GetRawResponse() => _operation.GetRawResponse(); + + /// + public override Response UpdateStatus(CancellationToken cancellationToken = default) => _operation.UpdateStatus(cancellationToken); + + /// + public override ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) => _operation.UpdateStatusAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(cancellationToken); + + /// + public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken = default) => _operation.WaitForCompletionAsync(pollingInterval, cancellationToken); + + AcquiredPhoneNumber IOperationSource.CreateResult(Response response, CancellationToken cancellationToken) + { + using var document = JsonDocument.Parse(response.ContentStream); + return AcquiredPhoneNumber.DeserializeAcquiredPhoneNumber(document.RootElement); + } + + async ValueTask IOperationSource.CreateResultAsync(Response response, CancellationToken cancellationToken) + { + using var document = await JsonDocument.ParseAsync(response.ContentStream, default, cancellationToken).ConfigureAwait(false); + return AcquiredPhoneNumber.DeserializeAcquiredPhoneNumber(document.RootElement); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/AdministrationModelFactory.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/AdministrationModelFactory.cs deleted file mode 100644 index c9ed4922f19ed..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/AdministrationModelFactory.cs +++ /dev/null @@ -1,228 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// - /// Model factory that enables mocking for the Administration library. - /// - public static class AdministrationModelFactory - { - /// - /// Initializes a new instance of the class. - /// - /// String of the E.164 format of the phone number. - /// The set of all acquired capabilities of the phone number. - /// The set of all available capabilities that can be acquired for this phone number. - /// A new instance for mocking. - public static AcquiredPhoneNumber AcquiredPhoneNumber(string phoneNumber, IEnumerable acquiredCapabilities, IEnumerable availableCapabilities) - => new AcquiredPhoneNumber(phoneNumber, acquiredCapabilities, availableCapabilities); - - /// - /// Initializes a new instance of the class. - /// - /// Represents the list of primary area codes. - /// Represents the list of secondary area codes. - /// Represents the URL link to the next page. - /// A new instance for mocking. - public static AreaCodes AreaCodes(IReadOnlyList primaryAreaCodes, IReadOnlyList secondaryAreaCodes, string nextLink) - => new AreaCodes(primaryAreaCodes, secondaryAreaCodes, nextLink); - - /// - /// Initializes a new instance of the class. - /// - /// Name of carrier details. - /// Display name of carrier details. - /// A new instance for mocking. - public static CarrierDetails CarrierDetails(string name, string localizedName) - => new CarrierDetails(name, localizedName); - - /// - /// Initializes a new instance of the class. - /// - /// PhoneNumberAdministrationClient - /// The reservation id that was created. - /// A new instance for mocking. - public static PhoneNumberReservationOperation PhoneNumberReservationOperation(PhoneNumberAdministrationClient client, string reservationId) - => new PhoneNumberReservationOperation(client, reservationId); - - /// - /// Initializes a new instance of the class. - /// - /// The label id of the location. - /// The display name of the location. - /// The underlying location option details. - /// A new instance for mocking. - public static LocationOptions LocationOptions(string labelId, string labelName, IList options) - => new LocationOptions(labelId, labelName, options); - - /// - /// Initializes a new instance of the class. - /// - /// The name of the location options. - /// The abbreviated name of the location options. - /// The underlying location options. - /// A new instance for mocking. - public static LocationOptionsDetails LocationOptionsDetails(string name, string value, IList locationOptions) - => new LocationOptionsDetails(name, value, locationOptions); - - /// - /// Initializes a new instance of the class. - /// - /// Represents a location options. - /// A new instance for mocking. - public static LocationOptionsResponse LocationOptionsResponse(LocationOptions locationOptions) - => new LocationOptionsResponse(locationOptions); - - /// - /// Initializes a new instance of the class. - /// - /// Definition for pstn number configuration. - /// A new instance for mocking. - public static NumberConfigurationResponse NumberConfigurationResponse(PstnConfiguration pstnConfiguration) - => new NumberConfigurationResponse(pstnConfiguration); - - /// - /// Initializes a new instance of the class. - /// - /// Capabilities to be added to a phone number. - /// Capabilities to be removed from a phone number. - /// A new instance for mocking. - public static NumberUpdateCapabilities NumberUpdateCapabilities(IList @add, IList @remove) - => new NumberUpdateCapabilities(@add, @remove); - - /// - /// Initializes a new instance of the class. - /// - /// Represents the name of the country. - /// Represents the abbreviated name of the country. - /// A new instance for mocking. - public static PhoneNumberCountry PhoneNumberCountry(string localizedName, string countryCode) - => new PhoneNumberCountry(localizedName, countryCode); - - /// - /// Initializes a new instance of the class. - /// - /// The id of the entity. It is the search id of a search. It is the release id of a release. - /// Date and time the entity is created. - /// Name of the entity. - /// Quantity of requested phone numbers in the entity. - /// Quantity of acquired phone numbers in the entity. - /// Status of the entity. - /// The Firm Order Confirmation date of the phone number entity. - /// A new instance for mocking. - - public static PhoneNumberEntity PhoneNumberEntity(string id, DateTimeOffset? createdAt, string displayName, int? quantity, int? quantityObtained, string status, DateTimeOffset? focDate) - => new PhoneNumberEntity(id, createdAt, displayName, quantity, quantityObtained, status, focDate); - - /// - /// Initializes a new instance of the class. - /// - /// The id of the release. - /// The creation time of the release. - /// The release status. - /// The underlying error message of a release. - /// The list of phone numbers in the release, mapped to its individual statuses. - /// A new instance for mocking. - public static PhoneNumberRelease PhoneNumberRelease(string releaseId, DateTimeOffset? createdAt, ReleaseStatus? status, string errorMessage, IReadOnlyDictionary phoneNumberReleaseStatusDetails) - => new PhoneNumberRelease(releaseId, createdAt, status, errorMessage, phoneNumberReleaseStatusDetails); - - /// - /// Initializes a new instance of the class. - /// - /// The release status of a phone number. - /// The error code in the case the status is error. - /// A new instance for mocking. - public static PhoneNumberReleaseDetails PhoneNumberReleaseDetails(PhoneNumberReleaseStatus? status, int? errorCode) - => new PhoneNumberReleaseDetails(status, errorCode); - - /// - /// Initializes a new instance of the class. - /// - /// The id of the reservation. - /// The name of the search. - /// The creation time of the search. - /// The description of the search. - /// The phone plan ids of the search. - /// The area code of the search. - /// The quantity of phone numbers in the search. - /// The location options of the search. - /// The status of the search. - /// The list of phone numbers in the search, in the case the status is reserved or success. - /// The date that search expires and the numbers become available. - /// The error code of the search. - /// A new instance for mocking. - public static PhoneNumberReservation PhoneNumberReservation(string reservationId, string displayName, DateTimeOffset? createdAt, string description, IReadOnlyList phonePlanIds, string areaCode, int? quantity, IReadOnlyList locationOptions, ReservationStatus? status, IReadOnlyList phoneNumbers, DateTimeOffset? reservationExpiryDate, int? errorCode) - => new PhoneNumberReservation(reservationId, displayName, createdAt, description, phonePlanIds, areaCode, quantity, locationOptions, status, phoneNumbers, reservationExpiryDate, errorCode); - - /// - /// Initializes a new instance of the class. - /// - /// The phone plan id. - /// The name of the phone plan. - /// The location type of the phone plan. - /// A new instance for mocking. - public static PhonePlan PhonePlan(string phonePlanId, string localizedName, LocationType locationType) - => new PhonePlan(phonePlanId, localizedName, locationType); - - /// - /// Initializes a new instance of the class. - /// - /// The id of the plan group. - /// The name of the plan group. - /// The description of the plan group. - /// A new instance for mocking. - public static PhonePlanGroup PhonePlanGroup(string phonePlanGroupId, string localizedName, string localizedDescription) - => new PhonePlanGroup(phonePlanGroupId, localizedName, localizedDescription); - - /// - /// Initializes a new instance of the class. - /// - /// The monthly rate of a phone plan group. - /// The currency of a phone plan group. - /// The error code of a phone plan group. - /// A new instance for mocking. - public static RateInformation RateInformation(double? monthlyRate, CurrencyType? currencyType, string rateErrorMessage) - => new RateInformation(monthlyRate, currencyType, rateErrorMessage); - - /// - /// Initializes a new instance of the class. - /// - /// The release id of a created release. - /// PhoneNumberAdministrationClient - /// A new instance for mocking. - public static ReleasePhoneNumberOperation ReleasePhoneNumberOperation(PhoneNumberAdministrationClient client, string releaseId) - => new ReleasePhoneNumberOperation(client, releaseId); - - /// - /// Initializes a new instance of the class. - /// - /// The reservation id of a created reservation. - /// PhoneNumberAdministrationClient - /// A new instance for mocking. - public static PhoneNumberReservationPurchaseOperation PhoneNumberReservationPurchaseOperation(PhoneNumberAdministrationClient client, string reservationId) - => new PhoneNumberReservationPurchaseOperation(client, reservationId); - - /// - /// Initializes a new instance of the class. - /// - /// The capabilities id. - /// A new instance for mocking. - public static UpdateNumberCapabilitiesResponse UpdateNumberCapabilitiesResponse(string capabilitiesUpdateId) - => new UpdateNumberCapabilitiesResponse(capabilitiesUpdateId); - - /// - /// Initializes a new instance of the class. - /// - /// The id of the phone number capabilities update. - /// The time the capabilities update was created. - /// Status of the capabilities update. - /// The capabilities update for each of a set of phone numbers. - /// A new instance for mocking. - public static UpdatePhoneNumberCapabilitiesResponse UpdatePhoneNumberCapabilitiesResponse(string capabilitiesUpdateId, DateTimeOffset? createdAt, CapabilitiesUpdateStatus? capabilitiesUpdateStatus, IReadOnlyDictionary phoneNumberCapabilitiesUpdates) - => new UpdatePhoneNumberCapabilitiesResponse(capabilitiesUpdateId, createdAt, capabilitiesUpdateStatus, phoneNumberCapabilitiesUpdates); - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlanGroups.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CommunicationError.cs similarity index 78% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlanGroups.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CommunicationError.cs index 4d11cdb650eda..76f686927262a 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlanGroups.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CommunicationError.cs @@ -3,7 +3,7 @@ namespace Azure.Communication.PhoneNumbers.Models { - internal partial class PhonePlanGroups + internal partial class CommunicationError { } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationResponse.cs deleted file mode 100644 index 8ff90c22ccc41..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationResponse.cs +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - [CodeGenModel("CreateSearchResponse")] - internal partial class CreateReservationResponse - { - /// The id of a created reservation. - [CodeGenMember("SearchId")] - public string ReservationId { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/InternalPhoneNumbersClient.cs similarity index 66% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationOptions.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Models/InternalPhoneNumbersClient.cs index bb050321b39d4..205c00b3d0519 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/CreateReservationOptions.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/InternalPhoneNumbersClient.cs @@ -5,8 +5,8 @@ namespace Azure.Communication.PhoneNumbers.Models { - [CodeGenModel("CreateSearchOptions")] - public partial class CreateReservationOptions + [CodeGenModel("PhoneNumbersClient")] + internal partial class InternalPhoneNumbersClient { } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCost.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCost.cs new file mode 100644 index 0000000000000..f515390f2ed88 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCost.cs @@ -0,0 +1,14 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class PhoneNumberCost + { + /// The ISO 4217 currency code for the cost amount, e.g. USD. + [CodeGenMember("CurrencyCode")] + public string ISOCurrencySymbol { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCountries.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCountries.cs deleted file mode 100644 index 6891a8d5a31e7..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCountries.cs +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhoneNumberCountries - { - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCapability.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberOperation.cs similarity index 67% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCapability.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberOperation.cs index 1e6d87a59a165..1d4f7b6d0156d 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberCapability.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberOperation.cs @@ -5,8 +5,8 @@ namespace Azure.Communication.PhoneNumbers.Models { - [CodeGenModel("Capability")] - public readonly partial struct PhoneNumberCapability + [CodeGenModel("PhoneNumberOperation")] + internal partial class PhoneNumberOperation { } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReleaseResponse.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReleaseResponse.cs deleted file mode 100644 index 6705a533c388d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReleaseResponse.cs +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - [CodeGenModel("ReleaseResponse")] - internal partial class PhoneNumberReleaseResponse - { - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservation.cs deleted file mode 100644 index 05c4140652ef9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservation.cs +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - [CodeGenModel("PhoneNumberSearch")] - public partial class PhoneNumberReservation - { - /// The id of reservation. - [CodeGenMember("SearchId")] - public string ReservationId { get; } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationOperation.cs deleted file mode 100644 index 01856f86272ff..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationOperation.cs +++ /dev/null @@ -1,200 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// - /// Represents a long-running phone number reservation operation. - /// - public class PhoneNumberReservationOperation : Operation - { - private bool _hasCompleted; - private readonly PhoneNumberAdministrationClient _client; - private readonly CancellationToken _cancellationToken; - private PhoneNumberReservation? _value; - private Response _rawResponse; - private readonly IReadOnlyList _terminateStatuses; - - /// - /// Initializes a new instance - /// - /// The client used to check for completion. - /// The reservation operation ID. - /// The cancellation token to use. - public PhoneNumberReservationOperation( - PhoneNumberAdministrationClient client, - string id, - CancellationToken cancellationToken = default) - : this(client, id, null!, cancellationToken) - { - } - - /// - /// Initializes a new instance - /// - /// The client used to check for completion. - /// The reservation operation ID. - /// The original server response on start operation request. - /// The cancellation token to use. - internal PhoneNumberReservationOperation( - PhoneNumberAdministrationClient client, - string id, - Response initialResponse, - CancellationToken cancellationToken = default) - { - _terminateStatuses = new[] - { - ReservationStatus.Reserved, - ReservationStatus.Expired, - ReservationStatus.Cancelled, - ReservationStatus.Error - }; - - Id = id; - _value = null; - _rawResponse = initialResponse; - _client = client; - _cancellationToken = cancellationToken; - } - - /// - public override string Id { get; } - - /// - public override PhoneNumberReservation Value - { - get - { -#pragma warning disable CA1065 // Do not raise exceptions in unexpected locations - if (!HasCompleted) - { - throw new InvalidOperationException("The operation has not completed yet."); - } - if (_value?.Status != ReservationStatus.Reserved) - { - throw new RequestFailedException(GetErrorMessage(_value)); - } -#pragma warning restore CA1065 // Do not raise exceptions in unexpected locations - - return OperationHelpers.GetValue(ref _value); - } - } - - /// - public override bool HasCompleted => _hasCompleted; - - /// - public override bool HasValue => _value?.Status == ReservationStatus.Reserved; - - /// - public override Response GetRawResponse() => _rawResponse; - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// The with the status update. - public override Response UpdateStatus(CancellationToken cancellationToken = default) - => UpdateStatusAsync(false, cancellationToken).EnsureCompleted(); - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// The with the status update. - public override async ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) - => await UpdateStatusAsync(true, cancellationToken).ConfigureAwait(false); - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// - /// The with the status update. - private async ValueTask UpdateStatusAsync(bool async, CancellationToken cancellationToken) - { - using DiagnosticScope scope = _client.ClientDiagnostics.CreateScope($"{nameof(PhoneNumberReservationOperation)}.{nameof(UpdateStatus)}"); - scope.Start(); - - try - { - if (HasCompleted) - { - return GetRawResponse(); - } - - if (cancellationToken == default) - { - cancellationToken = _cancellationToken; - } - - Response update = async - ? await _client.GetReservationByIdAsync(reservationId: Id, cancellationToken: cancellationToken).ConfigureAwait(false) - : _client.GetReservationById(reservationId: Id, cancellationToken: cancellationToken); - - if (!HasCompleted) - _rawResponse = update.GetRawResponse(); - - if (IsOperationCompleted(update)) - { - _value = update.Value; - _hasCompleted = true; - } - - return GetRawResponse(); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - private bool IsOperationCompleted(Response response) - { - if (response.Value?.Status == null) - return false; - - return _terminateStatuses.Contains(response.Value.Status.Value); - } - - /// - public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) - => this.DefaultWaitForCompletionAsync(cancellationToken); - - /// - public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken) - => this.DefaultWaitForCompletionAsync(pollingInterval, cancellationToken); - - private static string GetErrorMessage(PhoneNumberReservation? reservation) - { - var reservationStatus = reservation?.Status; - - if (reservationStatus == ReservationStatus.Cancelled) - return "Reservation is cancelled."; - if (reservationStatus == ReservationStatus.Error) - return "Reservation has failed."; - if (reservationStatus == ReservationStatus.Expired) - return "Reservation is expired."; - - throw new InvalidOperationException($"Unsupported status: {reservationStatus}"); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationPurchaseOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationPurchaseOperation.cs deleted file mode 100644 index 2329522885f0e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberReservationPurchaseOperation.cs +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// - /// Represents a long-running phone number reservation purchase operation. - /// - public class PhoneNumberReservationPurchaseOperation : Operation - { - private bool _hasCompleted; - private readonly PhoneNumberAdministrationClient _client; - private readonly CancellationToken _cancellationToken; - private ReservationStatus? _value; - private Response _rawResponse; - private readonly IReadOnlyList _terminateStatuses; - - /// - /// Initializes a new instance. - /// - /// The client used to check for completion. - /// The reservation operation ID. - /// The cancellation token to use. - public PhoneNumberReservationPurchaseOperation( - PhoneNumberAdministrationClient client, - string id, - CancellationToken cancellationToken = default) - : this(client, id, null!, cancellationToken) - { - } - - /// - /// Initializes a new instance - /// - /// The client used to check for completion. - /// The reservation operation ID. - /// The original server response on start operation request. - /// The cancellation token to use. - internal PhoneNumberReservationPurchaseOperation( - PhoneNumberAdministrationClient client, - string id, - Response initialResponse, - CancellationToken cancellationToken = default) - { - _terminateStatuses = new[] - { - ReservationStatus.Success, - ReservationStatus.Expired, - ReservationStatus.Cancelled, - ReservationStatus.Error - }; - Id = id; - _value = null; - _rawResponse = initialResponse; - _client = client; - _cancellationToken = cancellationToken; - } - - /// - public override string Id { get; } - - /// - public override ReservationStatus Value - { - get - { -#pragma warning disable CA1065 // Do not raise exceptions in unexpected locations - if (!HasCompleted) - { - throw new InvalidOperationException("The operation has not completed yet."); - } - if (_value != ReservationStatus.Success) - { - throw new RequestFailedException(GetErrorMessage(_value)); - } -#pragma warning restore CA1065 // Do not raise exceptions in unexpected locations - - return OperationHelpers.GetValue(ref _value); - } - } - - /// - public override bool HasCompleted => _hasCompleted; - - /// - public override bool HasValue => _value == ReservationStatus.Success; - - /// - public override Response GetRawResponse() => _rawResponse; - - /// - public override Response UpdateStatus(CancellationToken cancellationToken = default) - => UpdateStatusAsync(false, cancellationToken).EnsureCompleted(); - - /// - public override async ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) - => await UpdateStatusAsync(true, cancellationToken).ConfigureAwait(false); - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// - /// The with the status update. - private async ValueTask UpdateStatusAsync(bool async, CancellationToken cancellationToken) - { - using DiagnosticScope scope = _client.ClientDiagnostics.CreateScope($"{nameof(PhoneNumberReservationPurchaseOperation)}.{nameof(UpdateStatus)}"); - scope.Start(); - - try - { - if (HasCompleted) - { - return GetRawResponse(); - } - - if (cancellationToken == default) - { - cancellationToken = _cancellationToken; - } - - Response update = async - ? await _client.GetReservationByIdAsync(reservationId: Id, cancellationToken: cancellationToken).ConfigureAwait(false) - : _client.GetReservationById(reservationId: Id, cancellationToken: cancellationToken); - - if (!HasCompleted) - _rawResponse = update.GetRawResponse(); - - if (IsOperationCompleted(update)) - { - _value = update.Value.Status; - _hasCompleted = true; - } - - return GetRawResponse(); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - private bool IsOperationCompleted(Response response) - { - if (response.Value?.Status == null) - return false; - - return _terminateStatuses.Contains(response.Value.Status.Value); - } - - /// - public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) - => this.DefaultWaitForCompletionAsync(cancellationToken); - - /// - public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken) - => this.DefaultWaitForCompletionAsync(pollingInterval, cancellationToken); - - private static string GetErrorMessage(ReservationStatus? reservationStatus) - { - if (reservationStatus == ReservationStatus.Cancelled) - return "Reservation is cancelled."; - if (reservationStatus == ReservationStatus.Error) - return "Reservation has failed."; - if (reservationStatus == ReservationStatus.Expired) - return "Reservation is expired."; - - return string.Empty; - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberEntities.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchRequest.cs similarity index 71% rename from sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberEntities.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchRequest.cs index f08e6796b1525..c6aa6820ba69a 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberEntities.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchRequest.cs @@ -3,7 +3,6 @@ namespace Azure.Communication.PhoneNumbers.Models { - internal partial class PhoneNumberEntities - { - } + internal partial class PhoneNumberSearchRequest + { } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchResult.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchResult.cs new file mode 100644 index 0000000000000..50cde5b743fb5 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumberSearchResult.cs @@ -0,0 +1,15 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers.Models +{ + public partial class PhoneNumberSearchResult + { + /// The date that this search result expires and phone numbers are no longer on hold. A search result expires in less than 15min, e.g. 2020-11-19T16:31:49.048Z. + [CodeGenMember("SearchExpiresBy")] + public DateTimeOffset SearchExpiresOn { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumbersModelFactory.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumbersModelFactory.cs new file mode 100644 index 0000000000000..abf9e8895c434 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhoneNumbersModelFactory.cs @@ -0,0 +1,35 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Collections.Generic; + +namespace Azure.Communication.PhoneNumbers.Models +{ + /// + /// Model factory that enables mocking for the Azure.Communication.PhoneNumbers library. + /// + public static class PhoneNumbersModelFactory + { + /// Initializes a new instance of AcquiredPhoneNumber. + /// The id of the phone number, e.g. 11234567890. + /// String of the E.164 format of the phone number, e.g. +11234567890. + /// The ISO 3166-2 code of the phone number's country, e.g. US. + /// The phone number's type, e.g. Geographic, TollFree. + /// Capabilities of a phone number. + /// The assignment type of the phone number. A phone number can be assigned to a person, or to an application. + /// The date and time that the phone number was purchased. + /// The incurred cost for a single phone number. +#pragma warning disable CA1054 // URI-like parameters should not be strings + public static AcquiredPhoneNumber AcquiredPhoneNumber(string id, string phoneNumber, string countryCode, PhoneNumberType phoneNumberType, PhoneNumberCapabilities capabilities, PhoneNumberAssignmentType assignmentType, DateTimeOffset purchaseDate, PhoneNumberCost cost) +#pragma warning restore CA1054 // URI-like parameters should not be strings + => new AcquiredPhoneNumber(id, phoneNumber, countryCode, phoneNumberType, capabilities, assignmentType, purchaseDate, cost); + + /// Initializes a new instance of PhoneNumberCost. + /// The cost amount. + /// The ISO 4217 currency code for the cost amount. + /// The frequency with which the cost gets billed. + public static PhoneNumberCost PhoneNumberCost(double amount, string currencyCode, string billingFrequency) + => new PhoneNumberCost(amount, currencyCode, billingFrequency); + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlans.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlans.cs deleted file mode 100644 index fffc4dcab3251..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/PhonePlans.cs +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -namespace Azure.Communication.PhoneNumbers.Models -{ - internal partial class PhonePlans - { - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReleasePhoneNumberOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReleasePhoneNumberOperation.cs deleted file mode 100644 index dff0ae3991f75..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReleasePhoneNumberOperation.cs +++ /dev/null @@ -1,194 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers.Models -{ - /// - /// Represents a long-running operation for releasing a phone number. - /// - public class ReleasePhoneNumberOperation : Operation - { - private readonly PhoneNumberAdministrationClient _client; - private readonly CancellationToken _cancellationToken; - private bool _hasCompleted; - private PhoneNumberRelease? _value; - private Response _rawResponse; - private readonly ReleaseStatus[] _terminateStatuses = new[] { - ReleaseStatus.Complete, - ReleaseStatus.Failed, - ReleaseStatus.Expired - }; - - /// - /// Initializes a new instance. - /// - /// The client used to check for completion. - /// The phone number release operation ID. - /// The cancellation token to use. - public ReleasePhoneNumberOperation( - PhoneNumberAdministrationClient client, - string id, - CancellationToken cancellationToken = default) - { - Id = id; - _value = null; - _rawResponse = null!; - _client = client; - _cancellationToken = cancellationToken; - } - - /// - /// Initializes a new instance. - /// - /// The client used to check for completion. - /// The phone number release operation ID. - /// The original server response on start operation request. - /// The cancellation token to use. - internal ReleasePhoneNumberOperation( - PhoneNumberAdministrationClient client, - string id, - Response initialResponse, - CancellationToken cancellationToken = default) - { - Id = id; - _value = null; - _rawResponse = initialResponse; - _client = client; - _cancellationToken = cancellationToken; - } - - /// - public override string Id { get; } - - /// - public override PhoneNumberRelease Value - { - get - { -#pragma warning disable CA1065 // Do not raise exceptions in unexpected locations - if (!HasCompleted) - { - throw new InvalidOperationException("The operation has not completed yet."); - } - if (_value?.Status != ReleaseStatus.Complete) - { - throw new RequestFailedException(GetErrorMessage(_value)); - } -#pragma warning restore CA1065 // Do not raise exceptions in unexpected locations - - return OperationHelpers.GetValue(ref _value); - } - } - - /// - public override bool HasCompleted => _hasCompleted; - - /// - public override bool HasValue => _value?.Status == ReleaseStatus.Complete; - - /// - public override Response GetRawResponse() => _rawResponse; - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// The with the status update. - public override Response UpdateStatus(CancellationToken cancellationToken = default) - => UpdateStatusAsync(false, cancellationToken).EnsureCompleted(); - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// The with the status update. - public override async ValueTask UpdateStatusAsync(CancellationToken cancellationToken = default) - => await UpdateStatusAsync(true, cancellationToken).ConfigureAwait(false); - - /// - /// Check for the latest status of the operation. - /// - /// - /// Optional to propagate - /// notifications that the operation should be cancelled. - /// - /// - /// The with the status update. - private async ValueTask UpdateStatusAsync(bool async, CancellationToken cancellationToken) - { - using DiagnosticScope scope = _client.ClientDiagnostics.CreateScope($"{nameof(ReleasePhoneNumberOperation)}.{nameof(UpdateStatus)}"); - scope.Start(); - - try - { - if (HasCompleted) - { - return GetRawResponse(); - } - - if (cancellationToken == default) - { - cancellationToken = _cancellationToken; - } - - Response update = async - ? await _client.GetReleaseByIdAsync(releaseId: Id, cancellationToken: cancellationToken).ConfigureAwait(false) - : _client.GetReleaseById(releaseId: Id, cancellationToken: cancellationToken); - - if (!HasCompleted) - _rawResponse = update.GetRawResponse(); - - if (IsOperationCompleted(update)) - { - _value = update.Value; - _hasCompleted = true; - } - - return GetRawResponse(); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - private bool IsOperationCompleted(Response update) - { - return update.Value?.Status != null && _terminateStatuses.Contains(update.Value.Status.Value); - } - - /// - public override ValueTask> WaitForCompletionAsync(CancellationToken cancellationToken = default) - => this.DefaultWaitForCompletionAsync(cancellationToken); - - /// - public override ValueTask> WaitForCompletionAsync(TimeSpan pollingInterval, CancellationToken cancellationToken) - => this.DefaultWaitForCompletionAsync(pollingInterval, cancellationToken); - - private static string GetErrorMessage(PhoneNumberRelease? release) - { - var status = release?.Status; - - if (status == ReleaseStatus.Failed) - return "Phone number release failed."; - if (status == ReleaseStatus.Expired) - return "Phone number release operation is expired."; - - throw new InvalidOperationException($"Unsupported status: {status}"); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReservationStatus.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReservationStatus.cs deleted file mode 100644 index ac55ba01f143f..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/Models/ReservationStatus.cs +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using Azure.Core; - -namespace Azure.Communication.PhoneNumbers.Models -{ - [CodeGenModel("SearchStatus")] - public partial struct ReservationStatus - { - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClient.cs deleted file mode 100644 index 91418196bf5d3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClient.cs +++ /dev/null @@ -1,1003 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using Azure.Communication.PhoneNumbers.Models; -using Azure.Communication.Pipeline; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers -{ - /// - /// The Azure Communication Services phone number administration client. - /// - public class PhoneNumberAdministrationClient - { - internal ClientDiagnostics ClientDiagnostics { get; private set; } - internal PhoneNumberAdministrationRestClient RestClient { get; } - - #region public constructors - all arguments need null check - - /// - /// Initializes a phone number administration client with an Azure resource connection string and client options. - /// - public PhoneNumberAdministrationClient(string connectionString) - : this( - ConnectionString.Parse(AssertNotNullOrEmpty(connectionString, nameof(connectionString))), - new PhoneNumberAdministrationClientOptions()) - { } - - /// - /// Initializes a phone number administration client with an Azure resource connection string and client options. - /// - public PhoneNumberAdministrationClient(string connectionString, PhoneNumberAdministrationClientOptions options) - : this( - ConnectionString.Parse(AssertNotNullOrEmpty(connectionString, nameof(connectionString))), - options ?? new PhoneNumberAdministrationClientOptions()) - { } - - /// Initializes a new instance of . - /// The URI of the Azure Communication Services resource. - /// The used to authenticate requests. - /// Client option exposing , , , etc. - public PhoneNumberAdministrationClient(Uri endpoint, AzureKeyCredential keyCredential, PhoneNumberAdministrationClientOptions? options = default) - : this( - AssertNotNull(endpoint, nameof(endpoint)).AbsoluteUri, - AssertNotNull(keyCredential, nameof(keyCredential)), - options ?? new PhoneNumberAdministrationClientOptions()) - { } - - /// - /// Initializes a phone number administration client with a token credential. - /// The URI of the Azure Communication Services resource. - /// The used to authenticate requests, such as DefaultAzureCredential. - /// Client option exposing , , , etc. - /// - public PhoneNumberAdministrationClient(Uri endpoint, TokenCredential tokenCredential, PhoneNumberAdministrationClientOptions? options = default) - : this( - AssertNotNull(endpoint, nameof(endpoint)).AbsoluteUri, - AssertNotNull(tokenCredential, nameof(tokenCredential)), - options ?? new PhoneNumberAdministrationClientOptions()) - { } - - #endregion - - #region private constructors - - private PhoneNumberAdministrationClient(ConnectionString connectionString, PhoneNumberAdministrationClientOptions options) - : this(connectionString.GetRequired("endpoint"), options.BuildHttpPipeline(connectionString), options) - { } - - private PhoneNumberAdministrationClient(string endpoint, AzureKeyCredential keyCredential, PhoneNumberAdministrationClientOptions options) - : this(endpoint, options.BuildHttpPipeline(keyCredential), options) - { } - - private PhoneNumberAdministrationClient(string endpoint, TokenCredential tokenCredential, PhoneNumberAdministrationClientOptions options) - : this(endpoint, options.BuildHttpPipeline(tokenCredential), options) - { } - - private PhoneNumberAdministrationClient(string endpoint, HttpPipeline httpPipeline, PhoneNumberAdministrationClientOptions options) - { - ClientDiagnostics = new ClientDiagnostics(options); - RestClient = new PhoneNumberAdministrationRestClient(ClientDiagnostics, httpPipeline, endpoint, options.ApiVersion); - } - - #endregion - - /// Initializes a new instance of for mocking. - protected PhoneNumberAdministrationClient() - { - ClientDiagnostics = null!; - RestClient = null!; - } - - /// Gets the list of the acquired phone numbers. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetAllPhoneNumbersAsync(string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllPhoneNumbers)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? await RestClient.GetAllPhoneNumbersAsync(locale, skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetAllPhoneNumbersNextPageAsync(nextLink, locale, skip: null, take: null, cancellationToken).ConfigureAwait(false); - - return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets the list of the acquired phone numbers. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual Pageable GetAllPhoneNumbers(string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllPhoneNumbers)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? RestClient.GetAllPhoneNumbers(locale, skip: null, take: null, cancellationToken) - : RestClient.GetAllPhoneNumbersNextPage(nextLink, locale, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of the supported area codes. - /// The type of location information required by the plan. - /// The ISO 3166-2 country code. - /// The plan id from which to search area codes. - /// Represents the underlying list of countries. - /// The cancellation token to use. - /// A . - public virtual async Task> GetAllAreaCodesAsync(string locationType, string countryCode, string phonePlanId, IEnumerable locationOptions, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllAreaCodes)}"); - scope.Start(); - try - { - return await RestClient.GetAllAreaCodesAsync(locationType, countryCode, phonePlanId, locationOptions, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of the supported area codes. - /// The type of location information required by the plan. - /// The ISO 3166-2 country code. - /// The plan id from which to search area codes. - /// Represents the underlying list of countries. - /// The cancellation token to use. - /// A . - public virtual Response GetAllAreaCodes(string locationType, string countryCode, string phonePlanId, IEnumerable locationOptions, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllAreaCodes)}"); - scope.Start(); - try - { - return RestClient.GetAllAreaCodes(locationType, countryCode, phonePlanId, locationOptions, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Get capabilities by capabilities update id. - /// The String to use. - /// The cancellation token to use. - /// A . - public virtual async Task> GetCapabilitiesUpdateAsync(string capabilitiesUpdateId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetCapabilitiesUpdate)}"); - scope.Start(); - try - { - return await RestClient.GetCapabilitiesUpdateAsync(capabilitiesUpdateId, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Get capabilities by capabilities update id. - /// The String to use. - /// The cancellation token to use. - /// A . - public virtual Response GetCapabilitiesUpdate(string capabilitiesUpdateId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetCapabilitiesUpdate)}"); - scope.Start(); - try - { - return RestClient.GetCapabilitiesUpdate(capabilitiesUpdateId, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Adds or removes phone number capabilities. - /// Dictionary of <NumberUpdateCapabilities>. - /// The cancellation token to use. - /// A . - public virtual async Task> UpdateCapabilitiesAsync(IDictionary phoneNumberUpdateCapabilities, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(UpdateCapabilities)}"); - scope.Start(); - try - { - return await RestClient.UpdateCapabilitiesAsync(phoneNumberUpdateCapabilities, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Adds or removes phone number capabilities. - /// Dictionary of <NumberUpdateCapabilities>. - /// The cancellation token to use. - /// A . - public virtual Response UpdateCapabilities(IDictionary phoneNumberUpdateCapabilities, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(UpdateCapabilities)}.{nameof(UpdateCapabilities)}"); - scope.Start(); - try - { - return RestClient.UpdateCapabilities(phoneNumberUpdateCapabilities, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of supported countries. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetAllSupportedCountriesAsync(string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllSupportedCountries)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? await RestClient.GetAllSupportedCountriesAsync(locale, skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetAllSupportedCountriesNextPageAsync(nextLink, locale, skip: null, take: null, cancellationToken).ConfigureAwait(false); - - return Page.FromValues(response.Value.Countries, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of supported countries. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual Pageable GetAllSupportedCountries(string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllSupportedCountries)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? RestClient.GetAllSupportedCountries(locale, skip: null, take: null, cancellationToken) - : RestClient.GetAllSupportedCountriesNextPage(nextLink, locale, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.Countries, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Endpoint for getting number configurations. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// A . - public virtual async Task> GetNumberConfigurationAsync(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetNumberConfiguration)}"); - scope.Start(); - try - { - return await RestClient.GetNumberConfigurationAsync(phoneNumber.PhoneNumber, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Endpoint for getting number configurations. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// A . - public virtual Response GetNumberConfiguration(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetNumberConfiguration)}"); - scope.Start(); - try - { - return RestClient.GetNumberConfiguration(phoneNumber.PhoneNumber, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Endpoint for configuring a pstn number. - /// Definition for pstn number configuration. - /// The phone number to configure. - /// The cancellation token to use. - /// A . - public virtual async Task ConfigureNumberAsync(PstnConfiguration pstnConfiguration, PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(ConfigureNumber)}"); - scope.Start(); - try - { - return await RestClient.ConfigureNumberAsync(pstnConfiguration, phoneNumber.PhoneNumber, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Endpoint for configuring a pstn number. - /// The phone number to configure. - /// Definition for pstn number configuration. - /// The cancellation token to use. - /// A . - public virtual Response ConfigureNumber(PstnConfiguration pstnConfiguration, PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(ConfigureNumber)}"); - scope.Start(); - try - { - return RestClient.ConfigureNumber(pstnConfiguration, phoneNumber.PhoneNumber, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Endpoint for unconfiguring a pstn number by removing the configuration. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// A . - public virtual async Task UnconfigureNumberAsync(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(UnconfigureNumber)}"); - scope.Start(); - try - { - return await RestClient.UnconfigureNumberAsync(phoneNumber.PhoneNumber, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Endpoint for unconfiguring a pstn number by removing the configuration. - /// The phone number in the E.164 format. - /// The cancellation token to use. - /// A . - public virtual Response UnconfigureNumber(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(UnconfigureNumber)}"); - scope.Start(); - try - { - return RestClient.UnconfigureNumber(phoneNumber.PhoneNumber, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of phone plan groups for the given country. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localise the names of countries. - /// The Boolean to use. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetPhonePlanGroupsAsync(string countryCode, string? locale = null, bool? includeRateInformation = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlanGroups)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? await RestClient.GetPhonePlanGroupsAsync(countryCode, locale, includeRateInformation, skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetPhonePlanGroupsNextPageAsync(nextLink, countryCode, locale, includeRateInformation, skip: null, take: null, cancellationToken).ConfigureAwait(false); - - return Page.FromValues(response.Value.PhonePlanGroupsValue, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of phone plan groups for the given country. - /// The ISO 3166-2 country code. - /// A language-locale pairing which will be used to localise the names of countries. - /// The Boolean to use. - /// The cancellation token to use. - /// A . - public virtual Pageable GetPhonePlanGroups(string countryCode, string? locale = null, bool? includeRateInformation = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlanGroups)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? RestClient.GetPhonePlanGroups(countryCode, locale, includeRateInformation, skip: null, take: null, cancellationToken) - : RestClient.GetPhonePlanGroupsNextPage(nextLink, countryCode, locale, includeRateInformation, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.PhonePlanGroupsValue, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of phone plans for a phone plan group. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetPhonePlansAsync(string countryCode, string phonePlanGroupId, string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlans)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? await RestClient.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale, skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetPhonePlansNextPageAsync(nextLink, countryCode, phonePlanGroupId, locale, skip: null, take: null, cancellationToken).ConfigureAwait(false); - - return Page.FromValues(response.Value.PhonePlans, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of phone plans for a phone plan group. - /// The ISO 3166-2 country code. - /// The String to use. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual Pageable GetPhonePlans(string countryCode, string phonePlanGroupId, string? locale = null, CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlans)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? RestClient.GetPhonePlans(countryCode, phonePlanGroupId, locale, skip: null, take: null, cancellationToken) - : RestClient.GetPhonePlansNextPage(nextLink, countryCode, phonePlanGroupId, locale, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.PhonePlans, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of location options for a phone plan. - /// The ISO 3166-2 country code. - /// The String to use. - /// The String to use. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual async Task> GetPhonePlanLocationOptionsAsync(string countryCode, string phonePlanGroupId, string phonePlanId, string? locale = null, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlanLocationOptions)}"); - scope.Start(); - try - { - return await RestClient.GetPhonePlanLocationOptionsAsync(countryCode, phonePlanGroupId, phonePlanId, locale, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of location options for a phone plan. - /// The ISO 3166-2 country code. - /// The String to use. - /// The String to use. - /// A language-locale pairing which will be used to localise the names of countries. - /// The cancellation token to use. - /// A . - public virtual Response GetPhonePlanLocationOptions(string countryCode, string phonePlanGroupId, string phonePlanId, string? locale = null, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetPhonePlanLocationOptions)}"); - scope.Start(); - try - { - return RestClient.GetPhonePlanLocationOptions(countryCode, phonePlanGroupId, phonePlanId, locale, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a release by a release id. - /// Represents the release id. - /// The cancellation token to use. - /// A . - public virtual async Task> GetReleaseByIdAsync(string releaseId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetReleaseById)}"); - scope.Start(); - try - { - return await RestClient.GetReleaseByIdAsync(releaseId, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a release by a release id. - /// Represents the release id. - /// The cancellation token to use. - /// A . - public virtual Response GetReleaseById(string releaseId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetReleaseById)}"); - scope.Start(); - try - { - return RestClient.GetReleaseById(releaseId, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a release for the given phone numbers. - /// The phone number in the release request. - /// The cancellation token to use. - /// A . - public virtual async Task StartReleasePhoneNumberAsync(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReleasePhoneNumber)}"); - scope.Start(); - try - { - return await StartReleasePhoneNumbersAsync(new[] { phoneNumber }, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a release for the given phone numbers. - /// The list of phone numbers in the release request. - /// The cancellation token to use. - /// A . - public virtual async Task StartReleasePhoneNumbersAsync(IEnumerable phoneNumbers, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReleasePhoneNumbers)}"); - scope.Start(); - try - { - var response = await RestClient.ReleasePhoneNumbersAsync(phoneNumbers.Select(phoneNumber => phoneNumber.PhoneNumber), cancellationToken).ConfigureAwait(false); - return new ReleasePhoneNumberOperation( - this, - response.Value.ReleaseId, - response.GetRawResponse(), - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a release for the given phone number. - /// The phone number in the release request. - /// The cancellation token to use. - /// A . - public virtual ReleasePhoneNumberOperation StartReleasePhoneNumber(PhoneNumberIdentifier phoneNumber, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReleasePhoneNumber)}"); - scope.Start(); - try - { - return StartReleasePhoneNumbers(new[] { phoneNumber }, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a release for the given phone numbers. - /// The list of phone numbers in the release request. - /// The cancellation token to use. - /// A . - public virtual ReleasePhoneNumberOperation StartReleasePhoneNumbers(IEnumerable phoneNumbers, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReleasePhoneNumbers)}"); - scope.Start(); - try - { - var response = RestClient.ReleasePhoneNumbers(phoneNumbers.Select(phoneNumber => phoneNumber.PhoneNumber), cancellationToken); - return new ReleasePhoneNumberOperation( - this, - response.Value.ReleaseId, - response.GetRawResponse(), - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of all releases. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetAllReleasesAsync(CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllReleases)}"); - scope.Start(); - try - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - Response response = nextLink is null - ? await RestClient.GetAllReleasesAsync(skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetAllReleasesNextPageAsync(nextLink, skip: null, take: null, cancellationToken).ConfigureAwait(false); - return Page.FromValues(response.Value.Entities, response.Value.NextLink, response.GetRawResponse()); - }); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of all releases. - /// The cancellation token to use. - /// A . - public virtual Pageable GetAllReleases(CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllReleases)}"); - scope.Start(); - try - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - Response response = nextLink is null - ? RestClient.GetAllReleases(skip: null, take: null, cancellationToken) - : RestClient.GetAllReleasesNextPage(nextLink, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.Entities, response.Value.NextLink, response.GetRawResponse()); - }); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Get reservation by id. - /// The reservation id to be searched for. - /// The cancellation token to use. - /// A . - public virtual async Task> GetReservationByIdAsync(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetReservationById)}"); - scope.Start(); - try - { - return await RestClient.GetSearchByIdAsync(reservationId, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Get reservation by id. - /// The reservation id to be searched for. - /// The cancellation token to use. - /// A . - public virtual Response GetReservationById(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetReservationById)}"); - scope.Start(); - try - { - return RestClient.GetSearchById(reservationId, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a phone number reservation. - /// Defines the reservation options. - /// The cancellation token to use. - /// A . - public virtual async Task StartReservationAsync(CreateReservationOptions body, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReservation)}"); - scope.Start(); - try - { - var response = await RestClient.CreateSearchAsync(body, cancellationToken).ConfigureAwait(false); - return new PhoneNumberReservationOperation( - this, - response.Value.ReservationId, - response.GetRawResponse(), - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts a phone number reservation. - /// Defines the reservation options. - /// The cancellation token to use. - /// A . - public virtual PhoneNumberReservationOperation StartReservation(CreateReservationOptions body, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartReservation)}"); - scope.Start(); - try - { - var response = RestClient.CreateSearch(body, cancellationToken); - return new PhoneNumberReservationOperation( - this, - response.Value.ReservationId, - response.GetRawResponse(), - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Gets a list of all reservations. - /// The cancellation token to use. - /// A . - public virtual AsyncPageable GetAllReservationsAsync(CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateAsyncEnumerable(async nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllReservations)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? await RestClient.GetAllSearchesAsync(skip: null, take: null, cancellationToken).ConfigureAwait(false) - : await RestClient.GetAllSearchesNextPageAsync(nextLink, skip: null, take: null, cancellationToken).ConfigureAwait(false); - - return Page.FromValues(response.Value.Entities, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Gets a list of all reservations. - /// The cancellation token to use. - /// A . - public virtual Pageable GetAllReservations(CancellationToken cancellationToken = default) - { - return PageResponseEnumerator.CreateEnumerable(nextLink => - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(GetAllReservations)}"); - scope.Start(); - try - { - Response response = nextLink is null - ? RestClient.GetAllSearches(skip: null, take: null, cancellationToken) - : RestClient.GetAllSearchesNextPage(nextLink, skip: null, take: null, cancellationToken); - - return Page.FromValues(response.Value.Entities, response.Value.NextLink, response.GetRawResponse()); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - }); - } - - /// Cancels the reservation. This means existing numbers in the reservation will be made available. - /// The reservation id to be canceled. - /// The cancellation token to use. - /// A . - public virtual async Task CancelReservationAsync(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(CancelReservation)}"); - scope.Start(); - try - { - return await RestClient.CancelSearchAsync(reservationId, cancellationToken).ConfigureAwait(false); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Cancels the reservation. This means existing numbers in the reservation will be made available. - /// The reservation id to be canceled. - /// The cancellation token to use. - /// A . - public virtual Response CancelReservation(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(CancelReservation)}"); - scope.Start(); - try - { - return RestClient.CancelSearch(reservationId, cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts purchase the phone number reservation. - /// The reservation id to be purchased. - /// The cancellation token to use. - /// A . - public virtual async Task StartPurchaseReservationAsync(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartPurchaseReservation)}"); - scope.Start(); - try - { - var response = await RestClient.PurchaseSearchAsync(reservationId, cancellationToken).ConfigureAwait(false); - return new PhoneNumberReservationPurchaseOperation( - this, - reservationId, - response, - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - /// Starts purchase the phone number reservation. - /// The reservation id to be purchased. - /// The cancellation token to use. - /// A . - public virtual PhoneNumberReservationPurchaseOperation StartPurchaseReservation(string reservationId, CancellationToken cancellationToken = default) - { - using DiagnosticScope scope = ClientDiagnostics.CreateScope($"{nameof(PhoneNumberAdministrationClient)}.{nameof(StartPurchaseReservation)}"); - scope.Start(); - try - { - var response = RestClient.PurchaseSearch(reservationId, cancellationToken); - return new PhoneNumberReservationPurchaseOperation( - this, - reservationId, - response, - cancellationToken); - } - catch (Exception ex) - { - scope.Failed(ex); - throw; - } - } - - private static T AssertNotNull(T argument, string argumentName) - where T : class - { - Argument.AssertNotNull(argument, argumentName); - return argument; - } - - private static string AssertNotNullOrEmpty(string argument, string argumentName) - { - Argument.AssertNotNullOrEmpty(argument, argumentName); - return argument; - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClientOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClientOptions.cs deleted file mode 100644 index 7a9619d648fae..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberAdministrationClientOptions.cs +++ /dev/null @@ -1,56 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using Azure.Core; -using Azure.Core.Pipeline; - -namespace Azure.Communication.PhoneNumbers -{ - /// - /// The options for phone number management client options. - /// - public class PhoneNumberAdministrationClientOptions : ClientOptions - { - /// - /// The latest version of the Phone number management service. - /// - public const ServiceVersion LatestVersion = ServiceVersion.V1; - - internal string ApiVersion { get; } - - /// - /// Initializes a new instance of the . - /// - public PhoneNumberAdministrationClientOptions(ServiceVersion version = LatestVersion, RetryOptions? retryOptions = default, HttpPipelineTransport? transport = default) - { - ApiVersion = version switch - { - ServiceVersion.V1 => "2020-07-20-preview1", - _ => throw new ArgumentOutOfRangeException(nameof(version)), - }; - - if (transport != default) - Transport = transport; - - if (retryOptions != null) - { - Retry.Mode = retryOptions.Mode; - Retry.MaxRetries = retryOptions.MaxRetries; - Retry.Delay = retryOptions.Delay; - Retry.MaxDelay = retryOptions.MaxDelay; - } - } - - /// - /// The phone number configuration service version. - /// - public enum ServiceVersion - { - /// - /// The V1 of the phone number configuration service. - /// - V1 = 1 - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberSearchOptions.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberSearchOptions.cs new file mode 100644 index 0000000000000..9612c39e0ff96 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumberSearchOptions.cs @@ -0,0 +1,19 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Collections.Generic; +using System.Text; + +namespace Azure.Communication.PhoneNumbers +{ + /// Represents a phone number search options to find phone numbers. + public class PhoneNumberSearchOptions + { + /// The area code of the desired phone number, e.g. 425. + public string AreaCode { get; set; } + + /// The quantity of desired phone numbers. The default value is 1. + public int? Quantity { get; set; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClient.cs new file mode 100644 index 0000000000000..aa4f7eb163757 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClient.cs @@ -0,0 +1,419 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Communication.Pipeline; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + /// + /// The Azure Communication Services phone numbers client. + /// + public class PhoneNumbersClient + { + internal InternalPhoneNumbersRestClient RestClient { get; } + private readonly ClientDiagnostics _clientDiagnostics; + private readonly HttpPipeline _pipeline; + + #region public constructors - all arguments need null check + + /// + /// Initializes a phone numbers client with an Azure resource connection string and client options. + /// + public PhoneNumbersClient(string connectionString) + : this( + ConnectionString.Parse(AssertNotNullOrEmpty(connectionString, nameof(connectionString))), + new PhoneNumbersClientOptions()) + { } + + /// + /// Initializes a phone numbers client with an Azure resource connection string and client options. + /// + public PhoneNumbersClient(string connectionString, PhoneNumbersClientOptions options) + : this( + ConnectionString.Parse(AssertNotNullOrEmpty(connectionString, nameof(connectionString))), + options ?? new PhoneNumbersClientOptions()) + { } + + /// Initializes a new instance of . + /// The URI of the Azure Communication Services resource. + /// The used to authenticate requests. + /// Client option exposing , , , etc. + public PhoneNumbersClient(Uri endpoint, AzureKeyCredential keyCredential, PhoneNumbersClientOptions options = default) + : this( + AssertNotNull(endpoint, nameof(endpoint)).AbsoluteUri, + AssertNotNull(keyCredential, nameof(keyCredential)), + options ?? new PhoneNumbersClientOptions()) + { } + + /// + /// Initializes a phone numbers client with a token credential. + /// The URI of the Azure Communication Services resource. + /// The used to authenticate requests, such as DefaultAzureCredential. + /// Client option exposing , , , etc. + /// + public PhoneNumbersClient(Uri endpoint, TokenCredential tokenCredential, PhoneNumbersClientOptions options = default) + : this( + AssertNotNull(endpoint, nameof(endpoint)).AbsoluteUri, + AssertNotNull(tokenCredential, nameof(tokenCredential)), + options ?? new PhoneNumbersClientOptions()) + { } + + #endregion + + #region private constructors + + private PhoneNumbersClient(ConnectionString connectionString, PhoneNumbersClientOptions options) + : this(connectionString.GetRequired("endpoint"), options.BuildHttpPipeline(connectionString), options) + { } + + private PhoneNumbersClient(string endpoint, AzureKeyCredential keyCredential, PhoneNumbersClientOptions options) + : this(endpoint, options.BuildHttpPipeline(keyCredential), options) + { } + + private PhoneNumbersClient(string endpoint, TokenCredential tokenCredential, PhoneNumbersClientOptions options) + : this(endpoint, options.BuildHttpPipeline(tokenCredential), options) + { } + + private PhoneNumbersClient(string endpoint, HttpPipeline httpPipeline, PhoneNumbersClientOptions options) + : this(new ClientDiagnostics(options), httpPipeline, endpoint, options.Version) + { } + + /// Initializes a new instance of PhoneNumbersClient. + /// The handler for diagnostic messaging in the client. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The communication resource, for example https://resourcename.communication.azure.com. + /// Api Version. + private PhoneNumbersClient(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, string endpoint, string apiVersion = "2021-03-07") + { + RestClient = new InternalPhoneNumbersRestClient(clientDiagnostics, pipeline, endpoint, apiVersion); + _clientDiagnostics = clientDiagnostics; + _pipeline = pipeline; + } + + #endregion + + #region protected constructors + /// Initializes a new instance of PhoneNumbersClient for mocking. + protected PhoneNumbersClient() + { + } + #endregion protected constructors + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public virtual async Task StartReleasePhoneNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(phoneNumber, "phoneNumber"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartReleasePhoneNumber)}"); + scope.Start(); + try + { + var originalResponse = await RestClient.ReleasePhoneNumberAsync(phoneNumber, cancellationToken).ConfigureAwait(false); + return new ReleasePhoneNumberOperation(_clientDiagnostics, _pipeline, RestClient.CreateReleasePhoneNumberRequest(phoneNumber).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Releases an acquired phone number. + /// Phone number to be released, e.g. +11234567890. + /// The cancellation token to use. + /// is null. + public virtual ReleasePhoneNumberOperation StartReleasePhoneNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(phoneNumber, "phoneNumber"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartReleasePhoneNumber)}"); + scope.Start(); + try + { + var originalResponse = RestClient.ReleasePhoneNumber(phoneNumber, cancellationToken); + return new ReleasePhoneNumberOperation(_clientDiagnostics, _pipeline, RestClient.CreateReleasePhoneNumberRequest(phoneNumber).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public virtual async Task StartUpdateCapabilitiesAsync(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(phoneNumber, "phoneNumber"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartUpdateCapabilities)}"); + scope.Start(); + try + { + var originalResponse = await RestClient.UpdateCapabilitiesAsync(phoneNumber, calling, sms, cancellationToken).ConfigureAwait(false); + return new UpdatePhoneNumberCapabilitiesOperation(_clientDiagnostics, _pipeline, RestClient.CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Updates the capabilities of a phone number. + /// The phone number id in E.164 format. The leading plus can be either + or encoded as %2B, e.g. +11234567890. + /// Capability value for calling. + /// Capability value for SMS. + /// The cancellation token to use. + /// is null. + public virtual UpdatePhoneNumberCapabilitiesOperation StartUpdateCapabilities(string phoneNumber, PhoneNumberCapabilityType? calling = null, PhoneNumberCapabilityType? sms = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(phoneNumber, "phoneNumber"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartUpdateCapabilities)}"); + scope.Start(); + try + { + var originalResponse = RestClient.UpdateCapabilities(phoneNumber, calling, sms, cancellationToken); + return new UpdatePhoneNumberCapabilitiesOperation(_clientDiagnostics, _pipeline, RestClient.CreateUpdateCapabilitiesRequest(phoneNumber, calling, sms).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + public virtual async Task> GetPhoneNumberAsync(string phoneNumber, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumber)}"); + scope.Start(); + try + { + return await RestClient.GetByNumberAsync(phoneNumber, cancellationToken).ConfigureAwait(false); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the details of the given acquired phone number. + /// The acquired phone number whose details are to be fetched in E.164 format, e.g. +11234567890. + /// The cancellation token to use. + public virtual Response GetPhoneNumber(string phoneNumber, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumber)}"); + scope.Start(); + try + { + return RestClient.GetByNumber(phoneNumber, cancellationToken); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public virtual async Task StartPurchasePhoneNumbersAsync(string searchId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartPurchasePhoneNumbers)}"); + scope.Start(); + try + { + var originalResponse = await RestClient.PurchasePhoneNumbersAsync(searchId, cancellationToken).ConfigureAwait(false); + return new PurchasePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreatePurchasePhoneNumbersRequest(searchId).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Purchases phone numbers. + /// The search id. + /// The cancellation token to use. + public virtual PurchasePhoneNumbersOperation StartPurchasePhoneNumbers(string searchId, CancellationToken cancellationToken = default) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartPurchasePhoneNumbers)}"); + scope.Start(); + try + { + var originalResponse = RestClient.PurchasePhoneNumbers(searchId, cancellationToken); + return new PurchasePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreatePurchasePhoneNumbersRequest(searchId).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The type of phone numbers to search for. + /// The assignment type of the phone numbers to search for. + /// Capabilities of a phone number. + /// The phone number search options. + /// The cancellation token to use. + /// is null. + public virtual async Task StartSearchAvailablePhoneNumbersAsync(string threeLetterISOCountryName, PhoneNumberType phoneNumberType, PhoneNumberAssignmentType phoneNumberAssignmentType, + PhoneNumberCapabilities capabilities, PhoneNumberSearchOptions options = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(threeLetterISOCountryName, "threeLetterISOCountryName"); + Argument.AssertNotNull(capabilities, "capabilities"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartSearchAvailablePhoneNumbers)}"); + scope.Start(); + try + { + var searchRequest = new PhoneNumberSearchRequest(phoneNumberType, phoneNumberAssignmentType, capabilities) { AreaCode = options?.AreaCode, Quantity = options?.Quantity }; + var originalResponse = await RestClient.SearchAvailablePhoneNumbersAsync(threeLetterISOCountryName, searchRequest, cancellationToken).ConfigureAwait(false); + return new SearchAvailablePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreateSearchAvailablePhoneNumbersRequest(threeLetterISOCountryName, searchRequest).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Search for available phone numbers to purchase. + /// The ISO 3166-2 country code, e.g. US. + /// The type of phone numbers to search for. + /// The assignment type of the phone numbers to search for. + /// Capabilities of a phone number. + /// The phone number search options. + /// The cancellation token to use. + /// is null. + public virtual SearchAvailablePhoneNumbersOperation StartSearchAvailablePhoneNumbers(string threeLetterISOCountryName, PhoneNumberType phoneNumberType, PhoneNumberAssignmentType phoneNumberAssignmentType, + PhoneNumberCapabilities capabilities, PhoneNumberSearchOptions options = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(threeLetterISOCountryName, "threeLetterISOCountryName"); + Argument.AssertNotNull(capabilities, "capabilities"); + + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(StartSearchAvailablePhoneNumbers)}"); + scope.Start(); + try + { + var searchRequest = new PhoneNumberSearchRequest(phoneNumberType, phoneNumberAssignmentType, capabilities) { AreaCode = options?.AreaCode, Quantity = options?.Quantity }; + var originalResponse = RestClient.SearchAvailablePhoneNumbers(threeLetterISOCountryName, searchRequest, cancellationToken); + return new SearchAvailablePhoneNumbersOperation(_clientDiagnostics, _pipeline, RestClient.CreateSearchAvailablePhoneNumbersRequest(threeLetterISOCountryName, searchRequest).Request, originalResponse); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// Gets the list of all acquired phone numbers. + /// The cancellation token to use. + public virtual AsyncPageable GetPhoneNumbersAsync(CancellationToken cancellationToken = default) + { + async Task> FirstPageFunc(int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumbers)}"); + scope.Start(); + try + { + var response = await RestClient.ListPhoneNumbersAsync(skip: null, top: null, cancellationToken).ConfigureAwait(false); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + async Task> NextPageFunc(string nextLink, int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumbers)}"); + scope.Start(); + try + { + var response = await RestClient.ListPhoneNumbersNextPageAsync(nextLink, skip: null, top: null, cancellationToken).ConfigureAwait(false); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + return PageableHelpers.CreateAsyncEnumerable(FirstPageFunc, NextPageFunc); + } + + /// Gets the list of all acquired phone numbers. + /// The cancellation token to use. + public virtual Pageable GetPhoneNumbers(CancellationToken cancellationToken = default) + { + Page FirstPageFunc(int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumbers)}"); + scope.Start(); + try + { + var response = RestClient.ListPhoneNumbers(skip: null, top: null, cancellationToken); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + Page NextPageFunc(string nextLink, int? pageSizeHint) + { + using var scope = _clientDiagnostics.CreateScope($"{nameof(PhoneNumbersClient)}.{nameof(GetPhoneNumbers)}"); + scope.Start(); + try + { + var response = RestClient.ListPhoneNumbersNextPage(nextLink, skip: null, top: null, cancellationToken); + return Page.FromValues(response.Value.PhoneNumbers, response.Value.NextLink, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + return PageableHelpers.CreateEnumerable(FirstPageFunc, NextPageFunc); + } + + private static T AssertNotNull(T argument, string argumentName) + where T : class + { + Argument.AssertNotNull(argument, argumentName); + return argument; + } + + private static string AssertNotNullOrEmpty(string argument, string argumentName) + { + Argument.AssertNotNullOrEmpty(argument, argumentName); + return argument; + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClientsGetOperationHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClientsGetOperationHeaders.cs new file mode 100644 index 0000000000000..66cdc8416f5ed --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersClientsGetOperationHeaders.cs @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersGetOperationHeaders")] + internal partial class PhoneNumbersGetOperationHeaders + { + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersPurchasePhoneNumbersHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersPurchasePhoneNumbersHeaders.cs new file mode 100644 index 0000000000000..850271c6d1296 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersPurchasePhoneNumbersHeaders.cs @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersPurchasePhoneNumbersHeaders")] + internal partial class PhoneNumbersPurchasePhoneNumbersHeaders + { + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersReleasePhoneNumberHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersReleasePhoneNumberHeaders.cs new file mode 100644 index 0000000000000..03389e5b760ac --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersReleasePhoneNumberHeaders.cs @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersReleasePhoneNumberHeaders")] + internal partial class PhoneNumbersReleasePhoneNumberHeaders + { + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs new file mode 100644 index 0000000000000..d3e3ccc6f171a --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersSearchAvailablePhoneNumbersHeaders.cs @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersSearchAvailablePhoneNumbersHeaders")] + internal partial class PhoneNumbersSearchAvailablePhoneNumbersHeaders + { + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersUpdateCapabilitiesHeaders.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersUpdateCapabilitiesHeaders.cs new file mode 100644 index 0000000000000..911dad781f08f --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PhoneNumbersUpdateCapabilitiesHeaders.cs @@ -0,0 +1,12 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersUpdateCapabilitiesHeaders")] + internal partial class PhoneNumbersUpdateCapabilitiesHeaders + { + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/PurchasePhoneNumbersOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/PurchasePhoneNumbersOperation.cs new file mode 100644 index 0000000000000..435a9a2a70f20 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/PurchasePhoneNumbersOperation.cs @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersPurchasePhoneNumbersOperation")] + public partial class PurchasePhoneNumbersOperation + { + internal PurchasePhoneNumbersOperation(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, Request request, Response response) + { + _operation = new ArmOperationHelpers(this, clientDiagnostics, pipeline, request, response, OperationFinalStateVia.Location, "PurchasePhoneNumbersOperation"); + + if (response.Headers.TryGetValue("operation-id", out var id)) + { + Id = id; + } + } + + /// + public override string Id { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/ReleasePhoneNumberOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/ReleasePhoneNumberOperation.cs new file mode 100644 index 0000000000000..cf5c6bb0fb6ad --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/ReleasePhoneNumberOperation.cs @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersReleasePhoneNumberOperation")] + public partial class ReleasePhoneNumberOperation + { + internal ReleasePhoneNumberOperation(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, Request request, Response response) + { + _operation = new ArmOperationHelpers(this, clientDiagnostics, pipeline, request, response, OperationFinalStateVia.Location, "ReleasePhoneNumberOperation"); + + if (response.Headers.TryGetValue("operation-id", out var id)) + { + Id = id; + } + } + + /// + public override string Id { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/SearchAvailablePhoneNumbersOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/SearchAvailablePhoneNumbersOperation.cs new file mode 100644 index 0000000000000..45a23f08e4b65 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/SearchAvailablePhoneNumbersOperation.cs @@ -0,0 +1,26 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersSearchAvailablePhoneNumbersOperation")] + public partial class SearchAvailablePhoneNumbersOperation + { + internal SearchAvailablePhoneNumbersOperation(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, Request request, Response response) + { + _operation = new ArmOperationHelpers(this, clientDiagnostics, pipeline, request, response, OperationFinalStateVia.Location, "SearchAvailablePhoneNumbersOperation"); + + if (response.Headers.TryGetValue("operation-id", out var id)) + { + Id = id; + } + } + + /// + public override string Id { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/UpdatePhoneNumberCapabilitiesOperation.cs b/sdk/communication/Azure.Communication.PhoneNumbers/src/UpdatePhoneNumberCapabilitiesOperation.cs new file mode 100644 index 0000000000000..8770598d8b5d8 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/UpdatePhoneNumberCapabilitiesOperation.cs @@ -0,0 +1,26 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Azure.Communication.PhoneNumbers.Models; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.Communication.PhoneNumbers +{ + [CodeGenModel("InternalPhoneNumbersUpdateCapabilitiesOperation")] + public partial class UpdatePhoneNumberCapabilitiesOperation + { + internal UpdatePhoneNumberCapabilitiesOperation(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, Request request, Response response) + { + _operation = new ArmOperationHelpers(this, clientDiagnostics, pipeline, request, response, OperationFinalStateVia.Location, "UpdatePhoneNumberCapabilitiesOperation"); + + if (response.Headers.TryGetValue("operation-id", out var id)) + { + Id = id; + } + } + + /// + public override string Id { get; } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/src/autorest.md b/sdk/communication/Azure.Communication.PhoneNumbers/src/autorest.md index 7e6446a81844c..30875d6f7044e 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/src/autorest.md +++ b/sdk/communication/Azure.Communication.PhoneNumbers/src/autorest.md @@ -1,4 +1,4 @@ -# Azure.Communication.Administration +# Azure.Communication.PhoneNumbers Run `dotnet msbuild /t:GenerateCode` to generate code. @@ -6,8 +6,9 @@ Run `dotnet msbuild /t:GenerateCode` to generate code. > see https://aka.ms/autorest ``` yaml +public-clients: true input-file: - - https://raw.githubusercontent.com/Azure/azure-rest-api-specs/257f060be8b60d8468584682aa2d71b1faa5f82c/specification/communication/data-plane/Microsoft.CommunicationServicesAdministration/preview/2020-07-20-preview1/communicationservicesadministration.json -title: Phone number administration + - https://raw.githubusercontent.com/Azure/azure-rest-api-specs/a4d1e1516433894fca89f9600a6ac8a5471fc598/specification/communication/data-plane/Microsoft.CommunicationServicesPhoneNumbers/stable/2021-03-07/phonenumbers.json +title: Phone numbers payload-flattening-threshold: 3 ``` diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Azure.Communication.PhoneNumbers.Tests.csproj b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Azure.Communication.PhoneNumbers.Tests.csproj index e870f70ef9822..2d9454ab3b5bb 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Azure.Communication.PhoneNumbers.Tests.csproj +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Azure.Communication.PhoneNumbers.Tests.csproj @@ -22,7 +22,8 @@ - - + + + diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientLiveTestBase.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientLiveTestBase.cs similarity index 52% rename from sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientLiveTestBase.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientLiveTestBase.cs index 1572953947d47..06bf27d7c39e7 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientLiveTestBase.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientLiveTestBase.cs @@ -8,24 +8,24 @@ namespace Azure.Communication.PhoneNumbers.Tests { - public class PhoneNumberAdministrationClientLiveTestBase : RecordedTestBase + public class PhoneNumbersClientLiveTestBase : RecordedTestBase { - public PhoneNumberAdministrationClientLiveTestBase(bool isAsync) : base(isAsync) + public PhoneNumbersClientLiveTestBase(bool isAsync) : base(isAsync) => Sanitizer = new PhoneNumbersClientRecordedTestSanitizer(); public bool IncludePhoneNumberLiveTests => TestEnvironment.Mode == RecordedTestMode.Playback || Environment.GetEnvironmentVariable("INCLUDE_PHONENUMBER_LIVE_TESTS") == "True"; /// - /// Creates a with the connectionstring via environment + /// Creates a with the connectionstring via environment /// variables and instruments it to make use of the Azure Core Test Framework functionalities. /// - /// The instrumented . - protected PhoneNumberAdministrationClient CreateClient(bool isInstrumented = true) + /// The instrumented . + protected PhoneNumbersClient CreateClient(bool isInstrumented = true) { - var client = new PhoneNumberAdministrationClient( + var client = new PhoneNumbersClient( TestEnvironment.ConnectionString, - InstrumentClientOptions(new PhoneNumberAdministrationClientOptions())); + InstrumentClientOptions(new PhoneNumbersClientOptions())); // We always create the instrumented client to suppress the instrumentation check var instrumentedClient = InstrumentClient(client); @@ -33,16 +33,16 @@ protected PhoneNumberAdministrationClient CreateClient(bool isInstrumented = tru } /// - /// Creates a with the token credential + /// Creates a with the token credential /// and instruments it to make use of the Azure Core Test Framework functionalities. /// - /// The instrumented . - protected PhoneNumberAdministrationClient CreateClientWithTokenCredential(TokenCredential token, bool isInstrumented = true) + /// The instrumented . + protected PhoneNumbersClient CreateClientWithTokenCredential(TokenCredential token, bool isInstrumented = true) { - var client = new PhoneNumberAdministrationClient( + var client = new PhoneNumbersClient( TestEnvironment.Endpoint, token, - InstrumentClientOptions(new PhoneNumberAdministrationClientOptions())); + InstrumentClientOptions(new PhoneNumbersClientOptions())); return isInstrumented ? InstrumentClient(client) : client; } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientRecordedTestSanitizer.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientRecordedTestSanitizer.cs index afb7c90995b04..2234e35b5edee 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientRecordedTestSanitizer.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientRecordedTestSanitizer.cs @@ -1,6 +1,8 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. +using System.Collections.Generic; +using System.Linq; using System.Text.RegularExpressions; namespace Azure.Communication.Pipeline @@ -8,8 +10,25 @@ namespace Azure.Communication.Pipeline public class PhoneNumbersClientRecordedTestSanitizer : CommunicationRecordedTestSanitizer { private static readonly Regex _phoneNumberRegEx = new Regex(@"[\\+]?[0-9]{11,15}", RegexOptions.Compiled); + private static readonly Regex _urlEncodedPhoneNumberRegEx = new Regex(@"[\\%2B]{0,3}[0-9]{11,15}", RegexOptions.Compiled); public override string SanitizeTextBody(string contentType, string body) => base.SanitizeTextBody(contentType, _phoneNumberRegEx.Replace(body, SanitizeValue)); + + public override void SanitizeHeaders(IDictionary headers) + { + base.SanitizeHeaders(headers); + + if (headers.ContainsKey("location")) + { + headers["location"] = new[] { _urlEncodedPhoneNumberRegEx.Replace(headers["location"].First(), SanitizeValue) }; + } + } + + public override string SanitizeUri(string uri) + { + uri = base.SanitizeUri(uri); + return _urlEncodedPhoneNumberRegEx.Replace(uri, SanitizeValue); + } } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientTestEnvironment.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientTestEnvironment.cs similarity index 67% rename from sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientTestEnvironment.cs rename to sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientTestEnvironment.cs index e760aba20b81f..8d98811b05108 100644 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumberAdministrationClientTestEnvironment.cs +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/Infrastructure/PhoneNumbersClientTestEnvironment.cs @@ -5,7 +5,7 @@ namespace Azure.Communication.PhoneNumbers.Tests { - public class PhoneNumberAdministrationClientTestEnvironment : CommunicationTestEnvironment + public class PhoneNumbersClientTestEnvironment : CommunicationTestEnvironment { } } diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumberAdministrationClient/PhoneNumberAdministrationClientLiveTests.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumberAdministrationClient/PhoneNumberAdministrationClientLiveTests.cs deleted file mode 100644 index d35970205cad9..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumberAdministrationClient/PhoneNumberAdministrationClientLiveTests.cs +++ /dev/null @@ -1,349 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Net.WebSockets; -using System.Text; -using System.Text.RegularExpressions; -using System.Threading.Tasks; -using Azure.Communication.PhoneNumbers.Models; -using Azure.Core; -using Azure.Core.TestFramework; -using Azure.Identity; -using NUnit.Framework; - -namespace Azure.Communication.PhoneNumbers.Tests -{ - /// - /// The suite of tests for the class. - /// - /// - /// These tests have a dependency on live Azure services and may incur costs for the associated - /// Azure subscription. - /// - public class PhoneNumberAdministrationClientLiveTests : PhoneNumberAdministrationClientLiveTestBase - { - /// - /// Initializes a new instance of the class. - /// - /// A flag used by the Azure Core Test Framework to differentiate between tests for asynchronous and synchronous methods. - public PhoneNumberAdministrationClientLiveTests(bool isAsync) : base(isAsync) - { - } - - [Test] - [TestCase("en-US", TestName = "GeneratesPhoneNumberClientUsingTokenCredential")] - public async Task GeneratesPhoneNumberClientUsingTokenCredential(string? locale) - { - TokenCredential tokenCredential; - if (Mode == RecordedTestMode.Playback) - { - tokenCredential = new MockCredential(); - } - else - { - tokenCredential = new DefaultAzureCredential(); - } - var client = CreateClientWithTokenCredential(tokenCredential); - - // Smoke test to ensure that client generated from token is able to work as expected. - var numbersPagable = client.GetAllPhoneNumbersAsync(); - var numbers = await numbersPagable.ToEnumerableAsync(); - - Assert.IsNotNull(numbers); - } - - [Test] - [TestCase(null, TestName = "GetAllSupportedCountries")] - [TestCase("en-US", TestName = "GetAllSupportedCountriesEnUsLocale")] - public async Task GetAllSupportedCountries(string? locale) - { - var client = CreateClient(); - - var countries = client.GetAllSupportedCountriesAsync(locale); - - await foreach (var country in countries) - { - Assert.IsFalse(string.IsNullOrEmpty(country.CountryCode)); - Assert.IsFalse(string.IsNullOrEmpty(country.LocalizedName)); - } - } - - [Test] - public async Task GetAllPhoneNumbers() - { - var client = CreateClient(); - - var numbersPagable = client.GetAllPhoneNumbersAsync(); - var numbers = await numbersPagable.ToEnumerableAsync(); - - Assert.IsNotNull(numbers); - } - - [Test] - [PlaybackOnly("TollFreeNumbersAreDisabledTemporarily")] - public async Task GetAllReservations() - { - // Arrange - var client = CreateClient(); - - const string locale = "en-US"; - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - string phonePlanGroupId = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree).PhonePlanGroupId; - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); - var phonePlan = (await pageablePhonePlans.ToEnumerableAsync()).First(); - var areaCode = phonePlan.AreaCodes.First(); - - var reservationOptions = new CreateReservationOptions("My reservation", "my description", new[] { phonePlan.PhonePlanId }, areaCode); - reservationOptions.Quantity = 1; - var reservationOperation = await client.StartReservationAsync(reservationOptions); - - if (TestEnvironment.Mode == RecordedTestMode.Playback) - await reservationOperation.WaitForCompletionAsync(TimeSpan.Zero, default).ConfigureAwait(false); - else - await reservationOperation.WaitForCompletionAsync().ConfigureAwait(false); - - // Act - var reservationsPagable = client.GetAllReservationsAsync(); - var reservations = await reservationsPagable.ToEnumerableAsync(); - - Assert.IsNotEmpty(reservations); - - await client.CancelReservationAsync(reservationOperation.Id); - } - - [Test] - [TestCase(null, null)] - [TestCase("en-US", null)] - [TestCase("en-US", false)] - [TestCase("en-US", true)] - public async Task GetPlanGroups(string? locale, bool? includeRateInformation) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale, includeRateInformation); - - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync(); - - Assert.IsNotNull(phonePlanGroups); - Assert.IsNotEmpty(phonePlanGroups); - - var firstGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - - Assert.IsNotNull(firstGroup.LocalizedName); - Assert.IsNotNull(firstGroup.LocalizedDescription); - - if (includeRateInformation == true) - { - Assert.IsNotNull(firstGroup.RateInformation); - } - else - { - Assert.IsNull(firstGroup.RateInformation); - } - } - - [Test] - [TestCase(null)] - [TestCase("en-US")] - public async Task GetPhonePlans(string? locale) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroups.First().PhonePlanGroupId, locale); - var phonePlans = await pageablePhonePlans.ToEnumerableAsync(); - - Assert.IsNotNull(phonePlans); - Assert.IsNotEmpty(phonePlans); - } - - [Test] - [TestCase(null)] - [TestCase("en-US")] - public async Task GetAreaCodesForPlan(string? locale) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - string phonePlanGroupId = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic).PhonePlanGroupId; - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); - var phonePlans = await pageablePhonePlans.ToEnumerableAsync(); - var phonePlanId = phonePlans.First().PhonePlanId; - - var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, phonePlanGroupId, phonePlanId).ConfigureAwait(false); - - var locationOptions = new List - { - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = "NY" - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = "NOAM-US-NY-NY" - } - }; - - var areaCodes = await client.GetAllAreaCodesAsync("selection", countryCode, phonePlanId, locationOptions); - - Assert.IsNotNull(areaCodes.Value.PrimaryAreaCodes); - Assert.IsNotEmpty(areaCodes.Value.PrimaryAreaCodes); - } - - [Test] - [TestCase(null)] - [TestCase("en-US")] - [PlaybackOnly("TollFreeNumbersAreDisabledTemporarily")] - public async Task CreateReservationErrorState(string? locale) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - string phonePlanGroupId = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree).PhonePlanGroupId; - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); - var phonePlan = (await pageablePhonePlans.ToEnumerableAsync()).First(); - var tollFreeAreaCode = phonePlan.AreaCodes.First(); - - string geographicPhonePlanGroupId = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic).PhonePlanGroupId; - var geographicPhonePlanId = (await client.GetPhonePlansAsync(countryCode, geographicPhonePlanGroupId, locale).ToEnumerableAsync()).First().PhonePlanId; - - var reservationOptions = new CreateReservationOptions("My reservation", "my description", new[] { geographicPhonePlanId }, tollFreeAreaCode); - reservationOptions.Quantity = 1; - var reservationOperation = await client.StartReservationAsync(reservationOptions); - - try - { - if (TestEnvironment.Mode == RecordedTestMode.Playback) - await reservationOperation.WaitForCompletionAsync(TimeSpan.Zero, default).ConfigureAwait(false); - else - await reservationOperation.WaitForCompletionAsync().ConfigureAwait(false); - } - catch (Exception ex) - { - Assert.AreEqual("Reservation has failed.", ex.Message); - return; - } - - Assert.Fail("WaitForCompletionAsync should have thrown an exception."); - } - - [Test] - [TestCase(null)] - [TestCase("en-US")] - [PlaybackOnly("TollFreeNumbersAreDisabledTemporarily")] - public async Task CreateReservation(string? locale) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - string phonePlanGroupId = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree).PhonePlanGroupId; - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); - var phonePlan = (await pageablePhonePlans.ToEnumerableAsync()).First(); - var areaCode = phonePlan.AreaCodes.First(); - - var reservationOptions = new CreateReservationOptions("My reservation", "my description", new[] { phonePlan.PhonePlanId }, areaCode); - reservationOptions.Quantity = 1; - var reservationOperation = await client.StartReservationAsync(reservationOptions); - - if (TestEnvironment.Mode == RecordedTestMode.Playback) - await reservationOperation.WaitForCompletionAsync(TimeSpan.Zero, default).ConfigureAwait(false); - else - await reservationOperation.WaitForCompletionAsync().ConfigureAwait(false); - - Assert.IsNotNull(reservationOperation); - Assert.IsTrue(reservationOperation.HasCompleted); - Assert.IsTrue(reservationOperation.HasValue); - - var reservation = reservationOperation.Value; - Assert.IsNotNull(reservation); - - Assert.AreEqual(ReservationStatus.Reserved, reservation.Status); - Assert.AreEqual(areaCode, reservation.AreaCode); - Assert.IsNull(reservation.ErrorCode); - Assert.AreEqual(1, reservation.PhoneNumbers?.Count); - - await client.CancelReservationAsync(reservationOperation.Id); - } - - [Test] - [TestCase(null)] - [TestCase("en-US")] - public async Task CreateGeographicalReservation(string? locale) - { - var client = CreateClient(); - const string countryCode = "US"; - - var pageablePhonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - var phonePlanGroups = await pageablePhonePlanGroups.ToEnumerableAsync().ConfigureAwait(false); - - var phonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - var pageablePhonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroup.PhonePlanGroupId, locale); - var phonePlan = (await pageablePhonePlans.ToEnumerableAsync()).First(); - - var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, phonePlanGroup.PhonePlanGroupId, phonePlan.PhonePlanId); - var state = locationOptionsResponse.Value.LocationOptions.Options.First(); - - var locationOptionsQueries = new List - { - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = state.Value - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = state.LocationOptions.First().Options.First().Value - } - }; - - var areaCodes = await client.GetAllAreaCodesAsync(phonePlan.LocationType.ToString(), countryCode, phonePlan.PhonePlanId, locationOptionsQueries); - var areaCode = areaCodes.Value.PrimaryAreaCodes.First(); - - var reservationOptions = new CreateReservationOptions("My reservation", "my description", new[] { phonePlan.PhonePlanId }, areaCode); - reservationOptions.Quantity = 1; - var reservationOperation = await client.StartReservationAsync(reservationOptions); - - if (TestEnvironment.Mode == RecordedTestMode.Playback) - await reservationOperation.WaitForCompletionAsync(TimeSpan.Zero, default).ConfigureAwait(false); - else - await reservationOperation.WaitForCompletionAsync().ConfigureAwait(false); - - Assert.IsNotNull(reservationOperation); - Assert.IsTrue(reservationOperation.HasCompleted); - Assert.IsTrue(reservationOperation.HasValue); - - var reservation = reservationOperation.Value; - Assert.IsNotNull(reservation); - - Assert.AreEqual(ReservationStatus.Reserved, reservation.Status); - Assert.AreEqual(areaCode, reservation.AreaCode); - Assert.IsNull(reservation.ErrorCode); - Assert.AreEqual(1, reservation.PhoneNumbers?.Count); - - await client.CancelReservationAsync(reservationOperation.Id); - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumbersClient/PhoneNumbersClientLiveTests.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumbersClient/PhoneNumbersClientLiveTests.cs new file mode 100644 index 0000000000000..8605967edfc0d --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/PhoneNumbersClient/PhoneNumbersClientLiveTests.cs @@ -0,0 +1,68 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Net.WebSockets; +using System.Text; +using System.Text.RegularExpressions; +using System.Threading.Tasks; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Communication.PhoneNumbers.Tests; +using Azure.Core.TestFramework; +using NUnit.Framework; + +namespace Azure.Communication.PhoneNumbers.Tests +{ + /// + /// The suite of tests for the class. + /// + /// + /// These tests have a dependency on live Azure services and may incur costs for the associated + /// Azure subscription. + /// + public class PhoneNumbersClientLiveTests : PhoneNumbersClientLiveTestBase + { + /// + /// Initializes a new instance of the class. + /// + /// A flag used by the Azure Core Test Framework to differentiate between tests for asynchronous and synchronous methods. + public PhoneNumbersClientLiveTests(bool isAsync) : base(isAsync) + { + } + + [Test] + public async Task ListPhoneNumbersAsync() + { + var client = CreateClient(); + + var numbersPagable = client.GetPhoneNumbersAsync(); + var numbers = await numbersPagable.ToEnumerableAsync(); + + Assert.IsNotNull(numbers); + } + + [Test] + [TestCase(null)] + [TestCase("en-US")] + public async Task CreateSearchErrorState(string? locale) + { + var client = CreateClient(); + const string countryCode = "US"; + try + { + // User and toll free is an invalid combination + var searchOperation = await client.StartSearchAvailablePhoneNumbersAsync(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Person, + new PhoneNumberCapabilities(PhoneNumberCapabilityType.Outbound, PhoneNumberCapabilityType.None), new PhoneNumberSearchOptions { AreaCode = "212", Quantity = 1 }); + } + catch (Azure.RequestFailedException ex) + { + Assert.AreEqual(400, ex.Status); + return; + } + + Assert.Fail("WaitForCompletionAsync should have thrown an exception."); + } + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%).json deleted file mode 100644 index 6b40edc80530c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%).json +++ /dev/null @@ -1,2039 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:04 GMT", - "traceparent": "00-c27fb5d19d313e4d84588d810cee4757-c1d33a159a3d3343-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "739637468b25c540f32237a18d1a62db", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:03 GMT", - "MS-CV": "uoWlgdhqlESMqczoETvxHg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Cx0vYAAAAAAS8Vng3IXHR7JX09vPhGRrWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "297ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:04 GMT", - "traceparent": "00-580c348ea4b44e40823f3e68d047fe4d-a6e61426138f094d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "71b0c8d2006445bd827d68e883c245db", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:03 GMT", - "MS-CV": "JsIJ705HHkO5LdCgK4u7OA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Cx0vYAAAAADXm3mtW81uQ7PDGEmG3whWWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "294ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:04 GMT", - "traceparent": "00-3b1a237ab5d73d49aebb42a1a3813a0b-663f3e0bf2b26440-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "9ff8101377fb97322b051d2fe7c61df8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:03 GMT", - "MS-CV": "7t\u002BK4QfU9kS9tKoDyjgimA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Cx0vYAAAAABl4\u002B0rjcw5R4Z1YGDeu0arWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "302ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:05 GMT", - "traceparent": "00-2fd604f240c58b44929491dad894525f-454142e667f53743-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "8a6977790d6746537951f0a823584230", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:04 GMT", - "MS-CV": "E\u002B6/Tkify0mzzF7HQXvzxw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DB0vYAAAAAD5istXfCXARYChj4OeE\u002BdwWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "268ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "149", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:05 GMT", - "traceparent": "00-fed34151cea0bf4d9312755216ab28ae-36b95033673f8b4a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "7d8e5bddc3225bdf9518465ee38d5dbc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:05 GMT", - "MS-CV": "d6h808mUo0OFXHN2145nLg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DB0vYAAAAAAuOGyMeprjQ4t8AZRZv9kIWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1449ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:06 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "0c6e6f5fba580674bcb225aa868a73d2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:06 GMT", - "MS-CV": "bYDI9S4PDEqbK1\u002Bh97YhRw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Dh0vYAAAAACcwQfDqjB5Q4pUcpmcw4ntWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "462ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:08 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "8b52ecc3a038b6d6970ef54ec6f463eb", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:07 GMT", - "MS-CV": "7M9QSABMI0OXqNhJkHNWzg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Dx0vYAAAAADEmR76Yd7HR4UxlrU3yie9WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "476ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:09 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "b34934f335e922d8e787c06f9d35d40a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:09 GMT", - "MS-CV": "A\u002B7JGQadNkiHkTy7THnRFw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ER0vYAAAAAA4Wl39\u002BLpjTJ8ibWh4CqcDWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "464ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:11 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "f69b73a5d23bbe8399b87549c5253fc8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:10 GMT", - "MS-CV": "oZ/ratfX70iClJZVbTgz5w.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Eh0vYAAAAADrvJ1i9QrVR4gumhid55lCWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "461ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:13 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "52b6394fc0418ee81430a3b0e0661861", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:12 GMT", - "MS-CV": "\u002BVy/CYBIjUGMsPq16n5gFA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0FB0vYAAAAABxStm7\u002B25EQbcFYEV3X41EWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "470ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:14 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "53a9ea3a6c5921b0b08a1931bf8e5dc2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:13 GMT", - "MS-CV": "55dmEIaLhECHr6lWFsDxKA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0FR0vYAAAAADUPgrAVA5AQYn54vc61uGyWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "470ms" - }, - "ResponseBody": { - "searchId": "af74f978-cb34-44d7-9271-bcc96eeb6bbf", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:05.4400968\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2021-02-19T02:22:12.3316795\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/af74f978-cb34-44d7-9271-bcc96eeb6bbf/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:15 GMT", - "traceparent": "00-11da2125e86ca249a6a5fdf619669025-339e12c2aade7746-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6420f747817ee4c98a0ce20b2ed2de33", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Fri, 19 Feb 2021 02:06:14 GMT", - "MS-CV": "Zm\u002BPtAFgQE\u002Bk7ZIASt3mgQ.0", - "Request-Context": "appId=", - "X-Azure-Ref": "0Fh0vYAAAAABxbO1PSMNKQ5rgpa3\u002BC1fSWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "952ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "878685333" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%)Async.json deleted file mode 100644 index 0786b3b4c6494..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(%en-US%)Async.json +++ /dev/null @@ -1,2039 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:38 GMT", - "traceparent": "00-9bfd4fed79f1e549b2b18fb693ffbdcf-36c5312fd68b8b4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5decd27f89edb3cf40c24b3367b81e64", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:38 GMT", - "MS-CV": "zzFF\u002BzkdM0KsXP2aClLm/A.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Lh0vYAAAAAA9fHsuMQdnSZIyM/IIyjZfWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "309ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:39 GMT", - "traceparent": "00-43df04b093128145a9a6685cc8ffe053-e00c3bf748dd4c49-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "52c2a5c7b86ac49ceb0b298a89297050", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:38 GMT", - "MS-CV": "XFa9pHdwfUmZ9T91IxRIKw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Lh0vYAAAAADkrhxRDns4R4pNw9MwXW7eWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "320ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:39 GMT", - "traceparent": "00-b54e3d7dbc144b49bbfb1c7e887ff8ef-a493e44e29137a44-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "9b0408fbc20e3e55c89e1db18a747fa1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:39 GMT", - "MS-CV": "PXRr5k2HAk\u002BRoEJR3gHQ6Q.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Lh0vYAAAAAD0UqumIsodR6\u002BMRn\u002BKm6wSWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "319ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:40 GMT", - "traceparent": "00-94c4c06522ab5f498caf1f95e871b079-0720492ff86ab647-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "7c4e5ea62787c62e352772e160452916", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:39 GMT", - "MS-CV": "f6ZJwBpt7U\u002BJ/Qep2CgOJg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Lx0vYAAAAAAwi8kLcuF8QK6oMMarxRu9WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "298ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "149", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:40 GMT", - "traceparent": "00-6b34212268ea6944b74b283ded89eaf3-b99d4ce90590b944-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5e38fb5282b304554f8389cb9beb3a77", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:40 GMT", - "MS-CV": "yBieJ\u002BJ4DEej0dBLaaaUSg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Lx0vYAAAAAAnA5tvmlLQR7UhUyJNjvq0WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1262ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:41 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "2be4878bf3dbd3c9da3d66e75074de82", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:41 GMT", - "MS-CV": "GHqDGhMPY0qMxHFx8WIp6w.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0MB0vYAAAAAAwX2dO3jnnS4XYJY7NClOxWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "551ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:43 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "8f5f0675203c23ee09492c039d622a4a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:42 GMT", - "MS-CV": "nJuQGMMsREi5DLhbZMMW3Q.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Mh0vYAAAAAAPBiD7OeJOTb5ULlPDOsm5WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "479ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:44 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d855faecfe615f3b316484751c6db4db", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:44 GMT", - "MS-CV": "Df2wIARGgEa8LcmHQ9oHzw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0NB0vYAAAAAAyOQQ3olxuSZJabZ6pdT0WWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "510ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:46 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "955607a5aa8c6a3b99c02291c6c53678", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:46 GMT", - "MS-CV": "gdA\u002BJx\u002BoskG9jNFOd9Ucig.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0NR0vYAAAAABKN/ebMmMCQpXoY/XSyV4jWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "653ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:48 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "55fa1b12051e7721caff5dd79c78079b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:47 GMT", - "MS-CV": "WUMaGlkMYUGrVrH8C6axTg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Nx0vYAAAAAAEZ5nvZ\u002BluSpzyr7Xc0Hi9WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "495ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:49 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "965e5195950b42bebfea3ea1dcaa996c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:49 GMT", - "MS-CV": "bH8CeJnT5ECK53pHKz3Kew.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0OB0vYAAAAADXQEqvXxsnRLn2Mil9ta2TWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "567ms" - }, - "ResponseBody": { - "searchId": "3f040b03-ac1a-4208-bf6d-c96a483680ef", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:40.2185963\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2021-02-19T02:22:47.5536503\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/3f040b03-ac1a-4208-bf6d-c96a483680ef/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:50 GMT", - "traceparent": "00-b315c0e4893b8045a5ca24cb6ca2f6c0-0dfbb3252fdb1e4a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "00620b2d5e739fbce5dfcb8c4c63ce21", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Fri, 19 Feb 2021 02:06:50 GMT", - "MS-CV": "ZSSCg8aIH0edUm22uy\u002BzRg.0", - "Request-Context": "appId=", - "X-Azure-Ref": "0OR0vYAAAAACF7Jf9f6xkT7gmZLs1\u002B\u002B14WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1040ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1861070499" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null).json deleted file mode 100644 index 2b71525033f8e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null).json +++ /dev/null @@ -1,1997 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "traceparent": "00-faa586e04822df458de26c7ffda3d9b9-ab85ac80ea346a4f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "3ac927d16b10fce38fc85ea276793fd3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:52 GMT", - "MS-CV": "MrTIFGsmskur/j50fP7rVQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AB0vYAAAAAAk2KYeNixsQbE1yxJCFZ4LWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "403ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "traceparent": "00-fe0de420de937745abe811fa73eff462-79aff88596472a4a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "93485fb0bef8628ff6eaab6e76d836aa", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "MS-CV": "N5maTROGBUK5WqOCtSG4Zg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AR0vYAAAAABdCiL0U0nYQJjipvJvT3d3WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "287ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:54 GMT", - "traceparent": "00-75eb0d67cc95214f87a4fc2b3ccd51f8-d1c110200bcd9c46-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "f06c6b3e262493dd114c67da613d659a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "MS-CV": "yZjQ9cK7lUCCu1mqmSGvVQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AR0vYAAAAAB3u1xR0PgaR4Id4P\u002BPEpDpWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:05:54 GMT", - "traceparent": "00-ab3dff48ef5cdf4186e9de83d92dcca4-e127c7c8f724ad4e-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6cacfd4afd67131198664425bf7486b7", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "MS-CV": "hOEER3JxmEaR8Xb\u002B0B6r\u002Bw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AR0vYAAAAAAMiRJ4Vf39QaDpaFw/DiUIWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "261ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "149", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:05:54 GMT", - "traceparent": "00-4c99e7edbc53d94c8af772640b39e78b-ac15315118988941-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "0b63b4924f0c89af82b481ab56b401b9", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:55 GMT", - "MS-CV": "Zmah7zfojk\u002BYJaOM77\u002B8bw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ah0vYAAAAACaRN7JOSFsQLbdCvgKw/98WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1566ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:56 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "79241185c92b41435a5957bde2b7d39c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:56 GMT", - "MS-CV": "hlquUf/DNkGgGayFEcwd1Q.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ax0vYAAAAABL\u002BhZRrjUEQLUgov1HFWXVWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "513ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:05:54.7183855\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:58 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "ad48afc65ad9fa8d4d22eab27b66bce3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:57 GMT", - "MS-CV": "nz\u002Boo6vjKU\u002BOHVVPVNzFpw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0BR0vYAAAAAC2jJT3IprHQJ2iBe\u002BUKBCYWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "465ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:05:54.7183855\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:59 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "aea08a650d50c98b7022b0b3f7f1a6ca", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:59 GMT", - "MS-CV": "FANBi7nijk2b7RU2bjTdeg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Bh0vYAAAAAD192qCFu2vQarfjC6bY5MsWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "463ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:05:54.7183855\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:01 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "a7e4e4e0546c2adf842a2b08de90c5f4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:00 GMT", - "MS-CV": "32PxjjiWdEy72QoCYjqrxg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0CB0vYAAAAAA4\u002B\u002BbHAAFPRphMOvsWV0PFWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "466ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:05:54.7183855\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:02 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5858749c2517b84c247e3cb7aad9025c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:01 GMT", - "MS-CV": "ZMDo9nadH0qLxmfXYpGB2Q.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0CR0vYAAAAACi/c\u002B7Piw1Qaz72r6Rh5x9WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "480ms" - }, - "ResponseBody": { - "searchId": "7a7a8acf-d84c-42b3-8f41-35476766b44c", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:05:54.7183855\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2021-02-19T02:22:00.6273542\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7a7a8acf-d84c-42b3-8f41-35476766b44c/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:03 GMT", - "traceparent": "00-b85af30d13b29d4cb425432a227be5ca-b18e08b68c79a94d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "96d2207b15811076ab752925e282eadf", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Fri, 19 Feb 2021 02:06:02 GMT", - "MS-CV": "OaADveO\u002B2km0TtDOL5K19g.0", - "Request-Context": "appId=", - "X-Azure-Ref": "0Ch0vYAAAAAA6f9qyBeDGQKdsxV8RvSHVWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "943ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1433459237" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null)Async.json deleted file mode 100644 index 3ea2ba769bfb7..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateGeographicalReservation(null)Async.json +++ /dev/null @@ -1,2039 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:27 GMT", - "traceparent": "00-2e4b85338f08a34fadf2a15fa410ede9-67ef3911df29d844-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "fdb48c21299506025a21ade03d8ce3be", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:25 GMT", - "MS-CV": "5QjqUzbDP0CVIaWbRpIhfQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ih0vYAAAAACSY/U\u002BYiYdT4crsX7LZ16XWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "289ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:27 GMT", - "traceparent": "00-36ebdf35349b9748945764a3a7983828-7e0f053c187c0046-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "c6f1fbd3808f0fdde51928f7704f4e84", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:26 GMT", - "MS-CV": "JYtyFO68yEO9HWP1I4vM\u002BQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ih0vYAAAAAB35QibV9iSSbrO2sAgNi8xWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "297ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:27 GMT", - "traceparent": "00-90e80171e25d924f8852cebad00d4ce7-c9dd365cb47f4442-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "78cf5f5203cb765d252297e194892fe3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:26 GMT", - "MS-CV": "JBr2pYTvzEqV8ezbKkygOA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ih0vYAAAAABtb1VJUXqxR64MgPmL/s6VWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "290ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:28 GMT", - "traceparent": "00-8553496ebcdff242838f9a3322b23830-f6b94e3dd0a20a4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "a051131f153ca15bafa4187c000b950b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:27 GMT", - "MS-CV": "34YdZ3SPMECbd2irqapiHg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ix0vYAAAAAAQ7EZVl/AiTItwQouKQ9ppWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "611ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "149", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:28 GMT", - "traceparent": "00-029eb2d20c1e15408e154746e35ae310-78dff2621d583c49-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "de8e28d26bbcd0f29e7ba16ce8fb7b5b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:28 GMT", - "MS-CV": "5qgXqxFvz0yP1fFPc4qgqA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ix0vYAAAAAAEn98vclsTTIxhgByTf15LWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "965ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:29 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5dd745e9aefd3c48032ec827eae0751a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:28 GMT", - "MS-CV": "ubGJ/KAIQ0Ko6\u002BPEke\u002BdHg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JB0vYAAAAAA/dxbk4THaQrogkLmzlXHrWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "467ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:31 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6b0e8c8c51fbb427208101c073eeb8b3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:30 GMT", - "MS-CV": "kfKInY\u002BR\u002BEyQlmOZBbb1CQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Jh0vYAAAAAALQkOrpcqWRa8J4CfezWPNWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "464ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:32 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "bb92bd293733240ee051db8da2cae5bd", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:31 GMT", - "MS-CV": "UUgyrbzGkku1eBMczpDQ7A.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Jx0vYAAAAAD1jACileHjQZKvsPh\u002B9h4QWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "462ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:34 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5cdf87060fed985f1d233d7bac87c914", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:33 GMT", - "MS-CV": "3OVVVQPDbE2/hpGYPrYMnw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KR0vYAAAAAAsepb6gAYdQJC9cTpqRHH/WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "467ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:35 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "2dfe1476b94e55e77eea8ba976991255", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:34 GMT", - "MS-CV": "wEiL0XJxl0ujl33dntaUEw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Kh0vYAAAAAB7kTOggCCcQqBhDhMfVureWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "475ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:37 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "ecba449c5c0e19c65dfa9d10fa927758", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:36 GMT", - "MS-CV": "aHgS\u002Bw62nkSJ/kHXppS2KA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0LB0vYAAAAACkqgcC2nWsSp6\u002BDlywAwjvWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "592ms" - }, - "ResponseBody": { - "searchId": "8baca150-bb2d-4b6f-8d5b-470a55cdc6fb", - "displayName": "My reservation", - "createdAt": "2021-02-19T02:06:28.1853981\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "01432411-5169-4665-b13e-3fa56c10e1d1" - ], - "areaCode": "205", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2021-02-19T02:22:34.8008191\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8baca150-bb2d-4b6f-8d5b-470a55cdc6fb/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:37 GMT", - "traceparent": "00-8257054aba48b541838057d8217c3263-c29ccc9c2fa7cc40-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "8d17c688b7cc4c6fa08ade0283b52184", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Fri, 19 Feb 2021 02:06:38 GMT", - "MS-CV": "GLVd8mah/UOPeqp6vKlbEA.0", - "Request-Context": "appId=", - "X-Azure-Ref": "0LR0vYAAAAAAmJT64QtC9QYuQQb5VoaTBWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "993ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1085568144" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%).json deleted file mode 100644 index 92a0b8c9d2c3c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%).json +++ /dev/null @@ -1,494 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:30 GMT", - "traceparent": "00-90813ca109234b488334682b06b9d73e-d18df3a0afc47a41-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d411888c8e1506a27d323ae14f488935", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:30 GMT", - "MS-CV": "kk4A1iqxoUazARKxlcfnew.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VkosYAAAAADKTPaH7/DzRIhvb1yIFwCYWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "587ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:31 GMT", - "traceparent": "00-b416a06300c0f745868553afb5772a5f-43a1fd7a0fcf0047-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5f606fa9900c1898868d7a33412c82c2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:31 GMT", - "MS-CV": "\u002BOUGJqpeH0G0Np98Q0Jiiw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0V0osYAAAAAAGTR1zr0aPRKFWwTLNIpmPWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "332ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "855" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Tue, 16 Feb 2021 22:42:32 GMT", - "traceparent": "00-ee7c2ec4892e10438822409c27914457-bc096b615b02134a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "e3e295f5584d12d01819e418d2b69718", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:32 GMT", - "MS-CV": "f8h0HOTJH0iSiI7pOwIjmQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0WEosYAAAAABVb00OY641R7kfWU0TMx94WVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1046ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:33 GMT", - "traceparent": "00-bdc12b312119e941b796e37d72f56506-f16ca2e077d74b47-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "84b1dc48e53efb6aeff94e87136fc451", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:33 GMT", - "MS-CV": "mpJeObrLA0CfyYTZbcQbyg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0WUosYAAAAABloXzRGeDaTI5/0gm71K0qWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "680ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e", - "displayName": "My reservation", - "createdAt": "2021-02-16T22:42:32.3454039\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:35 GMT", - "traceparent": "00-99a8dab0489c594e96f21265e60743cb-93f2ece3e52d194e-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "baeb77b0a66550e89f4e46f2ac7f45d0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:34 GMT", - "MS-CV": "0zsIzEaySEGuopqZYv6pyA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0W0osYAAAAACf/pNEu/dHSZBPDllN8RUMWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "414ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e", - "displayName": "My reservation", - "createdAt": "2021-02-16T22:42:32.3454039\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:36 GMT", - "traceparent": "00-922fa56e2e64c54bace4d9b56fc6cd88-f1f8743cdc11474c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "64ea62f6fe7a10842be6f3530a48fea9", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:36 GMT", - "MS-CV": "3pcAI4NLgkqt2rwKI86XOw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0XEosYAAAAAB7lo4qjSZ4RJeFfLw1i6iLWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "411ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e", - "displayName": "My reservation", - "createdAt": "2021-02-16T22:42:32.3454039\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:38 GMT", - "traceparent": "00-1afcb99864bdcc41b183c9ae69793e98-c72fbdbbee9b8c42-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5a689255ddcaa2b3f460e4ef9f774f70", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:37 GMT", - "MS-CV": "baJZ\u002BpHoLESE46jhVJSx/w.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0XkosYAAAAAAPd/SoUHBuRqd6gLT52FIRWVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "421ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e", - "displayName": "My reservation", - "createdAt": "2021-02-16T22:42:32.3454039\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 16 Feb 2021 22:42:39 GMT", - "traceparent": "00-dd50d283adb31947911eb4b2c511c364-862b6d456c0d5d43-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210216.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "b1907eb45f84b2d7f3db8e7eb2954656", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 16 Feb 2021 22:42:39 GMT", - "MS-CV": "JPnmIGzyBUCfokn2RXjxYg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0X0osYAAAAAAEwCLsPMOOSJM9nbVZrEt0WVZSMzBFREdFMDMxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "467ms" - }, - "ResponseBody": { - "searchId": "7364009a-32c1-4341-907c-e17965f0a93e", - "displayName": "My reservation", - "createdAt": "2021-02-16T22:42:32.3454039\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "855", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:27:05.0366077\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/7364009a-32c1-4341-907c-e17965f0a93e/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:11:05 GMT", - "traceparent": "00-e0b15ecc13cbfa4e84e7e438c871b227-d1ba518ac4f06f41-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "199d9c4feb171905af487019199471b3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:11:06 GMT", - "MS-CV": "bpQ8ln3j40OgB84YeHaYVg.0", - "X-Azure-Ref": "0yjTUXwAAAABVCHfUeFS9TqL/WhLdYqQuRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1193ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "2053017020" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%)Async.json deleted file mode 100644 index 46afdd0fd8bc2..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(%en-US%)Async.json +++ /dev/null @@ -1,987 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:18 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "3daaf8d84376b37abfdec1d89857d9d3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:20 GMT", - "MS-CV": "aznVgyMKC0GtvA5rmwMwLA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0izXUXwAAAAD/31bg6Jo8QYeuePuxVcMNRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "752ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:19 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "292911b7b4b2798f789ad81617e4607f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:20 GMT", - "MS-CV": "pPvBCmQhhE6BLX8lOLb/\u002Bg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0jDXUXwAAAABh2mZxk1zTTaRXM3dhLlk4RVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "399ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:14:20 GMT", - "traceparent": "00-98615001605e1a49936b556dd0db73c5-09e4ec52ace25948-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "c464601850b89a2f06d91538823d2805", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:22 GMT", - "MS-CV": "r3gEQS5g4EywhzyDVXySfg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0jTXUXwAAAADgygE2jQWDT7TQBC138rfIRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1716ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:22 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "855dd6a1f54c24bd6830c4db6b639bdb", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:23 GMT", - "MS-CV": "bpCTCxfVLUW8S3uetPEupA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0jzXUXwAAAACQUha5j5hxQ5NoaME7I11hRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "445ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:24 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "37bf427d14f2661ae28f22d89e57f73b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:25 GMT", - "MS-CV": "rCiW06W5MEqhvgWecksznA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0kTXUXwAAAABT1FLPRBVIR4mle2kGldIDRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "450ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:26 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "4175d371db862332a3405c878c532ea2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:26 GMT", - "MS-CV": "YrUGvaxuIECLuN9hFPp2oQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0kjXUXwAAAAAspCZz8HgmQaMXQABtuuaTRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "446ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:27 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "40ba3a3ef17d8c13bbf6a2bcd2e48511", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:28 GMT", - "MS-CV": "/Et5idh5Q0eBkEezFgTCkA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0lDXUXwAAAABnPVNTIRKNQ44Oo\u002B9NTTbgRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "442ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:29 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9869893959eea2540f9c94b1b893da8e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:30 GMT", - "MS-CV": "XaLS/9gOXUqYDKMobzQnsg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ljXUXwAAAABIv85\u002BkP5NSY5J3QlR/B8gRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "447ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:31 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "649a7f60b69c80bdbfe98590387650be", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:31 GMT", - "MS-CV": "MPeLBDSdbUKUc\u002B1RXqvGmw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0lzXUXwAAAAA4LTq8fL0vTJ6FIWpjP6usRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "445ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:32 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "034d4aba96e9e4b4e51831e15c61d328", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:33 GMT", - "MS-CV": "gqkGjrEn40\u002Bu/ZqR8nxkuw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0mTXUXwAAAAC/kqJfTuOJT7FgE7XZfD0ZRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "437ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:34 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "535b141b214a8375cbe9d805d4c46998", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:34 GMT", - "MS-CV": "N5oea6E9bkGiHqFfvbujkQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0mjXUXwAAAACS00/OyfutTav4grH9GLgzRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "454ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:35 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "6ef7d54bd745c9a4cbb57e8384db235e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:36 GMT", - "MS-CV": "/RBlsfeJ9kKeC4Hfe4zo7g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0nDXUXwAAAAAhhimxLKbHTrN2FlAcD9uXRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "438ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:37 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "24745d15fd1a9874d5ca3700beaf1021", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:38 GMT", - "MS-CV": "L6XBZRYdCkGiJny/c8dm5Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0njXUXwAAAABPyuZQ53tBSrbeIJEIBjrqRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "441ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:38 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "879598ae656a43e26f918795a3f1fef0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:39 GMT", - "MS-CV": "iMK2RUkvu0Obm\u002BHgm/CPmg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0nzXUXwAAAADS4bsIDZPASKhHfV5v1wnTRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "441ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:40 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "77ef79c5454f4e7e605e997ba0a30b1c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:41 GMT", - "MS-CV": "g\u002BdwpqwjsEaacjUiDB6v6Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0oTXUXwAAAACD1SRZIgS1R4z9tTMz3eNHRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "442ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:42 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ecd45da49c45aff37a30b48975dff5e3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:42 GMT", - "MS-CV": "UtE0kcTNAkSNneT9rNSEog.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ojXUXwAAAADTTKQ2pik3QrZOZzftFgVwRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "448ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:43 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "443b46cb99bf69d11a46260ccc66a3cc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:44 GMT", - "MS-CV": "P\u002BZLR/uZU0q1D54DL42gCA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0pDXUXwAAAAA4wTw0dX3LQ4TeX6p0ThE3RVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "436ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:45 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "45f06b86111d28aa8540fc1e91f5d980", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:45 GMT", - "MS-CV": "Z7cpvQpNj0KKRMk/fIWL9g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0pjXUXwAAAAB7G0OwAENQRbiPoX4/Mjy0RVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "437ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:46 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "59afb668c6670a5d8c6bd2ff75e7e313", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:47 GMT", - "MS-CV": "qDdsKgJc1E\u002BWiLC7xMeayw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0pzXUXwAAAACN0yOYmu/2Q7Js2jbUIz02RVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "452ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:48 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "0902e88dafefbac59c13be7f9db2d824", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:49 GMT", - "MS-CV": "UQuxgUi2UkqFDRaK1xKBIA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0qTXUXwAAAADWmNqLUYsfR4XhimBSFZGNRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "839ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:50 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "16a3a66d49b7c0640ee5b9b13fabb39e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:51 GMT", - "MS-CV": "mdKhN5PTNkySzIWOBuO5xg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0qzXUXwAAAABdItW2ggnnRKG2\u002BfHr1Ya\u002BRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "453ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:52 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "a891e85ccff2b891f0f5bc5407de6dd9", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:14:52 GMT", - "MS-CV": "2qe3c6qHj0KQMBeuDGI30g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0rDXUXwAAAADdcMET0U9RQr8YUFg3CN96RVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "456ms" - }, - "ResponseBody": { - "searchId": "8fbf4e9e-e50c-4665-b8ec-fd88680b76dc", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:14:22.1837605\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:30:52.5603942\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/8fbf4e9e-e50c-4665-b8ec-fd88680b76dc/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:14:52 GMT", - "traceparent": "00-ae3ba58d05bca64ca1ccf59ba92fe6b7-103da342535c0945-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "cf91ad93cd43435c8442fb09f6147af1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:14:54 GMT", - "MS-CV": "jBd/qJzOIkurTD80ivhwsA.0", - "X-Azure-Ref": "0rTXUXwAAAACXydxPRpq1RZaePM6r\u002BP1jRVdSMzBFREdFMDYyMQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "926ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1100497228" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null).json deleted file mode 100644 index 3a06270ea80ac..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null).json +++ /dev/null @@ -1,455 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:45 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "c23cdf6029e01bd835a0a990544a8cb5", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:45 GMT", - "MS-CV": "UTbiTOeRi0iwBx7x9i3tYA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0tjTUXwAAAAC1tCyzLieVQZxlF7yz8rS8RVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "384ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:45 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "6676226a63a72c10f9221775f3a9d26c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:46 GMT", - "MS-CV": "8dsZKSKZ20qrAfMcP0Gnyg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0tjTUXwAAAAA47AXzOzgqTZCYvkM/DWT/RVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "395ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:10:46 GMT", - "traceparent": "00-5b6bb007ea71c347b6437f08ecd6ace3-55d8467c4fedf645-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "45715026c4f02597c5acfd5c50683346", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:47 GMT", - "MS-CV": "z7aJquGqIEiEk42nG8yybw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0tzTUXwAAAAA0D2uRCM7JT6fog3kL9rEHRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1043ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:47 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "98ac18e52b77fdf5ce0fc8be1262288c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:48 GMT", - "MS-CV": "VqimzBrhS0aRFKWHPEqz7g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0uDTUXwAAAAAtvUzhXkZlQbjRT5fWf4\u002BmRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "439ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:47.66292\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:49 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "03693ccd46d8a5c58b50a0fb65b4db90", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:49 GMT", - "MS-CV": "h4hJBOd6ZUOQyuoXd\u002BE8NQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ujTUXwAAAAAB4r/hisvGQI17ZW7qkiCjRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "435ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:47.66292\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:50 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "da90d0ef3afcfbf55b7376e0fbd81362", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:51 GMT", - "MS-CV": "mGOvr56dUECcGjHZ8LcPjQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0uzTUXwAAAAByCZaiOSP3RrZoO83Durf6RVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "450ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:47.66292\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:52 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "148e71832fff9e6d53060d278af9981a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:52 GMT", - "MS-CV": "CIqEinecGEinE3Lbsp6bJA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0vTTUXwAAAAAvNLbyQG/xRorCifN\u002B0pl1RVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "440ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:47.66292\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:54 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "41cf38344dd2938f466ea864d0e4aab2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:54 GMT", - "MS-CV": "w62IgbGKGUGVlr9mIXQV6g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0vzTUXwAAAABC83Vry8UMT7sTZg/GV3g7RVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "440ms" - }, - "ResponseBody": { - "searchId": "d905ffc3-3216-49c4-bae8-33c1364c49a0", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:47.66292\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:26:54.1693232\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/d905ffc3-3216-49c4-bae8-33c1364c49a0/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:54 GMT", - "traceparent": "00-bf33d7ba701df44097eddef975e344bb-66ef395e34e66a4a-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "f4773e3cc725bf9062f187f52dce7061", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:10:55 GMT", - "MS-CV": "YpyxsT/GKU2gjz0EYXiu3A.0", - "X-Azure-Ref": "0vzTUXwAAAAAaO4R7hIWMR5ANc4PYxZcURVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "939ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1209562406" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null)Async.json deleted file mode 100644 index 9ca06fce899a3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservation(null)Async.json +++ /dev/null @@ -1,455 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:13 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "7ce7f6aa6608ab1c26bf09ed608afed3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:14 GMT", - "MS-CV": "DpG3sBAAD0WPpIttIVdGTQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06jrUXwAAAAA8GpKaTXeJTppWDmZp16cMRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "729ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:14 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "13f8df2ecd03b6e3e3841da98e053448", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:15 GMT", - "MS-CV": "l4kU3/Eg2UqX1PoZeMc4KQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06zrUXwAAAADS3Z4XBbgrR5pXjURDfU9\u002BRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "414ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:37:15 GMT", - "traceparent": "00-a814ae46b189de4d9776c6c17dbf4dcd-db6defe135f7d641-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ce39aba6c5b17e7962860ade01df401e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:17 GMT", - "MS-CV": "4uKGw/4\u002BpEqsc/S4/eD3Cg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07DrUXwAAAABA66xm6cNtSI1vuxbW6dxBRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1675ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:17 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "64def57c3520dc5e1331998448721d20", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:17 GMT", - "MS-CV": "t\u002B1aO35y2UOgxcsEHfVjng.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07jrUXwAAAAA6WjHMseIuRLttFSlAtg3pRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "457ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:37:16.9004686\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:18 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "b547c08b2f5168226579b17cc304b504", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:19 GMT", - "MS-CV": "bwIP5gSvZU2I5hINv\u002B\u002B/9Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07zrUXwAAAADllaGfhCQKQrfbe17WaSVDRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "491ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:37:16.9004686\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:20 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "982dff43cf2771284d5cba7f2cf536ef", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:21 GMT", - "MS-CV": "W3izpXV2bUG4kS9eydUtTg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "08TrUXwAAAADG96N3ZQdSR7xZ2voBEaIxRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "959ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:37:16.9004686\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:22 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "4052ea688b984ccdd375fea684e1190e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:23 GMT", - "MS-CV": "ThmW63OuWk2rqyfIKonIcw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "08zrUXwAAAADIVhkq6sr6SoehSRqJ5lfORVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "459ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:37:16.9004686\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:24 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "4940947c8545bcf998d568f475a23c70", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:37:24 GMT", - "MS-CV": "5x0b\u002B0za8k\u002BpvP7rPC5Ybw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09TrUXwAAAACaFYx2xvnhR6W0CFLrFfxTRVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "459ms" - }, - "ResponseBody": { - "searchId": "9f13cce2-5e87-4b94-b732-499887ef9b66", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:37:16.9004686\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:53:24.637773\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/9f13cce2-5e87-4b94-b732-499887ef9b66/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:37:25 GMT", - "traceparent": "00-cd9a0fbc7ed54441bf8c7feb3956771b-9419ccd04026a149-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "d813c14374b1b86b31e0c4b1d081ec6b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:37:25 GMT", - "MS-CV": "Ia9Op1V5G0yh5cg4Exn6qA.0", - "X-Azure-Ref": "09TrUXwAAAABWJVTRH0noRYIoHNJ3deH/RVdSMzBFREdFMDUwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "941ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "301917519" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%).json deleted file mode 100644 index 549d4628683c3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%).json +++ /dev/null @@ -1,519 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:51 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ac7d70458b44ae80da7aedf954f62f28", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:52 GMT", - "MS-CV": "7Jw5La8blkyu/xLKWZPUSQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TDvUXwAAAACVubR2ZlyLT4Sxm5ptxu0cRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "383ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:52 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ce66f23efc2178eb93f08c830cb9fb80", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:52 GMT", - "MS-CV": "oSaZ6EhwUEClOBwQ2QPF0A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TTvUXwAAAABbrMBkxmaMR6k0beNInt2ARVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "374ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:52 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "a8de667048b0bfe2d486be8390f2e279", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:53 GMT", - "MS-CV": "hvGRhj/B/0K7tmnG0xqvFQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TTvUXwAAAAAIAoIWFPtkQ4RxI0MH4khFRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "386ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:38:53 GMT", - "traceparent": "00-495212f0d6e1ad4cad9b603d8f29bb42-94470239e8339841-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9b7b70fb2ed2486285051854fefca220", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:54 GMT", - "MS-CV": "Xj2AGpDQUEGnQ44pyASEuw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TjvUXwAAAADhMqUtWv7PSIgedW443w9\u002BRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1040ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:54 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ee896d7f8617f5780fa6f99a3d67e7a1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:55 GMT", - "MS-CV": "WjYVfvfcCUepCPIH\u002B\u002BqbAA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TzvUXwAAAAD4CKQMWYDvS45tIIhbQj0zRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "468ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:56 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9b88130d5f3e41ad039523aa308ec1d8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:56 GMT", - "MS-CV": "pNrNZOKI\u002Bk6\u002BS9Zj3U4j1A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0UTvUXwAAAACRnMqIJcnsRZHAEACU6GuwRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "432ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:58 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "22049de3f4687461f8858c2b34c80b1e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:58 GMT", - "MS-CV": "kqkkdzrAiU6Ppq22FX6e0w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0UjvUXwAAAADcz\u002BkKrgj2R7Od/wq7mgMjRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "436ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:59 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "ea46761d07741fe2c047ea8163cdc580", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:39:00 GMT", - "MS-CV": "nVEiWFDkKkac6Uyxd8pumA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VDvUXwAAAAAKQS3TtvXJSpwunLrpZT7NRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "452ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:39:01 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9fb621e5c5631939b113a3b8d3810c3b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:39:01 GMT", - "MS-CV": "24Px01tsj023mcr6z/dwiA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VjvUXwAAAAAYCEGu/0DeT7Rw9/GoD/QiRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "429ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/16b72c8b-26a3-489c-9621-02e093977cf8?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:39:02 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "b98c058ad648dc63bae5622009df112a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:39:03 GMT", - "MS-CV": "KQhNn7sUx0OKMVP91B6x0Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VzvUXwAAAAB\u002B8L5m6JeHS7FgAKHn9rI0RVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "529ms" - }, - "ResponseBody": { - "searchId": "16b72c8b-26a3-489c-9621-02e093977cf8", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:54.6342648\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Error", - "phoneNumbers": [], - "errorCode": 1000, - "error": "OutOfStock" - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "631123094" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%)Async.json deleted file mode 100644 index 7573f608e8e67..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(%en-US%)Async.json +++ /dev/null @@ -1,519 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:23 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "87deaf6c861fb6141b3d7636a89ee73b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:24 GMT", - "MS-CV": "V4G6GIKpv0maIKPa9m/dTQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0LzvUXwAAAAA12RoKkWjqR4T\u002BE8k8WZg3RVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "409ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:23 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "c83d961ee12cb941a7641b10c064970a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:24 GMT", - "MS-CV": "J2injjjQ702gg0flPDawGQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0MDvUXwAAAAAy4Gu6znziRZR25GYDzMWfRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "400ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:24 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "8e5b98d1d04514c49602677701a1bc16", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:25 GMT", - "MS-CV": "R/iCP9CyAU6WH5k\u002Bmv6Q6w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0MTvUXwAAAACWsKR9pYOnTY/rYZS0qDR4RVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "393ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:38:24 GMT", - "traceparent": "00-a92ba33a1677b84fac0afb878879b6aa-258b5407d9a0f74f-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "4b4f99aa9be58b726d24e0ba6b03f5b6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:26 GMT", - "MS-CV": "Z7VPlvmBAEaax6XoBVEk2A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0MTvUXwAAAAAFaywphpbpQpS6J1m494TLRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1049ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:26 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "10646ca559434df6d128322a79cab705", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:27 GMT", - "MS-CV": "7yzlI9XhaE2Yc4R99FZhhg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0MjvUXwAAAADQc0hj26r/RJBPPYYumijlRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "442ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:27 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "276504a84b15362425d02021f009a992", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:28 GMT", - "MS-CV": "xGrZ6pBNdUCMgbcShm72dw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0NDvUXwAAAAAet\u002B9\u002B0QdcQ41MhuUsxzrMRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "440ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:29 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "95d1b10cab3c51d2a30179bd684711a3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:30 GMT", - "MS-CV": "bTyXccadC0aVBCCeWx\u002B1dA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0NjvUXwAAAAAXfeh2bFkPRKdr\u002BNXJhrv1RVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "437ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:30 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "6612da6ccd9e59a0482eea7338d45dc7", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:31 GMT", - "MS-CV": "JEoQaLWDVkqzP7LqTlhXaQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0NzvUXwAAAADxA6IYeddGRKemwMFsyzozRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "439ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:32 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "c81ea07f22f8fcc931138414d166cddd", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:33 GMT", - "MS-CV": "aN1gxYYg/kyqV5Hr3Vh2JA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0OTvUXwAAAACMvtPJnxkdRb9Df8Z6g3CRRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "438ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/6931e1e7-5406-4a07-b07d-e3619fb9e653?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:33 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "15b57dbe42f73ef410774c0dc15f19ce", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:34 GMT", - "MS-CV": "waYNlam7RE22hYSn89jkkg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0OjvUXwAAAAC6rc06YahBQpCkgpVYnW7hRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "439ms" - }, - "ResponseBody": { - "searchId": "6931e1e7-5406-4a07-b07d-e3619fb9e653", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:25.9769451\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Error", - "phoneNumbers": [], - "errorCode": 1000, - "error": "OutOfStock" - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "725671667" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null).json deleted file mode 100644 index c39f518072f1f..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null).json +++ /dev/null @@ -1,481 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:40 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "d8b440d0bd9b5496e40570d81deebd9f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:41 GMT", - "MS-CV": "Z0PaWFPN106cn25NGGXhQQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QTvUXwAAAACGgQg2CLKkRaxcLbnw9Rs6RVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "891ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:42 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "f935b67fd0e0b5409fe266d804e2203b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:42 GMT", - "MS-CV": "i8dm5EAXT0eshkbBFlZmJg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QjvUXwAAAAC\u002BgP9JUvOCQZ0/lOdsVRXlRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "389ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:42 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "fc29e4fc86722fd5b54901a76a27e9dc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:42 GMT", - "MS-CV": "6XhFKkgmdESpbPNCQA2QJw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QzvUXwAAAAAWm3O/OrJWRqn0nwRQu4/hRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "380ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:38:43 GMT", - "traceparent": "00-87312e6bd600b24787cb45b75549f6bb-8f575245cc2ce744-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "d56908b6ff48ff4d00fe39b957bd5002", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:44 GMT", - "MS-CV": "wV2ZcvpwXkufHG6OqAYxCQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QzvUXwAAAABGQhORuBpZRa\u002BXecJefWzYRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1327ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/f7679ca0-3b67-473a-bc14-c6c5eeb60eaa?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:44 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "38db34e4c1c4f92ce1064396ce994b78", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:45 GMT", - "MS-CV": "3iL9M3nZLk60sMMoDHqPVQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RTvUXwAAAADX4iAh/0QzR650RlsZOWuSRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "447ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:44.2955936\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/f7679ca0-3b67-473a-bc14-c6c5eeb60eaa?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:46 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "fb2289f94a78fcf3972afb744c1cd7f8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:46 GMT", - "MS-CV": "oLeaRodphUCdmf0Rvl9UFw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RzvUXwAAAAAr72kNocwvQJ/4CGv9CoTIRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "446ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:44.2955936\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/f7679ca0-3b67-473a-bc14-c6c5eeb60eaa?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:47 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "35c2fff9b04bf417db6ff441bcb63166", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:48 GMT", - "MS-CV": "tbZthvL0vkuXc2v7Pdhfhg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SDvUXwAAAAASnSVkMKj3RboLyEAx39ePRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "448ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:44.2955936\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/f7679ca0-3b67-473a-bc14-c6c5eeb60eaa?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:49 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "cdbfc1b3549b998a41dea09ac5b8acc4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:49 GMT", - "MS-CV": "QpEmEMu/wUur/5YemlCOxw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SjvUXwAAAAB714bFQgTpSZ3UXEfED9U8RVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "433ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:44.2955936\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/f7679ca0-3b67-473a-bc14-c6c5eeb60eaa?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:50 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "cf9d4b2e15d6492c722d200856b140e1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:51 GMT", - "MS-CV": "n1gm3k8jyU2VbPEErxmI/Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SzvUXwAAAACLrW1iZs2XRqGHJIn3KsroRVdSMzBFREdFMDUwOAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "432ms" - }, - "ResponseBody": { - "searchId": "f7679ca0-3b67-473a-bc14-c6c5eeb60eaa", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:44.2955936\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Error", - "phoneNumbers": [], - "errorCode": 1000, - "error": "OutOfStock" - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1253681144" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null)Async.json deleted file mode 100644 index 3df501ba74b63..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/CreateReservationErrorState(null)Async.json +++ /dev/null @@ -1,481 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:11 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9e93c3d8a5cbfbf3fee52ae69b7fc4f5", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:13 GMT", - "MS-CV": "/dIJFvgo4keH4YzFurZFYQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JTvUXwAAAAAhC8p8OmByRqUa\u002B\u002Bn8M\u002BkARVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "570ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:13 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "6e4215e47f4056a68f10c9947ef77cc9", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:14 GMT", - "MS-CV": "4I7I2YOoy06tvgreTV3OXQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JjvUXwAAAACS5vAxnY\u002BHSpauHJ9S8NoLRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "390ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:14 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "936e264cbd31c33e96de98a05ce9b667", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:15 GMT", - "MS-CV": "Za8TMY1xqEqNPaZK9Od/Kg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JjvUXwAAAACNUnUvt\u002BrKR5i0TY9mDd6GRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "397ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:38:14 GMT", - "traceparent": "00-23bd999941894b479b674ad7bcd55cb9-de0c877525121f45-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "95ac8732b90759d01d3c0ebbdc5e7d06", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:16 GMT", - "MS-CV": "M1NzsgEMHk6z1mvtl5soQQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JzvUXwAAAACcv\u002BexBOeGQ4MxhO/VlC3rRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1032ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/b48d0718-2cd9-493a-a0ae-9e4ac7a44053?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:15 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "75996068311127c3d77ed761e605faa6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:17 GMT", - "MS-CV": "Ab4uXxRRBUWaD4vkJrv8ew.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KDvUXwAAAADl6w0qVV2HQ5HOr60\u002BQYK\u002BRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "458ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:15.9428493\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/b48d0718-2cd9-493a-a0ae-9e4ac7a44053?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:17 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "f661625ae64a93c2551475f5ae82e737", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:18 GMT", - "MS-CV": "M3YRD8QYGkGOJGenew29fQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KjvUXwAAAAAa2TWwrigBSJkyYk/EWaT5RVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "443ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:15.9428493\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/b48d0718-2cd9-493a-a0ae-9e4ac7a44053?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:19 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "fb379261414f0156c385be88e16e7318", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:20 GMT", - "MS-CV": "pVKx7ZmMJU2\u002BNUXZ9ovAnw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KzvUXwAAAACarQSr54aPQJ5KVrNE5JEhRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "447ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:15.9428493\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/b48d0718-2cd9-493a-a0ae-9e4ac7a44053?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:20 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "7961684286fc82bb9e061ffcbbce7854", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:21 GMT", - "MS-CV": "4W/fpJHdQEi3NLnXprvd/g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0LTvUXwAAAAA8S21uSdTZTqdWheWxQY7ZRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "440ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:15.9428493\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/b48d0718-2cd9-493a-a0ae-9e4ac7a44053?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:38:22 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "53ff9f97fecd19560c6033c52839b1e6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:38:23 GMT", - "MS-CV": "zky3r9kIhkWmhqpH0S7qJA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0LzvUXwAAAACsxLNm8QywS6vUuaWmtVTLRVdSMzBFREdFMDUxNwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "440ms" - }, - "ResponseBody": { - "searchId": "b48d0718-2cd9-493a-a0ae-9e4ac7a44053", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:38:15.9428493\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Error", - "phoneNumbers": [], - "errorCode": 1000, - "error": "OutOfStock" - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1268666862" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredential.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredential.json deleted file mode 100644 index 5b860f016034c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredential.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "traceparent": "00-218f801f1972304c8927262c61fdd334-d6911592b879fc4c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "841f3e63311dfb21c2a1c21d543716ee", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:14 GMT", - "MS-CV": "oAXnqkigJ0OOIJhRYe8YGQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Fx0vYAAAAADeygqv6YShT6ndR1uKmJdQWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "346ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "632430763" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredentialAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredentialAsync.json deleted file mode 100644 index edb3a3a47041e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GeneratesPhoneNumberClientUsingTokenCredentialAsync.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "traceparent": "00-8cd122dc8d90d247b0158bbb83122c39-83591317d41adf4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "3384cfd1217bd3aaff7b15e7825eca0f", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:50 GMT", - "MS-CV": "50XgCnN1EkSACw6YkfsInQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Oh0vYAAAAABS7T2fTrV4TaKKiLHhJBXdWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "557ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1794087222" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbers.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbers.json deleted file mode 100644 index 31d2a200f183d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbers.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:26 GMT", - "traceparent": "00-1e62c2505847d94ba9db8fc5af1a808d-af00da24ed68274b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "754ae8679bb8b814455328db7a3b2294", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:25 GMT", - "MS-CV": "gUu7Umx1qE6TBMvIXxOCMw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0IR0vYAAAAAD8yPdKQNacT5q/FTBLvEN2WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "345ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1736725081" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbersAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbersAsync.json deleted file mode 100644 index 2518a550c4feb..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllPhoneNumbersAsync.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:07:03 GMT", - "traceparent": "00-c4ed3c913983734f81f2bdc331688f62-1043bf0a83f65d4f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d1a7fb1f13bb8f936be0e578cf161573", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:07:02 GMT", - "MS-CV": "s7FK05FBlkm\u002B2VAeME4rSQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Rh0vYAAAAAD4PTU0Gmi5SqjQvNuRK3BUWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "350ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1419959097" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservations.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservations.json deleted file mode 100644 index 514656a4a6783..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservations.json +++ /dev/null @@ -1,509 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:33 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "efda758c9b9b98f310099ae7bff2634c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:35 GMT", - "MS-CV": "vyJXMVU0e065tgOS4W9Q/g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0qzTUXwAAAABo5u1h4bFlTYt5nsARuzlBRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "556ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:35 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "a8ffd6f6d3f4c025622dae1920803bd1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:36 GMT", - "MS-CV": "37doHziCtk6Grv3AGXsZYg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0rDTUXwAAAABTon4rVeY8QpGgktADT4KjRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "404ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:10:36 GMT", - "traceparent": "00-c0b0479cf1651843afc70e39e035d5db-f61177dc26f1fd4a-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "2082b735011dea2aebb83611590bc969", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:37 GMT", - "MS-CV": "lzvyd4XAA02\u002BySQtIX01cQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0rDTUXwAAAADLQp7pkzrbSr1nNZjsFUzRRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1081ms" - }, - "ResponseBody": { - "searchId": "1fcf9387-f51d-40da-b411-7fa30c39c7d1" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/1fcf9387-f51d-40da-b411-7fa30c39c7d1?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:37 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "84fae31da0a3b9264f198c6eedd97790", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:37 GMT", - "MS-CV": "hBMAL4nYuEKtonvNqxOuFQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0rjTUXwAAAAD/Rd8aH\u002Bx1SrGHNHS9bYUORVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "442ms" - }, - "ResponseBody": { - "searchId": "1fcf9387-f51d-40da-b411-7fa30c39c7d1", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:37.4069571\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/1fcf9387-f51d-40da-b411-7fa30c39c7d1?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:39 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "08b2c9ce4270f52eab15bc3c9c136656", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:39 GMT", - "MS-CV": "dKgcGajCNUSeEoe5HHz02g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0rzTUXwAAAACKXDoeqTrNQ5GMmMKKJJmNRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "441ms" - }, - "ResponseBody": { - "searchId": "1fcf9387-f51d-40da-b411-7fa30c39c7d1", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:37.4069571\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/1fcf9387-f51d-40da-b411-7fa30c39c7d1?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:40 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "3cfb4563b685952e90c8d10474bcfd12", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:41 GMT", - "MS-CV": "F6R4CfW\u002Bx0uxWUbOhkbJNQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0sTTUXwAAAAA7spd6kKimR5VQ7h0DrRhsRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "530ms" - }, - "ResponseBody": { - "searchId": "1fcf9387-f51d-40da-b411-7fa30c39c7d1", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:37.4069571\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/1fcf9387-f51d-40da-b411-7fa30c39c7d1?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:42 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9043a640c159daf8b405d88de3e91c3c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:43 GMT", - "MS-CV": "mUYayWciKEuA4ZsybCAVCg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0szTUXwAAAAAAz\u002BDx0Hl0QrvHKnAWebUqRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "584ms" - }, - "ResponseBody": { - "searchId": "1fcf9387-f51d-40da-b411-7fa30c39c7d1", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:10:37.4069571\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:26:43.2212749\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:43 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "a70a35b23bde180a9a1d77a7712a80ef", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:10:43 GMT", - "MS-CV": "lvEipjA5hEu4UnN1\u002Bwqo4A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0tDTUXwAAAAAu9myBDmEhTJq2kBjQwaMCRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "457ms" - }, - "ResponseBody": { - "entities": [ - { - "id": "Sanitized", - "createdAt": "2020-12-12T03:10:37.4069571\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Reserved" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-12T03:09:42.5771765\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Cancelled" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-12T03:09:27.6141198\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Cancelled" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Cancelled" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:36:40.8183049\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 0, - "status": "Error" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:31:43.599535\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 0, - "status": "Error" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:31:21.6796721\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Expired" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-09T18:34:57.5717971\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Expired" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/1fcf9387-f51d-40da-b411-7fa30c39c7d1/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:10:44 GMT", - "traceparent": "00-f36594c90f5156408622955818254166-4a7ae6250cf7724e-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "f6fcaa18d6d0a2fd4c208780dea0b1a6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:10:44 GMT", - "MS-CV": "jR1f4zEUI0mZWqkllf0h/w.0", - "X-Azure-Ref": "0tDTUXwAAAABqVgO0HHziQaB8bykJPUgjRVdSMzBFREdFMDYwNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1020ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1140872635" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservationsAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservationsAsync.json deleted file mode 100644 index eed723030d619..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllReservationsAsync.json +++ /dev/null @@ -1,523 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:46 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "bd4cfca3df36d1e6327be1471a6ffb27", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:48 GMT", - "MS-CV": "DCgjYXWO6km1UXy4C9daUg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QDTUXwAAAAARpo/Xva78Qormag6GYURpRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "687ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:48 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "0a655044447ac3ffbace3ec9b3a21081", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:49 GMT", - "MS-CV": "R6zY2vU77UKpNKtE1ke4qA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QTTUXwAAAAAoOarvQyYERpaUoJLx3iV9RVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "563ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "122", - "Content-Type": "application/json", - "Date": "Sat, 12 Dec 2020 03:08:49 GMT", - "traceparent": "00-701b9ae961132144bed0942555c64f23-4eac0b79f8207443-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "d0db98e5a0f5585a3cc19b71857afda8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:50 GMT", - "MS-CV": "lonAPSmfyE2dS1R6xQ\u002Bjbw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QTTUXwAAAACmYM8hKz4nR7\u002B5NNZ/OKYJRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1478ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:50 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "a3a8fc45dfd05fa1fc880267a11d1d8f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:51 GMT", - "MS-CV": "wMgnlPqqsE\u002ByRcikupqVQA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QzTUXwAAAABkfMArRWH/RJKpjXICZ/gaRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "433ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:52 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "8161606b2b94a331f50cceb9a88e3e3f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:53 GMT", - "MS-CV": "fbq7LhkXmE21zXr9hAKNBw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RTTUXwAAAACRHMhYLnwwRZS4Mx2IJZgiRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "448ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:54 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "b68495d16cfa05b0f77bd36d9df3b71f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:54 GMT", - "MS-CV": "QwbA04BeUE2yHRf\u002BnrbOaQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RjTUXwAAAAAJqdhnLIN4T7XWN0AE7XCORVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "435ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:55 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "25060ba37b181a14cb04adc311e8b66e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:56 GMT", - "MS-CV": "Bfxo5i181Eq7GYNN8HCrqA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SDTUXwAAAADdk4AKwCCVRLNvI\u002Bk/rilLRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "434ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:57 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "0c96c34a6698fe95af5b8a1857c40602", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:58 GMT", - "MS-CV": "5Ar0ES0OWUqxxAlFGkDLig.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SjTUXwAAAAAJdPFV4DFKQ4RbLx4VxKA9RVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "437ms" - }, - "ResponseBody": { - "searchId": "85511ef0-c05e-4231-9214-77f02cec7717", - "displayName": "My reservation", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "description": "my description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-12T03:24:57.7031389\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:58 GMT", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "9d15ae5519875527816aebf6bfedf40e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Sat, 12 Dec 2020 03:08:58 GMT", - "MS-CV": "9PZ0i6omz0KKeFia\u002B4ojIw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SjTUXwAAAAD5pZzQ9jwYQK9t7ul7ka6gRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "468ms" - }, - "ResponseBody": { - "entities": [ - { - "id": "Sanitized", - "createdAt": "2020-12-12T03:08:50.3002722\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Reserved" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:36:40.8183049\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 0, - "status": "Error" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:31:43.599535\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 0, - "status": "Error" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-10T18:31:21.6796721\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Expired" - }, - { - "id": "Sanitized", - "createdAt": "2020-12-09T18:34:57.5717971\u002B00:00", - "displayName": "My reservation", - "quantity": 1, - "quantityObtained": 1, - "status": "Expired" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/85511ef0-c05e-4231-9214-77f02cec7717/cancel?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Sat, 12 Dec 2020 03:08:58 GMT", - "traceparent": "00-991af3580f27ae4bb80cb573e6bbdea8-df77e68932e66049-00", - "User-Agent": "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1 (.NET Framework 4.8.4250.0; Microsoft Windows 10.0.19042 )", - "x-ms-client-request-id": "da2265c4ab5d3c86760876bdf1fbc207", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Sat, 12 Dec 2020 03:08:59 GMT", - "MS-CV": "DaUQaWyiZkqPsOwlurXWpw.0", - "X-Azure-Ref": "0SzTUXwAAAABxcECAvcsnRZCxvWZ\u002BXJUkRVdSMzBFREdFMDYxNAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "977ms" - }, - "ResponseBody": [] - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "486063139" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountries.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountries.json deleted file mode 100644 index a4342ffccfb74..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountries.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:16 GMT", - "traceparent": "00-640c6a32febbd744a09e9f3bf30e1d2c-1e17e60d53fe684d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "68b4fb6609e23b39665a310a6202e2aa", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:16 GMT", - "MS-CV": "bYOKqLsmyU6tODAoWo\u002B8OQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Fx0vYAAAAADDnfbxsWVpQYeCXSJBaazLWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1560ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1074755107" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesAsync.json deleted file mode 100644 index 53f441e077732..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesAsync.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:51 GMT", - "traceparent": "00-78d5d7494598b447990c9e5e55badce3-cc498334a4c73246-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5cdab42778cdd864c0eb7ad9b720026f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:52 GMT", - "MS-CV": "lNMfU70/XUWXMGEzMXz1rQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ox0vYAAAAACC\u002ByE5NdScSKjC25KpLQbBWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1695ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "508083956" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocale.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocale.json deleted file mode 100644 index 37c6cd81d63c4..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocale.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:18 GMT", - "traceparent": "00-33957e83fcdb91438596eb70f4d10356-2bc27ac652ed0146-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "1352de371f41de03d8dda3ff7c26b51e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:18 GMT", - "MS-CV": "15g6NNQPMUGTr\u002Bus8ZcFjQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0GR0vYAAAAAB/\u002BQwKx6rYTpmk3c6powV/WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1458ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1135784546" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocaleAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocaleAsync.json deleted file mode 100644 index cce179f62bd31..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAllSupportedCountriesEnUsLocaleAsync.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:53 GMT", - "traceparent": "00-6e7bad3c7a361d43ac54c7f876089d74-2247626f5d86b641-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "30a249b25a094000dc678e62d175ece1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:54 GMT", - "MS-CV": "LWsbAgNK5E6InbRPhPjYdA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0PB0vYAAAAACSYBu4ANo1TrUuORjEk2F8WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1563ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "815011431" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%).json deleted file mode 100644 index 90ef9a1929395..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%).json +++ /dev/null @@ -1,1716 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:21 GMT", - "traceparent": "00-612961546385ba4aafc7fb580300a2e0-c095b002c7dfc745-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "84755cc788cb85c3b2f2aaebd701d7e0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:19 GMT", - "MS-CV": "b9hanodfrEO0Zqw4JTp9DQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HB0vYAAAAAALXY\u002B9HBk7QLfU4aQhhorNWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "305ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:21 GMT", - "traceparent": "00-0f4cccb247390147a01e4af9b793acf0-765f04b406da0441-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "28a3056398fe9e37afde779cac21ab5f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:20 GMT", - "MS-CV": "St3NUV0cZUWe0bfLrHQSaA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HB0vYAAAAACxQAQOcW0XSq4LAM413Y0ZWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "291ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:21 GMT", - "traceparent": "00-2b29959175019c46b2745966ccb52c5c-4b69262f4bb37248-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "4f8c4709aeea20ba2a066836e0611f18", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:20 GMT", - "MS-CV": "2OuO9HI3AUGuzCzxZMP7Jw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HB0vYAAAAACgZ7UxNqSRSJoIpbbg7UwZWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "380ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "traceparent": "00-5e39157886271741b43be388a83cbd88-1f9a5c3e82b75348-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "17bf8b2268b62f7325d7d4ed1027d891", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "NY" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-NY-NY" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:20 GMT", - "MS-CV": "bdtR1lVUYEikxtsXriJtgw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HR0vYAAAAADfGXZVvmocSaIxAcXgDmOnWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "270ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "929", - "347" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "2034220363" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%)Async.json deleted file mode 100644 index 2cedd3e068771..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(%en-US%)Async.json +++ /dev/null @@ -1,1716 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:56 GMT", - "traceparent": "00-40ce2e81ab3265449ae90a0e99a90866-f4f2f521ae41cc4c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "b0831f93bb036bee0a0e792284605ab4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:55 GMT", - "MS-CV": "DbmsVcu4REaE3mEsOLH\u002BIQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QB0vYAAAAABjgAt1jGxrRZjw04IxuyW3WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "313ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:57 GMT", - "traceparent": "00-e479a64b02416541a64206d569dfc099-1a54c9310d7dc14f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "32050bf7a4a86116dd2cfe527b2aed00", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:56 GMT", - "MS-CV": "hTYd\u002BxKkIUKQcTuKFTr8lA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QB0vYAAAAABNjCa7dVB7TauLL\u002BOje34dWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "528ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:57 GMT", - "traceparent": "00-ddff3ede5fcfc14c9d28d7889c33eec9-d64c6da548a0744d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "58e7437d55f31114a220d6864c4b5387", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:56 GMT", - "MS-CV": "uCvuojJTmUuDN\u002Be7D/05jA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QR0vYAAAAABwlkTvhQFFRaNIh/ktKCNTWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "332ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:58 GMT", - "traceparent": "00-11e6bb5e07fc2840890645717b04de26-92ad0674afaa6f4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5cb29f8e4600efe40822d3d7bd9befdf", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "NY" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-NY-NY" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:57 GMT", - "MS-CV": "dgS8OKp0Mk2j1a\u002BAxB1GPQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QR0vYAAAAAC\u002BxCWj1om7SZmX3NXJOi3JWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "261ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "929", - "347" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "641757262" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null).json deleted file mode 100644 index 12468851a38b7..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null).json +++ /dev/null @@ -1,1716 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:19 GMT", - "traceparent": "00-06bfbb1cd8c10a4091a5e3999b7822cc-a5a979a303fa0841-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "40884fd956f2b49a3d4c2bc800fe9708", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:18 GMT", - "MS-CV": "w1etRvTd1EGLElanYLurXg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Gh0vYAAAAAA81Xdfm0ZXT6S7m4rBADJnWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "329ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:19 GMT", - "traceparent": "00-1271ddae115b324c9fe3cc67a95c9ab7-0c6f8f47e21aa740-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "9b3fefc3a51b6d9464bd67c53398142a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:18 GMT", - "MS-CV": "7pgB4N1qL0\u002B5yL76o4N7Og.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Gx0vYAAAAADxor328fOORoytbJFqRxEWWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "298ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:20 GMT", - "traceparent": "00-21cd167422b08545a04cbb15dc095a8a-c1f21d076c98fa4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "24eab2145e3289c19e780cca1a21b11e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:19 GMT", - "MS-CV": "xvYHub6UrU6xw1buJaFkkA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Gx0vYAAAAABZgIcstiRkRZWc1K7yATpHWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "300ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:20 GMT", - "traceparent": "00-6bcb195119079b4db5c12f519e035d51-6e1a2abf3138764b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "cd5d0fbf3e7b342cba1adb34eed480a4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "NY" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-NY-NY" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:19 GMT", - "MS-CV": "L4QDBOwnbkWJO6JQG6VlHA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Gx0vYAAAAAA0I\u002B18urhHTIcNO6xUXcB6WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "373ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "929", - "347" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1546943954" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null)Async.json deleted file mode 100644 index bb5d2dad697fd..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetAreaCodesForPlan(null)Async.json +++ /dev/null @@ -1,1716 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:55 GMT", - "traceparent": "00-b3a16d589026054ba22ae9f65fa61da3-13abf4c95cf51c4e-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "e87533b3abc4541214b18329c39d2211", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:54 GMT", - "MS-CV": "mxAwPwwX2UOdNTyP\u002BGCtPQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ph0vYAAAAABfgqjvoJh9T5q/BgLBXn0yWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "296ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:55 GMT", - "traceparent": "00-8be868a37ea832468e139abda4d0bef3-636deec57135c645-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6f4694ad5457c680e828eddec07946c0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:54 GMT", - "MS-CV": "5y/SDOvTH02fWR25nJpfmA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Ph0vYAAAAACidBdCqtXGTICFCDSVNbGpWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "306ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:56 GMT", - "traceparent": "00-4454b11aa546884696a7075daa2c8fb7-df3211af5044c949-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "5a0ce7cf48429ff598dcd6c889ee5358", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:55 GMT", - "MS-CV": "\u002BDxMsua12EGeTq\u002BfMqJN4w.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Px0vYAAAAAB7MavFQEyJSLC6ubI\u002BbLD0WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "501ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:06:56 GMT", - "traceparent": "00-da3581a54984364ca4aaf171e46303fa-5793824d24a6a24b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "486408555f805e2bb2af009bbe33939a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "NY" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-NY-NY" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:55 GMT", - "MS-CV": "icTRxMuUAEuvP53MdlTSag.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Px0vYAAAAABwiOzaM\u002BOVTrLE5ikv/wFKWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "285ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "929", - "347" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "2032726734" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%).json deleted file mode 100644 index 3fcd5ca9cfb1a..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%).json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:23 GMT", - "traceparent": "00-50ef618c115fe64d82ee8b5951a22eaf-07030722f6cec64a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "616510a462ba67ae5073127e5b88837c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "MS-CV": "TcRgtL/VZk2i4dZpaJVn5g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hh0vYAAAAABibzd\u002BWKwEQJijnOqvgrvxWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "301ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:23 GMT", - "traceparent": "00-0d102ce68f274f459c5c3c8af1d327ce-cbebda8ea51b7d4e-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "1641a4177d67de1a4c3dd693d419fa40", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "MS-CV": "y5eZx6vcw0OTXO0jXh2RnA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hh0vYAAAAADTsEso5tc7RpDsfdyPOgU8WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "310ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1863365519" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%)Async.json deleted file mode 100644 index 64d0f3373f4a1..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(%en-US%)Async.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:59 GMT", - "traceparent": "00-a5a9841fd5499e4f8d71f504562df5b3-d4b3b52380d4c74c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "59ce4b6a02979cbbff64c2c420cf4a3b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:58 GMT", - "MS-CV": "Qa1v5Y3u/0\u002BW36ibcjqE3g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Qh0vYAAAAACumPi08dNKS5W1nGiiy4jgWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "448ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:59 GMT", - "traceparent": "00-a23f3ae418824546aba9f1d409c1726d-bd15a8cb13675244-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d9daa191e8060dbdfaa37c32e101460c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:58 GMT", - "MS-CV": "ISkzyiED8UenF/7\u002BKHnG7g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Qh0vYAAAAAAeLMHdEtKoQqg92MGUEVKxWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "326ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1728370529" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null).json deleted file mode 100644 index 037b62827964b..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null).json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "traceparent": "00-4ea193dc4268ba459f7bfafbfaa9c50b-b099dc685243a449-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "05696a5a50b365020f8c828c1a16c0f2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:21 GMT", - "MS-CV": "dbEOTvDJ7kGE\u002Bd2v1A588A.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HR0vYAAAAADLzkq2v1aeTpoA38PxoHcTWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "359ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "traceparent": "00-cb13a52db619bf4eb61304653ac5fd8c-9f09dd59d0ecbe46-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "7e31e22295b6387c7d21cd7520d2023d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:21 GMT", - "MS-CV": "e6HysrjfLkO4r\u002BX7pl2Ucg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hh0vYAAAAAC5WyyJEoKbRr7fFl9BLbkKWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "409ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1249678682" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null)Async.json deleted file mode 100644 index 08695cc943388..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPhonePlans(null)Async.json +++ /dev/null @@ -1,110 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:58 GMT", - "traceparent": "00-f67a5e5ddebd9043bc4f8cdabe59a37e-03ea6150e6d4064b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "54079ccd269666fb3403e1ee00cc6a8e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:57 GMT", - "MS-CV": "hv\u002BThY6HhEmVCxoOCO4IoA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0QR0vYAAAAAA140TBzAsjT7FjjaytnyfpWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "301ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:58 GMT", - "traceparent": "00-b7ed5f5dd26c414193ff7bd59a1d5f5b-2e14c1d00f54fc4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "af2bb6f2ca2d7704be4f28f8125d6d0f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:57 GMT", - "MS-CV": "PMsoiY2pyEecOrdOJQ\u002BolA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Qh0vYAAAAABSloa/ehBMRrVjWzDN37PpWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "295ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "627743509" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False).json deleted file mode 100644 index e8bc7a1ed4801..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False).json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026includeRateInformation=false\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:24 GMT", - "traceparent": "00-23c2fdc95b86664d89c25b673fe60438-36846c5a79357845-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "b1074c2b661108cc800ff480343a9366", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:23 GMT", - "MS-CV": "CfEcZQ1nukGS2NGoi878AQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hx0vYAAAAABYOmmpsCnfTphdRILCd8e1WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1310708121" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False)Async.json deleted file mode 100644 index 7d9557ac32a7d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,False)Async.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026includeRateInformation=false\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:07:01 GMT", - "traceparent": "00-4aa90be107b798498394127ea7f02164-0ab965cd0204054b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "20dc374a12d6b397f6c1b9bce29282de", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:07:00 GMT", - "MS-CV": "\u002BP9FftTEJkiF7/jReKpTkA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RB0vYAAAAAC/1a/5nsPaT6NhaA\u002BeT\u002BlgWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "349ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "337401057" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True).json deleted file mode 100644 index 7897587c64ef4..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True).json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026includeRateInformation=true\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:25 GMT", - "traceparent": "00-5235a922893d334482b2e351524d32ea-3f9ce7a6cb9ef347-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6eeea0a97420258c8b12dbbd03e92622", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:24 GMT", - "MS-CV": "RPDz8eiDi0WWvHMqfbat/g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0IB0vYAAAAACBBTREKpqJQoPy0KkPOojeWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1400ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources.", - "rateInformation": { - "monthlyRate": 1.0, - "currencyType": "USD", - "rateErrorMessage": null - } - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources.", - "rateInformation": { - "monthlyRate": 1.0, - "currencyType": "USD", - "rateErrorMessage": null - } - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1954657508" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True)Async.json deleted file mode 100644 index 33dcbe753fe7b..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,True)Async.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026includeRateInformation=true\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:07:01 GMT", - "traceparent": "00-1432a2e547ed0c49a71c0003909fb12e-a5929043054b1946-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "68b09269e1c7cb96b723b35537e6d0cf", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:07:01 GMT", - "MS-CV": "v2tQoPg5J0SbOGEYM8qZEg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0RB0vYAAAAADJyttpsnN/QpZyJqt2B\u002BkWWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1585ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources.", - "rateInformation": { - "monthlyRate": 1.0, - "currencyType": "USD", - "rateErrorMessage": null - } - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources.", - "rateInformation": { - "monthlyRate": 1.0, - "currencyType": "USD", - "rateErrorMessage": null - } - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "794078690" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null).json deleted file mode 100644 index 363bcc3929f99..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null).json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:24 GMT", - "traceparent": "00-68ac92cc27b6b4429996780e965028fe-fd8c8eae9243bc4c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "adfa196010acb46ddc43efecdfdeb219", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:23 GMT", - "MS-CV": "xpNbo7LJUUWl1r\u002BkkN/dyg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hx0vYAAAAACnq34Lna7/S5mThd2EX1WSWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1273186525" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null)Async.json deleted file mode 100644 index 68690cdd39547..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(%en-US%,null)Async.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:07:00 GMT", - "traceparent": "00-472b1d419d0dd84ab6086db953ff66af-9f52497960fc9d4c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "405f74265e1c7b071f504354c58cc85a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:59 GMT", - "MS-CV": "\u002B9AQkQKSnkOHXHebVZ8hYQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Qx0vYAAAAADGLiib5ajjTYWN6NQvwLnZWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "341ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1070407389" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null).json deleted file mode 100644 index 91b2293200dd5..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null).json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:06:24 GMT", - "traceparent": "00-67eb33c3fd672b4997a3ff0c3532b056-b7ea685079f92a43-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "ffcf27462482bbff32e56f23453cd0bc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:22 GMT", - "MS-CV": "FOXBcaMPjUSNIunG30R6bQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Hx0vYAAAAAAmBPWvZuO0T4XWd4GbC/WOWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1774308574" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null)Async.json deleted file mode 100644 index 51685a2b8a104..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumberAdministrationClientLiveTests/GetPlanGroups(null,null)Async.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:07:00 GMT", - "traceparent": "00-1637b41a6ef4264cb9da3605e000cac8-f22e7789ac9bf44a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "60e8b001ad62437848f2cdecbe870dd5", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:06:59 GMT", - "MS-CV": "AqHH9zrA3UmMHmrtTAMJJw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0Qx0vYAAAAACHBekeFS2/RIPfY3o6EozQWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "426ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1803413721" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%).json new file mode 100644 index 0000000000000..7de9a48e045e8 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%).json @@ -0,0 +1,60 @@ +{ + "Entries": [ + { + "RequestUri": "https://sanitized.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "137", + "Content-Type": "application/json", + "Date": "Fri, 12 Feb 2021 18:45:38 GMT", + "traceparent": "00-461fbbe6eb6c68419e9cda535401d814-91b65bf02ea1cc4a-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210212.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "1998e942088b41528902c5a717b9722d", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "person", + "capabilities": { + "calling": "outbound", + "sms": "none" + }, + "areaCode": "212", + "quantity": 1 + }, + "StatusCode": 400, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 12 Feb 2021 18:45:37 GMT", + "MS-CV": "E9xjMhHnD0SnllCkvbbebw.0", + "Request-Context": "appId=", + "Transfer-Encoding": "chunked", + "X-Azure-Ref": "00swmYAAAAABVQUNZrWPeSLU8l/my5ZaDWVZSMzBFREdFMDMxMgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", + "X-Processing-Time": "67ms" + }, + "ResponseBody": { + "error": { + "code": "InvalidInput", + "message": "One or more request inputs are not valid.", + "details": [ + { + "code": "InvalidValue", + "message": "assignmentType is not valid.", + "target": "assignmenttype" + } + ] + } + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "1747956266" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%)Async.json new file mode 100644 index 0000000000000..0c7a45b79483a --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(%en-US%)Async.json @@ -0,0 +1,60 @@ +{ + "Entries": [ + { + "RequestUri": "https://sanitized.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "137", + "Content-Type": "application/json", + "Date": "Fri, 12 Feb 2021 18:45:43 GMT", + "traceparent": "00-e7a7cf0009ccd14e9780afad32d76070-cfab6eeb311dd042-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210212.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "1adb3619ff00c42d6db7cfaa5d1b4c57", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "person", + "capabilities": { + "calling": "outbound", + "sms": "none" + }, + "areaCode": "212", + "quantity": 1 + }, + "StatusCode": 400, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 12 Feb 2021 18:45:42 GMT", + "MS-CV": "qAIYX\u002BSywU6BWGLzSeEnsQ.0", + "Request-Context": "appId=", + "Transfer-Encoding": "chunked", + "X-Azure-Ref": "018wmYAAAAAC7ePr1LOoKTKo7VxLzYP3zWVZSMzBFREdFMDMxNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", + "X-Processing-Time": "12ms" + }, + "ResponseBody": { + "error": { + "code": "InvalidInput", + "message": "One or more request inputs are not valid.", + "details": [ + { + "code": "InvalidValue", + "message": "assignmentType is not valid.", + "target": "assignmenttype" + } + ] + } + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "981239205" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null).json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null).json new file mode 100644 index 0000000000000..6c43dea547682 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null).json @@ -0,0 +1,60 @@ +{ + "Entries": [ + { + "RequestUri": "https://sanitized.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "137", + "Content-Type": "application/json", + "Date": "Fri, 12 Feb 2021 18:45:33 GMT", + "traceparent": "00-80c20f334dd974478c51c7693dfd44cb-2f32b5c78506744f-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210212.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "7568aaf16445377673efcc7b9c206283", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "person", + "capabilities": { + "calling": "outbound", + "sms": "none" + }, + "areaCode": "212", + "quantity": 1 + }, + "StatusCode": 400, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 12 Feb 2021 18:45:33 GMT", + "MS-CV": "FetJYHAkE0qUh6Zj2IcCvA.0", + "Request-Context": "appId=", + "Transfer-Encoding": "chunked", + "X-Azure-Ref": "0zcwmYAAAAAB1GDpM4OUnSakR1xSzWBDoWVZSMzBFREdFMDMwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", + "X-Processing-Time": "39ms" + }, + "ResponseBody": { + "error": { + "code": "InvalidInput", + "message": "One or more request inputs are not valid.", + "details": [ + { + "code": "InvalidValue", + "message": "assignmentType is not valid.", + "target": "assignmenttype" + } + ] + } + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "146039084" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null)Async.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null)Async.json new file mode 100644 index 0000000000000..c7ba13be54428 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/CreateSearchErrorState(null)Async.json @@ -0,0 +1,60 @@ +{ + "Entries": [ + { + "RequestUri": "https://sanitized.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "137", + "Content-Type": "application/json", + "Date": "Fri, 12 Feb 2021 18:45:43 GMT", + "traceparent": "00-ae0c4cc821431f45b890c314bb31d191-ec65f49687bccd4e-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210212.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "bd276e0529925ca0425f223b817850c3", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "person", + "capabilities": { + "calling": "outbound", + "sms": "none" + }, + "areaCode": "212", + "quantity": 1 + }, + "StatusCode": 400, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 12 Feb 2021 18:45:42 GMT", + "MS-CV": "pPBBcXurJ0eEqUII1tVSMA.0", + "Request-Context": "appId=", + "Transfer-Encoding": "chunked", + "X-Azure-Ref": "018wmYAAAAADD/eVeA26VQo2qGBi0OpyFWVZSMzBFREdFMDMxNgA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", + "X-Processing-Time": "12ms" + }, + "ResponseBody": { + "error": { + "code": "InvalidInput", + "message": "One or more request inputs are not valid.", + "details": [ + { + "code": "InvalidValue", + "message": "assignmentType is not valid.", + "target": "assignmenttype" + } + ] + } + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "1262755216" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsync.json new file mode 100644 index 0000000000000..65e937a13a90c --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsync.json @@ -0,0 +1,125 @@ +{ + "Entries": [ + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 06:10:37 GMT", + "traceparent": "00-f9a7d5de5b323e42a400fd1409f6271c-3f849ae5fcea0e42-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "20ebe858182935f80f26182a75e5b17f", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 06:10:38 GMT", + "MS-CV": "rTUBNeJKuE2s2iqrPt3M4g.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "4ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://live-testing.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "1246562785" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsyncAsync.json new file mode 100644 index 0000000000000..522a7e6662615 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/PhoneNumbersClientLiveTests/ListPhoneNumbersAsyncAsync.json @@ -0,0 +1,125 @@ +{ + "Entries": [ + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 06:10:39 GMT", + "traceparent": "00-18194122267f524c8ba9260c3b4047c7-d7941dacbe93a548-00", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "57914b5847fc57ab7d329f21e9d2526a", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 06:10:38 GMT", + "MS-CV": "J1TR30GyqUyogC6/yMVlFg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "9ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://live-testing.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "136581784" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredential.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredential.json deleted file mode 100644 index b45f4a1b42079..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredential.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "traceparent": "00-cc378c5905e74447a0aa0d1192301700-d3b83b80abff0f46-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "27c8774175281c82bb326a748a832456", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:42 GMT", - "MS-CV": "72SUOSlS2Eiqco1uQwwMPw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09hwvYAAAAAB9Lr7EsEQrQIVoCWu2zSc9WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "584ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1364814218" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredentialAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredentialAsync.json deleted file mode 100644 index 229c938990f2e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/CreatePhoneNumberWithTokenCredentialAsync.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "traceparent": "00-e509e98acb7ece47b01f41c0dc5cf68f-46ff7dcb220b5743-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "c6b8b267b48a6e8c087dbfd82f1545fb", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:47 GMT", - "MS-CV": "cVazD020QEuXgaD7jNI0wQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/BwvYAAAAABIdS6Dc/vQRrNU1u8heg0zWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "354ms" - }, - "ResponseBody": { - "phoneNumbers": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1875430357" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodes.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodes.json deleted file mode 100644 index 8c2a239bfa215..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodes.json +++ /dev/null @@ -1,1711 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:44 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "3842b83a737c63b61efa20af45873db5", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:42 GMT", - "MS-CV": "8xQEnWiD9UqvaN4HP\u002Bcgsw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09xwvYAAAAACNCseKzS6dRrhWYH2q3Kw8WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "401ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:44 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "db4017535bbf4e303c6238d70143a7b4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:43 GMT", - "MS-CV": "ttmUTlqSMUm4XKlm4i4PcA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09xwvYAAAAAAmRSum\u002BDIiQ5YQmxW91Id3WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "610ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:45 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "ec0a3f305ddd3a89e2c6c105c844a5c6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:44 GMT", - "MS-CV": "mogHnFH9XES1kPg3GP\u002B55g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BBwvYAAAAADTqnnBHW1GRK8ta15dh7oIWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "336ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:05:45 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d4d23d5b9c22dec487f3fb193bde62db", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:44 GMT", - "MS-CV": "bGO/XxpJTEuUKMj3KnLO6g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BRwvYAAAAAC5i1rBCILKTJv7gGGTRtBpWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "287ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "2016080553" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodesAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodesAsyncAsync.json deleted file mode 100644 index 3962e3e0cf2f3..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GeographicalAreaCodesAsyncAsync.json +++ /dev/null @@ -1,1711 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:49 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "600e9b395f04b5e42a77e41dbdd390c0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:47 GMT", - "MS-CV": "K4/NZMQWBEKxayJv/O049g.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/BwvYAAAAAAJVlTIrCjqT4gyLH0QbM5HWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "293ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:49 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "620ebbc56fb302dcf046140614ad6228", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:48 GMT", - "MS-CV": "gKGsVq\u002BwWkKO9D8hsS5lMQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/BwvYAAAAAAFiowB6ZRXTaOuuTBdUN3qWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "296ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:50 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "bab8c0b4d205556331a110c804c6bf41", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:48 GMT", - "MS-CV": "N9XLGQHAPk6qkgftEJwtQA.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/RwvYAAAAADG8SY2mUhdQ6FzmNEippLxWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "298ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/areacodes?locationType=Selection\u0026phonePlanId=01432411-5169-4665-b13e-3fa56c10e1d1\u0026api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "111", - "Content-Type": "application/json", - "Date": "Fri, 19 Feb 2021 02:05:50 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "dee3ce43e131caafbf0b6fbd4adea07d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "locationOptions": [ - { - "labelId": "state", - "optionsValue": "AL" - }, - { - "labelId": "city", - "optionsValue": "NOAM-US-AL-BI" - } - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:48 GMT", - "MS-CV": "GN/AmDJeIU2lI7fz7jHGqQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/RwvYAAAAABC38FKfT6UQJmnujaLMqQmWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "261ms" - }, - "ResponseBody": { - "primaryAreaCodes": [ - "205" - ], - "secondaryAreaCodes": [], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "1591586086" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountries.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountries.json deleted file mode 100644 index 94ced84efc99b..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountries.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:46 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "035dd7e6d320cef0b9041c3c38a656a5", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:46 GMT", - "MS-CV": "62thRzeJnUiGz9znhABexQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BRwvYAAAAAAsS4S9Q0AtQ7CmM32MVQ4PWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1636ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "662632677" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountriesAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountriesAsyncAsync.json deleted file mode 100644 index e247f886acd2d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetAllSupportedCountriesAsyncAsync.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:50 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "28e9b728d3f2a2ee84f02e2e84f07370", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:51 GMT", - "MS-CV": "ZGkiyn4340\u002BgLXRbypRfXQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/RwvYAAAAAD2jmLVTgtiRI72V9O36AMVWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1495ms" - }, - "ResponseBody": { - "countries": [ - { - "localizedName": "United States", - "countryCode": "US" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "51555886" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptions.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptions.json deleted file mode 100644 index 1c3444f105626..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptions.json +++ /dev/null @@ -1,1664 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:47 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "6e7b1d7dd158e4206e758242b4f7cabe", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:46 GMT", - "MS-CV": "hNwn\u002Bo5ayUyuuhgXaI9\u002Bmw.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BxwvYAAAAADDEqM4nk4hSpP2m\u002BppltMsWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "307ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:48 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "8aea8835baedb0781dfed564c390bd59", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:46 GMT", - "MS-CV": "MSokw1kIcEyLRME8eglI1w.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BxwvYAAAAABWmFjq3RPHToPREF/yxPgRWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "292ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:48 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d39d6750c560d25fb9337b24992ffec6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:47 GMT", - "MS-CV": "0HTemWUSN0q8lYc4gR8Zwg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BxwvYAAAAAAbzbJuLHMOSLmXmjpm\u002BfjXWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "289ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "805460015" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptionsAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptionsAsyncAsync.json deleted file mode 100644 index ac7f96e2225cb..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/GetPhonePlanLocationOptionsAsyncAsync.json +++ /dev/null @@ -1,1664 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:52 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "0c196f3012c43caceb393b89df7e0f11", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:51 GMT", - "MS-CV": "3k9l0JDfZky3D1OJ6HHnig.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/xwvYAAAAADK9upx8it\u002BRIRszxgGSId0WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "315ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "671ee064-662f-4c3b-82a9-af2ab200dd5c", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:52 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "d5180b4de8ec08b41972b89207399838", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:52 GMT", - "MS-CV": "lfIvHU9KzU6pUdBLTyMBTQ.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/xwvYAAAAACPl0N7KhozSpZPEiuymEg8WVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "293ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "01432411-5169-4665-b13e-3fa56c10e1d1", - "localizedName": "Outbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "OutboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "b528a997-03bb-446e-af98-3d99877cf0ba", - "localizedName": "Inbound Only PSTN For User - Geographic", - "locationType": "Selection", - "areaCodes": [], - "capabilities": [ - "InboundCalling", - "UserAssignment", - "Geographic" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/55bc1415-9fe6-42d7-9ed4-5ea28c6a17cf/phoneplans/01432411-5169-4665-b13e-3fa56c10e1d1/locationoptions?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Fri, 19 Feb 2021 02:05:53 GMT", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.3; Microsoft Windows 10.0.18363)" - ], - "x-ms-client-request-id": "428ff1dadf047cd2b138a52834c0a5c6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Fri, 19 Feb 2021 02:05:52 GMT", - "MS-CV": "ut7mjvHqGEOcc2YDPmMHmg.0", - "Request-Context": "appId=", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AB0vYAAAAABH5rwhiVU/RIJSlL9vPTzmWVZSMzBFREdFMDMxMwA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "291ms" - }, - "ResponseBody": { - "locationOptions": { - "labelId": "state", - "labelName": "State", - "options": [ - { - "name": "AL", - "value": "AL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Birmingham", - "value": "NOAM-US-AL-BI", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-AL-HN", - "locationOptions": [] - }, - { - "name": "Mobile", - "value": "NOAM-US-AL-MO", - "locationOptions": [] - }, - { - "name": "Montgomery", - "value": "NOAM-US-AL-MN", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AR", - "value": "AR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fort Smith", - "value": "NOAM-US-AR-FS", - "locationOptions": [] - }, - { - "name": "Jonesboro", - "value": "NOAM-US-AR-JO", - "locationOptions": [] - }, - { - "name": "Little Rock", - "value": "NOAM-US-AR-LR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "AZ", - "value": "AZ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Phoenix", - "value": "NOAM-US-AZ-PH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CA", - "value": "CA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Anaheim", - "value": "NOAM-US-CA-AN", - "locationOptions": [] - }, - { - "name": "Burbank", - "value": "NOAM-US-CA-BU", - "locationOptions": [] - }, - { - "name": "Concord", - "value": "NOAM-US-CA-CO", - "locationOptions": [] - }, - { - "name": "Fresno", - "value": "NOAM-US-CA-FR", - "locationOptions": [] - }, - { - "name": "Irvine", - "value": "NOAM-US-CA-IR", - "locationOptions": [] - }, - { - "name": "Los Angeles", - "value": "NOAM-US-CA-LA", - "locationOptions": [] - }, - { - "name": "Riverside", - "value": "NOAM-US-CA-RI", - "locationOptions": [] - }, - { - "name": "Sacramento", - "value": "NOAM-US-CA-SA", - "locationOptions": [] - }, - { - "name": "Salinas", - "value": "NOAM-US-CA-SL", - "locationOptions": [] - }, - { - "name": "San Diego", - "value": "NOAM-US-CA-SD", - "locationOptions": [] - }, - { - "name": "San Francisco", - "value": "NOAM-US-CA-SF", - "locationOptions": [] - }, - { - "name": "San Jose", - "value": "NOAM-US-CA-SJ", - "locationOptions": [] - }, - { - "name": "Santa Barbara", - "value": "NOAM-US-CA-SB", - "locationOptions": [] - }, - { - "name": "Santa Clarita", - "value": "NOAM-US-CA-SC", - "locationOptions": [] - }, - { - "name": "Santa Rosa", - "value": "NOAM-US-CA-SR", - "locationOptions": [] - }, - { - "name": "Stockton", - "value": "NOAM-US-CA-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CL", - "value": "CL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Washington DC", - "value": "NOAM-US-CL-DC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CO", - "value": "CO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Denver", - "value": "NOAM-US-CO-DE", - "locationOptions": [] - }, - { - "name": "Grand Junction", - "value": "NOAM-US-CO-GJ", - "locationOptions": [] - }, - { - "name": "Pueblo", - "value": "NOAM-US-CO-PU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "CT", - "value": "CT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Bridgeport", - "value": "NOAM-US-CT-BR", - "locationOptions": [] - }, - { - "name": "Hartford", - "value": "NOAM-US-CT-HA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "DE", - "value": "DE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Wilmington", - "value": "NOAM-US-DE-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "FL", - "value": "FL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cape Coral", - "value": "NOAM-US-FL-CC", - "locationOptions": [] - }, - { - "name": "Fort Lauderdale", - "value": "NOAM-US-FL-FL", - "locationOptions": [] - }, - { - "name": "Gainesville", - "value": "NOAM-US-FL-GA", - "locationOptions": [] - }, - { - "name": "Jacksonville", - "value": "NOAM-US-FL-JA", - "locationOptions": [] - }, - { - "name": "Lakeland", - "value": "NOAM-US-FL-LA", - "locationOptions": [] - }, - { - "name": "Miami", - "value": "NOAM-US-FL-MI", - "locationOptions": [] - }, - { - "name": "Orlando", - "value": "NOAM-US-FL-OR", - "locationOptions": [] - }, - { - "name": "Port St Lucie", - "value": "NOAM-US-FL-PS", - "locationOptions": [] - }, - { - "name": "Sarasota", - "value": "NOAM-US-FL-SA", - "locationOptions": [] - }, - { - "name": "St. Petersburg", - "value": "NOAM-US-FL-SP", - "locationOptions": [] - }, - { - "name": "Tallahassee", - "value": "NOAM-US-FL-TA", - "locationOptions": [] - }, - { - "name": "Tampa", - "value": "NOAM-US-FL-TM", - "locationOptions": [] - }, - { - "name": "West Palm Beach", - "value": "NOAM-US-FL-WP", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "GA", - "value": "GA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-GA-AL", - "locationOptions": [] - }, - { - "name": "Atlanta", - "value": "NOAM-US-GA-AT", - "locationOptions": [] - }, - { - "name": "Augusta", - "value": "NOAM-US-GA-AU", - "locationOptions": [] - }, - { - "name": "Macon", - "value": "NOAM-US-GA-MA", - "locationOptions": [] - }, - { - "name": "Savannah", - "value": "NOAM-US-GA-SA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "HI", - "value": "HI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Honolulu", - "value": "NOAM-US-HI-HO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IA", - "value": "IA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Cedar Rapids", - "value": "NOAM-US-IA-CR", - "locationOptions": [] - }, - { - "name": "Davenport", - "value": "NOAM-US-IA-DA", - "locationOptions": [] - }, - { - "name": "Mason City", - "value": "NOAM-US-IA-MC", - "locationOptions": [] - }, - { - "name": "Sioux City", - "value": "NOAM-US-IA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ID", - "value": "ID", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boise", - "value": "NOAM-US-ID-BO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IL", - "value": "IL", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Aurora", - "value": "NOAM-US-IL-AU", - "locationOptions": [] - }, - { - "name": "Champaign", - "value": "NOAM-US-IL-CA", - "locationOptions": [] - }, - { - "name": "Chicago", - "value": "NOAM-US-IL-CH", - "locationOptions": [] - }, - { - "name": "Rock Island", - "value": "NOAM-US-IL-RI", - "locationOptions": [] - }, - { - "name": "Rockford", - "value": "NOAM-US-IL-RO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "IN", - "value": "IN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Evansville", - "value": "NOAM-US-IN-EV", - "locationOptions": [] - }, - { - "name": "Fort Wayne", - "value": "NOAM-US-IN-FW", - "locationOptions": [] - }, - { - "name": "Gary", - "value": "NOAM-US-IN-GA", - "locationOptions": [] - }, - { - "name": "Indianapolis", - "value": "NOAM-US-IN-IN", - "locationOptions": [] - }, - { - "name": "South Bend", - "value": "NOAM-US-IN-SB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KS", - "value": "KS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kansas City", - "value": "NOAM-US-KS-KS", - "locationOptions": [] - }, - { - "name": "Topeka", - "value": "NOAM-US-KS-TO", - "locationOptions": [] - }, - { - "name": "Wichita", - "value": "NOAM-US-KS-WI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "KY", - "value": "KY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ashland", - "value": "NOAM-US-KY-AS", - "locationOptions": [] - }, - { - "name": "Lexington", - "value": "NOAM-US-KY-LE", - "locationOptions": [] - }, - { - "name": "Louisville", - "value": "NOAM-US-KY-LO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "LA", - "value": "LA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baton Rouge", - "value": "NOAM-US-LA-BR", - "locationOptions": [] - }, - { - "name": "Lafayette", - "value": "NOAM-US-LA-LA", - "locationOptions": [] - }, - { - "name": "New Orleans", - "value": "NOAM-US-LA-NO", - "locationOptions": [] - }, - { - "name": "Shreveport", - "value": "NOAM-US-LA-SH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MA", - "value": "MA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Boston", - "value": "NOAM-US-MA-BO", - "locationOptions": [] - }, - { - "name": "Chicopee", - "value": "NOAM-US-MA-CH", - "locationOptions": [] - }, - { - "name": "Lowell", - "value": "NOAM-US-MA-LO", - "locationOptions": [] - }, - { - "name": "Worcester", - "value": "NOAM-US-MA-WO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MD", - "value": "MD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Baltimore", - "value": "NOAM-US-MD-BA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ME", - "value": "ME", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-ME-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MI", - "value": "MI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Ann Arbor", - "value": "NOAM-US-MI-AA", - "locationOptions": [] - }, - { - "name": "Detroit", - "value": "NOAM-US-MI-DE", - "locationOptions": [] - }, - { - "name": "Flint", - "value": "NOAM-US-MI-FL", - "locationOptions": [] - }, - { - "name": "Grand Rapids", - "value": "NOAM-US-MI-GP", - "locationOptions": [] - }, - { - "name": "Grant", - "value": "NOAM-US-MI-GR", - "locationOptions": [] - }, - { - "name": "Lansing", - "value": "NOAM-US-MI-LA", - "locationOptions": [] - }, - { - "name": "Otsego", - "value": "NOAM-US-MI-OT", - "locationOptions": [] - }, - { - "name": "Saginaw", - "value": "NOAM-US-MI-SA", - "locationOptions": [] - }, - { - "name": "Sault Ste Marie", - "value": "NOAM-US-MI-SS", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MN", - "value": "MN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Alexandria", - "value": "NOAM-US-MN-AL", - "locationOptions": [] - }, - { - "name": "Bloomington", - "value": "NOAM-US-MN-BL", - "locationOptions": [] - }, - { - "name": "Duluth", - "value": "NOAM-US-MN-DU", - "locationOptions": [] - }, - { - "name": "Minneapolis", - "value": "NOAM-US-MN-MI", - "locationOptions": [] - }, - { - "name": "Plymouth", - "value": "NOAM-US-MN-PL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MO", - "value": "MO", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Columbia", - "value": "NOAM-US-MO-CO", - "locationOptions": [] - }, - { - "name": "Kansas City", - "value": "NOAM-US-MO-KS", - "locationOptions": [] - }, - { - "name": "Marshall", - "value": "NOAM-US-MO-MA", - "locationOptions": [] - }, - { - "name": "Springfield", - "value": "NOAM-US-MO-SP", - "locationOptions": [] - }, - { - "name": "St. Charles", - "value": "NOAM-US-MO-SC", - "locationOptions": [] - }, - { - "name": "St. Louis", - "value": "NOAM-US-MO-SL", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MS", - "value": "MS", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Biloxi", - "value": "NOAM-US-MS-BI", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-MS-JA", - "locationOptions": [] - }, - { - "name": "Starkville", - "value": "NOAM-US-MS-ST", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "MT", - "value": "MT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Billings", - "value": "NOAM-US-MT-BI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NC", - "value": "NC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charlotte", - "value": "NOAM-US-NC-CH", - "locationOptions": [] - }, - { - "name": "Fayetteville", - "value": "NOAM-US-NC-FA", - "locationOptions": [] - }, - { - "name": "Greensboro", - "value": "NOAM-US-NC-GR", - "locationOptions": [] - }, - { - "name": "Raleigh", - "value": "NOAM-US-NC-RA", - "locationOptions": [] - }, - { - "name": "Rocky Mount", - "value": "NOAM-US-NC-RM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "ND", - "value": "ND", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Fargo", - "value": "NOAM-US-ND-FA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NE", - "value": "NE", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Kearney", - "value": "NOAM-US-NE-KE", - "locationOptions": [] - }, - { - "name": "Omaha", - "value": "NOAM-US-NE-OM", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NJ", - "value": "NJ", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Atlantic City", - "value": "NOAM-US-NJ-AC", - "locationOptions": [] - }, - { - "name": "Camden", - "value": "NOAM-US-NJ-CA", - "locationOptions": [] - }, - { - "name": "Edison", - "value": "NOAM-US-NJ-ED", - "locationOptions": [] - }, - { - "name": "Elizabeth", - "value": "NOAM-US-NJ-EL", - "locationOptions": [] - }, - { - "name": "Jersey City", - "value": "NOAM-US-NJ-JC", - "locationOptions": [] - }, - { - "name": "Newark", - "value": "NOAM-US-NJ-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NM", - "value": "NM", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albuquerque", - "value": "NOAM-US-NM-AL", - "locationOptions": [] - }, - { - "name": "Las Cruces", - "value": "NOAM-US-NM-LC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NV", - "value": "NV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Las Vegas", - "value": "NOAM-US-NV-LV", - "locationOptions": [] - }, - { - "name": "Reno", - "value": "NOAM-US-NV-RE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "NY", - "value": "NY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Albany", - "value": "NOAM-US-NY-AL", - "locationOptions": [] - }, - { - "name": "Brentwood", - "value": "NOAM-US-NY-BR", - "locationOptions": [] - }, - { - "name": "Elmira", - "value": "NOAM-US-NY-EL", - "locationOptions": [] - }, - { - "name": "Hempstead", - "value": "NOAM-US-NY-HE", - "locationOptions": [] - }, - { - "name": "New York City", - "value": "NOAM-US-NY-NY", - "locationOptions": [] - }, - { - "name": "Niagara Falls", - "value": "NOAM-US-NY-NF", - "locationOptions": [] - }, - { - "name": "Rochester", - "value": "NOAM-US-NY-RO", - "locationOptions": [] - }, - { - "name": "Yonkers", - "value": "NOAM-US-NY-YO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OH", - "value": "OH", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Akron", - "value": "NOAM-US-OH-AK", - "locationOptions": [] - }, - { - "name": "Cincinnati", - "value": "NOAM-US-OH-CI", - "locationOptions": [] - }, - { - "name": "Cleveland", - "value": "NOAM-US-OH-CL", - "locationOptions": [] - }, - { - "name": "Columbus", - "value": "NOAM-US-OH-CO", - "locationOptions": [] - }, - { - "name": "Dayton", - "value": "NOAM-US-OH-DA", - "locationOptions": [] - }, - { - "name": "Toledo", - "value": "NOAM-US-OH-TO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OK", - "value": "OK", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Lawton", - "value": "NOAM-US-OK-LA", - "locationOptions": [] - }, - { - "name": "Oklahoma City", - "value": "NOAM-US-OK-OC", - "locationOptions": [] - }, - { - "name": "Tulsa", - "value": "NOAM-US-OK-TU", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "OR", - "value": "OR", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Portland", - "value": "NOAM-US-OR-PO", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "PA", - "value": "PA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Erie", - "value": "NOAM-US-PA-ER", - "locationOptions": [] - }, - { - "name": "Lancaster", - "value": "NOAM-US-PA-LA", - "locationOptions": [] - }, - { - "name": "Philadelphia", - "value": "NOAM-US-PA-PI", - "locationOptions": [] - }, - { - "name": "Pittsburgh", - "value": "NOAM-US-PA-PT", - "locationOptions": [] - }, - { - "name": "Scranton", - "value": "NOAM-US-PA-SC", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "RI", - "value": "RI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Providence", - "value": "NOAM-US-RI-PR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SC", - "value": "SC", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-SC-CH", - "locationOptions": [] - }, - { - "name": "Columbia", - "value": "NOAM-US-SC-CO", - "locationOptions": [] - }, - { - "name": "Greenville", - "value": "NOAM-US-SC-GR", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "SD", - "value": "SD", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Sioux Falls", - "value": "NOAM-US-SD-SF", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TN", - "value": "TN", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Chattanooga", - "value": "NOAM-US-TN-CH", - "locationOptions": [] - }, - { - "name": "Clarksville", - "value": "NOAM-US-TN-CL", - "locationOptions": [] - }, - { - "name": "Jackson", - "value": "NOAM-US-TN-JA", - "locationOptions": [] - }, - { - "name": "Knoxville", - "value": "NOAM-US-TN-KN", - "locationOptions": [] - }, - { - "name": "Memphis", - "value": "NOAM-US-TN-ME", - "locationOptions": [] - }, - { - "name": "Nashville", - "value": "NOAM-US-TN-NA", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "TX", - "value": "TX", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Abilene", - "value": "NOAM-US-TX-AB", - "locationOptions": [] - }, - { - "name": "Austin", - "value": "NOAM-US-TX-AU", - "locationOptions": [] - }, - { - "name": "Bryan", - "value": "NOAM-US-TX-BR", - "locationOptions": [] - }, - { - "name": "Corpus Christi", - "value": "NOAM-US-TX-CC", - "locationOptions": [] - }, - { - "name": "Dallas", - "value": "NOAM-US-TX-DA", - "locationOptions": [] - }, - { - "name": "Denton", - "value": "NOAM-US-TX-DE", - "locationOptions": [] - }, - { - "name": "El Paso", - "value": "NOAM-US-TX-EP", - "locationOptions": [] - }, - { - "name": "Fort Worth", - "value": "NOAM-US-TX-FW", - "locationOptions": [] - }, - { - "name": "Galveston", - "value": "NOAM-US-TX-GA", - "locationOptions": [] - }, - { - "name": "Houston", - "value": "NOAM-US-TX-HO", - "locationOptions": [] - }, - { - "name": "Huntsville", - "value": "NOAM-US-TX-HU", - "locationOptions": [] - }, - { - "name": "Laredo", - "value": "NOAM-US-TX-LA", - "locationOptions": [] - }, - { - "name": "Lubbock", - "value": "NOAM-US-TX-LU", - "locationOptions": [] - }, - { - "name": "Odessa", - "value": "NOAM-US-TX-OD", - "locationOptions": [] - }, - { - "name": "San Antonio", - "value": "NOAM-US-TX-SA", - "locationOptions": [] - }, - { - "name": "Tyler", - "value": "NOAM-US-TX-TY", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "UT", - "value": "UT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Salt Lake City", - "value": "NOAM-US-UT-SL", - "locationOptions": [] - }, - { - "name": "St. George", - "value": "NOAM-US-UT-SG", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VA", - "value": "VA", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Arlington", - "value": "NOAM-US-VA-AR", - "locationOptions": [] - }, - { - "name": "Lynchburg", - "value": "NOAM-US-VA-LY", - "locationOptions": [] - }, - { - "name": "Richmond", - "value": "NOAM-US-VA-RI", - "locationOptions": [] - }, - { - "name": "Roanoke", - "value": "NOAM-US-VA-RO", - "locationOptions": [] - }, - { - "name": "Virginia Beach", - "value": "NOAM-US-VA-VB", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "VT", - "value": "VT", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Brattleboro", - "value": "NOAM-US-VT-BR", - "locationOptions": [] - }, - { - "name": "Burlington", - "value": "NOAM-US-VT-BU", - "locationOptions": [] - }, - { - "name": "Newport", - "value": "NOAM-US-VT-NE", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WI", - "value": "WI", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Eau Claire", - "value": "NOAM-US-WI-EC", - "locationOptions": [] - }, - { - "name": "Kenosha", - "value": "NOAM-US-WI-KE", - "locationOptions": [] - }, - { - "name": "Madison", - "value": "NOAM-US-WI-MA", - "locationOptions": [] - }, - { - "name": "Milwaukee", - "value": "NOAM-US-WI-MI", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WV", - "value": "WV", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Charleston", - "value": "NOAM-US-WV-CH", - "locationOptions": [] - } - ] - } - ] - }, - { - "name": "WY", - "value": "WY", - "locationOptions": [ - { - "labelId": "city", - "labelName": "City", - "options": [ - { - "name": "Laramie", - "value": "NOAM-US-WY-LA", - "locationOptions": [] - } - ] - } - ] - } - ] - } - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==", - "RandomSeed": "972002085" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndRelease.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndRelease.json deleted file mode 100644 index 4cfb29a1dc05d..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndRelease.json +++ /dev/null @@ -1,1865 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:37 GMT", - "Request-Id": "|6f8de629-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "15f81a50e021d5ba06758ae44d011507", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:39 GMT", - "MS-CV": "nsiOnmnZ\u002BkGUtq1hcITshQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0SizIXwAAAABpuYPlHJFJRovgAQgo/WxhWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "2126ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:41 GMT", - "Request-Id": "|6f8de62a-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "0956f6d0f783654d0d1d7d5131cfbf68", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:41 GMT", - "MS-CV": "npxWLfBvD0OObrkGdkHwVA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TCzIXwAAAAC734XtPcsTTYh3IuUn4D9xWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "2128ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:43 GMT", - "Request-Id": "|6f8de62b-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "096ce056e6a5ea056e02e4f02c7c63a7", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:42 GMT", - "MS-CV": "CTpVk\u002BO6UEGFyjlUhOBX4w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TizIXwAAAACaYwVKKXtLQbRdnsOTdlEfWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "322ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:43 GMT", - "Request-Id": "|6f8de62c-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "f21e1f72d1d3593ccc9307036369a337", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:42 GMT", - "MS-CV": "T0gPHHHtP0e\u002ByoFOziLmaA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TyzIXwAAAAAbygLV3K9FQbqI9XwaM2z2WVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "242ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "131", - "Content-Type": "application/json", - "Date": "Thu, 03 Dec 2020 00:07:44 GMT", - "Request-Id": "|6f8de62d-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "6c8e21b50c95e961f16c9b81135c3891", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:44 GMT", - "MS-CV": "YcrSH5qP5USzJLWxX6HLXA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0TyzIXwAAAADEN/sMUzi9TILIZ\u002B\u002BaxDZ5WVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1152ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:47 GMT", - "Request-Id": "|6f8de62e-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "11ded5b9ccb08495a4133d11df018605", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:46 GMT", - "MS-CV": "tO/W7EhZ30i0XrmeBBF91g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0UizIXwAAAABZ9U/xFEQESIqma4lvJ5vmWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "300ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:49 GMT", - "Request-Id": "|6f8de62f-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "0a3aac5ef7ed6612bd35016736ba456f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:48 GMT", - "MS-CV": "xgEicVPaO0qkox7mm0uv\u002BQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VSzIXwAAAAB4sFfvYJfjQ5rNAfQ3bXkEWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "379ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [], - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:52 GMT", - "Request-Id": "|6f8de630-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "8e49755b918be9868c09c781cf500aef", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:51 GMT", - "MS-CV": "betI4XzFeESZ5a3eSgnEXQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0VyzIXwAAAABexjfwbLG4To8ONVkIH5ozWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "324ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:54 GMT", - "Request-Id": "|6f8de631-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "662296e52d22c2a3c278547bcb2d4eea", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:53 GMT", - "MS-CV": "X13kPHNbfkSpG2xqHO36Ww.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0WizIXwAAAABS6Om7VaUzR4UlWwBx6QmbWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "465ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b/purchase?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:55 GMT", - "Request-Id": "|6f8de632-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "69b6cdcdf7b7cd7a26517ee42f90966d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Thu, 03 Dec 2020 00:07:55 GMT", - "MS-CV": "snLaA3KO0UaFp7VxBPB6Bw.0", - "X-Azure-Ref": "0WyzIXwAAAABMwjWHmkOnToFhg9hIN8Y\u002BWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "736ms" - }, - "ResponseBody": [] - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:07:58 GMT", - "Request-Id": "|6f8de633-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "a081112adf972d4dd286cc123d0b1d5e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:07:58 GMT", - "MS-CV": "kB/arANLuEOz2ByESWIfBQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0XSzIXwAAAABmOdRsdC6HQp1bWHLtN145WVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "352ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:00 GMT", - "Request-Id": "|6f8de634-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "01b4ddbaa099ed371b5540d0afbf9331", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:00 GMT", - "MS-CV": "fYiD7frwfUmUMYExMIYmww.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0YCzIXwAAAACOOwWc2OUNS7Mcgx8/gvMuWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "303ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:03 GMT", - "Request-Id": "|6f8de635-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "b950e6e1aeabed52808896312b67901b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:03 GMT", - "MS-CV": "rU14R0DpAkaS1/jNaUJefQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0YizIXwAAAADafnzUX6NxTLp3OU9riHIxWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "857ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:06 GMT", - "Request-Id": "|6f8de636-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "51291f3395dc8ad4d99484429f7d7e13", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:06 GMT", - "MS-CV": "H8PZWRMDUkS9yNYguxlHqA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ZSzIXwAAAAAOMEKVQJW6TaGXikDqgEmHWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "380ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:08 GMT", - "Request-Id": "|6f8de637-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "56319bf364ba0cb38bc681100a06c2b4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:08 GMT", - "MS-CV": "5YbgeURjXEKQtiGfnWILYg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0aCzIXwAAAACZdw4Ew7mPSZvi\u002B4R7FKlFWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "307ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:11 GMT", - "Request-Id": "|6f8de638-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "8f9c25c442954c5512c6df172a0f4e02", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:10 GMT", - "MS-CV": "wCzgvzamQ0KFVD8CPQyYVg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0aizIXwAAAAA731Qo3BiOToDut6ECbFXKWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "354ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:13 GMT", - "Request-Id": "|6f8de639-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "903d830a3936cf606c1cc51513c37fd3", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:13 GMT", - "MS-CV": "\u002BxiBwwN9IUWkMf4QJSVe3w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0bSzIXwAAAAB32UQpYvvaTYUlJVy\u002BJLIjWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:16 GMT", - "Request-Id": "|6f8de63a-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "7a7dcfd1efe0b17d45e444f4849be27b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:15 GMT", - "MS-CV": "fEYf3u0vP06BUanbE72EzQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0byzIXwAAAACixeMHFuWoTJLwU0AtSyLOWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "299ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:18 GMT", - "Request-Id": "|6f8de63b-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "86067e7831c98b7ec4cd22787c3f394e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:18 GMT", - "MS-CV": "t/F6yFlkK023HSmzBAjJ/w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0cizIXwAAAADtEhDmPR3pR6bNWngrXZcLWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1001ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/278d02bf-f03f-4b74-b0e2-dbb52f7eec6b?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:21 GMT", - "Request-Id": "|6f8de63c-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "5a450c46d4911b22068b4a51f46b4ad0", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:21 GMT", - "MS-CV": "BeBtdn5rrEewuXBqf4K4AQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0dSzIXwAAAADd95BL5tIjTI2Q3x/LCWpoWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "366ms" - }, - "ResponseBody": { - "searchId": "278d02bf-f03f-4b74-b0e2-dbb52f7eec6b", - "displayName": "My reservation", - "createdAt": "2020-12-03T00:07:44.0097537\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Success", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-03T00:23:50.4088229\u002B00:00", - "error": "NoError" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:22 GMT", - "Request-Id": "|6f8de63d-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "949c493af9bd9f0951f2b513cc043506", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:22 GMT", - "MS-CV": "Fe2V4cz8802sJ78ACV/8Zg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0dSzIXwAAAADHH6cy\u002BreuQoaHUjHA\u002BKbsWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "549ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, NOAM Toll Free", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree", - "InboundCalling" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:22 GMT", - "Request-Id": "|6f8de63e-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "78adf5ab8756a4e95cea803de72d9659", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:22 GMT", - "MS-CV": "XaoGvDwoR0ioz0UmpQrltA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0dizIXwAAAADI69EztaFgRIx6GChNdWVJWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "503ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, NOAM Toll Free", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree", - "InboundCalling" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "30", - "Content-Type": "application/json", - "Date": "Thu, 03 Dec 2020 00:08:23 GMT", - "Request-Id": "|6f8de63f-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "323e5282a4a34d9102a5089f1f0f4f01", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "phoneNumbers": [ - "Sanitized" - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:23 GMT", - "MS-CV": "QYzOz/8jz0KMlnbhiWhz1Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0dyzIXwAAAABDrYEKIgOFTJ6rlADmIh/3WVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "883ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:26 GMT", - "Request-Id": "|6f8de640-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "ffa54456d2beb27a5ff837d278ccb823", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:25 GMT", - "MS-CV": "c61t6/nMd0\u002BCpzql1sRjFw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0eizIXwAAAAAU8tn5hY9PS5Comlj41FStWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "259ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "Pending", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:28 GMT", - "Request-Id": "|6f8de641-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "79905c5c02c60663646075b07f4a854d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:28 GMT", - "MS-CV": "GYP6p3bPMUucWIBQA6siVA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0fCzIXwAAAAB7yLet\u002Bl4\u002BRaYJI88j4DVrWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "239ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:31 GMT", - "Request-Id": "|6f8de642-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "a2e77f9b9788b09ad78bd3aa6dbfd435", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:31 GMT", - "MS-CV": "N1AZCFn43UG0Ttji2cKoSw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0fizIXwAAAAB768jIcr\u002BjRbiXiYZe\u002Bx1uWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1174ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:34 GMT", - "Request-Id": "|6f8de643-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "c243e4ecd57e543be19e9b5d5cc93315", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:34 GMT", - "MS-CV": "ifFMypJLGkOYQ7QYGeYIGg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0gizIXwAAAADNXSa37thlSKXNgkI98s0qWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "570ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:37 GMT", - "Request-Id": "|6f8de644-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "f936ea7315e5c59bc1e0a23a2fb899a4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:38 GMT", - "MS-CV": "ijLlFPb6BUuyjy3qI3BgdA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0hCzIXwAAAABQZ\u002BFeqAjTRpa9s07NLwBHWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1793ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:41 GMT", - "Request-Id": "|6f8de645-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "9ac3408bc207c6cf4393c1e9fc3d530d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:40 GMT", - "MS-CV": "faKPqAa2h0OZKfNcBk61UQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0iCzIXwAAAAAzK5OsmLcdQ6CuAtLzvuHUWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "218ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:43 GMT", - "Request-Id": "|6f8de646-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "8336bd57db88d750497e019d32002428", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:42 GMT", - "MS-CV": "7P3uAzUNyEC\u002BYyOkXZBZuA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0iyzIXwAAAACFU8LbU3e1RJ11s0UDa2Q2WVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "257ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:46 GMT", - "Request-Id": "|6f8de647-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "1cd1f6049906b10d1b70b55254b2c983", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:45 GMT", - "MS-CV": "GObzr27V30m\u002B9TAyW9bUkg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0jSzIXwAAAAD1ZidbB7iASrw5dpa5/0VNWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "191ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:48 GMT", - "Request-Id": "|6f8de648-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "71e3948d1681b01cefec5189c0319343", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:47 GMT", - "MS-CV": "7SvgMMWx4U6PKZdK9Ic56w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0kCzIXwAAAABke7XaDkmYSK6\u002Ba17TpUhzWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "227ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/60b6088f-3f5f-41e3-af50-0b3d65be29c4?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:50 GMT", - "Request-Id": "|6f8de649-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "05e4986e376bbe07b085681725fe8397", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:49 GMT", - "MS-CV": "szYYB7TVaEuJcNdMxDHY2Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0kizIXwAAAABx4meE\u002BQFmRrDbbgr/FYUPWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "197ms" - }, - "ResponseBody": { - "releaseId": "60b6088f-3f5f-41e3-af50-0b3d65be29c4", - "createdAt": "2020-12-03T00:08:23.3390865\u002B00:00", - "status": "Complete", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Success" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Thu, 03 Dec 2020 00:08:51 GMT", - "Request-Id": "|6f8de64a-4803f071835a7fd8.", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "9d107eb4b31deea6da212c194884f1e9", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Thu, 03 Dec 2020 00:08:50 GMT", - "MS-CV": "oLPjD0MaSk\u002BKoSDEhbwAkA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0kizIXwAAAADNrAAI0g6hRbnXgB6FXUucWVZSMzBFREdFMDQxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "431ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree", - "InboundCalling" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "715976689" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndReleaseAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndReleaseAsyncAsync.json deleted file mode 100644 index 45a2c0bb3668c..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/PurchaseAndReleaseAsyncAsync.json +++ /dev/null @@ -1,2793 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:40 GMT", - "traceparent": "00-18263f741cd4c7498a1f29311fade117-5bcbf4b275a6db43-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "0461132b607677647a38a6084c7690ff", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:40 GMT", - "MS-CV": "cV2RyZYOs0\u002BNqsjYXxR9Ow.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06JLFXwAAAABEWj/2ICeqRLgmYlo81nDnWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "687ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:41 GMT", - "traceparent": "00-0847642f48ace347ae300a05d4439d47-c911618ec0a75e41-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "500e3a920e822f68dab35871051fde8e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:41 GMT", - "MS-CV": "oL7xnZsw2keSxsml0ml7zw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06ZLFXwAAAAD7VMql7kY7R4rIxJnp2L6MWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "283ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:41 GMT", - "traceparent": "00-eb468edef0861f4eabc12e8be501a3d1-441653c55eb90548-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "68be73fe2950d18d11215e8604d9d54d", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:41 GMT", - "MS-CV": "7x4CfX9rg0eFRDqo6Lhi2w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06ZLFXwAAAAD9kdFTJRPcQYrc71plHXyMWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "250ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:42 GMT", - "traceparent": "00-8fb7fb31420f8341a198e897d89586e6-2cf5bbe369adf54f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "785031b383901d09ab3129c207f2715a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:42 GMT", - "MS-CV": "zspYUfpttke1xF56yYrpfQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06pLFXwAAAACi7A03/k/fSbL8agIazZAfWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "256ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "131", - "Content-Type": "application/json", - "Date": "Tue, 01 Dec 2020 00:48:42 GMT", - "traceparent": "00-5fabd2cb98945d4fb27b4c4bfbee5f3f-ea21d02aa497454d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "d909185928b769afad3d3e61afe22b01", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "displayName": "My reservation", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1 - }, - "StatusCode": 201, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:43 GMT", - "MS-CV": "AJ0tDqB\u002BZUC2aZnoA31ieQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "06pLFXwAAAACw9m82qPgJSLsPrUoZE3QyWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "1336ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:44 GMT", - "traceparent": "00-570f77ed7fd0de4aa1afe898399390e0-a9e71421c4de7f48-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "d4be0bdd65ce7bfe69a1bd1e00cac91f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:44 GMT", - "MS-CV": "JLwiGccNbEK5RUY3pWw57A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07JLFXwAAAAB/IyEV0TF/RqCVOZDjWp9sWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "288ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [] - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:45 GMT", - "traceparent": "00-aecb01bc6798a34383dcf1d2119a7b52-a4a8a330b2f95242-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "ec2c04affccf8b9582e7cb5344a86dc8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:45 GMT", - "MS-CV": "HxswTGEEl0itbPGcKD9cgg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07ZLFXwAAAAB9qcCM7MlaSav0JkBzh9OTWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "293ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Pending", - "phoneNumbers": [] - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:46 GMT", - "traceparent": "00-0bf435e5caa23a4b8539f59623d85711-2e031609823ceb41-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "fce427069d34f38b198e6f166a9068e2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:46 GMT", - "MS-CV": "ijlPbjH91UuI0vNZ0a4p4g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "07pLFXwAAAAB0CfPy/691Q4hs8ybH7di4WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "262ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [] - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:48 GMT", - "traceparent": "00-7a407c5bb338804f8ab868c5fb5d58a9-7f58663491209848-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "abb11f733eb5e131753251e79aaa37c1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:48 GMT", - "MS-CV": "oweRgRn1QkWKtcjuy2hhCg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "08JLFXwAAAAA6mnW8/e0WTIgRDrNyr67bWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "296ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "InProgress", - "phoneNumbers": [] - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:49 GMT", - "traceparent": "00-48d7ec8a3ba9a44a976e6ad52104abab-b696d90871c6b744-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "d818f433cde512ea7838d2418d7f20f2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:49 GMT", - "MS-CV": "GooSmmdtvUS/0bj6d4pOBw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "08ZLFXwAAAABPnKDI1U4FT4fbtsY4PmWJWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "267ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:50 GMT", - "traceparent": "00-d802d2f603e157478c95d5e31f85aa3f-dfa2de706ff1fb41-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "24e0e87fc2f7c813f60386014ba4596f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:49 GMT", - "MS-CV": "NFXz0ET8X0iRNWm/\u002BxZsrA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "08pLFXwAAAAB9KvMILJQkSKs9iBtKQdDEWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "297ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Reserved", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce/purchase?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:50 GMT", - "traceparent": "00-651c28ac2d17094b88b06902b2fe54c7-17710015a6624445-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "76e3ad569077a5fc349e327c6cef54f6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 202, - "ResponseHeaders": { - "Content-Length": "0", - "Date": "Tue, 01 Dec 2020 00:48:50 GMT", - "MS-CV": "2BkqHrnOKUe\u002B64Mlzrd4ig.0", - "X-Azure-Ref": "08pLFXwAAAADi/MzfOd4cSJOhF8vs9j8AWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "773ms" - }, - "ResponseBody": [] - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:51 GMT", - "traceparent": "00-661eff0ba9d6114c959845c0f1687565-1bdaa11c58685d49-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "b1685f1112ca70cae150e1e247e9c6d4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:51 GMT", - "MS-CV": "h7BsBBtzdk\u002BMkOEqUbBajw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "085LFXwAAAADE\u002BHoHohGUTarBJYNgKVLhWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "271ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:52 GMT", - "traceparent": "00-3ed0284ca4e43c4e9b550f4c0eb15c35-d32741e8f5ccbf4a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "dfea62dfaa9bee7aec3bef588f965b06", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:52 GMT", - "MS-CV": "cFU6CSaJF0uZhgUkKE5NOw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09JLFXwAAAACteRe0fvlEQZjqYM5BIK4XWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "262ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:54 GMT", - "traceparent": "00-38827e3ceec50b4c81216a49f4f9b80d-e41835acfc8f604c-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "ecef8fafa83c44a5e3729427ae1a5d4b", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:53 GMT", - "MS-CV": "Iqw0fM0BEEmE5DfrCTTJQQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "09pLFXwAAAABLeU2CHENGSq5PJQ0S\u002BccXWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "277ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:55 GMT", - "traceparent": "00-7fda133883d7da46a8a114181264de87-a426fc17476f9548-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "099d5ed87404665ae579c58f2272e14a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:55 GMT", - "MS-CV": "YltZZg92DEmyBdr9/G2vrA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "095LFXwAAAAD9l5LzsZonTrQArmEIxpHJWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "366ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:56 GMT", - "traceparent": "00-eff50216e2722d408d3d7f45dcd176ee-0b7635b4554d5742-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "b733daf4daf93797bda6fc29165240d1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:56 GMT", - "MS-CV": "uBAQ\u002B0wv/EyXvNPFdv\u002BcRQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BJLFXwAAAAAjDzqO1cnCTa4hxBVybF7PWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "330ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:58 GMT", - "traceparent": "00-0df40b4a5dce594a9c8d89633f6aa48a-b8be57940cef9547-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "317fa4dd52f83a01358806c3e2162170", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:57 GMT", - "MS-CV": "JnjlQiS0YUipUezXOsDqsg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002BpLFXwAAAABW97szUk1rSbjP7adPLoitWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "272ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Completing", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:48:59 GMT", - "traceparent": "00-38298d60a781e448afa4f4e3e74b224e-c4e6dd4ca9ee744b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "d3334991a5e7fe51c6664b5e78305092", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:48:59 GMT", - "MS-CV": "bSD2klaoE0W9pPFihrz21g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0\u002B5LFXwAAAABVyuIcPsb6S4liJOUdCB9nWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "277ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:01 GMT", - "traceparent": "00-dee36419a720ac49bde1356323444c0e-e90f3a467e1dc842-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "7eb1f338b0f2a252d8f88270d3d454a7", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:00 GMT", - "MS-CV": "QjH2aeLx2UOktTe9fYV\u002BLw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/ZLFXwAAAADe4zOQapt\u002BRLiYtOayVyHhWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "342ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:02 GMT", - "traceparent": "00-5c204850686d89428c03623872c64f94-cb0bbdb17e5a7f40-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "cc988b846d1f37ea52816a9206a3c204", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:01 GMT", - "MS-CV": "dM/NNOu5RkWG\u002BOU3Iqvtlg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/pLFXwAAAACVobbp2lT5RK0BNZdIgxsyWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "267ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:03 GMT", - "traceparent": "00-9d02a93afd6c5841a960aceb853be28d-ff0e9f39f189054b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "ef8a7437a364e17ef791faee23e02af1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:03 GMT", - "MS-CV": "boP0zhwqOkGw21S4FpsMtg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0/5LFXwAAAADd6EKAq3HbT7\u002Bd\u002BsT6pvFMWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "266ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:05 GMT", - "traceparent": "00-c780c546dd653b4bbfe481d33d2433be-4f112900fb1c7a48-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "ecdaa4128498cb72097a2b7045bf9b35", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:04 GMT", - "MS-CV": "LhBvUa7Pik63fhJvdhiGzw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0AZPFXwAAAAARzAbW1/bDT4cf5KCd\u002BHmRWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "265ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:06 GMT", - "traceparent": "00-8b1bea397aca114faa51dfb3e8a4ffaa-cd19caf4d112cd48-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "5e387e36654ae0420db7d48e72fc1371", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:05 GMT", - "MS-CV": "OYyyp3ryG0mUgRXGhXKsFw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ApPFXwAAAABHRboCGRxRQI\u002BPnQ2aXOxZWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "268ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:07 GMT", - "traceparent": "00-9dea1242656c88418e1cc200ab878957-4a6a44a2b0f15545-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "62807957d5c9b36b02bfe5ea780d9b38", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:08 GMT", - "MS-CV": "gWH/cfL0p0\u002B7UEiArzxXKA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0BJPFXwAAAABR/O8ZROBIQqUZ38L3QBZ5WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "294ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:09 GMT", - "traceparent": "00-285b7c8360148e41a57566ef5f42467e-f9c6de282c1dea46-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "a5b7c4f5cba7ada761f9dee1afe3580c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:09 GMT", - "MS-CV": "l7gUvDttZEuDjjWIvhW2Fg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0BZPFXwAAAAB7zQdWyKMYQqHwAjzTdY6VWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "294ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:10 GMT", - "traceparent": "00-df4120aafb479d42889d879d26485278-999e6d96c7864644-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "cc19b966383f606c12855c8b7f586800", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:11 GMT", - "MS-CV": "C4mXmJ3IW0u4Ku4E4kge9g.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0BpPFXwAAAACRghcqGIsbTKtC\u002BKdNXg7PWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "272ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:12 GMT", - "traceparent": "00-e3ad84dc903b794889ac7d5a49d4d4e1-2dcd665f8b502644-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "ae999c1b6e448bc9d1d301cff78a041f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:12 GMT", - "MS-CV": "hogaurRZKEGasRGOjtdsEg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0CJPFXwAAAADRfo/sHnqzTIWQXpVZHiETWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "276ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:13 GMT", - "traceparent": "00-4be6058a9d76534bbb065366f564d630-f9c948f9c7f6984a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "be83d966cff4bdf8585692226f1b2d08", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:13 GMT", - "MS-CV": "0\u002BpazvHcfUC4iMj/Ge46Hg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0CZPFXwAAAAAwIOi7z5l\u002BQ7pFU1VmUflVWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "272ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:14 GMT", - "traceparent": "00-2f6f300a29f56b4ca3f1d375761b0d99-42323ac4d889594d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "12c6de91aa4af7c7ef8efa6b379c6988", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:15 GMT", - "MS-CV": "HQfdQmOF50yhjMBbKc\u002Be1Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0CpPFXwAAAAA/KaYi\u002BgCJSbUv1gejlpW5WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "277ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:16 GMT", - "traceparent": "00-d80ba3f5658b74498abe925daaa2abeb-7597af3d2d868743-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "a6243d80a9d44b0ca3db55eedba71bb6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:16 GMT", - "MS-CV": "NJi4lCTiS0es\u002BTvS4n5hJA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DJPFXwAAAABh9kCxxCJgQ6ZZAJ/XNfw7WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "636ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "PurchasePending", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/searches/a83f9c32-d87d-4e82-ac33-409fa0803bce?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:17 GMT", - "traceparent": "00-4795b76412f4fa48b1ddb7209975b728-750123c59f63bc42-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "183ef8a5f1c4bcd4118ccf65d58d86bc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:18 GMT", - "MS-CV": "Vowp5XynCEKadBcVdayZ9w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DpPFXwAAAAARR4By9iBaTYG39oQ\u002BupD7WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "264ms" - }, - "ResponseBody": { - "searchId": "a83f9c32-d87d-4e82-ac33-409fa0803bce", - "displayName": "My reservation", - "createdAt": "2020-12-01T00:48:42.8995901\u002B00:00", - "description": "reservation description", - "phonePlanIds": [ - "Sanitized" - ], - "areaCode": "833", - "quantity": 1, - "locationOptions": [], - "status": "Success", - "phoneNumbers": [ - "Sanitized" - ], - "reservationExpiryDate": "2020-12-01T01:04:48.2880174\u002B00:00" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:18 GMT", - "traceparent": "00-529651c6776cbd479e2c46876e1e4eca-b770911a43180249-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "32a10aec87f6e734d27a6e6e54d91c48", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:18 GMT", - "MS-CV": "0pnf6TrRakKQ7D6GnqlzpA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DpPFXwAAAAAKoZAjDlg0ToqgvmO9nFwwWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "419ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, NOAM Toll Free", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:18 GMT", - "traceparent": "00-2251462a3d2efd429550f762d2ce9657-6d60cf76b0aac140-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "3ec64472515d8fc368689448daa67616", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:19 GMT", - "MS-CV": "revY4VTwfkePayIi7/CX3w.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0DpPFXwAAAADpq6PXolyITq6evDiAm8L3WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "490ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, NOAM Toll Free", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases?api-version=2020-07-20-preview1", - "RequestMethod": "POST", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Content-Length": "30", - "Content-Type": "application/json", - "Date": "Tue, 01 Dec 2020 00:49:19 GMT", - "traceparent": "00-06c533a27e3d6948965e670686d2b56b-5b1de83c5127e945-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "d0029955e9051dbfc357464982666737", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": { - "phoneNumbers": [ - "Sanitized" - ] - }, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:20 GMT", - "MS-CV": "iKsi0QmLeUyVv8Fqg41hQw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0D5PFXwAAAABAFqXs5SJ3SoN6rOg0gfF3WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "660ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb" - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:20 GMT", - "traceparent": "00-8ea3340f9643634fa7161f7b452b7be3-80f0a6c30f56db4d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "90f3866f47c69b5e4612c98ef2eb0d2c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:20 GMT", - "MS-CV": "R9kidmMhIE6qSB22w55BtQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0EJPFXwAAAABZAWkFkaTiSZvDtJelC2HrWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "183ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "Pending", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:21 GMT", - "traceparent": "00-33ec4aa5941e424f82f66cd98d7a1f70-3b30e589cdf2c24f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "bb1958034bd7884384a87a060a790c02", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:21 GMT", - "MS-CV": "UCgO6Zr/1kCwWeViccwxjw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0EZPFXwAAAACaDAbC5BJTRIWP9e22X2N3WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "185ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "Pending", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:22 GMT", - "traceparent": "00-a348904d23a1284a80cbba04aa238666-66250be252252a43-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "53d85d00e6b20d4f3a668af21f302bd8", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:22 GMT", - "MS-CV": "jU9fAOwGrUezp9VLICqmDQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0EpPFXwAAAADfBTBa7mb5TJufD3R1xm/GWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "179ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:24 GMT", - "traceparent": "00-1b1c729d89f8b84693305e519d81dedb-dd7271e3d275bc4d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "2a461a49ac4c2460426a0b1ecc5890cc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:24 GMT", - "MS-CV": "XcnSWVP2JESXF/exUY3djA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0FJPFXwAAAADUPG4md0OXQYns\u002BtL\u002BMz2SWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "182ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:25 GMT", - "traceparent": "00-d6bce2d3e9555841bb7da9ca21dee651-f7f4ad296989bb47-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "958ec706ba131d79080b8170c1516854", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:25 GMT", - "MS-CV": "iauf6jLSmEW5M95cp/vGvw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0FZPFXwAAAAB\u002BVATROmg8R6CCCSwdE/NnWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "189ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:26 GMT", - "traceparent": "00-0300ac6018b3b84b908ab2a51aeba25f-608fc4bf9de99944-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "f0bda27de13354b5fcb41047da3141e1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:26 GMT", - "MS-CV": "c7GAPl93HE2IwQ6PAoPUew.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0FpPFXwAAAAC2H4bZoIwWSbM/kgntgungWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "180ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:27 GMT", - "traceparent": "00-da392472815c0e4da8d0685f95d267f8-ec3038ccbe3f5a4d-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "58ecbdd595a28fc5a02922412bef63f1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:27 GMT", - "MS-CV": "vFIzXK22rkuUz1YtrCaWNw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0F5PFXwAAAABCVPoXWUJ9TbyDrXUEwERVWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "192ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:29 GMT", - "traceparent": "00-6f68f48500f9f64db9ef29181cc52b97-b612398794ead045-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "29a0b702a09b24991139985ea93143d6", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:29 GMT", - "MS-CV": "evdWADC5qkuiFk/2YYWiPw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0GZPFXwAAAABRWaSzeS6yS4Yz6w8M3AtcWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "182ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:30 GMT", - "traceparent": "00-d3a0be55e78072499e1e30cca888d7b3-956a77464a293848-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "049b9fc90f64e8b1dd2d4f0abf74290c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:30 GMT", - "MS-CV": "9GQBiz91jEaS3AlNzV2YoQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0GpPFXwAAAABs6zGrQtdhQK2Q\u002BOZGj4SQWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "184ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Pending" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:31 GMT", - "traceparent": "00-b29bba70b3b1694787b3016a4e955b77-298f19433ba3bd4b-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "22451f511791354623c74768fc66e66e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:31 GMT", - "MS-CV": "4Au4iorzSE6EGDRe13ciJA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0G5PFXwAAAADezZmHwssRR48VtfW8f8guWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "203ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:33 GMT", - "traceparent": "00-7c2779430de4714ea77a15acf6c0101f-542c607bb9a4de45-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "8c774ce55f54f28c06b84c6d508f659c", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:33 GMT", - "MS-CV": "ITLVUPh9ZkK1hIOxk\u002B8qCg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0HZPFXwAAAACSX4He4CMAR7rnjBDH/QNMWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "961ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:35 GMT", - "traceparent": "00-d880c3b234d56e4caba6d05ebe37c1de-773e172dffc30848-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "8a0d8b1021ecb2455866e09dc848eb77", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:35 GMT", - "MS-CV": "9OqXI/AqSEuL3HpsQ20bqQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0H5PFXwAAAAAKggT7/8oqRIBu9kgQdpIqWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "184ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:36 GMT", - "traceparent": "00-0fa29dccea435a42a7f4e91e4a3e6f12-f78bffd00e79ac40-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "7224e0479cfdf1b892531bd8cbd8e494", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:36 GMT", - "MS-CV": "0C\u002Bhv0KZX0yVQCOa7wwIbg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0IJPFXwAAAACK92GJALchR7RKTH9TfxOWWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "193ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:37 GMT", - "traceparent": "00-6048c19ef7355f41b512b4e17346a036-ce40faed81b84642-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "7058ab625c58c48206c533ee7eef29be", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:37 GMT", - "MS-CV": "hiq\u002BkIocTUS5rfhoe5FtRg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0IZPFXwAAAAB1famQCVUdSKmXEL8jW3Y2WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "247ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:39 GMT", - "traceparent": "00-45639d884a43994c8ea09fcc33e4cad6-c8dcfd50b9e0b24a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "7026d5cdf26a739fd31bf798056ce77f", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:38 GMT", - "MS-CV": "7Whe5Mu14E\u002BXewr5sAjMsQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0I5PFXwAAAACopjtLpZ8tSraZ6lAAcoAvWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "180ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:40 GMT", - "traceparent": "00-a14a582232c64840beba0162af112807-43aa190379aa2541-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "1d3b4b817af0eb1e5d5f6c3869ca73a2", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:40 GMT", - "MS-CV": "kzg8Aebg6UuZz/GS\u002Bp5SFQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JJPFXwAAAABcc2K0jYQ5SIjUFn\u002B3nL8TWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "183ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:41 GMT", - "traceparent": "00-e7a5813fc05f9947b7bbd055cb5adf0b-f47cf853e56aad4f-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "f60b5d2973b26f2a0be49d3c64eabf9a", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:41 GMT", - "MS-CV": "kszHXJteKUuxtLUJHimtCQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JZPFXwAAAAAcGnw9AZJvSYyMKCYA0BhLWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "186ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:42 GMT", - "traceparent": "00-3dbe670aec93384da7125bbeabca640b-6019e7e80794d245-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "326cb3dd0cb452ceb63a120a86670a09", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:42 GMT", - "MS-CV": "K\u002BLWmZsI90OBN0vvz/r5Nw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0JpPFXwAAAAATmtUkKJK0Tall7a7M7nW7WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "238ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:44 GMT", - "traceparent": "00-9f4c231c1cfe35489b3e264c9865b1c0-431db84706d6b941-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "a76e55a8f1610dcd21cb110bdde28773", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:44 GMT", - "MS-CV": "3rbO0VUiBUmPfs6iIt75jw.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KJPFXwAAAABgDldDcIlRT5QwLZpEoIowWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "244ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:45 GMT", - "traceparent": "00-5aa6b7986ffd054dafba812bbf66a6c8-4bf7b6e7473ba345-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "b55ad1a0405d1ced8fb83f77611fe9a4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:45 GMT", - "MS-CV": "bzPb/Ij0mUyTX01kNHmrnA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KZPFXwAAAAAF4RACgoMJTqv\u002BDUCDbki4WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "188ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "InProgress", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "InProgress" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/releases/a19e6453-7580-47cb-bc6f-dd90281ee2fb?api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:46 GMT", - "traceparent": "00-ac60a38039175747af43ad8e07a4eb9d-01c6cebbe5d97644-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "0f9393da177bec38e65e11e9fbc274d4", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:46 GMT", - "MS-CV": "xnXlg81hfkOrWgDTm1DGqQ.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0KpPFXwAAAABk09Ht2afOQb6P5qd/bXM9WVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "274ms" - }, - "ResponseBody": { - "releaseId": "a19e6453-7580-47cb-bc6f-dd90281ee2fb", - "createdAt": "2020-12-01T00:49:19.6537955\u002B00:00", - "status": "Complete", - "phoneNumberReleaseStatusDetails": { - "Sanitized": { - "status": "Success" - } - } - } - }, - { - "RequestUri": "https://chitchat-test.communication.azure.com/administration/phonenumbers/phonenumbers?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Tue, 01 Dec 2020 00:49:47 GMT", - "traceparent": "00-9eb03b928859884d96028fbe0bed4fea-7ed52aeee92a914a-00", - "User-Agent": [ - "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210218.1", - "(.NET 5.0.0; Microsoft Windows 10.0.19042)" - ], - "x-ms-client-request-id": "b4699fb3540d68ab675118a8b155ac01", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Tue, 01 Dec 2020 00:49:47 GMT", - "MS-CV": "ogeFlMwnDU6cHuL9e26A6Q.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0K5PFXwAAAACtykWdbrh5R4I50QY9X9dFWVZSMzBFREdFMDMxNQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "408ms" - }, - "ResponseBody": { - "phoneNumbers": [ - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "InboundCalling", - "UserAssignment", - "Geographic", - "OutboundCalling" - ], - "availableCapabilities": [ - "UserAssignment", - "Geographic", - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling" - ], - "assignmentStatus": "Unassigned", - "placeName": "Birmingham, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "ThirdPartyAppAssigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - }, - { - "phoneNumber": "Sanitized", - "acquiredCapabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "availableCapabilities": [ - "Azure", - "Office365", - "InboundCalling", - "OutboundCalling", - "ThirdPartyAppAssignment", - "ConferenceAssignment", - "FirstPartyAppAssignment", - "TollFree", - "InboundA2PSms", - "OutboundA2PSms" - ], - "assignmentStatus": "Unassigned", - "placeName": "Toll-Free, United States", - "activationState": "Activated" - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://chitchat-test.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "2023484593" - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodes.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodes.json deleted file mode 100644 index f448ad1928223..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodes.json +++ /dev/null @@ -1,215 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://sanitized.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Mon, 23 Nov 2020 18:16:29 GMT", - "User-Agent": [ - "azsdk-net-Communication.Administration/1.0.0-alpha.20201120.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "ab48c5d45a660e8d9a9bf63dfb4147fc", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Mon, 23 Nov 2020 18:16:29 GMT", - "MS-CV": "pafpio6Dqkyi4NYn96HDyg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0ffy7XwAAAACOJl3OleDfQJEOGb1dG2XzWVZSMzBFREdFMDMwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "263ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://sanitized.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Mon, 23 Nov 2020 18:16:29 GMT", - "User-Agent": [ - "azsdk-net-Communication.Administration/1.0.0-alpha.20201120.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "28d615065d5a20a7dabd9eb33bbed83e", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Mon, 23 Nov 2020 18:16:30 GMT", - "MS-CV": "5cgTeZcjDUaV\u002BjdOp6FMiA.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "0fvy7XwAAAAARGnEJZ5gwSJfORnG7kWb4WVZSMzBFREdFMDMwOQA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "304ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1217693232" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodesAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodesAsyncAsync.json deleted file mode 100644 index b8dcde6c4395e..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample2_PhoneNumberAdministrationClient/TollFreePlanAreaCodesAsyncAsync.json +++ /dev/null @@ -1,215 +0,0 @@ -{ - "Entries": [ - { - "RequestUri": "https://sanitized.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Mon, 23 Nov 2020 18:13:55 GMT", - "User-Agent": [ - "azsdk-net-Communication.Administration/1.0.0-alpha.20201120.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "429d2c8024dab51c00e6ea9f6e89d892", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Mon, 23 Nov 2020 18:13:56 GMT", - "MS-CV": "pR0xBR2WHU21h62bK4vnvg.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "04/u7XwAAAAA7lj0sRQjTRrfAsQ3vrNRCWVZSMzBFREdFMDQxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "249ms" - }, - "ResponseBody": { - "phonePlanGroups": [ - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure- User - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "Geographic", - "localizedName": "Azure - Geographic", - "localizedDescription": "These are numbers used by Azure resources." - }, - { - "phonePlanGroupId": "Sanitized", - "phoneNumberType": "TollFree", - "localizedName": "Azure - Toll Free", - "localizedDescription": "These are toll free numbers used by Azure resources." - } - ], - "nextLink": null - } - }, - { - "RequestUri": "https://sanitized.communication.azure.com/administration/phonenumbers/countries/US/phoneplangroups/Sanitized/phoneplans?locale=en-US\u0026api-version=2020-07-20-preview1", - "RequestMethod": "GET", - "RequestHeaders": { - "Accept": "application/json", - "Authorization": "Sanitized", - "Date": "Mon, 23 Nov 2020 18:13:56 GMT", - "User-Agent": [ - "azsdk-net-Communication.Administration/1.0.0-alpha.20201120.1", - "(.NET Core 4.6.29321.03; Microsoft Windows 10.0.19042 )" - ], - "x-ms-client-request-id": "7bd0f60afccb07cb0d294030034188a1", - "x-ms-content-sha256": "Sanitized", - "x-ms-return-client-request-id": "true" - }, - "RequestBody": null, - "StatusCode": 200, - "ResponseHeaders": { - "Content-Type": "application/json; charset=utf-8", - "Date": "Mon, 23 Nov 2020 18:13:56 GMT", - "MS-CV": "DaTVdNWJJkupZN6KBpI77A.0", - "Transfer-Encoding": "chunked", - "X-Azure-Ref": "05Pu7XwAAAAB9QIq/SYf3SKxwqKFXgRkDWVZSMzBFREdFMDQxMAA5ZmM3YjUxOS1hOGNjLTRmODktOTM1ZS1jOTE0OGFlMDllODE=", - "X-Processing-Time": "429ms" - }, - "ResponseBody": { - "phonePlans": [ - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only Sms - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "OutboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only SMS (A2P) \u0026 Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "InboundCalling", - "ThirdPartyAppAssignment", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "2-way SMS (A2P) - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundA2PSms", - "OutboundA2PSms", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Outbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "OutboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - }, - { - "phonePlanId": "Sanitized", - "localizedName": "Inbound Only PSTN - Toll Free", - "locationType": "NotRequired", - "areaCodes": [ - "833" - ], - "capabilities": [ - "Azure", - "ThirdPartyAppAssignment", - "InboundCalling", - "TollFree" - ], - "maximumSearchSize": 20 - } - ], - "nextLink": null - } - } - ], - "Variables": { - "COMMUNICATION_CONNECTION_STRING": "endpoint=https://sanitized.communication.azure.com/;accesskey=Kg==;", - "RandomSeed": "1274970044" - } -} \ No newline at end of file diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndRelease.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndRelease.json new file mode 100644 index 0000000000000..9a23f0feb5a80 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndRelease.json @@ -0,0 +1,1111 @@ +{ + "Entries": [ + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "112", + "Content-Type": "application/json", + "Date": "Fri, 26 Feb 2021 07:44:59 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "a3fc6de758fce1aef019fb455fd44824", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "application", + "capabilities": { + "calling": "none", + "sms": "outbound" + } + }, + "StatusCode": 202, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location,Operation-Location,operation-id,search-id", + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:00 GMT", + "Location": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "MS-CV": "y4mdzZ7WpkO2HgPJBbTUXg.0", + "operation-id": "search_802ce504-8699-49ae-89f0-4c441a886eaf", + "Operation-Location": "/phoneNumbers/operations/search_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "search-id": "802ce504-8699-49ae-89f0-4c441a886eaf", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "22ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:02 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "213b45f7a3880ae09392a52d6734df72", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:02 GMT", + "Location": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "MS-CV": "TVsc26whFkm5E9uf2QROvg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "search_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:04 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "d79ad86071e4b3d3e7f349b9bc5dd46e", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:04 GMT", + "Location": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "MS-CV": "2mPnGs5UKEWebc/5Vi8RPg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "search_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:06 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "1a4e6d132799829c1f992cbb8e59a225", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:06 GMT", + "Location": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "MS-CV": "qAoXPhjml0iLsa7aH8m1sw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "search_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "33ef29642ee786aa71873a945a274d35", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "Location": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "MS-CV": "jbBfmvhLMUOIbc3o5zOaGA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": "/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "search_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/searchResults/802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "fa1937bdc5e539d83c17b74b4417248e", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "MS-CV": "yhCc74aF8kKzP87qINPJKQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "searchId": "802ce504-8699-49ae-89f0-4c441a886eaf", + "phoneNumbers": [ + "Sanitized" + ], + "phoneNumberType": "TollFree", + "assignmentType": "Application", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + }, + "searchExpiresBy": "2021-02-26T08:00:00.8108012\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/:purchase?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "51", + "Content-Type": "application/json", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "93542350a16de486c2c7a811ec0728f8", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "searchId": "802ce504-8699-49ae-89f0-4c441a886eaf" + }, + "StatusCode": 202, + "ResponseHeaders": { + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:08 GMT", + "MS-CV": "d0OJTklziESeHzDVO8fkgw.0", + "operation-id": "purchase_802ce504-8699-49ae-89f0-4c441a886eaf", + "Operation-Location": "/phoneNumbers/operations/purchase_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "purchase-id": "802ce504-8699-49ae-89f0-4c441a886eaf", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "17ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:11 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "3644ac63b9d21cc7b035371e1dc74c34", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:10 GMT", + "MS-CV": "TK0KRoJpY0yxLbxfCbK7rg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "purchase_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:13 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "4dffbfefcd1aa84ee3b643b7a9b66d63", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:12 GMT", + "MS-CV": "tECSzxJ2b0CK8f5JdVTKQQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "purchase_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:15 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "40ae4e85f1c392252fe1a60a70218189", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:14 GMT", + "MS-CV": "VmjdafXAc0Snfk8KIGD8Ig.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "purchase_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_802ce504-8699-49ae-89f0-4c441a886eaf?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:17 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "b7e0c26af55f953f5d9b521c761073f9", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:16 GMT", + "MS-CV": "DeKsvh2riESuHeu0y\u002B7hYQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:00.8108025\u002B00:00", + "id": "purchase_802ce504-8699-49ae-89f0-4c441a886eaf", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:17 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "ce98d3c70b18fd71996d1d38274437c1", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:16 GMT", + "MS-CV": "vNd6lX2cNEGCuQle0tOzug.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "10ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/Sanitized/capabilities?api-version=2021-03-07", + "RequestMethod": "PATCH", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "52", + "Content-Type": "application/merge-patch\u002Bjson", + "Date": "Fri, 26 Feb 2021 07:45:17 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "e64dba34b6d690040e18e3289e091b1f", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "StatusCode": 202, + "ResponseHeaders": { + "capabilities-id": "c2961bba-2da4-4e6c-b92e-cda0775c65c2", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:16 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "hQ5KNl\u002BjpEqCKcqK3VqLqA.0", + "operation-id": "capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2", + "Operation-Location": "/phoneNumbers/operations/capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2?api-version=2021-03-07", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "52ms" + }, + "ResponseBody": { + "capabilitiesUpdateId": "c2961bba-2da4-4e6c-b92e-cda0775c65c2" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:19 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "bbe791638cc31023cf07c00028485e8f", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:18 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "3WUibavmokOVtRNjEHJlLQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "9ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:17.2378837\u002B00:00", + "id": "capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:21 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "7acbfe519a0181384aee94f39911b907", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:20 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "oOZ\u002BDBmQ3k6gDLPhH/FPkg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:17.2378837\u002B00:00", + "id": "capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:23 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "0dc4caaa6022e05c8932ce81f2703509", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:22 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "6aKLcXZ8Xk2Yy3SNvaVayw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:17.2378837\u002B00:00", + "id": "capabilities_c2961bba-2da4-4e6c-b92e-cda0775c65c2", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:23 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "d9a18d83f33bc917586571d4f82f77bd", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:22 GMT", + "MS-CV": "qpO/PQj\u002B1kWJXVqmztogew.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "15ms" + }, + "ResponseBody": { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:23 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "5e55b84e5184f06da2eaf1cfcbb68fd9", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:22 GMT", + "MS-CV": "s0XTKq95gEG\u002BGmcjwQ4Zeg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "11ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/Sanitized?api-version=2021-03-07", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:23 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "0b6f8bb8df6fb6cbb2fbb4bdee87e859", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 202, + "ResponseHeaders": { + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:22 GMT", + "MS-CV": "2twiXN1H5EqJgn0ixs2sMg.0", + "operation-id": "release_3402e46d-2189-4c92-b56b-18a519850493", + "Operation-Location": "/phoneNumbers/operations/release_3402e46d-2189-4c92-b56b-18a519850493?api-version=2021-03-07", + "release-id": "3402e46d-2189-4c92-b56b-18a519850493", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "16ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_3402e46d-2189-4c92-b56b-18a519850493?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:25 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "6c1c97d56bbf6e4eed9eab899cb0021a", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:24 GMT", + "MS-CV": "pMsoPZmah02dywvm/5/a1Q.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "6ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:23.4833803\u002B00:00", + "id": "release_3402e46d-2189-4c92-b56b-18a519850493", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_3402e46d-2189-4c92-b56b-18a519850493?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:27 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "bb1397015683e1bf063debbea87ab46a", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:26 GMT", + "MS-CV": "ZYbHDGZHI0qgOvO5iFjdkA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:23.4833803\u002B00:00", + "id": "release_3402e46d-2189-4c92-b56b-18a519850493", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_3402e46d-2189-4c92-b56b-18a519850493?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:29 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "56e712fd7b6b509ac1c44c7c2bfb9670", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:28 GMT", + "MS-CV": "swgMpTu0Qk2/\u002BxF8QXybmg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:23.4833803\u002B00:00", + "id": "release_3402e46d-2189-4c92-b56b-18a519850493", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:29 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "6a4f1cae42347f1fd83a6582808fc672", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:28 GMT", + "MS-CV": "eq2WGzKEx06ZYXPdIU3Wfg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "4ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://live-testing.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "681638112" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndReleaseAsyncAsync.json b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndReleaseAsyncAsync.json new file mode 100644 index 0000000000000..afe09c9e94894 --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/SessionRecords/Sample_PhoneNumbersClient/PurchaseAndReleaseAsyncAsync.json @@ -0,0 +1,1251 @@ +{ + "Entries": [ + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/countries/US/:search?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "112", + "Content-Type": "application/json", + "Date": "Fri, 26 Feb 2021 07:45:29 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "a69cc59eea8a8782b0500f7f93317352", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "phoneNumberType": "tollFree", + "assignmentType": "application", + "capabilities": { + "calling": "none", + "sms": "outbound" + } + }, + "StatusCode": 202, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location,Operation-Location,operation-id,search-id", + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:30 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "AfX1RwkP3Ee3H4cN3vbczA.0", + "operation-id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "Operation-Location": "/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "search-id": "1c469383-f782-4fa2-8290-9c36778313cd", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "22ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:30 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "e05a873ad18c8df8c861577ab09beecd", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:30 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "K4Y2CbUgLk\u002BUsR67tajhaw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:32 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "7ee84ffaea401a9c802e911aaedf5e17", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:32 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "n2a8knIdiEyPDwoIFSitPA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "4ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:34 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "0c45889c93d715c502f6cc6b2ccabe79", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:34 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "yciFMfQChUyodDTiw3BJsA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:36 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "d8a86e8134b14f46ea3f5f5e40dedee9", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:36 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "SaLXhCVH00OXzynS4tjYEg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "5ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/search_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "27dd3f02e25667f589d27c491e31eeb6", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "Location": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "MS-CV": "2pVkKvXzfUWaxvJ7\u002BNO9tg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": "/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "search_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Search", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/searchResults/1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "3f99176f8537686642f521973366d524", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "MS-CV": "F8NuYEiAMkaRscbEKQ5lJQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "searchId": "1c469383-f782-4fa2-8290-9c36778313cd", + "phoneNumbers": [ + "Sanitized" + ], + "phoneNumberType": "TollFree", + "assignmentType": "Application", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + }, + "searchExpiresBy": "2021-02-26T08:00:30.7860590\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/availablePhoneNumbers/:purchase?api-version=2021-03-07", + "RequestMethod": "POST", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "51", + "Content-Type": "application/json", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "ec68e31796ed9f2378414fdeb7fc31b9", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "searchId": "1c469383-f782-4fa2-8290-9c36778313cd" + }, + "StatusCode": 202, + "ResponseHeaders": { + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "MS-CV": "aSYz6tIVuECSNTHzn7Po0Q.0", + "operation-id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "Operation-Location": "/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "purchase-id": "1c469383-f782-4fa2-8290-9c36778313cd", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "10ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:39 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "3b3158fc01c8d9c9f4fac6f53687b045", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:38 GMT", + "MS-CV": "zQ2ngQDhYECIHP78ec1ZqQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:41 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "894568c3ad7779df31eb1377b1c2de1a", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:40 GMT", + "MS-CV": "Ehtbp9BuOU6ZVzo3DsdtCA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:43 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "5fe12b0df5cb50f0e016334ad8bc4651", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:42 GMT", + "MS-CV": "zcvX6LRQ902\u002Bx1y8YXYjjw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:45 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "589d9fc4a9194fab79b80adced512732", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:44 GMT", + "MS-CV": "wViJ/XnInkS1M0VvC4h5Yg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/purchase_1c469383-f782-4fa2-8290-9c36778313cd?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:47 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "0ae7ac1b51a5cd7a77f5a9617994a074", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:46 GMT", + "MS-CV": "pBMKoHb6I0OI/7/SrBWCrw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:30.78606\u002B00:00", + "id": "purchase_1c469383-f782-4fa2-8290-9c36778313cd", + "operationType": "Purchase", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:47 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "12b2c2a5862464018092e513eb14628f", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:46 GMT", + "MS-CV": "vK1oV\u002B7jx0moYbqIUtE0tg.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "10ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/Sanitized/capabilities?api-version=2021-03-07", + "RequestMethod": "PATCH", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Content-Length": "52", + "Content-Type": "application/merge-patch\u002Bjson", + "Date": "Fri, 26 Feb 2021 07:45:47 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "2b2f01ee3bd573ab25cfe023004ad5e5", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "StatusCode": 202, + "ResponseHeaders": { + "capabilities-id": "2f43a5e9-1292-486b-8f00-f7d29f265f30", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:46 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "\u002B0N7/lKSKEuEfg9h7g65EQ.0", + "operation-id": "capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30", + "Operation-Location": "/phoneNumbers/operations/capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30?api-version=2021-03-07", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "18ms" + }, + "ResponseBody": { + "capabilitiesUpdateId": "2f43a5e9-1292-486b-8f00-f7d29f265f30" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:47 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "7872199375646a9f163eec55a5dd6335", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:46 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "Eor60d/fGEuyfJ7InnsXLQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "9ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:47.274365\u002B00:00", + "id": "capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:49 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "55fb00bd36ddd9f0f3998051b09808be", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:48 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "R5W5fH01WUex9\u002Bsipk9qKQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:47.274365\u002B00:00", + "id": "capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:51 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "e6907ced5cd7a280f6cc155f28b7efce", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:50 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "E6c9ZgrXXkerRsPkPJ6LYw.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "4ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:47.274365\u002B00:00", + "id": "capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:53 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "6a5654208c6b5c86299984caf54eb97e", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Access-Control-Expose-Headers": "Location", + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:52 GMT", + "Location": "/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "MS-CV": "g4XLI9bXwU\u002B8VqKpZopBsQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "3ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": "/phoneNumbers/Sanitized?api-version=2021-03-07", + "createdDateTime": "2021-02-26T07:45:47.274365\u002B00:00", + "id": "capabilities_2f43a5e9-1292-486b-8f00-f7d29f265f30", + "operationType": "UpdatePhoneNumberCapabilities", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/\u002BSanitized?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:53 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "29682e367c4c605e80595f102191b03c", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:52 GMT", + "MS-CV": "HKQhA49QhE\u002BelYXB2YXYMA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "4ms" + }, + "ResponseBody": { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:53 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "5b31b1aa9e416053f634bd3dd8b5ada7", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:52 GMT", + "MS-CV": "cuEvjCJJo0\u002BYyAE4cMQWWA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "9ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "outbound", + "sms": "inbound\u002Boutbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/Sanitized?api-version=2021-03-07", + "RequestMethod": "DELETE", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:53 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "f9299712c64fa381f6f6e9112c753b97", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 202, + "ResponseHeaders": { + "Content-Length": "0", + "Date": "Fri, 26 Feb 2021 07:45:52 GMT", + "MS-CV": "zQL4aLzaWk\u002BbueQiHOeBwA.0", + "operation-id": "release_59c132b3-545c-4292-89de-18f823fe8b8a", + "Operation-Location": "/phoneNumbers/operations/release_59c132b3-545c-4292-89de-18f823fe8b8a?api-version=2021-03-07", + "release-id": "59c132b3-545c-4292-89de-18f823fe8b8a", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "X-Processing-Time": "4ms" + }, + "ResponseBody": [] + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_59c132b3-545c-4292-89de-18f823fe8b8a?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:53 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "8afeb8acb668e4ed308d654bb5423480", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:52 GMT", + "MS-CV": "AZVPdh4PZ0qHjaEQ4Ep7ow.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "NotStarted", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:53.530853\u002B00:00", + "id": "release_59c132b3-545c-4292-89de-18f823fe8b8a", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_59c132b3-545c-4292-89de-18f823fe8b8a?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:55 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "8f5526f86994b48b5a911f479368e5d5", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:54 GMT", + "MS-CV": "pZ5DOTTTqEKqbb6UrOtxuQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:53.530853\u002B00:00", + "id": "release_59c132b3-545c-4292-89de-18f823fe8b8a", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_59c132b3-545c-4292-89de-18f823fe8b8a?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:57 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "74641e6eb177312f5b3c128ff8f0e298", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:56 GMT", + "MS-CV": "oS2hrST0E0C8yDdN1CGjgA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Running", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:53.530853\u002B00:00", + "id": "release_59c132b3-545c-4292-89de-18f823fe8b8a", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers/operations/release_59c132b3-545c-4292-89de-18f823fe8b8a?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:59 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "9820b2d3f8cb42362c492fd697a651c8", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:59 GMT", + "MS-CV": "UYNj90xpDE6sSQbpQQFEXA.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "2ms" + }, + "ResponseBody": { + "status": "Succeeded", + "resourceLocation": null, + "createdDateTime": "2021-02-26T07:45:53.530853\u002B00:00", + "id": "release_59c132b3-545c-4292-89de-18f823fe8b8a", + "operationType": "ReleasePhoneNumber", + "lastActionDateTime": "0001-01-01T00:00:00\u002B00:00" + } + }, + { + "RequestUri": "https://live-testing.communication.azure.com/phoneNumbers?api-version=2021-03-07", + "RequestMethod": "GET", + "RequestHeaders": { + "Accept": "application/json", + "Authorization": "Sanitized", + "Date": "Fri, 26 Feb 2021 07:45:59 GMT", + "User-Agent": [ + "azsdk-net-Communication.PhoneNumbers/1.0.0-alpha.20210225.1", + "(.NET 5.0.3; Microsoft Windows 10.0.19042)" + ], + "x-ms-client-request-id": "96dd90a8bfdd4709f623345857fcbc6a", + "x-ms-content-sha256": "Sanitized", + "x-ms-return-client-request-id": "true" + }, + "RequestBody": null, + "StatusCode": 200, + "ResponseHeaders": { + "Content-Type": "application/json; charset=utf-8", + "Date": "Fri, 26 Feb 2021 07:45:59 GMT", + "MS-CV": "JlIsl3k7Sk2drTByTI77EQ.0", + "Server": "Kestrel", + "Strict-Transport-Security": "max-age=2592000", + "Transfer-Encoding": "chunked", + "X-Processing-Time": "11ms" + }, + "ResponseBody": { + "phoneNumbers": [ + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + }, + { + "id": "Sanitized", + "phoneNumber": "Sanitized", + "countryCode": "US", + "phoneNumberType": "TollFree", + "capabilities": { + "calling": "none", + "sms": "outbound" + }, + "assignmentType": "Application", + "purchaseDate": "0001-01-01T00:00:00\u002B00:00", + "cost": { + "amount": 0.0, + "currencyCode": "USD", + "billingFrequency": "Monthly" + } + } + ] + } + } + ], + "Variables": { + "COMMUNICATION_CONNECTION_STRING": "endpoint=https://live-testing.communication.azure.com/;accesskey=Kg==", + "RandomSeed": "1498271171" + } +} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample2_PhoneNumberAdministrationClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample2_PhoneNumberAdministrationClient.cs deleted file mode 100644 index 7b0fd7fda7869..0000000000000 --- a/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample2_PhoneNumberAdministrationClient.cs +++ /dev/null @@ -1,518 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; -using System.Linq; -using System.Text; -using System.Threading; -using System.Threading.Tasks; -using Azure.Communication.PhoneNumbers.Models; -using Azure.Communication.PhoneNumbers.Tests; -using Azure.Core; -using Azure.Core.TestFramework; -using Azure.Identity; -using NUnit.Framework; - -namespace Azure.Communication.PhoneNumbers.Samples -{ - /// - /// Basic Azure Communication Administration samples. - /// - public class Sample2_PhoneNumberAdministrationClient : PhoneNumberAdministrationClientLiveTestBase - { - public Sample2_PhoneNumberAdministrationClient(bool isAsync) : base(isAsync) - { - } - - [Test] - public async Task CreatePhoneNumberWithTokenCredential() - { - var endpoint = ConnectionString.Parse(TestEnvironment.ConnectionString, allowEmptyValues: true).GetRequired("endpoint"); - #region Snippet:CreatePhoneNumberWithTokenCredential - //@@var endpoint = ""; - TokenCredential tokenCredential = new DefaultAzureCredential(); - var client = new PhoneNumberAdministrationClient(new Uri(endpoint), tokenCredential); - #endregion Snippet:CreatePhoneNumberWithTokenCredential - - tokenCredential = (Mode == RecordedTestMode.Playback) ? new MockCredential() : new DefaultAzureCredential(); - client = CreateClientWithTokenCredential(tokenCredential); - try - { - // Smoke test to ensure that client generated from token is able to work as expected. - var numbersPagable = client.GetAllPhoneNumbersAsync(); - var numbers = await numbersPagable.ToEnumerableAsync(); - - Assert.IsNotNull(numbers); - } - catch (Exception ex) - { - Assert.Fail($"Unexpected error: {ex}"); - } - } - - [Test] - [AsyncOnly] - public async Task PurchaseAndReleaseAsync() - { - if (!IncludePhoneNumberLiveTests) - Assert.Ignore("Include phone number live tests flag is off."); - - const string locale = "en-US"; - var connectionString = TestEnvironment.ConnectionString; - var client = CreateClient(false); - - const string countryCode = "US"; - - #region Snippet:GetPhonePlanGroupsAsync - var phonePlanGroups = client.GetPhonePlanGroupsAsync(countryCode, locale); - - await foreach (var phonePlanGroup in phonePlanGroups) - { - Console.WriteLine($"Plan group: {phonePlanGroup.LocalizedName}, type: {phonePlanGroup.PhoneNumberType}"); - } - #endregion Snippet:GetPhonePlanGroupsAsync - - var phonePlanGroupsList = await phonePlanGroups.ToEnumerableAsync(); - string phonePlanGroupId = phonePlanGroupsList.First(group => group.PhoneNumberType == PhoneNumberType.TollFree).PhonePlanGroupId; - - #region Snippet:GetPhonePlansAsync - var phonePlans = client.GetPhonePlansAsync(countryCode, phonePlanGroupId, locale); - await foreach (var phonePlan in phonePlans) - { - Console.WriteLine($"Plan: {phonePlan.LocalizedName}, {phonePlan.LocationType}"); - } - #endregion Snippet:GetPhonePlansAsync - - var firstphonePlan = (await phonePlans.ToEnumerableAsync()).First(); - var areaCode = firstphonePlan.AreaCodes.First(); - var phonePlanId = firstphonePlan.PhonePlanId; - - #region Snippet:ReservePhoneNumbersAsync - var reservationName = "My reservation"; - var reservationDescription = "reservation description"; - var reservationOptions = new CreateReservationOptions(reservationName, reservationDescription, new[] { phonePlanId }, areaCode); - reservationOptions.Quantity = 1; - - var reserveOperation = await client.StartReservationAsync(reservationOptions); - //@@ await reserveOperation.WaitForCompletionAsync(); - /*@@*/ await WaitForCompletionAsync(reserveOperation); - #endregion Snippet:ReservePhoneNumbersAsync - - reserveOperation = new PhoneNumberReservationOperation(client, reserveOperation.Id); - - #region Snippet:PersistReservePhoneNumbersOperationAsync - var reservationId = reserveOperation.Id; - - // persist reservationId and then continue with a new operation - - //@@var reserveOperation = new PhoneNumberReservationOperation(client, reservationId); - //@@ await reserveOperation.WaitForCompletionAsync(); - /*@@*/ await WaitForCompletionAsync(reserveOperation); - - #endregion Snippet:PersistReservePhoneNumbersOperationAsync - - #region Snippet:StartPurchaseReservationAsync - var purchaseOperation = await client.StartPurchaseReservationAsync(reservationId); - //@@ await purchaseOperation.WaitForCompletionAsync(); - /*@@*/ await WaitForCompletionAsync(purchaseOperation); - #endregion Snippet:StartPurchaseReservationAsync - - #region Snippet:ListAcquiredPhoneNumbersAsync - var acquiredPhoneNumbers = client.GetAllPhoneNumbersAsync(locale); - - await foreach (var phoneNumber in acquiredPhoneNumbers) - { - Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, activation state: {phoneNumber.ActivationState}"); - } - #endregion Snippet:ListAcquiredPhoneNumbersAsync - - var acquiredPhoneNumber = reserveOperation.Value.PhoneNumbers.Single(); - acquiredPhoneNumbers = client.GetAllPhoneNumbersAsync(locale); - var beforeReleaseNumberCount = (await acquiredPhoneNumbers.ToEnumerableAsync()).Count; - - #region Snippet:ReleasePhoneNumbersAsync - //@@var acquiredPhoneNumber = ""; - var releaseOperation = client.StartReleasePhoneNumber(new PhoneNumberIdentifier(acquiredPhoneNumber)); - //@@ await releaseOperation.WaitForCompletionAsync(); - /*@@*/ await WaitForCompletionAsync(releaseOperation); - #endregion Snippet:ReleasePhoneNumbersAsync - - acquiredPhoneNumbers = client.GetAllPhoneNumbersAsync(locale); - var afterReleaseNumberCount = (await acquiredPhoneNumbers.ToEnumerableAsync()).Count; - Assert.AreEqual(1, beforeReleaseNumberCount - afterReleaseNumberCount); - } - - private ValueTask> WaitForCompletionAsync(Operation operation) where T : notnull - => operation.WaitForCompletionAsync(TestEnvironment.Mode == RecordedTestMode.Playback ? TimeSpan.Zero: TimeSpan.FromSeconds(2), default); - - [Test] - [SyncOnly] - public void PurchaseAndRelease() - { - if (!IncludePhoneNumberLiveTests) - Assert.Ignore("Include phone number live tests flag is off."); - - const string locale = "en-US"; - var connectionString = TestEnvironment.ConnectionString; - - #region Snippet:CreatePhoneNumberAdministrationClient - // Get a connection string to our Azure Communication resource. - //@@var connectionString = ""; - var client = new PhoneNumberAdministrationClient(connectionString); - #endregion Snippet:CreatePhoneNumberAdministrationClient - - client = CreateClient(false); - - const string countryCode = "US"; - - #region Snippet:GetPhonePlanGroups - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - - foreach (var phonePlanGroup in phonePlanGroups) - { - Console.WriteLine($"Plan group: {phonePlanGroup.LocalizedName}, type: {phonePlanGroup.PhoneNumberType}"); - } - #endregion Snippet:GetPhonePlanGroups - - var tollFreePhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree); - var phonePlanGroupId = tollFreePhonePlanGroup.PhonePlanGroupId; - - #region Snippet:GetPhonePlans - var phonePlans = client.GetPhonePlans(countryCode, phonePlanGroupId, locale); - foreach (var phonePlan in phonePlans) - { - Console.WriteLine($"Plan: {phonePlan.LocalizedName}, {phonePlan.LocationType}"); - } - #endregion Snippet:GetPhonePlans - - var tollFreePhonePlan = phonePlans.First(); - var phonePlanId = tollFreePhonePlan.PhonePlanId; - var areaCode = tollFreePhonePlan.AreaCodes.First(); - - #region Snippet:ReservePhoneNumbers - var reservationName = "My reservation"; - var reservationDescription = "reservation description"; - var reservationOptions = new CreateReservationOptions(reservationName, reservationDescription, new[] { phonePlanId }, areaCode); - reservationOptions.Quantity = 1; - - var reserveOperation = client.StartReservation(reservationOptions); - - while (!reserveOperation.HasCompleted) - { - //@@ Thread.Sleep(2000); - /*@@*/ SleepIfNotInPlaybackMode(); - - reserveOperation.UpdateStatus(); - } - - #endregion Snippet:ReservePhoneNumbers - - reserveOperation = new PhoneNumberReservationOperation(client, reserveOperation.Id); - - #region Snippet:PersistReservePhoneNumbersOperation - var reservationId = reserveOperation.Id; - - // persist reservationId and then continue with a new operation - - //@@var reserveOperation = new PhoneNumberReservationOperation(client, reservationId); - - while (!reserveOperation.HasCompleted) - { - //@@ Thread.Sleep(2000); - /*@@*/ SleepIfNotInPlaybackMode(); - - reserveOperation.UpdateStatus(); - } - #endregion Snippet:PersistReservePhoneNumbersOperation - - #region Snippet:StartPurchaseReservation - var purchaseOperation = client.StartPurchaseReservation(reservationId); - - while (!purchaseOperation.HasCompleted) - { - //@@ Thread.Sleep(2000); - /*@@*/ SleepIfNotInPlaybackMode(); - - purchaseOperation.UpdateStatus(); - } - #endregion Snippet:StartPurchaseReservation - - #region Snippet:ListAcquiredPhoneNumbers - var acquiredPhoneNumbers = client.GetAllPhoneNumbers(locale); - - foreach (var phoneNumber in acquiredPhoneNumbers) - { - Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, activation state: {phoneNumber.ActivationState}"); - } - #endregion Snippet:ListAcquiredPhoneNumbers - - var acquiredPhoneNumber = reserveOperation.Value.PhoneNumbers.Single(); - acquiredPhoneNumbers = client.GetAllPhoneNumbers(locale); - var beforeReleaseNumberCount = acquiredPhoneNumbers.Count(); - - #region Snippet:ReleasePhoneNumbers - //@@var acquiredPhoneNumber = ""; - var releaseOperation = client.StartReleasePhoneNumber(new PhoneNumberIdentifier(acquiredPhoneNumber)); - - while (!releaseOperation.HasCompleted) - { - //@@ Thread.Sleep(2000); - /*@@*/ SleepIfNotInPlaybackMode(); - - releaseOperation.UpdateStatus(); - } - #endregion Snippet:ReleasePhoneNumbers - - acquiredPhoneNumbers = client.GetAllPhoneNumbers(locale); - var afterReleaseNumberCount = acquiredPhoneNumbers.Count(); - Assert.AreEqual(1, beforeReleaseNumberCount - afterReleaseNumberCount); - } - - private void SleepIfNotInPlaybackMode() - { - if (TestEnvironment.Mode != RecordedTestMode.Playback) - Thread.Sleep(2000); - } - - [Test] - [SyncOnly] - public void GetAllSupportedCountries() - { - var client = CreateClient(false); - const string locale = "en-US"; - - #region Snippet:GetAllSupportedCountries - var supportedCountries = client.GetAllSupportedCountries(locale); - foreach (var country in supportedCountries) - { - Console.WriteLine($"Supported country code: {country.CountryCode}, name: {country.LocalizedName}"); - } - #endregion Snippet:GetAllSupportedCountries - } - - [Test] - [AsyncOnly] - public async Task GetAllSupportedCountriesAsync() - { - var client = CreateClient(false); - const string locale = "en-US"; - - #region Snippet:GetAllSupportedCountriesAsync - var supportedCountries = client.GetAllSupportedCountriesAsync(locale); - await foreach (var country in supportedCountries) - { - Console.WriteLine($"Supported country code: {country.CountryCode}, name: {country.LocalizedName}"); - } - #endregion Snippet:GetAllSupportedCountriesAsync - } - - [Test] - [SyncOnly] - public void GetPhonePlanLocationOptions() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var geographicPhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - - var phonePlans = client.GetPhonePlans(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, locale); - var phonePlanId = phonePlans.First().PhonePlanId; - - #region Snippet:GetPhonePlanLocationOptions - - var locationOptionsResponse = client.GetPhonePlanLocationOptions(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, phonePlanId); - - void PrintLocationOption(LocationOptions locationOptions) - { - Console.WriteLine($"LabelId: {locationOptions.LabelId}, LabelName: {locationOptions.LabelName}"); - - foreach (var locationOption in locationOptions.Options) - { - Console.WriteLine($"Name: {locationOption.Name}, Value: {locationOption.Value}"); - - foreach (var subLocationOption in locationOption.LocationOptions) - PrintLocationOption(subLocationOption); - } - } - PrintLocationOption(locationOptionsResponse.Value.LocationOptions); - - #endregion Snippet:GetPhonePlanLocationOptions - } - - [Test] - [AsyncOnly] - public async Task GetPhonePlanLocationOptionsAsync() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var geographicPhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - - var phonePlans = client.GetPhonePlans(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, locale); - var phonePlanId = phonePlans.First().PhonePlanId; - var geographicPhonePlanGroupId = geographicPhonePlanGroup.PhonePlanGroupId; - - #region Snippet:GetPhonePlanLocationOptionsAsync - - var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, geographicPhonePlanGroupId, phonePlanId); - - void PrintLocationOption(LocationOptions locationOptions) - { - Console.WriteLine($"LabelId: {locationOptions.LabelId}, LabelName: {locationOptions.LabelName}"); - - foreach (var locationOption in locationOptions.Options) - { - Console.WriteLine($"Name: {locationOption.Name}, Value: {locationOption.Value}"); - - foreach (var subLocationOption in locationOption.LocationOptions) - PrintLocationOption(subLocationOption); - } - } - PrintLocationOption(locationOptionsResponse.Value.LocationOptions); - - #endregion Snippet:GetPhonePlanLocationOptionsAsync - } - - [Test] - [SyncOnly] - public void GeographicalAreaCodes() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var geographicPhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - - var phonePlans = client.GetPhonePlans(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, locale); - var geographicPhonePlan = phonePlans.First(); - var geographicPhonePlanGroupId = geographicPhonePlanGroup.PhonePlanGroupId; - var geographicPhonePlanId = geographicPhonePlan.PhonePlanId; - - #region Snippet:GeographicalAreaCodes - var locationOptionsResponse = client.GetPhonePlanLocationOptions(countryCode, geographicPhonePlanGroupId, geographicPhonePlanId); - var state = locationOptionsResponse.Value.LocationOptions.Options.First(); - - var locationOptionsQueries = new List - { - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = state.Value - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = state.LocationOptions.First().Options.First().Value - } - }; - - var areaCodes = client.GetAllAreaCodes(geographicPhonePlan.LocationType.ToString(), countryCode, geographicPhonePlan.PhonePlanId, locationOptionsQueries); - - foreach (var areaCode in areaCodes.Value.PrimaryAreaCodes) - { - Console.WriteLine($"Primary area code: {areaCode}"); - } - #endregion Snippet:GeographicalAreaCodes - } - - [Test] - [AsyncOnly] - public async Task GeographicalAreaCodesAsync() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var geographicPhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.Geographic); - - var phonePlans = client.GetPhonePlans(countryCode, geographicPhonePlanGroup.PhonePlanGroupId, locale); - var geographicPhonePlan = phonePlans.First(); - var geographicPhonePlanGroupId = geographicPhonePlanGroup.PhonePlanGroupId; - var geographicPhonePlanId = geographicPhonePlan.PhonePlanId; - - #region Snippet:GeographicalAreaCodesAsync - var locationOptionsResponse = await client.GetPhonePlanLocationOptionsAsync(countryCode, geographicPhonePlanGroupId, geographicPhonePlanId); - var state = locationOptionsResponse.Value.LocationOptions.Options.First(); - - var locationOptionsQueries = new List - { - new LocationOptionsQuery - { - LabelId = "state", - OptionsValue = state.Value - }, - new LocationOptionsQuery - { - LabelId = "city", - OptionsValue = state.LocationOptions.First().Options.First().Value - } - }; - - var areaCodes = await client.GetAllAreaCodesAsync(geographicPhonePlan.LocationType.ToString(), countryCode, geographicPhonePlan.PhonePlanId, locationOptionsQueries); - - foreach (var areaCode in areaCodes.Value.PrimaryAreaCodes) - { - Console.WriteLine($"Primary area code: {areaCode}"); - } - #endregion Snippet:GeographicalAreaCodesAsync - } - - [Test] - [SyncOnly] - [PlaybackOnly("TollFreeNumbersAreDisabledTemporarily")] - public void TollFreePlanAreaCodes() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var tollFreePhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree); - var tollFreePhonePlanGroupId = tollFreePhonePlanGroup.PhonePlanGroupId; - #region Snippet:TollFreePlanAreaCodes - - var phonePlans = client.GetPhonePlans(countryCode, tollFreePhonePlanGroupId, locale); - var tollFreePhonePlan = phonePlans.First(); - - foreach (var areaCode in tollFreePhonePlan.AreaCodes) - { - Console.WriteLine($"Area code: {areaCode}"); - } - - #endregion Snippet:TollFreePlanAreaCodes - } - - [Test] - [AsyncOnly] - [PlaybackOnly("TollFreeNumbersAreDisabledTemporarily")] - public async Task TollFreePlanAreaCodesAsync() - { - var client = CreateClient(false); - const string locale = "en-US"; - const string countryCode = "US"; - - var phonePlanGroups = client.GetPhonePlanGroups(countryCode, locale); - var tollFreePhonePlanGroup = phonePlanGroups.First(group => group.PhoneNumberType == PhoneNumberType.TollFree); - - #region Snippet:TollFreePlanAreaCodesAsync - - var phonePlans = client.GetPhonePlansAsync(countryCode, tollFreePhonePlanGroup.PhonePlanGroupId, locale); - var tollFreePhonePlan = (await phonePlans.ToEnumerableAsync()).First(); - - foreach (var areaCode in tollFreePhonePlan.AreaCodes) - { - Console.WriteLine($"Area code: {areaCode}"); - } - - #endregion Snippet:TollFreePlanAreaCodesAsync - } - } -} diff --git a/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample_PhoneNumbersClient.cs b/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample_PhoneNumbersClient.cs new file mode 100644 index 0000000000000..46a716b3f5dad --- /dev/null +++ b/sdk/communication/Azure.Communication.PhoneNumbers/tests/samples/Sample_PhoneNumbersClient.cs @@ -0,0 +1,205 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading; +using System.Threading.Tasks; +using Azure.Communication.PhoneNumbers; +using Azure.Communication.PhoneNumbers.Models; +using Azure.Communication.PhoneNumbers.Tests; +using Azure.Core; +using Azure.Core.TestFramework; +using Azure.Identity; +using NUnit.Framework; + +namespace Azure.Communication.PhoneNumbers.Tests.Samples +{ + /// + /// Basic Azure Communication Phone Numbers samples. + /// + public class Sample_PhoneNumbersClient : PhoneNumbersClientLiveTestBase + { + public Sample_PhoneNumbersClient(bool isAsync) : base(isAsync) + { + } + + [Test] + [AsyncOnly] + public async Task PurchaseAndReleaseAsync() + { + if (!IncludePhoneNumberLiveTests) + Assert.Ignore("Include phone number live tests flag is off."); + + var client = CreateClient(false); + + const string countryCode = "US"; + + #region Snippet:SearchPhoneNumbersAsync + + var capabilities = new PhoneNumberCapabilities(calling:PhoneNumberCapabilityType.None, sms:PhoneNumberCapabilityType.Outbound); + + var searchOperation = await client.StartSearchAvailablePhoneNumbersAsync(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Application, capabilities); + //@@ await searchOperation.WaitForCompletionAsync(); + /*@@*/ await WaitForCompletionAsync(searchOperation); + + #endregion Snippet:SearchPhoneNumbersAsync + + #region Snippet:StartPurchaseSearchAsync + + var purchaseOperation = await client.StartPurchasePhoneNumbersAsync(searchOperation.Value.SearchId); + //@@ await purchaseOperation.WaitForCompletionAsync(); + /*@@*/ await WaitForCompletionAsync(purchaseOperation); + + #endregion Snippet:StartPurchaseSearchAsync + + #region Snippet:ListAcquiredPhoneNumbersAsync + var acquiredPhoneNumbers = client.GetPhoneNumbersAsync(); + + await foreach (var phoneNumber in acquiredPhoneNumbers) + { + Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, monthly cost: {phoneNumber.Cost}"); + } + #endregion Snippet:ListAcquiredPhoneNumbersAsync + + var acquiredPhoneNumber = searchOperation.Value.PhoneNumbers.Single(); + + #region Snippet:UpdateCapabilitiesNumbersAsync + var updateCapabilitiesOperation = client.StartUpdateCapabilities(acquiredPhoneNumber, calling: PhoneNumberCapabilityType.Outbound, sms: PhoneNumberCapabilityType.InboundOutbound); + + //@@ await updateCapabilitiesOperation.WaitForCompletionAsync(); + /*@@*/ await WaitForCompletionAsync(updateCapabilitiesOperation); + + #endregion Snippet:UpdateCapabilitiesNumbersAsync + + Assert.AreEqual(PhoneNumberCapabilityType.Outbound, updateCapabilitiesOperation.Value.Capabilities.Calling); + Assert.AreEqual(PhoneNumberCapabilityType.InboundOutbound, updateCapabilitiesOperation.Value.Capabilities.Sms); + + acquiredPhoneNumbers = client.GetPhoneNumbersAsync(); + var beforeReleaseNumberCount = (await acquiredPhoneNumbers.ToEnumerableAsync()).Count; + + #region Snippet:ReleasePhoneNumbersAsync + + //@@var acquiredPhoneNumber = ""; + var releaseOperation = client.StartReleasePhoneNumber(acquiredPhoneNumber); + //@@ await releaseOperation.WaitForCompletionAsync(); + /*@@*/ await WaitForCompletionAsync(releaseOperation); + + #endregion Snippet:ReleasePhoneNumbersAsync + + acquiredPhoneNumbers = client.GetPhoneNumbersAsync(); + var afterReleaseNumberCount = (await acquiredPhoneNumbers.ToEnumerableAsync()).Count; + Assert.AreEqual(1, beforeReleaseNumberCount - afterReleaseNumberCount); + } + + private ValueTask> WaitForCompletionAsync(Operation operation) where T : notnull + => operation.WaitForCompletionAsync(TestEnvironment.Mode == RecordedTestMode.Playback ? TimeSpan.Zero : TimeSpan.FromSeconds(2), default); + + [Test] + [SyncOnly] + public void PurchaseAndRelease() + { + if (!IncludePhoneNumberLiveTests) + Assert.Ignore("Include phone number live tests flag is off."); + + var connectionString = TestEnvironment.ConnectionString; + + #region Snippet:CreatePhoneNumbersClient + // Get a connection string to our Azure Communication resource. + //@@var connectionString = ""; + var client = new PhoneNumbersClient(connectionString); + #endregion Snippet:CreatePhoneNumbersClient + + #region Snippet:CreatePhoneNumbersClientWithTokenCredential + // Get an endpoint to our Azure Communication resource. + //@@var endpoint = new Uri(""); + //@@TokenCredential tokenCredential = new DefaultAzureCredential(); + //@@client = new PhoneNumbersClient(endpoint, tokenCredential); + #endregion Snippet:CreatePhoneNumbersClientWithTokenCredential + + client = CreateClient(false); + + const string countryCode = "US"; + + #region Snippet:SearchPhoneNumbers + + var capabilities = new PhoneNumberCapabilities(calling:PhoneNumberCapabilityType.None, sms:PhoneNumberCapabilityType.Outbound); + + var searchOperation = client.StartSearchAvailablePhoneNumbers(countryCode, PhoneNumberType.TollFree, PhoneNumberAssignmentType.Application, capabilities); + + while (!searchOperation.HasCompleted) + { + //@@ Thread.Sleep(2000); + /*@@*/ SleepIfNotInPlaybackMode(); + searchOperation.UpdateStatus(); + } + + #endregion Snippet:SearchPhoneNumbers + + #region Snippet:StartPurchaseSearch + var purchaseOperation = client.StartPurchasePhoneNumbers(searchOperation.Value.SearchId); + + while (!purchaseOperation.HasCompleted) + { + //@@ Thread.Sleep(2000); + /*@@*/ SleepIfNotInPlaybackMode(); + purchaseOperation.UpdateStatus(); + } + #endregion Snippet:StartPurchaseSearch + + #region Snippet:ListAcquiredPhoneNumbers + var acquiredPhoneNumbers = client.GetPhoneNumbers(); + + foreach (var phoneNumber in acquiredPhoneNumbers) + { + Console.WriteLine($"Phone number: {phoneNumber.PhoneNumber}, monthly cost: {phoneNumber.Cost}"); + } + #endregion Snippet:ListAcquiredPhoneNumbers + + var acquiredPhoneNumber = searchOperation.Value.PhoneNumbers.Single(); + + #region Snippet:UpdateCapabilitiesNumbers + var updateCapabilitiesOperation = client.StartUpdateCapabilities(acquiredPhoneNumber, calling:PhoneNumberCapabilityType.Outbound, sms:PhoneNumberCapabilityType.InboundOutbound); + + while (!updateCapabilitiesOperation.HasCompleted) + { + //@@ Thread.Sleep(2000); + /*@@*/ SleepIfNotInPlaybackMode(); + updateCapabilitiesOperation.UpdateStatus(); + } + + #endregion Snippet:UpdateCapabilitiesNumbers + + Assert.AreEqual(PhoneNumberCapabilityType.Outbound, updateCapabilitiesOperation.Value.Capabilities.Calling); + Assert.AreEqual(PhoneNumberCapabilityType.InboundOutbound, updateCapabilitiesOperation.Value.Capabilities.Sms); + + acquiredPhoneNumbers = client.GetPhoneNumbers(); + var beforeReleaseNumberCount = acquiredPhoneNumbers.Count(); + + #region Snippet:ReleasePhoneNumbers + //@@var acquiredPhoneNumber = ""; + var releaseOperation = client.StartReleasePhoneNumber(acquiredPhoneNumber); + + while (!releaseOperation.HasCompleted) + { + //@@ Thread.Sleep(2000); + /*@@*/ SleepIfNotInPlaybackMode(); + releaseOperation.UpdateStatus(); + } + #endregion Snippet:ReleasePhoneNumbers + + acquiredPhoneNumbers = client.GetPhoneNumbers(); + var afterReleaseNumberCount = acquiredPhoneNumbers.Count(); + Assert.AreEqual(1, beforeReleaseNumberCount - afterReleaseNumberCount); + } + + private void SleepIfNotInPlaybackMode() + { + if (TestEnvironment.Mode != RecordedTestMode.Playback) + Thread.Sleep(2000); + } + } +}