UNPKG

@aws-amplify/auth

Version:
31 lines (28 loc) 937 B
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 import { composeServiceApi } from '@aws-amplify/core/internals/aws-client-utils/composers'; import { AssociateSoftwareTokenCommandInput, AssociateSoftwareTokenCommandOutput, ServiceClientFactoryInput, } from './types'; import { cognitoUserPoolTransferHandler } from './shared/handler'; import { createUserPoolDeserializer, createUserPoolSerializer, } from './shared/serde'; import { DEFAULT_SERVICE_CLIENT_API_CONFIG } from './constants'; export const createAssociateSoftwareTokenClient = ( config: ServiceClientFactoryInput, ) => composeServiceApi( cognitoUserPoolTransferHandler, createUserPoolSerializer<AssociateSoftwareTokenCommandInput>( 'AssociateSoftwareToken', ), createUserPoolDeserializer<AssociateSoftwareTokenCommandOutput>(), { ...DEFAULT_SERVICE_CLIENT_API_CONFIG, ...config, }, );