import { PagedAsyncIterableIterator } from "@azure/core-paging" ; import { IntegrationRuntimes } from "../operationsInterfaces" ; import * as coreClient from "@azure/core-client" ; import * as Mappers from "../models/mappers" ; import * as Parameters from "../models/parameters" ; import { DataFactoryClient } from "../dataFactoryClient" ; import { PollerLike , PollOperationState , LroEngine } from "@azure/core-lro" ; import { LroImpl } from "../lroImpl" ; import { IntegrationRuntimeResource , IntegrationRuntimesListByFactoryNextOptionalParams , IntegrationRuntimesListByFactoryOptionalParams , IntegrationRuntimesListByFactoryResponse , IntegrationRuntimesCreateOrUpdateOptionalParams , IntegrationRuntimesCreateOrUpdateResponse , IntegrationRuntimesGetOptionalParams , IntegrationRuntimesGetResponse , UpdateIntegrationRuntimeRequest , IntegrationRuntimesUpdateOptionalParams , IntegrationRuntimesUpdateResponse , IntegrationRuntimesDeleteOptionalParams , IntegrationRuntimesGetStatusOptionalParams , IntegrationRuntimesGetStatusResponse , IntegrationRuntimesListOutboundNetworkDependenciesEndpointsOptionalParams , IntegrationRuntimesListOutboundNetworkDependenciesEndpointsResponse , IntegrationRuntimesGetConnectionInfoOptionalParams , IntegrationRuntimesGetConnectionInfoResponse , IntegrationRuntimeRegenerateKeyParameters , IntegrationRuntimesRegenerateAuthKeyOptionalParams , IntegrationRuntimesRegenerateAuthKeyResponse , IntegrationRuntimesListAuthKeysOptionalParams , IntegrationRuntimesListAuthKeysResponse , IntegrationRuntimesStartOptionalParams , IntegrationRuntimesStartResponse , IntegrationRuntimesStopOptionalParams , IntegrationRuntimesSyncCredentialsOptionalParams , IntegrationRuntimesGetMonitoringDataOptionalParams , IntegrationRuntimesGetMonitoringDataResponse , IntegrationRuntimesUpgradeOptionalParams , LinkedIntegrationRuntimeRequest , IntegrationRuntimesRemoveLinksOptionalParams , CreateLinkedIntegrationRuntimeRequest , IntegrationRuntimesCreateLinkedIntegrationRuntimeOptionalParams , IntegrationRuntimesCreateLinkedIntegrationRuntimeResponse , IntegrationRuntimesListByFactoryNextResponse } from "../models" ; /** Class containing IntegrationRuntimes operations. */ export class IntegrationRuntimesImpl implements IntegrationRuntimes { private readonly client : DataFactoryClient ; param client constructor ( client ) { this . client = client ; } param resourceGroupName param factoryName param options public listByFactory ( resourceGroupName , factoryName , options ? ) { const iter = this . listByFactoryPagingAll ( resourceGroupName , factoryName , options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listByFactoryPagingPage ( resourceGroupName , factoryName , options ) ; } } ; } private async * listByFactoryPagingPage ( resourceGroupName , factoryName , options ? ) { let result = await this . _listByFactory ( resourceGroupName , factoryName , options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listByFactoryNext ( resourceGroupName , factoryName , continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listByFactoryPagingAll ( resourceGroupName , factoryName , options ? ) { for await ( const page of this . listByFactoryPagingPage ( resourceGroupName , factoryName , options ) ) { yield * page ; } } param resourceGroupName param factoryName param options private _listByFactory ( resourceGroupName , factoryName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , options } , listByFactoryOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param integrationRuntime param options createOrUpdate ( resourceGroupName , factoryName , integrationRuntimeName , integrationRuntime , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , integrationRuntime , options } , createOrUpdateOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options get ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , getOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param updateIntegrationRuntimeRequest param options update ( resourceGroupName , factoryName , integrationRuntimeName , updateIntegrationRuntimeRequest , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , updateIntegrationRuntimeRequest , options } , updateOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options delete ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , deleteOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options getStatus ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , getStatusOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options listOutboundNetworkDependenciesEndpoints ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , listOutboundNetworkDependenciesEndpointsOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options getConnectionInfo ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , getConnectionInfoOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param regenerateKeyParameters param options regenerateAuthKey ( resourceGroupName , factoryName , integrationRuntimeName , regenerateKeyParameters , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , regenerateKeyParameters , options } , regenerateAuthKeyOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options listAuthKeys ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , listAuthKeysOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options async beginStart ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { const directSendOperation = async ( args , spec ) : Promise < IntegrationRuntimesStartResponse > => { 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 , factoryName , integrationRuntimeName , options } , startOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options async beginStartAndWait ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { const poller = await this . beginStart ( resourceGroupName , factoryName , integrationRuntimeName , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options async beginStop ( resourceGroupName , factoryName , integrationRuntimeName , 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 , { resourceGroupName , factoryName , integrationRuntimeName , options } , stopOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options async beginStopAndWait ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { const poller = await this . beginStop ( resourceGroupName , factoryName , integrationRuntimeName , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options syncCredentials ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , syncCredentialsOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options getMonitoringData ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , getMonitoringDataOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param options upgrade ( resourceGroupName , factoryName , integrationRuntimeName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , options } , upgradeOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param linkedIntegrationRuntimeRequest param options removeLinks ( resourceGroupName , factoryName , integrationRuntimeName , linkedIntegrationRuntimeRequest , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , linkedIntegrationRuntimeRequest , options } , removeLinksOperationSpec ) ; } param resourceGroupName param factoryName param integrationRuntimeName param createLinkedIntegrationRuntimeRequest param options createLinkedIntegrationRuntime ( resourceGroupName , factoryName , integrationRuntimeName , createLinkedIntegrationRuntimeRequest , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , integrationRuntimeName , createLinkedIntegrationRuntimeRequest , options } , createLinkedIntegrationRuntimeOperationSpec ) ; } param resourceGroupName param factoryName param nextLink param options private _listByFactoryNext ( resourceGroupName , factoryName , nextLink , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , factoryName , nextLink , options } , listByFactoryNextOperationSpec ) ; } } const serializer = coreClient . createSerializer ( Mappers , false ) ; const listByFactoryOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeListResponse } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName ] , headerParameters : [ Parameters . accept ] , serializer } ; const createOrUpdateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}" , httpMethod : "PUT" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . integrationRuntime , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . contentType , Parameters . ifMatch ] , mediaType : "json" , serializer } ; const getOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeResource } , 304 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . ifNoneMatch ] , serializer } ; const updateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}" , httpMethod : "PATCH" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . updateIntegrationRuntimeRequest , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const deleteOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}" , httpMethod : "DELETE" , responses : { 200 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getStatusOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/getStatus" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listOutboundNetworkDependenciesEndpointsOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/outboundNetworkDependenciesEndpoints" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeOutboundNetworkDependenciesEndpointsResponse } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getConnectionInfoOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/getConnectionInfo" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeConnectionInfo } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const regenerateAuthKeyOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/regenerateAuthKey" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeAuthKeys } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . regenerateKeyParameters , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const listAuthKeysOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/listAuthKeys" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeAuthKeys } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const startOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/start" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , 201 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , 202 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , 204 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const stopOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/stop" , httpMethod : "POST" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const syncCredentialsOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/syncCredentials" , httpMethod : "POST" , responses : { 200 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const getMonitoringDataOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/monitoringData" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeMonitoringData } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const upgradeOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/upgrade" , httpMethod : "POST" , responses : { 200 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept ] , serializer } ; const removeLinksOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/removeLinks" , httpMethod : "POST" , responses : { 200 : { } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . linkedIntegrationRuntimeRequest , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const createLinkedIntegrationRuntimeOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{factoryName}/integrationRuntimes/{integrationRuntimeName}/linkedIntegrationRuntime" , httpMethod : "POST" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeStatusResponse } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . createLinkedIntegrationRuntimeRequest , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName , Parameters . integrationRuntimeName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const listByFactoryNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . IntegrationRuntimeListResponse } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . factoryName ] , headerParameters : [ Parameters . accept ] , serializer } ;