@naturalpay/sdk 1.6.46 → 1.6.47
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/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/Client.d.ts +3 -0
- package/dist/cjs/Client.js +31 -26
- package/dist/cjs/api/resources/index.d.ts +3 -0
- package/dist/cjs/api/resources/index.js +4 -1
- package/dist/cjs/api/resources/merchantReports/client/Client.d.ts +57 -0
- package/dist/cjs/api/resources/merchantReports/client/Client.js +177 -0
- package/dist/cjs/api/resources/merchantReports/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/merchantReports/client/index.js +17 -0
- package/dist/cjs/api/resources/merchantReports/client/requests/CreateMerchantReportsRequest.d.ts +36 -0
- package/dist/cjs/api/resources/merchantReports/client/requests/CreateMerchantReportsRequest.js +3 -0
- package/dist/cjs/api/resources/merchantReports/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/merchantReports/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/merchantReports/exports.d.ts +2 -0
- package/dist/cjs/api/resources/merchantReports/exports.js +21 -0
- package/dist/cjs/api/resources/merchantReports/index.d.ts +2 -0
- package/dist/cjs/api/resources/merchantReports/index.js +18 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.d.ts +19 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.js +3 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.d.ts +10 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.js +13 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponse.d.ts +4 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponse.js +3 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponseData.d.ts +8 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponseData.js +3 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.d.ts +10 -0
- package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.js +13 -0
- package/dist/cjs/api/resources/merchantReports/types/index.d.ts +5 -0
- package/dist/cjs/api/resources/merchantReports/types/index.js +21 -0
- package/dist/cjs/serialization/resources/index.d.ts +3 -0
- package/dist/cjs/serialization/resources/index.js +4 -1
- package/dist/cjs/serialization/resources/merchantReports/client/index.d.ts +1 -0
- package/dist/cjs/serialization/resources/merchantReports/client/index.js +17 -0
- package/dist/cjs/serialization/resources/merchantReports/client/requests/CreateMerchantReportsRequest.d.ts +17 -0
- package/dist/cjs/serialization/resources/merchantReports/client/requests/CreateMerchantReportsRequest.js +49 -0
- package/dist/cjs/serialization/resources/merchantReports/client/requests/index.d.ts +1 -0
- package/dist/cjs/serialization/resources/merchantReports/client/requests/index.js +5 -0
- package/dist/cjs/serialization/resources/merchantReports/index.d.ts +2 -0
- package/dist/cjs/serialization/resources/merchantReports/index.js +18 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.d.ts +15 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.js +47 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.d.ts +7 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.js +46 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponse.d.ts +10 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponse.js +42 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponseData.d.ts +13 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponseData.js +45 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.d.ts +7 -0
- package/dist/cjs/serialization/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.js +46 -0
- package/dist/cjs/serialization/resources/merchantReports/types/index.d.ts +5 -0
- package/dist/cjs/serialization/resources/merchantReports/types/index.js +21 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +3 -0
- package/dist/esm/Client.mjs +5 -0
- package/dist/esm/api/resources/index.d.mts +3 -0
- package/dist/esm/api/resources/index.mjs +3 -0
- package/dist/esm/api/resources/merchantReports/client/Client.d.mts +57 -0
- package/dist/esm/api/resources/merchantReports/client/Client.mjs +140 -0
- package/dist/esm/api/resources/merchantReports/client/index.d.mts +1 -0
- package/dist/esm/api/resources/merchantReports/client/index.mjs +1 -0
- package/dist/esm/api/resources/merchantReports/client/requests/CreateMerchantReportsRequest.d.mts +36 -0
- package/dist/esm/api/resources/merchantReports/client/requests/CreateMerchantReportsRequest.mjs +2 -0
- package/dist/esm/api/resources/merchantReports/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/merchantReports/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/merchantReports/exports.d.mts +2 -0
- package/dist/esm/api/resources/merchantReports/exports.mjs +3 -0
- package/dist/esm/api/resources/merchantReports/index.d.mts +2 -0
- package/dist/esm/api/resources/merchantReports/index.mjs +2 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.d.mts +19 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.mjs +2 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.d.mts +10 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.mjs +10 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponse.d.mts +4 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponse.mjs +2 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponseData.d.mts +8 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponseData.mjs +2 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.d.mts +10 -0
- package/dist/esm/api/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.mjs +10 -0
- package/dist/esm/api/resources/merchantReports/types/index.d.mts +5 -0
- package/dist/esm/api/resources/merchantReports/types/index.mjs +5 -0
- package/dist/esm/serialization/resources/index.d.mts +3 -0
- package/dist/esm/serialization/resources/index.mjs +3 -0
- package/dist/esm/serialization/resources/merchantReports/client/index.d.mts +1 -0
- package/dist/esm/serialization/resources/merchantReports/client/index.mjs +1 -0
- package/dist/esm/serialization/resources/merchantReports/client/requests/CreateMerchantReportsRequest.d.mts +17 -0
- package/dist/esm/serialization/resources/merchantReports/client/requests/CreateMerchantReportsRequest.mjs +13 -0
- package/dist/esm/serialization/resources/merchantReports/client/requests/index.d.mts +1 -0
- package/dist/esm/serialization/resources/merchantReports/client/requests/index.mjs +1 -0
- package/dist/esm/serialization/resources/merchantReports/index.d.mts +2 -0
- package/dist/esm/serialization/resources/merchantReports/index.mjs +2 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.d.mts +15 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.mjs +11 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.d.mts +7 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsRequestOutcome.mjs +10 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponse.d.mts +10 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponse.mjs +6 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponseData.d.mts +13 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponseData.mjs +9 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.d.mts +7 -0
- package/dist/esm/serialization/resources/merchantReports/types/CreateMerchantReportsResponseDataOutcome.mjs +10 -0
- package/dist/esm/serialization/resources/merchantReports/types/index.d.mts +5 -0
- package/dist/esm/serialization/resources/merchantReports/types/index.mjs +5 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +12 -1
- package/reference.md +79 -0
package/dist/cjs/BaseClient.js
CHANGED
|
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
|
|
|
43
43
|
const headers = (0, headers_js_1.mergeHeaders)({
|
|
44
44
|
"X-Fern-Language": "JavaScript",
|
|
45
45
|
"X-Fern-SDK-Name": "@naturalpay/sdk",
|
|
46
|
-
"X-Fern-SDK-Version": "1.6.
|
|
47
|
-
"User-Agent": "@naturalpay/sdk/1.6.
|
|
46
|
+
"X-Fern-SDK-Version": "1.6.47",
|
|
47
|
+
"User-Agent": "@naturalpay/sdk/1.6.47",
|
|
48
48
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
49
49
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
50
50
|
"X-Instance-ID": options === null || options === void 0 ? void 0 : options.instanceId,
|
package/dist/cjs/Client.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ import { ExternalPartiesClient } from "./api/resources/externalParties/client/Cl
|
|
|
15
15
|
import { ExternalPartyAccountsClient } from "./api/resources/externalPartyAccounts/client/Client.js";
|
|
16
16
|
import { InvitationLinksClient } from "./api/resources/invitationLinks/client/Client.js";
|
|
17
17
|
import { InvitationsClient } from "./api/resources/invitations/client/Client.js";
|
|
18
|
+
import { MerchantReportsClient } from "./api/resources/merchantReports/client/Client.js";
|
|
18
19
|
import { PartiesClient } from "./api/resources/parties/client/Client.js";
|
|
19
20
|
import { PaymentIntentsClient } from "./api/resources/paymentIntents/client/Client.js";
|
|
20
21
|
import { PaymentRequestsClient } from "./api/resources/paymentRequests/client/Client.js";
|
|
@@ -64,6 +65,7 @@ export declare class NaturalClient {
|
|
|
64
65
|
protected _apiKeys: ApiKeysClient | undefined;
|
|
65
66
|
protected _agentKeys: AgentKeysClient | undefined;
|
|
66
67
|
protected _cardSessions: CardSessionsClient | undefined;
|
|
68
|
+
protected _merchantReports: MerchantReportsClient | undefined;
|
|
67
69
|
protected _agenticPayments: AgenticPaymentsClient | undefined;
|
|
68
70
|
protected _webhooks: WebhooksClient | undefined;
|
|
69
71
|
protected _events: EventsClient | undefined;
|
|
@@ -95,6 +97,7 @@ export declare class NaturalClient {
|
|
|
95
97
|
get apiKeys(): ApiKeysClient;
|
|
96
98
|
get agentKeys(): AgentKeysClient;
|
|
97
99
|
get cardSessions(): CardSessionsClient;
|
|
100
|
+
get merchantReports(): MerchantReportsClient;
|
|
98
101
|
get agenticPayments(): AgenticPaymentsClient;
|
|
99
102
|
get webhooks(): WebhooksClient;
|
|
100
103
|
get events(): EventsClient;
|
package/dist/cjs/Client.js
CHANGED
|
@@ -61,19 +61,20 @@ const Client_js_14 = require("./api/resources/externalParties/client/Client.js")
|
|
|
61
61
|
const Client_js_15 = require("./api/resources/externalPartyAccounts/client/Client.js");
|
|
62
62
|
const Client_js_16 = require("./api/resources/invitationLinks/client/Client.js");
|
|
63
63
|
const Client_js_17 = require("./api/resources/invitations/client/Client.js");
|
|
64
|
-
const Client_js_18 = require("./api/resources/
|
|
65
|
-
const Client_js_19 = require("./api/resources/
|
|
66
|
-
const Client_js_20 = require("./api/resources/
|
|
67
|
-
const Client_js_21 = require("./api/resources/
|
|
68
|
-
const Client_js_22 = require("./api/resources/
|
|
69
|
-
const Client_js_23 = require("./api/resources/
|
|
70
|
-
const Client_js_24 = require("./api/resources/
|
|
71
|
-
const Client_js_25 = require("./api/resources/
|
|
72
|
-
const Client_js_26 = require("./api/resources/
|
|
73
|
-
const Client_js_27 = require("./api/resources/
|
|
74
|
-
const Client_js_28 = require("./api/resources/
|
|
75
|
-
const Client_js_29 = require("./api/resources/
|
|
76
|
-
const Client_js_30 = require("./api/resources/
|
|
64
|
+
const Client_js_18 = require("./api/resources/merchantReports/client/Client.js");
|
|
65
|
+
const Client_js_19 = require("./api/resources/parties/client/Client.js");
|
|
66
|
+
const Client_js_20 = require("./api/resources/paymentIntents/client/Client.js");
|
|
67
|
+
const Client_js_21 = require("./api/resources/paymentRequests/client/Client.js");
|
|
68
|
+
const Client_js_22 = require("./api/resources/payments/client/Client.js");
|
|
69
|
+
const Client_js_23 = require("./api/resources/realtime/client/Client.js");
|
|
70
|
+
const Client_js_24 = require("./api/resources/refunds/client/Client.js");
|
|
71
|
+
const Client_js_25 = require("./api/resources/simulations/client/Client.js");
|
|
72
|
+
const Client_js_26 = require("./api/resources/transactions/client/Client.js");
|
|
73
|
+
const Client_js_27 = require("./api/resources/transfers/client/Client.js");
|
|
74
|
+
const Client_js_28 = require("./api/resources/voiceSessions/client/Client.js");
|
|
75
|
+
const Client_js_29 = require("./api/resources/wallets/client/Client.js");
|
|
76
|
+
const Client_js_30 = require("./api/resources/webhooks/client/Client.js");
|
|
77
|
+
const Client_js_31 = require("./api/resources/wire/client/Client.js");
|
|
77
78
|
const BaseClient_js_1 = require("./BaseClient.js");
|
|
78
79
|
const core = __importStar(require("./core/index.js"));
|
|
79
80
|
class NaturalClient {
|
|
@@ -94,7 +95,7 @@ class NaturalClient {
|
|
|
94
95
|
}
|
|
95
96
|
get payments() {
|
|
96
97
|
var _a;
|
|
97
|
-
return ((_a = this._payments) !== null && _a !== void 0 ? _a : (this._payments = new
|
|
98
|
+
return ((_a = this._payments) !== null && _a !== void 0 ? _a : (this._payments = new Client_js_22.PaymentsClient(this._options)));
|
|
98
99
|
}
|
|
99
100
|
get externalParties() {
|
|
100
101
|
var _a;
|
|
@@ -110,11 +111,11 @@ class NaturalClient {
|
|
|
110
111
|
}
|
|
111
112
|
get realtime() {
|
|
112
113
|
var _a;
|
|
113
|
-
return ((_a = this._realtime) !== null && _a !== void 0 ? _a : (this._realtime = new
|
|
114
|
+
return ((_a = this._realtime) !== null && _a !== void 0 ? _a : (this._realtime = new Client_js_23.RealtimeClient(this._options)));
|
|
114
115
|
}
|
|
115
116
|
get wire() {
|
|
116
117
|
var _a;
|
|
117
|
-
return ((_a = this._wire) !== null && _a !== void 0 ? _a : (this._wire = new
|
|
118
|
+
return ((_a = this._wire) !== null && _a !== void 0 ? _a : (this._wire = new Client_js_31.WireClient(this._options)));
|
|
118
119
|
}
|
|
119
120
|
get check() {
|
|
120
121
|
var _a;
|
|
@@ -122,7 +123,7 @@ class NaturalClient {
|
|
|
122
123
|
}
|
|
123
124
|
get paymentIntents() {
|
|
124
125
|
var _a;
|
|
125
|
-
return ((_a = this._paymentIntents) !== null && _a !== void 0 ? _a : (this._paymentIntents = new
|
|
126
|
+
return ((_a = this._paymentIntents) !== null && _a !== void 0 ? _a : (this._paymentIntents = new Client_js_20.PaymentIntentsClient(this._options)));
|
|
126
127
|
}
|
|
127
128
|
get cardPayments() {
|
|
128
129
|
var _a;
|
|
@@ -130,11 +131,11 @@ class NaturalClient {
|
|
|
130
131
|
}
|
|
131
132
|
get voiceSessions() {
|
|
132
133
|
var _a;
|
|
133
|
-
return ((_a = this._voiceSessions) !== null && _a !== void 0 ? _a : (this._voiceSessions = new
|
|
134
|
+
return ((_a = this._voiceSessions) !== null && _a !== void 0 ? _a : (this._voiceSessions = new Client_js_28.VoiceSessionsClient(this._options)));
|
|
134
135
|
}
|
|
135
136
|
get refunds() {
|
|
136
137
|
var _a;
|
|
137
|
-
return ((_a = this._refunds) !== null && _a !== void 0 ? _a : (this._refunds = new
|
|
138
|
+
return ((_a = this._refunds) !== null && _a !== void 0 ? _a : (this._refunds = new Client_js_24.RefundsClient(this._options)));
|
|
138
139
|
}
|
|
139
140
|
get chargebacks() {
|
|
140
141
|
var _a;
|
|
@@ -142,15 +143,15 @@ class NaturalClient {
|
|
|
142
143
|
}
|
|
143
144
|
get transactions() {
|
|
144
145
|
var _a;
|
|
145
|
-
return ((_a = this._transactions) !== null && _a !== void 0 ? _a : (this._transactions = new
|
|
146
|
+
return ((_a = this._transactions) !== null && _a !== void 0 ? _a : (this._transactions = new Client_js_26.TransactionsClient(this._options)));
|
|
146
147
|
}
|
|
147
148
|
get transfers() {
|
|
148
149
|
var _a;
|
|
149
|
-
return ((_a = this._transfers) !== null && _a !== void 0 ? _a : (this._transfers = new
|
|
150
|
+
return ((_a = this._transfers) !== null && _a !== void 0 ? _a : (this._transfers = new Client_js_27.TransfersClient(this._options)));
|
|
150
151
|
}
|
|
151
152
|
get paymentRequests() {
|
|
152
153
|
var _a;
|
|
153
|
-
return ((_a = this._paymentRequests) !== null && _a !== void 0 ? _a : (this._paymentRequests = new
|
|
154
|
+
return ((_a = this._paymentRequests) !== null && _a !== void 0 ? _a : (this._paymentRequests = new Client_js_21.PaymentRequestsClient(this._options)));
|
|
154
155
|
}
|
|
155
156
|
get approvals() {
|
|
156
157
|
var _a;
|
|
@@ -162,11 +163,11 @@ class NaturalClient {
|
|
|
162
163
|
}
|
|
163
164
|
get parties() {
|
|
164
165
|
var _a;
|
|
165
|
-
return ((_a = this._parties) !== null && _a !== void 0 ? _a : (this._parties = new
|
|
166
|
+
return ((_a = this._parties) !== null && _a !== void 0 ? _a : (this._parties = new Client_js_19.PartiesClient(this._options)));
|
|
166
167
|
}
|
|
167
168
|
get wallets() {
|
|
168
169
|
var _a;
|
|
169
|
-
return ((_a = this._wallets) !== null && _a !== void 0 ? _a : (this._wallets = new
|
|
170
|
+
return ((_a = this._wallets) !== null && _a !== void 0 ? _a : (this._wallets = new Client_js_29.WalletsClient(this._options)));
|
|
170
171
|
}
|
|
171
172
|
get externalAccounts() {
|
|
172
173
|
var _a;
|
|
@@ -184,13 +185,17 @@ class NaturalClient {
|
|
|
184
185
|
var _a;
|
|
185
186
|
return ((_a = this._cardSessions) !== null && _a !== void 0 ? _a : (this._cardSessions = new Client_js_8.CardSessionsClient(this._options)));
|
|
186
187
|
}
|
|
188
|
+
get merchantReports() {
|
|
189
|
+
var _a;
|
|
190
|
+
return ((_a = this._merchantReports) !== null && _a !== void 0 ? _a : (this._merchantReports = new Client_js_18.MerchantReportsClient(this._options)));
|
|
191
|
+
}
|
|
187
192
|
get agenticPayments() {
|
|
188
193
|
var _a;
|
|
189
194
|
return ((_a = this._agenticPayments) !== null && _a !== void 0 ? _a : (this._agenticPayments = new Client_js_2.AgenticPaymentsClient(this._options)));
|
|
190
195
|
}
|
|
191
196
|
get webhooks() {
|
|
192
197
|
var _a;
|
|
193
|
-
return ((_a = this._webhooks) !== null && _a !== void 0 ? _a : (this._webhooks = new
|
|
198
|
+
return ((_a = this._webhooks) !== null && _a !== void 0 ? _a : (this._webhooks = new Client_js_30.WebhooksClient(this._options)));
|
|
194
199
|
}
|
|
195
200
|
get events() {
|
|
196
201
|
var _a;
|
|
@@ -198,7 +203,7 @@ class NaturalClient {
|
|
|
198
203
|
}
|
|
199
204
|
get simulations() {
|
|
200
205
|
var _a;
|
|
201
|
-
return ((_a = this._simulations) !== null && _a !== void 0 ? _a : (this._simulations = new
|
|
206
|
+
return ((_a = this._simulations) !== null && _a !== void 0 ? _a : (this._simulations = new Client_js_25.SimulationsClient(this._options)));
|
|
202
207
|
}
|
|
203
208
|
/**
|
|
204
209
|
* Make a passthrough request using the SDK's configured auth, retry, logging, etc.
|
|
@@ -49,6 +49,9 @@ export * from "./invitationLinks/types/index.js";
|
|
|
49
49
|
export * from "./invitations/client/requests/index.js";
|
|
50
50
|
export * as invitations from "./invitations/index.js";
|
|
51
51
|
export * from "./invitations/types/index.js";
|
|
52
|
+
export * from "./merchantReports/client/requests/index.js";
|
|
53
|
+
export * as merchantReports from "./merchantReports/index.js";
|
|
54
|
+
export * from "./merchantReports/types/index.js";
|
|
52
55
|
export * from "./parties/client/requests/index.js";
|
|
53
56
|
export * as parties from "./parties/index.js";
|
|
54
57
|
export * from "./parties/types/index.js";
|
|
@@ -36,7 +36,7 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
36
36
|
};
|
|
37
37
|
})();
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.wire = exports.webhooks = exports.wallets = exports.voiceSessions = exports.transfers = exports.transactions = exports.simulations = exports.refunds = exports.realtime = exports.payments = exports.paymentRequests = exports.paymentIntents = exports.parties = exports.invitations = exports.invitationLinks = exports.externalPartyAccounts = exports.externalParties = exports.externalAccounts = exports.events = exports.customers = exports.check = exports.chargebacks = exports.cardSessions = exports.cardPayments = exports.approvals = exports.apiKeys = exports.agents = exports.agentKeys = exports.agenticPayments = exports.ach = void 0;
|
|
39
|
+
exports.wire = exports.webhooks = exports.wallets = exports.voiceSessions = exports.transfers = exports.transactions = exports.simulations = exports.refunds = exports.realtime = exports.payments = exports.paymentRequests = exports.paymentIntents = exports.parties = exports.merchantReports = exports.invitations = exports.invitationLinks = exports.externalPartyAccounts = exports.externalParties = exports.externalAccounts = exports.events = exports.customers = exports.check = exports.chargebacks = exports.cardSessions = exports.cardPayments = exports.approvals = exports.apiKeys = exports.agents = exports.agentKeys = exports.agenticPayments = exports.ach = void 0;
|
|
40
40
|
__exportStar(require("./ach/client/requests/index.js"), exports);
|
|
41
41
|
exports.ach = __importStar(require("./ach/index.js"));
|
|
42
42
|
__exportStar(require("./ach/types/index.js"), exports);
|
|
@@ -88,6 +88,9 @@ __exportStar(require("./invitationLinks/types/index.js"), exports);
|
|
|
88
88
|
__exportStar(require("./invitations/client/requests/index.js"), exports);
|
|
89
89
|
exports.invitations = __importStar(require("./invitations/index.js"));
|
|
90
90
|
__exportStar(require("./invitations/types/index.js"), exports);
|
|
91
|
+
__exportStar(require("./merchantReports/client/requests/index.js"), exports);
|
|
92
|
+
exports.merchantReports = __importStar(require("./merchantReports/index.js"));
|
|
93
|
+
__exportStar(require("./merchantReports/types/index.js"), exports);
|
|
91
94
|
__exportStar(require("./parties/client/requests/index.js"), exports);
|
|
92
95
|
exports.parties = __importStar(require("./parties/index.js"));
|
|
93
96
|
__exportStar(require("./parties/types/index.js"), exports);
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js";
|
|
2
|
+
import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js";
|
|
3
|
+
import * as core from "../../../../core/index.js";
|
|
4
|
+
import * as Natural from "../../../index.js";
|
|
5
|
+
export declare namespace MerchantReportsClient {
|
|
6
|
+
type Options = BaseClientOptions;
|
|
7
|
+
interface RequestOptions extends BaseRequestOptions {
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Tell Natural which merchant checkouts agents couldn't pay
|
|
12
|
+
*/
|
|
13
|
+
export declare class MerchantReportsClient {
|
|
14
|
+
protected readonly _options: NormalizedClientOptionsWithAuth<MerchantReportsClient.Options>;
|
|
15
|
+
constructor(options?: MerchantReportsClient.Options);
|
|
16
|
+
/**
|
|
17
|
+
* Report a merchant checkout you couldn't pay with a browser token. Natural uses the details to add support for the merchant or its processor.
|
|
18
|
+
*
|
|
19
|
+
* @param {Natural.CreateMerchantReportsRequest} request
|
|
20
|
+
* @param {MerchantReportsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
21
|
+
*
|
|
22
|
+
* @throws {@link Natural.BadRequestError}
|
|
23
|
+
* @throws {@link Natural.UnauthorizedError}
|
|
24
|
+
* @throws {@link Natural.ForbiddenError}
|
|
25
|
+
* @throws {@link Natural.NotFoundError}
|
|
26
|
+
* @throws {@link Natural.ConflictError}
|
|
27
|
+
* @throws {@link Natural.UnprocessableEntityError}
|
|
28
|
+
* @throws {@link Natural.PreconditionError}
|
|
29
|
+
* @throws {@link Natural.TooManyRequestsError}
|
|
30
|
+
* @throws {@link Natural.InternalServerError}
|
|
31
|
+
* @throws {@link Natural.NotImplementedError}
|
|
32
|
+
* @throws {@link Natural.BadGatewayError}
|
|
33
|
+
* @throws {@link Natural.ServiceUnavailableError}
|
|
34
|
+
* @throws {@link errors.NaturalError}
|
|
35
|
+
* @throws {@link errors.NaturalTimeoutError}
|
|
36
|
+
*
|
|
37
|
+
* @example
|
|
38
|
+
* await client.merchantReports.create({
|
|
39
|
+
* merchantUrl: "https://www.example-air.com/booking/payment",
|
|
40
|
+
* outcome: "proxy_error",
|
|
41
|
+
* cardSessionId: "csn_01a0e6466ba3713bba0f0d9d36803b92",
|
|
42
|
+
* proxyErrorCode: "card_proxy_adyen_checkout_unknown",
|
|
43
|
+
* checkout: {
|
|
44
|
+
* cardFieldOrigin: "https://checkoutshopper-live.adyen.com",
|
|
45
|
+
* processorSdkUrl: "https://checkoutshopper-live.cdn.adyen.com/checkoutshopper/sdk/6.35.0/adyen.js",
|
|
46
|
+
* processorSdkVersion: "6.35.0",
|
|
47
|
+
* submitUrl: "POST https://www.example-air.com/payments/v2/create_payment",
|
|
48
|
+
* submitContentType: "application/json",
|
|
49
|
+
* cardFieldNames: ["payment_method.encryptedCardNumber", "payment_method.encryptedSecurityCode"],
|
|
50
|
+
* errorText: "Your payment has been refused. Please try again with a different payment method."
|
|
51
|
+
* },
|
|
52
|
+
* notes: "Card fields were on screen before the claim; the first Pay was refused, a reload fixed it."
|
|
53
|
+
* })
|
|
54
|
+
*/
|
|
55
|
+
create(request: Natural.CreateMerchantReportsRequest, requestOptions?: MerchantReportsClient.RequestOptions): core.HttpResponsePromise<Natural.CreateMerchantReportsResponse>;
|
|
56
|
+
private __create;
|
|
57
|
+
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.MerchantReportsClient = void 0;
|
|
47
|
+
const BaseClient_js_1 = require("../../../../BaseClient.js");
|
|
48
|
+
const headers_js_1 = require("../../../../core/headers.js");
|
|
49
|
+
const core = __importStar(require("../../../../core/index.js"));
|
|
50
|
+
const requestBody_js_1 = require("../../../../core/requestBody.js");
|
|
51
|
+
const environments = __importStar(require("../../../../environments.js"));
|
|
52
|
+
const handleNonStatusCodeError_js_1 = require("../../../../errors/handleNonStatusCodeError.js");
|
|
53
|
+
const errors = __importStar(require("../../../../errors/index.js"));
|
|
54
|
+
const serializers = __importStar(require("../../../../serialization/index.js"));
|
|
55
|
+
const Natural = __importStar(require("../../../index.js"));
|
|
56
|
+
/**
|
|
57
|
+
* Tell Natural which merchant checkouts agents couldn't pay
|
|
58
|
+
*/
|
|
59
|
+
class MerchantReportsClient {
|
|
60
|
+
constructor(options = {}) {
|
|
61
|
+
this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Report a merchant checkout you couldn't pay with a browser token. Natural uses the details to add support for the merchant or its processor.
|
|
65
|
+
*
|
|
66
|
+
* @param {Natural.CreateMerchantReportsRequest} request
|
|
67
|
+
* @param {MerchantReportsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
|
+
*
|
|
69
|
+
* @throws {@link Natural.BadRequestError}
|
|
70
|
+
* @throws {@link Natural.UnauthorizedError}
|
|
71
|
+
* @throws {@link Natural.ForbiddenError}
|
|
72
|
+
* @throws {@link Natural.NotFoundError}
|
|
73
|
+
* @throws {@link Natural.ConflictError}
|
|
74
|
+
* @throws {@link Natural.UnprocessableEntityError}
|
|
75
|
+
* @throws {@link Natural.PreconditionError}
|
|
76
|
+
* @throws {@link Natural.TooManyRequestsError}
|
|
77
|
+
* @throws {@link Natural.InternalServerError}
|
|
78
|
+
* @throws {@link Natural.NotImplementedError}
|
|
79
|
+
* @throws {@link Natural.BadGatewayError}
|
|
80
|
+
* @throws {@link Natural.ServiceUnavailableError}
|
|
81
|
+
* @throws {@link errors.NaturalError}
|
|
82
|
+
* @throws {@link errors.NaturalTimeoutError}
|
|
83
|
+
*
|
|
84
|
+
* @example
|
|
85
|
+
* await client.merchantReports.create({
|
|
86
|
+
* merchantUrl: "https://www.example-air.com/booking/payment",
|
|
87
|
+
* outcome: "proxy_error",
|
|
88
|
+
* cardSessionId: "csn_01a0e6466ba3713bba0f0d9d36803b92",
|
|
89
|
+
* proxyErrorCode: "card_proxy_adyen_checkout_unknown",
|
|
90
|
+
* checkout: {
|
|
91
|
+
* cardFieldOrigin: "https://checkoutshopper-live.adyen.com",
|
|
92
|
+
* processorSdkUrl: "https://checkoutshopper-live.cdn.adyen.com/checkoutshopper/sdk/6.35.0/adyen.js",
|
|
93
|
+
* processorSdkVersion: "6.35.0",
|
|
94
|
+
* submitUrl: "POST https://www.example-air.com/payments/v2/create_payment",
|
|
95
|
+
* submitContentType: "application/json",
|
|
96
|
+
* cardFieldNames: ["payment_method.encryptedCardNumber", "payment_method.encryptedSecurityCode"],
|
|
97
|
+
* errorText: "Your payment has been refused. Please try again with a different payment method."
|
|
98
|
+
* },
|
|
99
|
+
* notes: "Card fields were on screen before the claim; the first Pay was refused, a reload fixed it."
|
|
100
|
+
* })
|
|
101
|
+
*/
|
|
102
|
+
create(request, requestOptions) {
|
|
103
|
+
return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions));
|
|
104
|
+
}
|
|
105
|
+
__create(request, requestOptions) {
|
|
106
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
107
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
108
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
109
|
+
const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ "X-Instance-ID": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.instanceId) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.instanceId }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
110
|
+
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
111
|
+
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.NaturalEnvironment.Production, "merchant-reports"),
|
|
112
|
+
method: "POST",
|
|
113
|
+
headers: _headers,
|
|
114
|
+
contentType: "application/json",
|
|
115
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
116
|
+
requestType: "json",
|
|
117
|
+
body: (0, requestBody_js_1.mergeAdditionalBodyParameters)(serializers.CreateMerchantReportsRequest.jsonOrThrow(request, {
|
|
118
|
+
unrecognizedObjectKeys: "strip",
|
|
119
|
+
omitUndefined: true,
|
|
120
|
+
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.additionalBodyParameters),
|
|
121
|
+
timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
|
|
122
|
+
maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
|
|
123
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
124
|
+
fetchFn: (_m = this._options) === null || _m === void 0 ? void 0 : _m.fetch,
|
|
125
|
+
logging: this._options.logging,
|
|
126
|
+
});
|
|
127
|
+
if (_response.ok) {
|
|
128
|
+
return {
|
|
129
|
+
data: serializers.CreateMerchantReportsResponse.parseOrThrow(_response.body, {
|
|
130
|
+
unrecognizedObjectKeys: "passthrough",
|
|
131
|
+
allowUnrecognizedUnionMembers: true,
|
|
132
|
+
allowUnrecognizedEnumValues: true,
|
|
133
|
+
skipValidation: true,
|
|
134
|
+
breadcrumbsPrefix: ["response"],
|
|
135
|
+
}),
|
|
136
|
+
rawResponse: _response.rawResponse,
|
|
137
|
+
};
|
|
138
|
+
}
|
|
139
|
+
if (_response.error.reason === "status-code") {
|
|
140
|
+
switch (_response.error.statusCode) {
|
|
141
|
+
case 400:
|
|
142
|
+
throw new Natural.BadRequestError(_response.error.body, _response.rawResponse);
|
|
143
|
+
case 401:
|
|
144
|
+
throw new Natural.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
145
|
+
case 403:
|
|
146
|
+
throw new Natural.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
147
|
+
case 404:
|
|
148
|
+
throw new Natural.NotFoundError(_response.error.body, _response.rawResponse);
|
|
149
|
+
case 409:
|
|
150
|
+
throw new Natural.ConflictError(_response.error.body, _response.rawResponse);
|
|
151
|
+
case 422:
|
|
152
|
+
throw new Natural.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
153
|
+
case 428:
|
|
154
|
+
throw new Natural.PreconditionError(_response.error.body, _response.rawResponse);
|
|
155
|
+
case 429:
|
|
156
|
+
throw new Natural.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
157
|
+
case 500:
|
|
158
|
+
throw new Natural.InternalServerError(_response.error.body, _response.rawResponse);
|
|
159
|
+
case 501:
|
|
160
|
+
throw new Natural.NotImplementedError(_response.error.body, _response.rawResponse);
|
|
161
|
+
case 502:
|
|
162
|
+
throw new Natural.BadGatewayError(_response.error.body, _response.rawResponse);
|
|
163
|
+
case 503:
|
|
164
|
+
throw new Natural.ServiceUnavailableError(_response.error.body, _response.rawResponse);
|
|
165
|
+
default:
|
|
166
|
+
throw new errors.NaturalError({
|
|
167
|
+
statusCode: _response.error.statusCode,
|
|
168
|
+
body: _response.error.body,
|
|
169
|
+
rawResponse: _response.rawResponse,
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/merchant-reports");
|
|
174
|
+
});
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
exports.MerchantReportsClient = MerchantReportsClient;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./requests/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./requests/index.js"), exports);
|
package/dist/cjs/api/resources/merchantReports/client/requests/CreateMerchantReportsRequest.d.ts
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type * as Natural from "../../../../index.js";
|
|
2
|
+
/**
|
|
3
|
+
* @example
|
|
4
|
+
* {
|
|
5
|
+
* merchantUrl: "https://www.example-air.com/booking/payment",
|
|
6
|
+
* outcome: "proxy_error",
|
|
7
|
+
* cardSessionId: "csn_01a0e6466ba3713bba0f0d9d36803b92",
|
|
8
|
+
* proxyErrorCode: "card_proxy_adyen_checkout_unknown",
|
|
9
|
+
* checkout: {
|
|
10
|
+
* cardFieldOrigin: "https://checkoutshopper-live.adyen.com",
|
|
11
|
+
* processorSdkUrl: "https://checkoutshopper-live.cdn.adyen.com/checkoutshopper/sdk/6.35.0/adyen.js",
|
|
12
|
+
* processorSdkVersion: "6.35.0",
|
|
13
|
+
* submitUrl: "POST https://www.example-air.com/payments/v2/create_payment",
|
|
14
|
+
* submitContentType: "application/json",
|
|
15
|
+
* cardFieldNames: ["payment_method.encryptedCardNumber", "payment_method.encryptedSecurityCode"],
|
|
16
|
+
* errorText: "Your payment has been refused. Please try again with a different payment method."
|
|
17
|
+
* },
|
|
18
|
+
* notes: "Card fields were on screen before the claim; the first Pay was refused, a reload fixed it."
|
|
19
|
+
* }
|
|
20
|
+
*/
|
|
21
|
+
export interface CreateMerchantReportsRequest {
|
|
22
|
+
/** The checkout page you were on. Strip query strings that carry personal data or tokens. */
|
|
23
|
+
merchantUrl: string;
|
|
24
|
+
/** What stopped the payment. host_not_allowed: the card request went to a host you couldn't put in allowedHosts. proxy_error: the proxy answered an error (put its code in proxyErrorCode). card_refused: the merchant or processor refused the card. three_ds_required: a 3DS challenge you couldn't complete. bot_wall: a CAPTCHA or bot check kept you from the card form. other: anything else; say what in notes. */
|
|
25
|
+
outcome: Natural.CreateMerchantReportsRequestOutcome;
|
|
26
|
+
/** The card session the attempt used, if any. */
|
|
27
|
+
cardSessionId?: string;
|
|
28
|
+
/** The proxy's error code when outcome is proxy_error (card_proxy_adyen_checkout_unknown, ...). */
|
|
29
|
+
proxyErrorCode?: string;
|
|
30
|
+
/** Details of the checkout, for adding support later. Fill in what you saw; never card data. */
|
|
31
|
+
checkout?: Natural.CreateMerchantReportsRequestCheckout;
|
|
32
|
+
/** What you tried and what happened, in your own words. */
|
|
33
|
+
notes?: string;
|
|
34
|
+
/** Customer party you were acting for (pty_*). Omit when acting as your own party. */
|
|
35
|
+
customerPartyId?: string;
|
|
36
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type { CreateMerchantReportsRequest } from "./CreateMerchantReportsRequest.js";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.MerchantReportsClient = void 0;
|
|
19
|
+
var Client_js_1 = require("./client/Client.js");
|
|
20
|
+
Object.defineProperty(exports, "MerchantReportsClient", { enumerable: true, get: function () { return Client_js_1.MerchantReportsClient; } });
|
|
21
|
+
__exportStar(require("./client/index.js"), exports);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|
|
18
|
+
__exportStar(require("./types/index.js"), exports);
|
package/dist/cjs/api/resources/merchantReports/types/CreateMerchantReportsRequestCheckout.d.ts
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Details of the checkout, for adding support later. Fill in what you saw; never card data.
|
|
3
|
+
*/
|
|
4
|
+
export interface CreateMerchantReportsRequestCheckout {
|
|
5
|
+
/** Where the card number field comes from: the merchant page itself, or the iframe origin (https://checkoutshopper-live.adyen.com, https://flex.cybersource.com, ...). */
|
|
6
|
+
cardFieldOrigin?: string;
|
|
7
|
+
/** URL of the payment script the page loads (the processor's SDK or the merchant's own encryption bundle). */
|
|
8
|
+
processorSdkUrl?: string;
|
|
9
|
+
/** Its version, when the URL or script says. */
|
|
10
|
+
processorSdkVersion?: string;
|
|
11
|
+
/** The request that carries the card or its token out of the browser (method and URL). */
|
|
12
|
+
submitUrl?: string;
|
|
13
|
+
/** Its Content-Type. */
|
|
14
|
+
submitContentType?: string;
|
|
15
|
+
/** Field names in that request that carry the card or its ciphertext (encryptedCardNumber, token, ...). */
|
|
16
|
+
cardFieldNames?: string[];
|
|
17
|
+
/** The error the page or the proxy showed, verbatim. */
|
|
18
|
+
errorText?: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** What stopped the payment. host_not_allowed: the card request went to a host you couldn't put in allowedHosts. proxy_error: the proxy answered an error (put its code in proxyErrorCode). card_refused: the merchant or processor refused the card. three_ds_required: a 3DS challenge you couldn't complete. bot_wall: a CAPTCHA or bot check kept you from the card form. other: anything else; say what in notes. */
|
|
2
|
+
export declare const CreateMerchantReportsRequestOutcome: {
|
|
3
|
+
readonly HostNotAllowed: "host_not_allowed";
|
|
4
|
+
readonly ProxyError: "proxy_error";
|
|
5
|
+
readonly CardRefused: "card_refused";
|
|
6
|
+
readonly ThreeDsRequired: "three_ds_required";
|
|
7
|
+
readonly BotWall: "bot_wall";
|
|
8
|
+
readonly Other: "other";
|
|
9
|
+
};
|
|
10
|
+
export type CreateMerchantReportsRequestOutcome = (typeof CreateMerchantReportsRequestOutcome)[keyof typeof CreateMerchantReportsRequestOutcome];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.CreateMerchantReportsRequestOutcome = void 0;
|
|
5
|
+
/** What stopped the payment. host_not_allowed: the card request went to a host you couldn't put in allowedHosts. proxy_error: the proxy answered an error (put its code in proxyErrorCode). card_refused: the merchant or processor refused the card. three_ds_required: a 3DS challenge you couldn't complete. bot_wall: a CAPTCHA or bot check kept you from the card form. other: anything else; say what in notes. */
|
|
6
|
+
exports.CreateMerchantReportsRequestOutcome = {
|
|
7
|
+
HostNotAllowed: "host_not_allowed",
|
|
8
|
+
ProxyError: "proxy_error",
|
|
9
|
+
CardRefused: "card_refused",
|
|
10
|
+
ThreeDsRequired: "three_ds_required",
|
|
11
|
+
BotWall: "bot_wall",
|
|
12
|
+
Other: "other",
|
|
13
|
+
};
|