From 7886368601fd69cae15af4f0ea93001effab5eee Mon Sep 17 00:00:00 2001 From: morteza-mortezai Date: Tue, 24 Feb 2026 15:33:42 +0330 Subject: [PATCH] zarin --- src/modules/payment/controllers/payment.controller.ts | 4 ++-- src/modules/payment/gateways/zarinpal.gateway.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/payment/controllers/payment.controller.ts b/src/modules/payment/controllers/payment.controller.ts index f246c27..e8b1467 100644 --- a/src/modules/payment/controllers/payment.controller.ts +++ b/src/modules/payment/controllers/payment.controller.ts @@ -38,10 +38,10 @@ export class PaymentController { return this.paymentService.payInvoice(invoiceId, dto); } - @Get('public/payments/online/:token/verify') + @Get('public/payments/online/zarin/verify') @ApiOperation({ summary: 'Verify online payment' }) async verifyOnlinePayment( - @Param('token') token: string, + @Query('Authority') token: string, @Res() res: Response, ) { try { diff --git a/src/modules/payment/gateways/zarinpal.gateway.ts b/src/modules/payment/gateways/zarinpal.gateway.ts index 67626db..42c7648 100755 --- a/src/modules/payment/gateways/zarinpal.gateway.ts +++ b/src/modules/payment/gateways/zarinpal.gateway.ts @@ -44,7 +44,7 @@ export class ZarinpalGateway implements IPaymentGateway { async requestPayment({ amount, invoiceId }: IRequestPaymentParams): Promise { // Transform camelCase to snake_case for Zarinpal API v4 - const callbackUrl = `${this.apiUrl}/verify/${invoiceId}`; + const callbackUrl = `${this.apiUrl}/public/payments/online/zarin/verify`; const zarinpalRequest: IZarinpalRequestPayment = { amount, merchant_id: this.zarinpalMerchantId,