@payabli/sdk-node 0.0.116 → 0.0.117
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.
- package/README.md +24 -7
- package/dist/cjs/BaseClient.d.ts +10 -1
- package/dist/cjs/BaseClient.js +57 -0
- package/dist/cjs/Client.d.ts +87 -86
- package/dist/cjs/Client.js +31 -72
- package/dist/cjs/api/resources/bill/client/Client.d.ts +33 -33
- package/dist/cjs/api/resources/bill/client/Client.js +69 -216
- package/dist/cjs/api/resources/boarding/client/Client.d.ts +27 -27
- package/dist/cjs/api/resources/boarding/client/Client.js +51 -198
- package/dist/cjs/api/resources/chargeBacks/client/Client.d.ts +17 -15
- package/dist/cjs/api/resources/chargeBacks/client/Client.js +38 -79
- package/dist/cjs/api/resources/checkCapture/client/Client.d.ts +7 -7
- package/dist/cjs/api/resources/checkCapture/client/Client.js +11 -28
- package/dist/cjs/api/resources/cloud/client/Client.d.ts +17 -17
- package/dist/cjs/api/resources/cloud/client/Client.js +33 -89
- package/dist/cjs/api/resources/customer/client/Client.d.ts +17 -17
- package/dist/cjs/api/resources/customer/client/Client.js +31 -113
- package/dist/cjs/api/resources/export/client/Client.d.ts +93 -89
- package/dist/cjs/api/resources/export/client/Client.js +205 -582
- package/dist/cjs/api/resources/hostedPaymentPages/client/Client.d.ts +11 -11
- package/dist/cjs/api/resources/hostedPaymentPages/client/Client.js +19 -62
- package/dist/cjs/api/resources/import/client/Client.d.ts +11 -11
- package/dist/cjs/api/resources/import/client/Client.js +19 -62
- package/dist/cjs/api/resources/invoice/client/Client.d.ts +31 -31
- package/dist/cjs/api/resources/invoice/client/Client.js +62 -209
- package/dist/cjs/api/resources/lineItem/client/Client.d.ts +15 -15
- package/dist/cjs/api/resources/lineItem/client/Client.js +27 -96
- package/dist/cjs/api/resources/moneyIn/client/Client.d.ts +39 -39
- package/dist/cjs/api/resources/moneyIn/client/Client.js +79 -249
- package/dist/cjs/api/resources/moneyOut/client/Client.d.ts +43 -26
- package/dist/cjs/api/resources/moneyOut/client/Client.js +105 -168
- package/dist/cjs/api/resources/moneyOut/client/requests/MoneyOutTypesRequestOutAuthorize.d.ts +2 -1
- package/dist/cjs/api/resources/moneyOutTypes/types/AuthorizePayoutBody.d.ts +3 -1
- package/dist/cjs/api/resources/notification/client/Client.d.ts +16 -16
- package/dist/cjs/api/resources/notification/client/Client.js +32 -101
- package/dist/cjs/api/resources/notificationlogs/client/Client.d.ts +13 -13
- package/dist/cjs/api/resources/notificationlogs/client/Client.js +23 -79
- package/dist/cjs/api/resources/ocr/client/Client.d.ts +13 -9
- package/dist/cjs/api/resources/ocr/client/Client.js +19 -45
- package/dist/cjs/api/resources/organization/client/Client.d.ts +19 -19
- package/dist/cjs/api/resources/organization/client/Client.js +35 -130
- package/dist/cjs/api/resources/paymentLink/client/Client.d.ts +23 -23
- package/dist/cjs/api/resources/paymentLink/client/Client.js +43 -164
- package/dist/cjs/api/resources/paymentMethodDomain/client/Client.d.ts +19 -19
- package/dist/cjs/api/resources/paymentMethodDomain/client/Client.js +35 -130
- package/dist/cjs/api/resources/paypoint/client/Client.d.ts +22 -22
- package/dist/cjs/api/resources/paypoint/client/Client.js +44 -152
- package/dist/cjs/api/resources/query/client/Client.d.ts +71 -71
- package/dist/cjs/api/resources/query/client/Client.js +137 -572
- package/dist/cjs/api/resources/query/client/requests/ListPayoutOrgRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListPayoutRequest.d.ts +1 -0
- package/dist/cjs/api/resources/query/client/requests/ListTransactionsRequest.d.ts +1 -0
- package/dist/cjs/api/resources/statistic/client/Client.d.ts +50 -50
- package/dist/cjs/api/resources/statistic/client/Client.js +80 -133
- package/dist/cjs/api/resources/statistic/client/requests/BasicStatsRequest.d.ts +2 -2
- package/dist/cjs/api/resources/statistic/types/StatBasicExtendedQueryRecord.d.ts +76 -0
- package/dist/cjs/api/resources/statistic/types/StatBasicExtendedQueryRecord.js +3 -0
- package/dist/cjs/api/resources/statistic/types/index.d.ts +1 -0
- package/dist/cjs/api/resources/statistic/types/index.js +1 -0
- package/dist/cjs/api/resources/subscription/client/Client.d.ts +13 -13
- package/dist/cjs/api/resources/subscription/client/Client.js +23 -79
- package/dist/cjs/api/resources/templates/client/Client.d.ts +15 -15
- package/dist/cjs/api/resources/templates/client/Client.js +28 -84
- package/dist/cjs/api/resources/tokenStorage/client/Client.d.ts +13 -13
- package/dist/cjs/api/resources/tokenStorage/client/Client.js +23 -79
- package/dist/cjs/api/resources/user/client/Client.d.ts +54 -32
- package/dist/cjs/api/resources/user/client/Client.js +84 -222
- package/dist/cjs/api/resources/vendor/client/Client.d.ts +13 -13
- package/dist/cjs/api/resources/vendor/client/Client.js +23 -79
- package/dist/cjs/api/resources/wallet/client/Client.d.ts +13 -13
- package/dist/cjs/api/resources/wallet/client/Client.js +23 -79
- package/dist/cjs/api/types/ApplicationDetailsRecord.d.ts +2 -2
- package/dist/cjs/api/types/NotificationContent.d.ts +1 -0
- package/dist/cjs/api/types/NotificationContent.js +1 -0
- package/dist/cjs/api/types/NotificationStandardRequest.d.ts +1 -0
- package/dist/cjs/api/types/NotificationStandardRequest.js +1 -0
- package/dist/cjs/api/types/QueryResponseSettlements.d.ts +1 -1
- package/dist/cjs/auth/HeaderAuthProvider.d.ts +14 -0
- package/dist/cjs/auth/HeaderAuthProvider.js +71 -0
- package/dist/cjs/auth/index.d.ts +1 -0
- package/dist/cjs/auth/index.js +5 -0
- package/dist/cjs/core/auth/AuthProvider.d.ts +7 -0
- package/dist/cjs/{version.js → core/auth/AuthProvider.js} +0 -2
- package/dist/cjs/core/auth/AuthRequest.d.ts +9 -0
- package/dist/cjs/core/auth/AuthRequest.js +2 -0
- package/dist/cjs/core/auth/BasicAuth.d.ts +8 -0
- package/dist/cjs/core/auth/BasicAuth.js +27 -0
- package/dist/cjs/core/auth/BearerToken.d.ts +7 -0
- package/dist/cjs/core/auth/BearerToken.js +16 -0
- package/dist/cjs/core/auth/NoOpAuthProvider.d.ts +5 -0
- package/dist/cjs/core/auth/NoOpAuthProvider.js +9 -0
- package/dist/cjs/core/auth/index.d.ts +5 -0
- package/dist/cjs/core/auth/index.js +9 -0
- package/dist/cjs/core/base64.d.ts +2 -0
- package/dist/cjs/core/base64.js +26 -0
- package/dist/cjs/core/fetcher/BinaryResponse.d.ts +6 -7
- package/dist/cjs/core/fetcher/Fetcher.d.ts +5 -1
- package/dist/cjs/core/fetcher/Fetcher.js +42 -24
- package/dist/cjs/core/fetcher/getResponseBody.js +18 -4
- package/dist/cjs/core/fetcher/makeRequest.d.ts +1 -1
- package/dist/cjs/core/fetcher/makeRequest.js +0 -2
- package/dist/cjs/core/fetcher/requestWithRetries.js +0 -9
- package/dist/cjs/core/fetcher/signals.d.ts +1 -7
- package/dist/cjs/core/fetcher/signals.js +0 -12
- package/dist/cjs/core/index.d.ts +2 -0
- package/dist/cjs/core/index.js +2 -0
- package/dist/cjs/core/logging/logger.js +1 -1
- package/dist/cjs/core/runtime/runtime.js +11 -10
- package/dist/cjs/core/url/join.js +0 -1
- package/dist/cjs/errors/handleNonStatusCodeError.d.ts +2 -0
- package/dist/cjs/errors/handleNonStatusCodeError.js +65 -0
- package/dist/esm/BaseClient.d.mts +10 -1
- package/dist/esm/BaseClient.mjs +22 -1
- package/dist/esm/Client.d.mts +87 -86
- package/dist/esm/Client.mjs +59 -67
- package/dist/esm/api/resources/bill/client/Client.d.mts +33 -33
- package/dist/esm/api/resources/bill/client/Client.mjs +67 -214
- package/dist/esm/api/resources/boarding/client/Client.d.mts +27 -27
- package/dist/esm/api/resources/boarding/client/Client.mjs +50 -197
- package/dist/esm/api/resources/chargeBacks/client/Client.d.mts +17 -15
- package/dist/esm/api/resources/chargeBacks/client/Client.mjs +36 -77
- package/dist/esm/api/resources/checkCapture/client/Client.d.mts +7 -7
- package/dist/esm/api/resources/checkCapture/client/Client.mjs +10 -27
- package/dist/esm/api/resources/cloud/client/Client.d.mts +17 -17
- package/dist/esm/api/resources/cloud/client/Client.mjs +31 -87
- package/dist/esm/api/resources/customer/client/Client.d.mts +17 -17
- package/dist/esm/api/resources/customer/client/Client.mjs +29 -111
- package/dist/esm/api/resources/export/client/Client.d.mts +93 -89
- package/dist/esm/api/resources/export/client/Client.mjs +204 -581
- package/dist/esm/api/resources/hostedPaymentPages/client/Client.d.mts +11 -11
- package/dist/esm/api/resources/hostedPaymentPages/client/Client.mjs +17 -60
- package/dist/esm/api/resources/import/client/Client.d.mts +11 -11
- package/dist/esm/api/resources/import/client/Client.mjs +17 -60
- package/dist/esm/api/resources/invoice/client/Client.d.mts +31 -31
- package/dist/esm/api/resources/invoice/client/Client.mjs +60 -207
- package/dist/esm/api/resources/lineItem/client/Client.d.mts +15 -15
- package/dist/esm/api/resources/lineItem/client/Client.mjs +25 -94
- package/dist/esm/api/resources/moneyIn/client/Client.d.mts +39 -39
- package/dist/esm/api/resources/moneyIn/client/Client.mjs +77 -247
- package/dist/esm/api/resources/moneyOut/client/Client.d.mts +43 -26
- package/dist/esm/api/resources/moneyOut/client/Client.mjs +103 -166
- package/dist/esm/api/resources/moneyOut/client/requests/MoneyOutTypesRequestOutAuthorize.d.mts +2 -1
- package/dist/esm/api/resources/moneyOutTypes/types/AuthorizePayoutBody.d.mts +3 -1
- package/dist/esm/api/resources/notification/client/Client.d.mts +16 -16
- package/dist/esm/api/resources/notification/client/Client.mjs +31 -100
- package/dist/esm/api/resources/notificationlogs/client/Client.d.mts +13 -13
- package/dist/esm/api/resources/notificationlogs/client/Client.mjs +22 -78
- package/dist/esm/api/resources/ocr/client/Client.d.mts +13 -9
- package/dist/esm/api/resources/ocr/client/Client.mjs +18 -44
- package/dist/esm/api/resources/organization/client/Client.d.mts +19 -19
- package/dist/esm/api/resources/organization/client/Client.mjs +33 -128
- package/dist/esm/api/resources/paymentLink/client/Client.d.mts +23 -23
- package/dist/esm/api/resources/paymentLink/client/Client.mjs +41 -162
- package/dist/esm/api/resources/paymentMethodDomain/client/Client.d.mts +19 -19
- package/dist/esm/api/resources/paymentMethodDomain/client/Client.mjs +34 -129
- package/dist/esm/api/resources/paypoint/client/Client.d.mts +22 -22
- package/dist/esm/api/resources/paypoint/client/Client.mjs +43 -151
- package/dist/esm/api/resources/query/client/Client.d.mts +71 -71
- package/dist/esm/api/resources/query/client/Client.mjs +136 -571
- package/dist/esm/api/resources/query/client/requests/ListPayoutOrgRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListPayoutRequest.d.mts +1 -0
- package/dist/esm/api/resources/query/client/requests/ListTransactionsRequest.d.mts +1 -0
- package/dist/esm/api/resources/statistic/client/Client.d.mts +50 -50
- package/dist/esm/api/resources/statistic/client/Client.mjs +79 -132
- package/dist/esm/api/resources/statistic/client/requests/BasicStatsRequest.d.mts +2 -2
- package/dist/esm/api/resources/statistic/types/StatBasicExtendedQueryRecord.d.mts +76 -0
- package/dist/esm/api/resources/statistic/types/StatBasicExtendedQueryRecord.mjs +2 -0
- package/dist/esm/api/resources/statistic/types/index.d.mts +1 -0
- package/dist/esm/api/resources/statistic/types/index.mjs +1 -0
- package/dist/esm/api/resources/subscription/client/Client.d.mts +13 -13
- package/dist/esm/api/resources/subscription/client/Client.mjs +21 -77
- package/dist/esm/api/resources/templates/client/Client.d.mts +15 -15
- package/dist/esm/api/resources/templates/client/Client.mjs +27 -83
- package/dist/esm/api/resources/tokenStorage/client/Client.d.mts +13 -13
- package/dist/esm/api/resources/tokenStorage/client/Client.mjs +21 -77
- package/dist/esm/api/resources/user/client/Client.d.mts +54 -32
- package/dist/esm/api/resources/user/client/Client.mjs +83 -221
- package/dist/esm/api/resources/vendor/client/Client.d.mts +13 -13
- package/dist/esm/api/resources/vendor/client/Client.mjs +22 -78
- package/dist/esm/api/resources/wallet/client/Client.d.mts +13 -13
- package/dist/esm/api/resources/wallet/client/Client.mjs +22 -78
- package/dist/esm/api/types/ApplicationDetailsRecord.d.mts +2 -2
- package/dist/esm/api/types/NotificationContent.d.mts +1 -0
- package/dist/esm/api/types/NotificationContent.mjs +1 -0
- package/dist/esm/api/types/NotificationStandardRequest.d.mts +1 -0
- package/dist/esm/api/types/NotificationStandardRequest.mjs +1 -0
- package/dist/esm/api/types/QueryResponseSettlements.d.mts +1 -1
- package/dist/esm/auth/HeaderAuthProvider.d.mts +14 -0
- package/dist/esm/auth/HeaderAuthProvider.mjs +34 -0
- package/dist/esm/auth/index.d.mts +1 -0
- package/dist/esm/auth/index.mjs +1 -0
- package/dist/esm/core/auth/AuthProvider.d.mts +7 -0
- package/dist/esm/core/auth/AuthProvider.mjs +1 -0
- package/dist/esm/core/auth/AuthRequest.d.mts +9 -0
- package/dist/esm/core/auth/AuthRequest.mjs +1 -0
- package/dist/esm/core/auth/BasicAuth.d.mts +8 -0
- package/dist/esm/core/auth/BasicAuth.mjs +24 -0
- package/dist/esm/core/auth/BearerToken.d.mts +7 -0
- package/dist/esm/core/auth/BearerToken.mjs +13 -0
- package/dist/esm/core/auth/NoOpAuthProvider.d.mts +5 -0
- package/dist/esm/core/auth/NoOpAuthProvider.mjs +5 -0
- package/dist/esm/core/auth/index.d.mts +5 -0
- package/dist/esm/core/auth/index.mjs +3 -0
- package/dist/esm/core/base64.d.mts +2 -0
- package/dist/esm/core/base64.mjs +22 -0
- package/dist/esm/core/fetcher/BinaryResponse.d.mts +6 -7
- package/dist/esm/core/fetcher/Fetcher.d.mts +5 -1
- package/dist/esm/core/fetcher/Fetcher.mjs +42 -24
- package/dist/esm/core/fetcher/getResponseBody.mjs +18 -4
- package/dist/esm/core/fetcher/makeRequest.d.mts +1 -1
- package/dist/esm/core/fetcher/makeRequest.mjs +0 -2
- package/dist/esm/core/fetcher/requestWithRetries.mjs +0 -9
- package/dist/esm/core/fetcher/signals.d.mts +1 -7
- package/dist/esm/core/fetcher/signals.mjs +0 -12
- package/dist/esm/core/index.d.mts +2 -0
- package/dist/esm/core/index.mjs +2 -0
- package/dist/esm/core/logging/logger.mjs +1 -1
- package/dist/esm/core/runtime/runtime.mjs +11 -10
- package/dist/esm/core/url/join.mjs +0 -1
- package/dist/esm/errors/handleNonStatusCodeError.d.mts +2 -0
- package/dist/esm/errors/handleNonStatusCodeError.mjs +29 -0
- package/package.json +4 -4
- package/reference.md +761 -473
- package/dist/cjs/core/fetcher/ResponseWithBody.d.ts +0 -4
- package/dist/cjs/core/fetcher/ResponseWithBody.js +0 -6
- package/dist/cjs/version.d.ts +0 -1
- package/dist/esm/core/fetcher/ResponseWithBody.d.mts +0 -4
- package/dist/esm/core/fetcher/ResponseWithBody.mjs +0 -3
- package/dist/esm/version.d.mts +0 -1
- package/dist/esm/version.mjs +0 -1
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
2
3
|
import * as core from "../../../../core/index.js";
|
|
3
4
|
import * as Payabli from "../../../index.js";
|
|
4
|
-
export declare namespace
|
|
5
|
+
export declare namespace PaymentMethodDomainClient {
|
|
5
6
|
interface Options extends BaseClientOptions {
|
|
6
7
|
}
|
|
7
8
|
interface RequestOptions extends BaseRequestOptions {
|
|
8
9
|
}
|
|
9
10
|
}
|
|
10
|
-
export declare class
|
|
11
|
-
protected readonly _options:
|
|
12
|
-
constructor(
|
|
11
|
+
export declare class PaymentMethodDomainClient {
|
|
12
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<PaymentMethodDomainClient.Options>;
|
|
13
|
+
constructor(options?: PaymentMethodDomainClient.Options);
|
|
13
14
|
/**
|
|
14
15
|
* Add a payment method domain to an organization or paypoint.
|
|
15
16
|
*
|
|
16
17
|
* @param {Payabli.AddPaymentMethodDomainRequest} request
|
|
17
|
-
* @param {
|
|
18
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
19
|
*
|
|
19
20
|
* @throws {@link Payabli.BadRequestError}
|
|
20
21
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -34,13 +35,13 @@ export declare class PaymentMethodDomain {
|
|
|
34
35
|
* }
|
|
35
36
|
* })
|
|
36
37
|
*/
|
|
37
|
-
addPaymentMethodDomain(request?: Payabli.AddPaymentMethodDomainRequest, requestOptions?:
|
|
38
|
+
addPaymentMethodDomain(request?: Payabli.AddPaymentMethodDomainRequest, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.AddPaymentMethodDomainApiResponse>;
|
|
38
39
|
private __addPaymentMethodDomain;
|
|
39
40
|
/**
|
|
40
41
|
* Cascades a payment method domain to all child entities. All paypoints and suborganization under this parent will inherit this domain and its settings.
|
|
41
42
|
*
|
|
42
43
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
43
|
-
* @param {
|
|
44
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
44
45
|
*
|
|
45
46
|
* @throws {@link Payabli.BadRequestError}
|
|
46
47
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -50,13 +51,13 @@ export declare class PaymentMethodDomain {
|
|
|
50
51
|
* @example
|
|
51
52
|
* await client.paymentMethodDomain.cascadePaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5")
|
|
52
53
|
*/
|
|
53
|
-
cascadePaymentMethodDomain(domainId: string, requestOptions?:
|
|
54
|
+
cascadePaymentMethodDomain(domainId: string, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.PaymentMethodDomainGeneralResponse>;
|
|
54
55
|
private __cascadePaymentMethodDomain;
|
|
55
56
|
/**
|
|
56
57
|
* Delete a payment method domain. You can't delete an inherited domain, you must delete a domain at the organization level.
|
|
57
58
|
*
|
|
58
59
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
59
|
-
* @param {
|
|
60
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
60
61
|
*
|
|
61
62
|
* @throws {@link Payabli.BadRequestError}
|
|
62
63
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -66,13 +67,13 @@ export declare class PaymentMethodDomain {
|
|
|
66
67
|
* @example
|
|
67
68
|
* await client.paymentMethodDomain.deletePaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5")
|
|
68
69
|
*/
|
|
69
|
-
deletePaymentMethodDomain(domainId: string, requestOptions?:
|
|
70
|
+
deletePaymentMethodDomain(domainId: string, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.DeletePaymentMethodDomainResponse>;
|
|
70
71
|
private __deletePaymentMethodDomain;
|
|
71
72
|
/**
|
|
72
73
|
* Get the details for a payment method domain.
|
|
73
74
|
*
|
|
74
75
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
75
|
-
* @param {
|
|
76
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
76
77
|
*
|
|
77
78
|
* @throws {@link Payabli.BadRequestError}
|
|
78
79
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -82,13 +83,13 @@ export declare class PaymentMethodDomain {
|
|
|
82
83
|
* @example
|
|
83
84
|
* await client.paymentMethodDomain.getPaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5")
|
|
84
85
|
*/
|
|
85
|
-
getPaymentMethodDomain(domainId: string, requestOptions?:
|
|
86
|
+
getPaymentMethodDomain(domainId: string, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.PaymentMethodDomainApiResponse>;
|
|
86
87
|
private __getPaymentMethodDomain;
|
|
87
88
|
/**
|
|
88
89
|
* Get a list of payment method domains that belong to a PSP, organization, or paypoint.
|
|
89
90
|
*
|
|
90
91
|
* @param {Payabli.ListPaymentMethodDomainsRequest} request
|
|
91
|
-
* @param {
|
|
92
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
92
93
|
*
|
|
93
94
|
* @throws {@link Payabli.BadRequestError}
|
|
94
95
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -107,14 +108,14 @@ export declare class PaymentMethodDomain {
|
|
|
107
108
|
* entityType: "organization"
|
|
108
109
|
* })
|
|
109
110
|
*/
|
|
110
|
-
listPaymentMethodDomains(request?: Payabli.ListPaymentMethodDomainsRequest, requestOptions?:
|
|
111
|
+
listPaymentMethodDomains(request?: Payabli.ListPaymentMethodDomainsRequest, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.ListPaymentMethodDomainsResponse>;
|
|
111
112
|
private __listPaymentMethodDomains;
|
|
112
113
|
/**
|
|
113
114
|
* Update a payment method domain's configuration values.
|
|
114
115
|
*
|
|
115
116
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
116
117
|
* @param {Payabli.UpdatePaymentMethodDomainRequest} request
|
|
117
|
-
* @param {
|
|
118
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
118
119
|
*
|
|
119
120
|
* @throws {@link Payabli.BadRequestError}
|
|
120
121
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -131,13 +132,13 @@ export declare class PaymentMethodDomain {
|
|
|
131
132
|
* }
|
|
132
133
|
* })
|
|
133
134
|
*/
|
|
134
|
-
updatePaymentMethodDomain(domainId: string, request?: Payabli.UpdatePaymentMethodDomainRequest, requestOptions?:
|
|
135
|
+
updatePaymentMethodDomain(domainId: string, request?: Payabli.UpdatePaymentMethodDomainRequest, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.PaymentMethodDomainGeneralResponse>;
|
|
135
136
|
private __updatePaymentMethodDomain;
|
|
136
137
|
/**
|
|
137
138
|
* Verify a new payment method domain. If verification is successful, Apple Pay is automatically activated for the domain.
|
|
138
139
|
*
|
|
139
140
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
140
|
-
* @param {
|
|
141
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
141
142
|
*
|
|
142
143
|
* @throws {@link Payabli.BadRequestError}
|
|
143
144
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -147,7 +148,6 @@ export declare class PaymentMethodDomain {
|
|
|
147
148
|
* @example
|
|
148
149
|
* await client.paymentMethodDomain.verifyPaymentMethodDomain("pmd_b8237fa45c964d8a9ef27160cd42b8c5")
|
|
149
150
|
*/
|
|
150
|
-
verifyPaymentMethodDomain(domainId: string, requestOptions?:
|
|
151
|
+
verifyPaymentMethodDomain(domainId: string, requestOptions?: PaymentMethodDomainClient.RequestOptions): core.HttpResponsePromise<Payabli.PaymentMethodDomainGeneralResponse>;
|
|
151
152
|
private __verifyPaymentMethodDomain;
|
|
152
|
-
protected _getCustomAuthorizationHeaders(): Promise<Record<string, string | undefined>>;
|
|
153
153
|
}
|
|
@@ -43,21 +43,23 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
43
43
|
});
|
|
44
44
|
};
|
|
45
45
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
-
exports.
|
|
46
|
+
exports.PaymentMethodDomainClient = void 0;
|
|
47
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
47
48
|
const headers_js_1 = require("../../../../core/headers.js");
|
|
48
49
|
const core = __importStar(require("../../../../core/index.js"));
|
|
49
50
|
const environments = __importStar(require("../../../../environments.js"));
|
|
51
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
50
52
|
const errors = __importStar(require("../../../../errors/index.js"));
|
|
51
53
|
const Payabli = __importStar(require("../../../index.js"));
|
|
52
|
-
class
|
|
53
|
-
constructor(
|
|
54
|
-
this._options =
|
|
54
|
+
class PaymentMethodDomainClient {
|
|
55
|
+
constructor(options = {}) {
|
|
56
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
55
57
|
}
|
|
56
58
|
/**
|
|
57
59
|
* Add a payment method domain to an organization or paypoint.
|
|
58
60
|
*
|
|
59
61
|
* @param {Payabli.AddPaymentMethodDomainRequest} request
|
|
60
|
-
* @param {
|
|
62
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
61
63
|
*
|
|
62
64
|
* @throws {@link Payabli.BadRequestError}
|
|
63
65
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -83,7 +85,8 @@ class PaymentMethodDomain {
|
|
|
83
85
|
__addPaymentMethodDomain() {
|
|
84
86
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
85
87
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
86
|
-
const
|
|
88
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
89
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
87
90
|
const _response = yield core.fetcher({
|
|
88
91
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, "PaymentMethodDomain"),
|
|
89
92
|
method: "POST",
|
|
@@ -122,28 +125,14 @@ class PaymentMethodDomain {
|
|
|
122
125
|
});
|
|
123
126
|
}
|
|
124
127
|
}
|
|
125
|
-
|
|
126
|
-
case "non-json":
|
|
127
|
-
throw new errors.PayabliError({
|
|
128
|
-
statusCode: _response.error.statusCode,
|
|
129
|
-
body: _response.error.rawBody,
|
|
130
|
-
rawResponse: _response.rawResponse,
|
|
131
|
-
});
|
|
132
|
-
case "timeout":
|
|
133
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling POST /PaymentMethodDomain.");
|
|
134
|
-
case "unknown":
|
|
135
|
-
throw new errors.PayabliError({
|
|
136
|
-
message: _response.error.errorMessage,
|
|
137
|
-
rawResponse: _response.rawResponse,
|
|
138
|
-
});
|
|
139
|
-
}
|
|
128
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/PaymentMethodDomain");
|
|
140
129
|
});
|
|
141
130
|
}
|
|
142
131
|
/**
|
|
143
132
|
* Cascades a payment method domain to all child entities. All paypoints and suborganization under this parent will inherit this domain and its settings.
|
|
144
133
|
*
|
|
145
134
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
146
|
-
* @param {
|
|
135
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
147
136
|
*
|
|
148
137
|
* @throws {@link Payabli.BadRequestError}
|
|
149
138
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -159,7 +148,8 @@ class PaymentMethodDomain {
|
|
|
159
148
|
__cascadePaymentMethodDomain(domainId, requestOptions) {
|
|
160
149
|
return __awaiter(this, void 0, void 0, function* () {
|
|
161
150
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
162
|
-
const
|
|
151
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
152
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
163
153
|
const _response = yield core.fetcher({
|
|
164
154
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `PaymentMethodDomain/${core.url.encodePathParam(domainId)}/cascade`),
|
|
165
155
|
method: "POST",
|
|
@@ -195,28 +185,14 @@ class PaymentMethodDomain {
|
|
|
195
185
|
});
|
|
196
186
|
}
|
|
197
187
|
}
|
|
198
|
-
|
|
199
|
-
case "non-json":
|
|
200
|
-
throw new errors.PayabliError({
|
|
201
|
-
statusCode: _response.error.statusCode,
|
|
202
|
-
body: _response.error.rawBody,
|
|
203
|
-
rawResponse: _response.rawResponse,
|
|
204
|
-
});
|
|
205
|
-
case "timeout":
|
|
206
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling POST /PaymentMethodDomain/{domainId}/cascade.");
|
|
207
|
-
case "unknown":
|
|
208
|
-
throw new errors.PayabliError({
|
|
209
|
-
message: _response.error.errorMessage,
|
|
210
|
-
rawResponse: _response.rawResponse,
|
|
211
|
-
});
|
|
212
|
-
}
|
|
188
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/PaymentMethodDomain/{domainId}/cascade");
|
|
213
189
|
});
|
|
214
190
|
}
|
|
215
191
|
/**
|
|
216
192
|
* Delete a payment method domain. You can't delete an inherited domain, you must delete a domain at the organization level.
|
|
217
193
|
*
|
|
218
194
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
219
|
-
* @param {
|
|
195
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
220
196
|
*
|
|
221
197
|
* @throws {@link Payabli.BadRequestError}
|
|
222
198
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -232,7 +208,8 @@ class PaymentMethodDomain {
|
|
|
232
208
|
__deletePaymentMethodDomain(domainId, requestOptions) {
|
|
233
209
|
return __awaiter(this, void 0, void 0, function* () {
|
|
234
210
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
235
|
-
const
|
|
211
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
212
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
236
213
|
const _response = yield core.fetcher({
|
|
237
214
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `PaymentMethodDomain/${core.url.encodePathParam(domainId)}`),
|
|
238
215
|
method: "DELETE",
|
|
@@ -268,28 +245,14 @@ class PaymentMethodDomain {
|
|
|
268
245
|
});
|
|
269
246
|
}
|
|
270
247
|
}
|
|
271
|
-
|
|
272
|
-
case "non-json":
|
|
273
|
-
throw new errors.PayabliError({
|
|
274
|
-
statusCode: _response.error.statusCode,
|
|
275
|
-
body: _response.error.rawBody,
|
|
276
|
-
rawResponse: _response.rawResponse,
|
|
277
|
-
});
|
|
278
|
-
case "timeout":
|
|
279
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling DELETE /PaymentMethodDomain/{domainId}.");
|
|
280
|
-
case "unknown":
|
|
281
|
-
throw new errors.PayabliError({
|
|
282
|
-
message: _response.error.errorMessage,
|
|
283
|
-
rawResponse: _response.rawResponse,
|
|
284
|
-
});
|
|
285
|
-
}
|
|
248
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/PaymentMethodDomain/{domainId}");
|
|
286
249
|
});
|
|
287
250
|
}
|
|
288
251
|
/**
|
|
289
252
|
* Get the details for a payment method domain.
|
|
290
253
|
*
|
|
291
254
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
292
|
-
* @param {
|
|
255
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
293
256
|
*
|
|
294
257
|
* @throws {@link Payabli.BadRequestError}
|
|
295
258
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -305,7 +268,8 @@ class PaymentMethodDomain {
|
|
|
305
268
|
__getPaymentMethodDomain(domainId, requestOptions) {
|
|
306
269
|
return __awaiter(this, void 0, void 0, function* () {
|
|
307
270
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
308
|
-
const
|
|
271
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
272
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
309
273
|
const _response = yield core.fetcher({
|
|
310
274
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `PaymentMethodDomain/${core.url.encodePathParam(domainId)}`),
|
|
311
275
|
method: "GET",
|
|
@@ -341,28 +305,14 @@ class PaymentMethodDomain {
|
|
|
341
305
|
});
|
|
342
306
|
}
|
|
343
307
|
}
|
|
344
|
-
|
|
345
|
-
case "non-json":
|
|
346
|
-
throw new errors.PayabliError({
|
|
347
|
-
statusCode: _response.error.statusCode,
|
|
348
|
-
body: _response.error.rawBody,
|
|
349
|
-
rawResponse: _response.rawResponse,
|
|
350
|
-
});
|
|
351
|
-
case "timeout":
|
|
352
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling GET /PaymentMethodDomain/{domainId}.");
|
|
353
|
-
case "unknown":
|
|
354
|
-
throw new errors.PayabliError({
|
|
355
|
-
message: _response.error.errorMessage,
|
|
356
|
-
rawResponse: _response.rawResponse,
|
|
357
|
-
});
|
|
358
|
-
}
|
|
308
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/PaymentMethodDomain/{domainId}");
|
|
359
309
|
});
|
|
360
310
|
}
|
|
361
311
|
/**
|
|
362
312
|
* Get a list of payment method domains that belong to a PSP, organization, or paypoint.
|
|
363
313
|
*
|
|
364
314
|
* @param {Payabli.ListPaymentMethodDomainsRequest} request
|
|
365
|
-
* @param {
|
|
315
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
366
316
|
*
|
|
367
317
|
* @throws {@link Payabli.BadRequestError}
|
|
368
318
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -401,7 +351,8 @@ class PaymentMethodDomain {
|
|
|
401
351
|
if (limitRecord != null) {
|
|
402
352
|
_queryParams.limitRecord = limitRecord.toString();
|
|
403
353
|
}
|
|
404
|
-
const
|
|
354
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
355
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
405
356
|
const _response = yield core.fetcher({
|
|
406
357
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, "PaymentMethodDomain/list"),
|
|
407
358
|
method: "GET",
|
|
@@ -437,21 +388,7 @@ class PaymentMethodDomain {
|
|
|
437
388
|
});
|
|
438
389
|
}
|
|
439
390
|
}
|
|
440
|
-
|
|
441
|
-
case "non-json":
|
|
442
|
-
throw new errors.PayabliError({
|
|
443
|
-
statusCode: _response.error.statusCode,
|
|
444
|
-
body: _response.error.rawBody,
|
|
445
|
-
rawResponse: _response.rawResponse,
|
|
446
|
-
});
|
|
447
|
-
case "timeout":
|
|
448
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling GET /PaymentMethodDomain/list.");
|
|
449
|
-
case "unknown":
|
|
450
|
-
throw new errors.PayabliError({
|
|
451
|
-
message: _response.error.errorMessage,
|
|
452
|
-
rawResponse: _response.rawResponse,
|
|
453
|
-
});
|
|
454
|
-
}
|
|
391
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/PaymentMethodDomain/list");
|
|
455
392
|
});
|
|
456
393
|
}
|
|
457
394
|
/**
|
|
@@ -459,7 +396,7 @@ class PaymentMethodDomain {
|
|
|
459
396
|
*
|
|
460
397
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
461
398
|
* @param {Payabli.UpdatePaymentMethodDomainRequest} request
|
|
462
|
-
* @param {
|
|
399
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
463
400
|
*
|
|
464
401
|
* @throws {@link Payabli.BadRequestError}
|
|
465
402
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -482,7 +419,8 @@ class PaymentMethodDomain {
|
|
|
482
419
|
__updatePaymentMethodDomain(domainId_1) {
|
|
483
420
|
return __awaiter(this, arguments, void 0, function* (domainId, request = {}, requestOptions) {
|
|
484
421
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
485
|
-
const
|
|
422
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
423
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
486
424
|
const _response = yield core.fetcher({
|
|
487
425
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `PaymentMethodDomain/${core.url.encodePathParam(domainId)}`),
|
|
488
426
|
method: "PATCH",
|
|
@@ -521,28 +459,14 @@ class PaymentMethodDomain {
|
|
|
521
459
|
});
|
|
522
460
|
}
|
|
523
461
|
}
|
|
524
|
-
|
|
525
|
-
case "non-json":
|
|
526
|
-
throw new errors.PayabliError({
|
|
527
|
-
statusCode: _response.error.statusCode,
|
|
528
|
-
body: _response.error.rawBody,
|
|
529
|
-
rawResponse: _response.rawResponse,
|
|
530
|
-
});
|
|
531
|
-
case "timeout":
|
|
532
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling PATCH /PaymentMethodDomain/{domainId}.");
|
|
533
|
-
case "unknown":
|
|
534
|
-
throw new errors.PayabliError({
|
|
535
|
-
message: _response.error.errorMessage,
|
|
536
|
-
rawResponse: _response.rawResponse,
|
|
537
|
-
});
|
|
538
|
-
}
|
|
462
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "PATCH", "/PaymentMethodDomain/{domainId}");
|
|
539
463
|
});
|
|
540
464
|
}
|
|
541
465
|
/**
|
|
542
466
|
* Verify a new payment method domain. If verification is successful, Apple Pay is automatically activated for the domain.
|
|
543
467
|
*
|
|
544
468
|
* @param {string} domainId - The payment method domain's ID in Payabli.
|
|
545
|
-
* @param {
|
|
469
|
+
* @param {PaymentMethodDomainClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
546
470
|
*
|
|
547
471
|
* @throws {@link Payabli.BadRequestError}
|
|
548
472
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -558,7 +482,8 @@ class PaymentMethodDomain {
|
|
|
558
482
|
__verifyPaymentMethodDomain(domainId, requestOptions) {
|
|
559
483
|
return __awaiter(this, void 0, void 0, function* () {
|
|
560
484
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
561
|
-
const
|
|
485
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
486
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
562
487
|
const _response = yield core.fetcher({
|
|
563
488
|
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.PayabliEnvironment.Sandbox, `PaymentMethodDomain/${core.url.encodePathParam(domainId)}/verify`),
|
|
564
489
|
method: "POST",
|
|
@@ -594,28 +519,8 @@ class PaymentMethodDomain {
|
|
|
594
519
|
});
|
|
595
520
|
}
|
|
596
521
|
}
|
|
597
|
-
|
|
598
|
-
case "non-json":
|
|
599
|
-
throw new errors.PayabliError({
|
|
600
|
-
statusCode: _response.error.statusCode,
|
|
601
|
-
body: _response.error.rawBody,
|
|
602
|
-
rawResponse: _response.rawResponse,
|
|
603
|
-
});
|
|
604
|
-
case "timeout":
|
|
605
|
-
throw new errors.PayabliTimeoutError("Timeout exceeded when calling POST /PaymentMethodDomain/{domainId}/verify.");
|
|
606
|
-
case "unknown":
|
|
607
|
-
throw new errors.PayabliError({
|
|
608
|
-
message: _response.error.errorMessage,
|
|
609
|
-
rawResponse: _response.rawResponse,
|
|
610
|
-
});
|
|
611
|
-
}
|
|
612
|
-
});
|
|
613
|
-
}
|
|
614
|
-
_getCustomAuthorizationHeaders() {
|
|
615
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
616
|
-
const apiKeyValue = yield core.Supplier.get(this._options.apiKey);
|
|
617
|
-
return { requestToken: apiKeyValue };
|
|
522
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/PaymentMethodDomain/{domainId}/verify");
|
|
618
523
|
});
|
|
619
524
|
}
|
|
620
525
|
}
|
|
621
|
-
exports.
|
|
526
|
+
exports.PaymentMethodDomainClient = PaymentMethodDomainClient;
|
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
2
3
|
import * as core from "../../../../core/index.js";
|
|
3
4
|
import * as Payabli from "../../../index.js";
|
|
4
|
-
export declare namespace
|
|
5
|
+
export declare namespace PaypointClient {
|
|
5
6
|
interface Options extends BaseClientOptions {
|
|
6
7
|
}
|
|
7
8
|
interface RequestOptions extends BaseRequestOptions {
|
|
8
9
|
}
|
|
9
10
|
}
|
|
10
|
-
export declare class
|
|
11
|
-
protected readonly _options:
|
|
12
|
-
constructor(
|
|
11
|
+
export declare class PaypointClient {
|
|
12
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<PaypointClient.Options>;
|
|
13
|
+
constructor(options?: PaypointClient.Options);
|
|
13
14
|
/**
|
|
14
15
|
* Gets the basic details for a paypoint.
|
|
15
16
|
*
|
|
16
17
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
17
|
-
* @param {
|
|
18
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
18
19
|
*
|
|
19
20
|
* @throws {@link Payabli.BadRequestError}
|
|
20
21
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -24,13 +25,13 @@ export declare class Paypoint {
|
|
|
24
25
|
* @example
|
|
25
26
|
* await client.paypoint.getBasicEntry("8cfec329267")
|
|
26
27
|
*/
|
|
27
|
-
getBasicEntry(entry: string, requestOptions?:
|
|
28
|
+
getBasicEntry(entry: string, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.GetBasicEntryResponse>;
|
|
28
29
|
private __getBasicEntry;
|
|
29
30
|
/**
|
|
30
31
|
* Retrieves the basic details for a paypoint by ID.
|
|
31
32
|
*
|
|
32
|
-
* @param {string}
|
|
33
|
-
* @param {
|
|
33
|
+
* @param {string} IdPaypoint - Paypoint ID. You can find this value by querying `/api/Query/paypoints/{orgId}`
|
|
34
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
34
35
|
*
|
|
35
36
|
* @throws {@link Payabli.BadRequestError}
|
|
36
37
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -40,14 +41,14 @@ export declare class Paypoint {
|
|
|
40
41
|
* @example
|
|
41
42
|
* await client.paypoint.getBasicEntryById("198")
|
|
42
43
|
*/
|
|
43
|
-
getBasicEntryById(
|
|
44
|
+
getBasicEntryById(IdPaypoint: string, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.GetBasicEntryByIdResponse>;
|
|
44
45
|
private __getBasicEntryById;
|
|
45
46
|
/**
|
|
46
47
|
* Gets the details for a single paypoint.
|
|
47
48
|
*
|
|
48
49
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
49
50
|
* @param {Payabli.GetEntryConfigRequest} request
|
|
50
|
-
* @param {
|
|
51
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
52
|
*
|
|
52
53
|
* @throws {@link Payabli.BadRequestError}
|
|
53
54
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -57,14 +58,14 @@ export declare class Paypoint {
|
|
|
57
58
|
* @example
|
|
58
59
|
* await client.paypoint.getEntryConfig("8cfec329267")
|
|
59
60
|
*/
|
|
60
|
-
getEntryConfig(entry: string, request?: Payabli.GetEntryConfigRequest, requestOptions?:
|
|
61
|
+
getEntryConfig(entry: string, request?: Payabli.GetEntryConfigRequest, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.GetEntryConfigResponse>;
|
|
61
62
|
private __getEntryConfig;
|
|
62
63
|
/**
|
|
63
64
|
* Gets the details for single payment page for a paypoint.
|
|
64
65
|
*
|
|
65
66
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
66
67
|
* @param {string} subdomain - Payment page identifier. The subdomain value is the last portion of the payment page URL. For example, in`https://paypages-sandbox.payabli.com/513823dc10/pay-your-fees-1`, the subdomain is `pay-your-fees-1`.
|
|
67
|
-
* @param {
|
|
68
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
69
|
*
|
|
69
70
|
* @throws {@link Payabli.BadRequestError}
|
|
70
71
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -74,14 +75,14 @@ export declare class Paypoint {
|
|
|
74
75
|
* @example
|
|
75
76
|
* await client.paypoint.getPage("8cfec329267", "pay-your-fees-1")
|
|
76
77
|
*/
|
|
77
|
-
getPage(entry: string, subdomain: string, requestOptions?:
|
|
78
|
+
getPage(entry: string, subdomain: string, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.PayabliPages>;
|
|
78
79
|
private __getPage;
|
|
79
80
|
/**
|
|
80
81
|
* Deletes a payment page in a paypoint.
|
|
81
82
|
*
|
|
82
83
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
83
84
|
* @param {string} subdomain - Payment page identifier. The subdomain value is the last portion of the payment page URL. For example, in`https://paypages-sandbox.payabli.com/513823dc10/pay-your-fees-1`, the subdomain is `pay-your-fees-1`.
|
|
84
|
-
* @param {
|
|
85
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
85
86
|
*
|
|
86
87
|
* @throws {@link Payabli.BadRequestError}
|
|
87
88
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -91,14 +92,14 @@ export declare class Paypoint {
|
|
|
91
92
|
* @example
|
|
92
93
|
* await client.paypoint.removePage("8cfec329267", "pay-your-fees-1")
|
|
93
94
|
*/
|
|
94
|
-
removePage(entry: string, subdomain: string, requestOptions?:
|
|
95
|
+
removePage(entry: string, subdomain: string, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.PayabliApiResponseGeneric2Part>;
|
|
95
96
|
private __removePage;
|
|
96
97
|
/**
|
|
97
98
|
* Updates a paypoint logo.
|
|
98
99
|
*
|
|
99
100
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
100
101
|
* @param {Payabli.FileContent} request
|
|
101
|
-
* @param {
|
|
102
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
102
103
|
*
|
|
103
104
|
* @throws {@link Payabli.BadRequestError}
|
|
104
105
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -108,13 +109,13 @@ export declare class Paypoint {
|
|
|
108
109
|
* @example
|
|
109
110
|
* await client.paypoint.saveLogo("8cfec329267", {})
|
|
110
111
|
*/
|
|
111
|
-
saveLogo(entry: string, request: Payabli.FileContent, requestOptions?:
|
|
112
|
+
saveLogo(entry: string, request: Payabli.FileContent, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.PayabliApiResponse00Responsedatanonobject>;
|
|
112
113
|
private __saveLogo;
|
|
113
114
|
/**
|
|
114
115
|
* Retrieves an paypoint's basic settings like custom fields, identifiers, and invoicing settings.
|
|
115
116
|
*
|
|
116
117
|
* @param {string} entry - The paypoint's entrypoint identifier. [Learn more](/api-reference/api-overview#entrypoint-vs-entry)
|
|
117
|
-
* @param {
|
|
118
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
118
119
|
*
|
|
119
120
|
* @throws {@link Payabli.BadRequestError}
|
|
120
121
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -124,13 +125,13 @@ export declare class Paypoint {
|
|
|
124
125
|
* @example
|
|
125
126
|
* await client.paypoint.settingsPage("8cfec329267")
|
|
126
127
|
*/
|
|
127
|
-
settingsPage(entry: string, requestOptions?:
|
|
128
|
+
settingsPage(entry: string, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.SettingsQueryRecord>;
|
|
128
129
|
private __settingsPage;
|
|
129
130
|
/**
|
|
130
131
|
* Migrates a paypoint to a new parent organization.
|
|
131
132
|
*
|
|
132
133
|
* @param {Payabli.PaypointMoveRequest} request
|
|
133
|
-
* @param {
|
|
134
|
+
* @param {PaypointClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
134
135
|
*
|
|
135
136
|
* @throws {@link Payabli.BadRequestError}
|
|
136
137
|
* @throws {@link Payabli.UnauthorizedError}
|
|
@@ -150,7 +151,6 @@ export declare class Paypoint {
|
|
|
150
151
|
* }
|
|
151
152
|
* })
|
|
152
153
|
*/
|
|
153
|
-
migrate(request: Payabli.PaypointMoveRequest, requestOptions?:
|
|
154
|
+
migrate(request: Payabli.PaypointMoveRequest, requestOptions?: PaypointClient.RequestOptions): core.HttpResponsePromise<Payabli.MigratePaypointResponse>;
|
|
154
155
|
private __migrate;
|
|
155
|
-
protected _getCustomAuthorizationHeaders(): Promise<Record<string, string | undefined>>;
|
|
156
156
|
}
|