@delopay/sdk 0.244.0 → 0.246.0
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/{chunk-LT6DP5KX.js → chunk-LFNDWJ5X.js} +43 -1
- package/dist/chunk-LFNDWJ5X.js.map +1 -0
- package/dist/index.cjs +42 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +303 -4
- package/dist/index.d.ts +303 -4
- package/dist/index.js +1 -1
- package/dist/internal.cjs +71 -0
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +15 -3
- package/dist/internal.d.ts +15 -3
- package/dist/internal.js +30 -1
- package/dist/internal.js.map +1 -1
- package/package.json +17 -18
- package/dist/chunk-LT6DP5KX.js.map +0 -1
|
@@ -2351,6 +2351,48 @@ var Payments = class {
|
|
|
2351
2351
|
options
|
|
2352
2352
|
);
|
|
2353
2353
|
}
|
|
2354
|
+
/**
|
|
2355
|
+
* The traffic of a payment, oldest first: the requests DeloPay sent to the
|
|
2356
|
+
* payment provider, the webhooks the provider sent, and the webhooks DeloPay
|
|
2357
|
+
* sent to the shop with every delivery attempt. No payloads; read an entry
|
|
2358
|
+
* with {@link getLogConnectorCall}, {@link getLogIncomingWebhook} or
|
|
2359
|
+
* {@link getLogOutgoingWebhook}. Dashboard (JWT) only.
|
|
2360
|
+
*
|
|
2361
|
+
* @param paymentId - The payment intent ID.
|
|
2362
|
+
*
|
|
2363
|
+
* @example
|
|
2364
|
+
* ```typescript
|
|
2365
|
+
* const logs = await delopay.payments.listLogs('pay_abc123');
|
|
2366
|
+
* if (!logs.psp_traffic_recorded) console.log('provider traffic is not recorded');
|
|
2367
|
+
* ```
|
|
2368
|
+
*/
|
|
2369
|
+
async listLogs(paymentId, options) {
|
|
2370
|
+
return this.request("GET", `/payments/${encodeURIComponent(paymentId)}/logs`, options);
|
|
2371
|
+
}
|
|
2372
|
+
/** One provider request of a payment, with its masked request, response and error. */
|
|
2373
|
+
async getLogConnectorCall(paymentId, callId, options) {
|
|
2374
|
+
return this.request(
|
|
2375
|
+
"GET",
|
|
2376
|
+
`/payments/${encodeURIComponent(paymentId)}/logs/connector-calls/${encodeURIComponent(callId)}`,
|
|
2377
|
+
options
|
|
2378
|
+
);
|
|
2379
|
+
}
|
|
2380
|
+
/** One provider webhook of a payment, with its masked headers and body. */
|
|
2381
|
+
async getLogIncomingWebhook(paymentId, eventId, options) {
|
|
2382
|
+
return this.request(
|
|
2383
|
+
"GET",
|
|
2384
|
+
`/payments/${encodeURIComponent(paymentId)}/logs/incoming-webhooks/${encodeURIComponent(eventId)}`,
|
|
2385
|
+
options
|
|
2386
|
+
);
|
|
2387
|
+
}
|
|
2388
|
+
/** Every delivery attempt of one shop webhook of a payment, with request and response. */
|
|
2389
|
+
async getLogOutgoingWebhook(paymentId, initialAttemptId, options) {
|
|
2390
|
+
return this.request(
|
|
2391
|
+
"GET",
|
|
2392
|
+
`/payments/${encodeURIComponent(paymentId)}/logs/outgoing-webhooks/${encodeURIComponent(initialAttemptId)}`,
|
|
2393
|
+
options
|
|
2394
|
+
);
|
|
2395
|
+
}
|
|
2354
2396
|
/**
|
|
2355
2397
|
* What the payment's rail says about settling each attempt: whether the
|
|
2356
2398
|
* money is still `pending` in the rail's hands, `available` in its balance
|
|
@@ -12913,4 +12955,4 @@ export {
|
|
|
12913
12955
|
decodeNativePanes,
|
|
12914
12956
|
encodeNativePanes
|
|
12915
12957
|
};
|
|
12916
|
-
//# sourceMappingURL=chunk-
|
|
12958
|
+
//# sourceMappingURL=chunk-LFNDWJ5X.js.map
|