import { ApiResponse , RequestOptions } from '../core' ; import { RegisterDomainRequest , registerDomainRequestSchema , } from '../models/registerDomainRequest' ; import { RegisterDomainResponse , registerDomainResponseSchema , } from '../models/registerDomainResponse' ; import { BaseApi } from './baseApi' ; export class ApplePayApi extends BaseApi { param body return async registerDomain ( body , requestOptions ? ) { const req = this . createRequest ( 'POST' , '/v2/apple-pay/domains' ) ; const mapped = req . prepareArgs ( { body : [ body , registerDomainRequestSchema ] , } ) ; req . header ( 'Content-Type' , 'application/json' ) ; req . json ( mapped . body ) ; return req . callAsJson ( registerDomainResponseSchema , requestOptions ) ; } }