liqpay-nestjs 0.3.13 → 0.3.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,6 +14,12 @@ export declare class PaymentsClient {
14
14
  signature: string;
15
15
  url: string;
16
16
  };
17
+ getAuthUrl(payload: CheckoutInput): {
18
+ request: CheckoutRequest;
19
+ data: string;
20
+ signature: string;
21
+ url: string;
22
+ };
17
23
  hold(payload: CheckoutInput): {
18
24
  request: CheckoutRequest;
19
25
  data: string;
@@ -43,6 +43,15 @@ class PaymentsClient {
43
43
  url: this.buildUrl(data, signature),
44
44
  };
45
45
  }
46
+ getAuthUrl(payload) {
47
+ const { request, data, signature } = this.prepare(payload, 'auth');
48
+ return {
49
+ request,
50
+ data,
51
+ signature,
52
+ url: this.buildUrl(data, signature),
53
+ };
54
+ }
46
55
  // TODO: implement
47
56
  hold(payload) {
48
57
  const { request, data, signature } = this.prepare(payload, 'hold');
@@ -41,7 +41,7 @@ export declare const ActionSchema: z.ZodEnum<{
41
41
  regular: "regular";
42
42
  }>;
43
43
  export type Action = z.infer<typeof ActionSchema>;
44
- export type CheckoutAction = Extract<Action, 'pay' | 'hold' | 'subscribe' | 'paydonate'>;
44
+ export type CheckoutAction = Extract<Action, 'pay' | 'hold' | 'subscribe' | 'paydonate' | 'auth'>;
45
45
  export type PaymentStatusAction = Extract<Action, 'status'>;
46
46
  export type RefundAction = Extract<Action, 'refund'>;
47
47
  export type VerificationAction = Extract<Action, 'confirm' | 'mpi' | 'cardverification'>;
@@ -10,6 +10,12 @@ export declare class PaymentsService {
10
10
  signature: string;
11
11
  url: string;
12
12
  };
13
+ getAuthUrl(payload: CheckoutInput): {
14
+ request: import("../../core/types/checkout").CheckoutRequest;
15
+ data: string;
16
+ signature: string;
17
+ url: string;
18
+ };
13
19
  hold(payload: CheckoutInput): {
14
20
  request: import("../../core/types/checkout").CheckoutRequest;
15
21
  data: string;
@@ -9,6 +9,9 @@ class PaymentsService {
9
9
  getCheckoutUrl(payload) {
10
10
  return this.client.payments.getCheckoutUrl(payload);
11
11
  }
12
+ getAuthUrl(payload) {
13
+ return this.client.payments.getAuthUrl(payload);
14
+ }
12
15
  hold(payload) {
13
16
  return this.client.payments.hold(payload);
14
17
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "liqpay-nestjs",
3
3
  "description": "LiqPay integration module for NestJS with support for payments, callbacks, and configuration via DI.",
4
- "version": "0.3.13",
4
+ "version": "0.3.14",
5
5
  "type": "commonjs",
6
6
  "module": "dist/index.js",
7
7
  "main": "dist/index.js",