import { PagedAsyncIterableIterator } from "@azure/core-paging" ; import { IotDpsResource } from "../operationsInterfaces" ; import * as coreClient from "@azure/core-client" ; import * as Mappers from "../models/mappers" ; import * as Parameters from "../models/parameters" ; import { DeviceProvisioningClient } from "../deviceProvisioningClient" ; import { PollerLike , PollOperationState , LroEngine } from "@azure/core-lro" ; import { LroImpl } from "../lroImpl" ; import { ProvisioningServiceDescription , IotDpsResourceListBySubscriptionNextOptionalParams , IotDpsResourceListBySubscriptionOptionalParams , IotDpsResourceListByResourceGroupNextOptionalParams , IotDpsResourceListByResourceGroupOptionalParams , IotDpsSkuDefinition , IotDpsResourceListValidSkusNextOptionalParams , IotDpsResourceListValidSkusOptionalParams , SharedAccessSignatureAuthorizationRuleAccessRightsDescription , IotDpsResourceListKeysNextOptionalParams , IotDpsResourceListKeysOptionalParams , IotDpsResourceGetOptionalParams , IotDpsResourceGetResponse , IotDpsResourceCreateOrUpdateOptionalParams , IotDpsResourceCreateOrUpdateResponse , TagsResource , IotDpsResourceUpdateOptionalParams , IotDpsResourceUpdateResponse , IotDpsResourceDeleteOptionalParams , IotDpsResourceListBySubscriptionResponse , IotDpsResourceListByResourceGroupResponse , IotDpsResourceGetOperationResultOptionalParams , IotDpsResourceGetOperationResultResponse , IotDpsResourceListValidSkusResponse , OperationInputs , IotDpsResourceCheckProvisioningServiceNameAvailabilityOptionalParams , IotDpsResourceCheckProvisioningServiceNameAvailabilityResponse , IotDpsResourceListKeysResponse , IotDpsResourceListKeysForKeyNameOptionalParams , IotDpsResourceListKeysForKeyNameResponse , IotDpsResourceListPrivateLinkResourcesOptionalParams , IotDpsResourceListPrivateLinkResourcesResponse , IotDpsResourceGetPrivateLinkResourcesOptionalParams , IotDpsResourceGetPrivateLinkResourcesResponse , IotDpsResourceListPrivateEndpointConnectionsOptionalParams , IotDpsResourceListPrivateEndpointConnectionsResponse , IotDpsResourceGetPrivateEndpointConnectionOptionalParams , IotDpsResourceGetPrivateEndpointConnectionResponse , PrivateEndpointConnection , IotDpsResourceCreateOrUpdatePrivateEndpointConnectionOptionalParams , IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse , IotDpsResourceDeletePrivateEndpointConnectionOptionalParams , IotDpsResourceDeletePrivateEndpointConnectionResponse , IotDpsResourceListBySubscriptionNextResponse , IotDpsResourceListByResourceGroupNextResponse , IotDpsResourceListValidSkusNextResponse , IotDpsResourceListKeysNextResponse } from "../models" ; /** Class containing IotDpsResource operations. */ export class IotDpsResourceImpl implements IotDpsResource { private readonly client : DeviceProvisioningClient ; param client constructor ( client ) { this . client = client ; } param options public listBySubscription ( options ? ) { const iter = this . listBySubscriptionPagingAll ( options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listBySubscriptionPagingPage ( options ) ; } } ; } private async * listBySubscriptionPagingPage ( options ? ) { let result = await this . _listBySubscription ( options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listBySubscriptionNext ( continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listBySubscriptionPagingAll ( options ? ) { for await ( const page of this . listBySubscriptionPagingPage ( options ) ) { yield * page ; } } param resourceGroupName param options public listByResourceGroup ( resourceGroupName , options ? ) { const iter = this . listByResourceGroupPagingAll ( resourceGroupName , options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listByResourceGroupPagingPage ( resourceGroupName , options ) ; } } ; } private async * listByResourceGroupPagingPage ( resourceGroupName , options ? ) { let result = await this . _listByResourceGroup ( resourceGroupName , options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listByResourceGroupNext ( resourceGroupName , continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listByResourceGroupPagingAll ( resourceGroupName , options ? ) { for await ( const page of this . listByResourceGroupPagingPage ( resourceGroupName , options ) ) { yield * page ; } } param provisioningServiceName param resourceGroupName param options public listValidSkus ( provisioningServiceName , resourceGroupName , options ? ) { const iter = this . listValidSkusPagingAll ( provisioningServiceName , resourceGroupName , options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listValidSkusPagingPage ( provisioningServiceName , resourceGroupName , options ) ; } } ; } private async * listValidSkusPagingPage ( provisioningServiceName , resourceGroupName , options ? ) { let result = await this . _listValidSkus ( provisioningServiceName , resourceGroupName , options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listValidSkusNext ( provisioningServiceName , resourceGroupName , continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listValidSkusPagingAll ( provisioningServiceName , resourceGroupName , options ? ) { for await ( const page of this . listValidSkusPagingPage ( provisioningServiceName , resourceGroupName , options ) ) { yield * page ; } } param provisioningServiceName param resourceGroupName param options public listKeys ( provisioningServiceName , resourceGroupName , options ? ) { const iter = this . listKeysPagingAll ( provisioningServiceName , resourceGroupName , options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listKeysPagingPage ( provisioningServiceName , resourceGroupName , options ) ; } } ; } private async * listKeysPagingPage ( provisioningServiceName , resourceGroupName , options ? ) { let result = await this . _listKeys ( provisioningServiceName , resourceGroupName , options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listKeysNext ( provisioningServiceName , resourceGroupName , continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listKeysPagingAll ( provisioningServiceName , resourceGroupName , options ? ) { for await ( const page of this . listKeysPagingPage ( provisioningServiceName , resourceGroupName , options ) ) { yield * page ; } } param provisioningServiceName param resourceGroupName param options get ( provisioningServiceName , resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , resourceGroupName , options } , getOperationSpec ) ; } param resourceGroupName param provisioningServiceName param iotDpsDescription param options async beginCreateOrUpdate ( resourceGroupName , provisioningServiceName , iotDpsDescription , options ? ) { const directSendOperation = async ( args , spec ) : Promise < IotDpsResourceCreateOrUpdateResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , provisioningServiceName , iotDpsDescription , options } , createOrUpdateOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param provisioningServiceName param iotDpsDescription param options async beginCreateOrUpdateAndWait ( resourceGroupName , provisioningServiceName , iotDpsDescription , options ? ) { const poller = await this . beginCreateOrUpdate ( resourceGroupName , provisioningServiceName , iotDpsDescription , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param provisioningServiceName param provisioningServiceTags param options async beginUpdate ( resourceGroupName , provisioningServiceName , provisioningServiceTags , options ? ) { const directSendOperation = async ( args , spec ) : Promise < IotDpsResourceUpdateResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , provisioningServiceName , provisioningServiceTags , options } , updateOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param provisioningServiceName param provisioningServiceTags param options async beginUpdateAndWait ( resourceGroupName , provisioningServiceName , provisioningServiceTags , options ? ) { const poller = await this . beginUpdate ( resourceGroupName , provisioningServiceName , provisioningServiceTags , options ) ; return poller . pollUntilDone ( ) ; } param provisioningServiceName param resourceGroupName param options async beginDelete ( provisioningServiceName , resourceGroupName , options ? ) { const directSendOperation = async ( args , spec ) : Promise < void > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { provisioningServiceName , resourceGroupName , options } , deleteOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param provisioningServiceName param resourceGroupName param options async beginDeleteAndWait ( provisioningServiceName , resourceGroupName , options ? ) { const poller = await this . beginDelete ( provisioningServiceName , resourceGroupName , options ) ; return poller . pollUntilDone ( ) ; } param options private _listBySubscription ( options ? ) { return this . client . sendOperationRequest ( { options } , listBySubscriptionOperationSpec ) ; } param resourceGroupName param options private _listByResourceGroup ( resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , options } , listByResourceGroupOperationSpec ) ; } param operationId param resourceGroupName param provisioningServiceName param asyncinfo param options getOperationResult ( operationId , resourceGroupName , provisioningServiceName , asyncinfo , options ? ) { return this . client . sendOperationRequest ( { operationId , resourceGroupName , provisioningServiceName , asyncinfo , options } , getOperationResultOperationSpec ) ; } param provisioningServiceName param resourceGroupName param options private _listValidSkus ( provisioningServiceName , resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , resourceGroupName , options } , listValidSkusOperationSpec ) ; } param argumentsParam param options checkProvisioningServiceNameAvailability ( argumentsParam , options ? ) { return this . client . sendOperationRequest ( { argumentsParam , options } , checkProvisioningServiceNameAvailabilityOperationSpec ) ; } param provisioningServiceName param resourceGroupName param options private _listKeys ( provisioningServiceName , resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , resourceGroupName , options } , listKeysOperationSpec ) ; } param provisioningServiceName param keyName param resourceGroupName param options listKeysForKeyName ( provisioningServiceName , keyName , resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , keyName , resourceGroupName , options } , listKeysForKeyNameOperationSpec ) ; } param resourceGroupName param resourceName param options listPrivateLinkResources ( resourceGroupName , resourceName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceName , options } , listPrivateLinkResourcesOperationSpec ) ; } param resourceGroupName param resourceName param groupId param options getPrivateLinkResources ( resourceGroupName , resourceName , groupId , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceName , groupId , options } , getPrivateLinkResourcesOperationSpec ) ; } param resourceGroupName param resourceName param options listPrivateEndpointConnections ( resourceGroupName , resourceName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceName , options } , listPrivateEndpointConnectionsOperationSpec ) ; } param resourceGroupName param resourceName param privateEndpointConnectionName param options getPrivateEndpointConnection ( resourceGroupName , resourceName , privateEndpointConnectionName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceName , privateEndpointConnectionName , options } , getPrivateEndpointConnectionOperationSpec ) ; } param resourceGroupName param resourceName param privateEndpointConnectionName param privateEndpointConnection param options async beginCreateOrUpdatePrivateEndpointConnection ( resourceGroupName , resourceName , privateEndpointConnectionName , privateEndpointConnection , options ? ) { const directSendOperation = async ( args , spec ) : Promise < IotDpsResourceCreateOrUpdatePrivateEndpointConnectionResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , resourceName , privateEndpointConnectionName , privateEndpointConnection , options } , createOrUpdatePrivateEndpointConnectionOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param resourceName param privateEndpointConnectionName param privateEndpointConnection param options async beginCreateOrUpdatePrivateEndpointConnectionAndWait ( resourceGroupName , resourceName , privateEndpointConnectionName , privateEndpointConnection , options ? ) { const poller = await this . beginCreateOrUpdatePrivateEndpointConnection ( resourceGroupName , resourceName , privateEndpointConnectionName , privateEndpointConnection , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param resourceName param privateEndpointConnectionName param options async beginDeletePrivateEndpointConnection ( resourceGroupName , resourceName , privateEndpointConnectionName , options ? ) { const directSendOperation = async ( args , spec ) : Promise < IotDpsResourceDeletePrivateEndpointConnectionResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , resourceName , privateEndpointConnectionName , options } , deletePrivateEndpointConnectionOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param resourceName param privateEndpointConnectionName param options async beginDeletePrivateEndpointConnectionAndWait ( resourceGroupName , resourceName , privateEndpointConnectionName , options ? ) { const poller = await this . beginDeletePrivateEndpointConnection ( resourceGroupName , resourceName , privateEndpointConnectionName , options ) ; return poller . pollUntilDone ( ) ; } param nextLink param options private _listBySubscriptionNext ( nextLink , options ? ) { return this . client . sendOperationRequest ( { nextLink , options } , listBySubscriptionNextOperationSpec ) ; } param resourceGroupName param nextLink param options private _listByResourceGroupNext ( resourceGroupName , nextLink , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , nextLink , options } , listByResourceGroupNextOperationSpec ) ; } param provisioningServiceName param resourceGroupName param nextLink param options private _listValidSkusNext ( provisioningServiceName , resourceGroupName , nextLink , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , resourceGroupName , nextLink , options } , listValidSkusNextOperationSpec ) ; } param provisioningServiceName param resourceGroupName param nextLink param options private _listKeysNext ( provisioningServiceName , resourceGroupName , nextLink , options ? ) { return this . client . sendOperationRequest ( { provisioningServiceName , resourceGroupName , nextLink , options } , listKeysNextOperationSpec ) ; } } const serializer = coreClient . createSerializer ( Mappers , false ) ; const getOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescription } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const createOrUpdateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}" , httpMethod : "PUT" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 201 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 202 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 204 : { bodyMapper : Mappers . ProvisioningServiceDescription } , default : { bodyMapper : Mappers . ErrorDetails } } , requestBody : Parameters . iotDpsDescription , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const updateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}" , httpMethod : "PATCH" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 201 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 202 : { bodyMapper : Mappers . ProvisioningServiceDescription } , 204 : { bodyMapper : Mappers . ProvisioningServiceDescription } } , requestBody : Parameters . provisioningServiceTags , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const deleteOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}" , httpMethod : "DELETE" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listBySubscriptionOperationSpec = { path : "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/provisioningServices" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescriptionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId ] , headerParameters : [ Parameters . accept ] , serializer } ; const listByResourceGroupOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescriptionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getOperationResultOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/operationresults/{operationId}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . AsyncOperationResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion , Parameters . asyncinfo ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName , Parameters . operationId ] , headerParameters : [ Parameters . accept ] , serializer } ; const listValidSkusOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/skus" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IotDpsSkuDefinitionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const checkProvisioningServiceNameAvailabilityOperationSpec = { path : "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/checkProvisioningServiceNameAvailability" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . NameAvailabilityInfo } , default : { bodyMapper : Mappers . ErrorDetails } } , requestBody : Parameters . argumentsParam , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const listKeysOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/listkeys" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . SharedAccessSignatureAuthorizationRuleListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listKeysForKeyNameOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}/keys/{keyName}/listkeys" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . SharedAccessSignatureAuthorizationRuleAccessRightsDescription } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName , Parameters . keyName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listPrivateLinkResourcesOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . PrivateLinkResources } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getPrivateLinkResourcesOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateLinkResources/{groupId}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . GroupIdInformation } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName , Parameters . groupId ] , headerParameters : [ Parameters . accept ] , serializer } ; const listPrivateEndpointConnectionsOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections" , httpMethod : "GET" , responses : { 200 : { bodyMapper : { type : { name : "Sequence" , element : { type : { name : "Composite" , className : "PrivateEndpointConnection" } } } } } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getPrivateEndpointConnectionOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . PrivateEndpointConnection } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName , Parameters . privateEndpointConnectionName ] , headerParameters : [ Parameters . accept ] , serializer } ; const createOrUpdatePrivateEndpointConnectionOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}" , httpMethod : "PUT" , responses : { 200 : { bodyMapper : Mappers . PrivateEndpointConnection } , 201 : { bodyMapper : Mappers . PrivateEndpointConnection } , 202 : { bodyMapper : Mappers . PrivateEndpointConnection } , 204 : { bodyMapper : Mappers . PrivateEndpointConnection } , default : { bodyMapper : Mappers . ErrorDetails } } , requestBody : Parameters . privateEndpointConnection , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName , Parameters . privateEndpointConnectionName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const deletePrivateEndpointConnectionOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}" , httpMethod : "DELETE" , responses : { 200 : { bodyMapper : Mappers . PrivateEndpointConnection } , 201 : { bodyMapper : Mappers . PrivateEndpointConnection } , 202 : { bodyMapper : Mappers . PrivateEndpointConnection } , 204 : { bodyMapper : Mappers . PrivateEndpointConnection } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceName , Parameters . privateEndpointConnectionName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listBySubscriptionNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescriptionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId ] , headerParameters : [ Parameters . accept ] , serializer } ; const listByResourceGroupNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ProvisioningServiceDescriptionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId , Parameters . resourceGroupName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listValidSkusNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IotDpsSkuDefinitionListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listKeysNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . SharedAccessSignatureAuthorizationRuleListResult } , default : { bodyMapper : Mappers . ErrorDetails } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . provisioningServiceName ] , headerParameters : [ Parameters . accept ] , serializer } ;