diff --git a/src/payments/infra/gateways/asaas/asaas-payment.gateway.ts b/src/payments/infra/gateways/asaas/asaas-payment.gateway.ts index 4a48aeb..2ba51cb 100644 --- a/src/payments/infra/gateways/asaas/asaas-payment.gateway.ts +++ b/src/payments/infra/gateways/asaas/asaas-payment.gateway.ts @@ -16,7 +16,7 @@ import { CreateCreditCardChargeResponse, CreateCustomerRequest, CreateCustomerResponse, - findCustomerByDocumentResponse, + FindCustomerByDocumentResponse, } from './asaas.contract'; export class AsaasPaymentGateway implements PaymentGateway { @@ -67,7 +67,7 @@ export class AsaasPaymentGateway implements PaymentGateway { async findCustomerByDocument(document: string): Promise { try { - const { data } = await this.api.get( + const { data } = await this.api.get( '/customers', { params: new URLSearchParams({ cpfCnpj: document }), diff --git a/src/payments/infra/gateways/asaas/asaas.contract.ts b/src/payments/infra/gateways/asaas/asaas.contract.ts index 4d55789..515c82b 100644 --- a/src/payments/infra/gateways/asaas/asaas.contract.ts +++ b/src/payments/infra/gateways/asaas/asaas.contract.ts @@ -22,7 +22,7 @@ export type CreateCustomerRequest = { export type CreateCustomerResponse = Customer; -export type findCustomerByDocumentResponse = { +export type FindCustomerByDocumentResponse = { data: Customer[]; };