@delopay/sdk 0.266.0 → 0.269.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-T7DDPU7M.js → chunk-HEDL3UHE.js} +301 -10
- package/dist/chunk-HEDL3UHE.js.map +1 -0
- package/dist/index.cjs +302 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +568 -39
- package/dist/index.d.ts +568 -39
- package/dist/index.js +5 -1
- package/dist/internal.cjs +378 -9
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +44 -3
- package/dist/internal.d.ts +44 -3
- package/dist/internal.js +81 -1
- package/dist/internal.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunk-T7DDPU7M.js.map +0 -1
package/dist/internal.js
CHANGED
|
@@ -23,6 +23,7 @@ import {
|
|
|
23
23
|
BUILTIN_PAYMENT_ICON_KEYS,
|
|
24
24
|
BuyerBlocklist,
|
|
25
25
|
BuyerConversations,
|
|
26
|
+
BuyerEvidenceReviews,
|
|
26
27
|
CARD_FIELD_CHROMES,
|
|
27
28
|
CARD_FIELD_FONT_SIZES,
|
|
28
29
|
CARD_FIELD_WEIGHTS,
|
|
@@ -113,6 +114,7 @@ import {
|
|
|
113
114
|
SellToRestrictions,
|
|
114
115
|
Settings,
|
|
115
116
|
Settlement,
|
|
117
|
+
ShopLabels,
|
|
116
118
|
Subscriptions,
|
|
117
119
|
UNKNOWN_SECTION_ORDER,
|
|
118
120
|
WCAG_AA_TEXT,
|
|
@@ -251,7 +253,7 @@ import {
|
|
|
251
253
|
visibleCustomFields,
|
|
252
254
|
whopAccentSwatch,
|
|
253
255
|
whopCardElement
|
|
254
|
-
} from "./chunk-
|
|
256
|
+
} from "./chunk-HEDL3UHE.js";
|
|
255
257
|
|
|
256
258
|
// src/internal/resources/admin.ts
|
|
257
259
|
var Admin = class {
|
|
@@ -577,6 +579,82 @@ var AdminPortal = class {
|
|
|
577
579
|
query: params
|
|
578
580
|
});
|
|
579
581
|
}
|
|
582
|
+
// --- Buyer evidence review --------------------------------------------------
|
|
583
|
+
/**
|
|
584
|
+
* DeloPay's review queue of buyers' evidence, the nearest target first,
|
|
585
|
+
* across merchants unless `merchant_id` narrows it.
|
|
586
|
+
*/
|
|
587
|
+
async listBuyerEvidence(params) {
|
|
588
|
+
return this.request("GET", "/admin-portal/buyer-evidence", {
|
|
589
|
+
query: params
|
|
590
|
+
});
|
|
591
|
+
}
|
|
592
|
+
/** One case's evidence with every step and file, internal ones included. */
|
|
593
|
+
async getBuyerEvidence(evidenceId) {
|
|
594
|
+
return this.request("GET", `/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}`);
|
|
595
|
+
}
|
|
596
|
+
/** Download a file of a case's evidence. */
|
|
597
|
+
async downloadBuyerEvidenceFile(evidenceId, fileId) {
|
|
598
|
+
return this.request(
|
|
599
|
+
"GET",
|
|
600
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/files/${encodeURIComponent(fileId)}`,
|
|
601
|
+
{ responseType: "blob" }
|
|
602
|
+
);
|
|
603
|
+
}
|
|
604
|
+
/**
|
|
605
|
+
* Ask the buyer for more, by a cut-off. Refused once a result has closed
|
|
606
|
+
* the review.
|
|
607
|
+
*/
|
|
608
|
+
async requestBuyerEvidenceInformation(evidenceId, params) {
|
|
609
|
+
return this.request(
|
|
610
|
+
"POST",
|
|
611
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/information-requests`,
|
|
612
|
+
{ body: params }
|
|
613
|
+
);
|
|
614
|
+
}
|
|
615
|
+
/** An answer the buyer sees. */
|
|
616
|
+
async replyToBuyerEvidence(evidenceId, params) {
|
|
617
|
+
return this.request(
|
|
618
|
+
"POST",
|
|
619
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/replies`,
|
|
620
|
+
{ body: params }
|
|
621
|
+
);
|
|
622
|
+
}
|
|
623
|
+
/**
|
|
624
|
+
* Record the result, which closes the review. It never refunds a payment
|
|
625
|
+
* and never decides a dispute with the payment provider.
|
|
626
|
+
*/
|
|
627
|
+
async reviewBuyerEvidence(evidenceId, params) {
|
|
628
|
+
return this.request(
|
|
629
|
+
"POST",
|
|
630
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/reviews`,
|
|
631
|
+
{ body: params }
|
|
632
|
+
);
|
|
633
|
+
}
|
|
634
|
+
/** Move the buyer's cut-off, with a reason the buyer sees. */
|
|
635
|
+
async moveBuyerEvidenceDeadline(evidenceId, params) {
|
|
636
|
+
return this.request(
|
|
637
|
+
"PUT",
|
|
638
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/deadline`,
|
|
639
|
+
{ body: params }
|
|
640
|
+
);
|
|
641
|
+
}
|
|
642
|
+
/** Make a user responsible for the review: an id, `me`, or `null` for nobody. */
|
|
643
|
+
async assignBuyerEvidence(evidenceId, params) {
|
|
644
|
+
return this.request(
|
|
645
|
+
"PUT",
|
|
646
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/reviewer`,
|
|
647
|
+
{ body: params }
|
|
648
|
+
);
|
|
649
|
+
}
|
|
650
|
+
/** An internal note, never shown to the buyer. */
|
|
651
|
+
async noteBuyerEvidence(evidenceId, params) {
|
|
652
|
+
return this.request(
|
|
653
|
+
"POST",
|
|
654
|
+
`/admin-portal/buyer-evidence/${encodeURIComponent(evidenceId)}/notes`,
|
|
655
|
+
{ body: params }
|
|
656
|
+
);
|
|
657
|
+
}
|
|
580
658
|
async analytics(params) {
|
|
581
659
|
return this.request("GET", "/admin-portal/analytics", {
|
|
582
660
|
query: params
|
|
@@ -1909,6 +1987,7 @@ export {
|
|
|
1909
1987
|
BUILTIN_PAYMENT_ICON_KEYS,
|
|
1910
1988
|
BuyerBlocklist,
|
|
1911
1989
|
BuyerConversations,
|
|
1990
|
+
BuyerEvidenceReviews,
|
|
1912
1991
|
CARD_FIELD_CHROMES,
|
|
1913
1992
|
CARD_FIELD_FONT_SIZES,
|
|
1914
1993
|
CARD_FIELD_WEIGHTS,
|
|
@@ -2012,6 +2091,7 @@ export {
|
|
|
2012
2091
|
SellToRestrictions,
|
|
2013
2092
|
Settings,
|
|
2014
2093
|
Settlement,
|
|
2094
|
+
ShopLabels,
|
|
2015
2095
|
Subscriptions,
|
|
2016
2096
|
UNKNOWN_SECTION_ORDER,
|
|
2017
2097
|
WCAG_AA_TEXT,
|