@delopay/sdk 0.26.0 → 0.27.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-XK6RSV5Y.js → chunk-TE4LLC2R.js} +133 -133
- package/dist/chunk-TE4LLC2R.js.map +1 -0
- package/dist/index.cjs +132 -132
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +40 -40
- package/dist/index.d.ts +40 -40
- package/dist/index.js +1 -1
- package/dist/internal.cjs +132 -132
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-XK6RSV5Y.js.map +0 -1
package/dist/index.cjs
CHANGED
|
@@ -115,7 +115,7 @@ var ApiKeys = class {
|
|
|
115
115
|
* ```
|
|
116
116
|
*/
|
|
117
117
|
async create(merchantId, params) {
|
|
118
|
-
return this.request("POST", `/
|
|
118
|
+
return this.request("POST", `/api-keys/${encodeURIComponent(merchantId)}`, { body: params });
|
|
119
119
|
}
|
|
120
120
|
/**
|
|
121
121
|
* Retrieve metadata about an API key (does not return the plaintext secret).
|
|
@@ -127,7 +127,7 @@ var ApiKeys = class {
|
|
|
127
127
|
async retrieve(merchantId, keyId) {
|
|
128
128
|
return this.request(
|
|
129
129
|
"GET",
|
|
130
|
-
`/
|
|
130
|
+
`/api-keys/${encodeURIComponent(merchantId)}/${encodeURIComponent(keyId)}`
|
|
131
131
|
);
|
|
132
132
|
}
|
|
133
133
|
/**
|
|
@@ -141,7 +141,7 @@ var ApiKeys = class {
|
|
|
141
141
|
async update(merchantId, keyId, params) {
|
|
142
142
|
return this.request(
|
|
143
143
|
"POST",
|
|
144
|
-
`/
|
|
144
|
+
`/api-keys/${encodeURIComponent(merchantId)}/${encodeURIComponent(keyId)}`,
|
|
145
145
|
{ body: params }
|
|
146
146
|
);
|
|
147
147
|
}
|
|
@@ -155,7 +155,7 @@ var ApiKeys = class {
|
|
|
155
155
|
async revoke(merchantId, keyId) {
|
|
156
156
|
return this.request(
|
|
157
157
|
"DELETE",
|
|
158
|
-
`/
|
|
158
|
+
`/api-keys/${encodeURIComponent(merchantId)}/${encodeURIComponent(keyId)}`
|
|
159
159
|
);
|
|
160
160
|
}
|
|
161
161
|
/**
|
|
@@ -165,7 +165,7 @@ var ApiKeys = class {
|
|
|
165
165
|
* @returns Array of API key metadata objects.
|
|
166
166
|
*/
|
|
167
167
|
async list(merchantId) {
|
|
168
|
-
return this.request("GET", `/
|
|
168
|
+
return this.request("GET", `/api-keys/${encodeURIComponent(merchantId)}/list`);
|
|
169
169
|
}
|
|
170
170
|
};
|
|
171
171
|
|
|
@@ -196,11 +196,11 @@ var Authentication = class {
|
|
|
196
196
|
body: params
|
|
197
197
|
});
|
|
198
198
|
}
|
|
199
|
-
/** Enable authn methods token. `POST /authentication/{authId}/
|
|
199
|
+
/** Enable authn methods token. `POST /authentication/{authId}/enabled-authn-methods-token` */
|
|
200
200
|
async enabledAuthnMethodsToken(authId, params) {
|
|
201
201
|
return this.request(
|
|
202
202
|
"POST",
|
|
203
|
-
`/authentication/${encodeURIComponent(authId)}/
|
|
203
|
+
`/authentication/${encodeURIComponent(authId)}/enabled-authn-methods-token`,
|
|
204
204
|
{
|
|
205
205
|
body: params
|
|
206
206
|
}
|
|
@@ -434,9 +434,9 @@ var Connectors = class {
|
|
|
434
434
|
`/account/${encodeURIComponent(merchantId)}/connectors/webhooks/${encodeURIComponent(connectorId)}`
|
|
435
435
|
);
|
|
436
436
|
}
|
|
437
|
-
/** List available payment methods. `GET /account/
|
|
437
|
+
/** List available payment methods. `GET /account/payment-methods` */
|
|
438
438
|
async listPaymentMethods() {
|
|
439
|
-
return this.request("GET", "/account/
|
|
439
|
+
return this.request("GET", "/account/payment-methods");
|
|
440
440
|
}
|
|
441
441
|
};
|
|
442
442
|
|
|
@@ -507,9 +507,9 @@ var Customers = class {
|
|
|
507
507
|
});
|
|
508
508
|
}
|
|
509
509
|
// --- OLAP extensions (Task 4.6) ---
|
|
510
|
-
/** List customers with count. `GET /customers/
|
|
510
|
+
/** List customers with count. `GET /customers/list-with-count` */
|
|
511
511
|
async listWithCount(params) {
|
|
512
|
-
return this.request("GET", "/customers/
|
|
512
|
+
return this.request("GET", "/customers/list-with-count", {
|
|
513
513
|
query: params
|
|
514
514
|
});
|
|
515
515
|
}
|
|
@@ -643,7 +643,7 @@ var EphemeralKeys = class {
|
|
|
643
643
|
* ```
|
|
644
644
|
*/
|
|
645
645
|
async create(params) {
|
|
646
|
-
return this.request("POST", "/
|
|
646
|
+
return this.request("POST", "/ephemeral-keys", { body: params });
|
|
647
647
|
}
|
|
648
648
|
/**
|
|
649
649
|
* Invalidate an ephemeral key before it expires.
|
|
@@ -652,7 +652,7 @@ var EphemeralKeys = class {
|
|
|
652
652
|
* @returns The deleted key object.
|
|
653
653
|
*/
|
|
654
654
|
async delete(keyId) {
|
|
655
|
-
return this.request("DELETE", `/
|
|
655
|
+
return this.request("DELETE", `/ephemeral-keys/${encodeURIComponent(keyId)}`);
|
|
656
656
|
}
|
|
657
657
|
};
|
|
658
658
|
|
|
@@ -695,7 +695,7 @@ var Fees = class {
|
|
|
695
695
|
* @param merchantId - The merchant account ID.
|
|
696
696
|
*/
|
|
697
697
|
async create(params, merchantId) {
|
|
698
|
-
return this.request("POST", "/
|
|
698
|
+
return this.request("POST", "/merchant-fees", {
|
|
699
699
|
body: params,
|
|
700
700
|
query: { merchant_id: merchantId }
|
|
701
701
|
});
|
|
@@ -706,7 +706,7 @@ var Fees = class {
|
|
|
706
706
|
* @param merchantId - The merchant account ID.
|
|
707
707
|
*/
|
|
708
708
|
async list(merchantId) {
|
|
709
|
-
return this.request("GET", "/
|
|
709
|
+
return this.request("GET", "/merchant-fees/list", {
|
|
710
710
|
query: { merchant_id: merchantId }
|
|
711
711
|
});
|
|
712
712
|
}
|
|
@@ -717,7 +717,7 @@ var Fees = class {
|
|
|
717
717
|
* @param params - Fields to update.
|
|
718
718
|
*/
|
|
719
719
|
async update(feeId, params) {
|
|
720
|
-
return this.request("PUT", `/
|
|
720
|
+
return this.request("PUT", `/merchant-fees/${encodeURIComponent(feeId)}`, { body: params });
|
|
721
721
|
}
|
|
722
722
|
/**
|
|
723
723
|
* Delete a merchant-scoped fee schedule.
|
|
@@ -725,7 +725,7 @@ var Fees = class {
|
|
|
725
725
|
* @param feeId - The fee schedule ID.
|
|
726
726
|
*/
|
|
727
727
|
async delete(feeId) {
|
|
728
|
-
return this.request("DELETE", `/
|
|
728
|
+
return this.request("DELETE", `/merchant-fees/${encodeURIComponent(feeId)}`);
|
|
729
729
|
}
|
|
730
730
|
};
|
|
731
731
|
|
|
@@ -813,7 +813,7 @@ var PaymentLinks = class {
|
|
|
813
813
|
* @returns The payment link details.
|
|
814
814
|
*/
|
|
815
815
|
async retrieve(linkId) {
|
|
816
|
-
return this.request("GET", `/
|
|
816
|
+
return this.request("GET", `/payment-link/${encodeURIComponent(linkId)}`);
|
|
817
817
|
}
|
|
818
818
|
/**
|
|
819
819
|
* List payment links, optionally filtered by status or date range.
|
|
@@ -822,20 +822,20 @@ var PaymentLinks = class {
|
|
|
822
822
|
* @returns Paginated list of payment links.
|
|
823
823
|
*/
|
|
824
824
|
async list(params) {
|
|
825
|
-
return this.request("POST", "/
|
|
825
|
+
return this.request("POST", "/payment-link/list", { body: params });
|
|
826
826
|
}
|
|
827
|
-
/** Initiate (render) a payment link page. `GET /
|
|
827
|
+
/** Initiate (render) a payment link page. `GET /payment-link/{merchantId}/{paymentId}` */
|
|
828
828
|
async initiate(merchantId, paymentId) {
|
|
829
829
|
return this.request(
|
|
830
830
|
"GET",
|
|
831
|
-
`/
|
|
831
|
+
`/payment-link/${encodeURIComponent(merchantId)}/${encodeURIComponent(paymentId)}`
|
|
832
832
|
);
|
|
833
833
|
}
|
|
834
|
-
/** Get payment link status. `GET /
|
|
834
|
+
/** Get payment link status. `GET /payment-linkstatus/{merchantId}/{paymentId}` */
|
|
835
835
|
async status(merchantId, paymentId) {
|
|
836
836
|
return this.request(
|
|
837
837
|
"GET",
|
|
838
|
-
`/
|
|
838
|
+
`/payment-linkstatus/${encodeURIComponent(merchantId)}/${encodeURIComponent(paymentId)}`
|
|
839
839
|
);
|
|
840
840
|
}
|
|
841
841
|
};
|
|
@@ -861,7 +861,7 @@ var PaymentMethods = class {
|
|
|
861
861
|
* ```
|
|
862
862
|
*/
|
|
863
863
|
async create(params) {
|
|
864
|
-
return this.request("POST", "/
|
|
864
|
+
return this.request("POST", "/payment-methods", { body: params });
|
|
865
865
|
}
|
|
866
866
|
/**
|
|
867
867
|
* Retrieve a saved payment method by its ID.
|
|
@@ -870,7 +870,7 @@ var PaymentMethods = class {
|
|
|
870
870
|
* @returns The payment method.
|
|
871
871
|
*/
|
|
872
872
|
async retrieve(methodId) {
|
|
873
|
-
return this.request("GET", `/
|
|
873
|
+
return this.request("GET", `/payment-methods/${encodeURIComponent(methodId)}`);
|
|
874
874
|
}
|
|
875
875
|
/**
|
|
876
876
|
* Update an existing payment method (e.g. update card expiry).
|
|
@@ -880,7 +880,7 @@ var PaymentMethods = class {
|
|
|
880
880
|
* @returns The updated payment method.
|
|
881
881
|
*/
|
|
882
882
|
async update(methodId, params) {
|
|
883
|
-
return this.request("POST", `/
|
|
883
|
+
return this.request("POST", `/payment-methods/${encodeURIComponent(methodId)}/update`, {
|
|
884
884
|
body: params
|
|
885
885
|
});
|
|
886
886
|
}
|
|
@@ -891,7 +891,7 @@ var PaymentMethods = class {
|
|
|
891
891
|
* @returns Deletion confirmation.
|
|
892
892
|
*/
|
|
893
893
|
async delete(methodId) {
|
|
894
|
-
return this.request("DELETE", `/
|
|
894
|
+
return this.request("DELETE", `/payment-methods/${encodeURIComponent(methodId)}`);
|
|
895
895
|
}
|
|
896
896
|
/**
|
|
897
897
|
* List payment methods using a client secret.
|
|
@@ -900,7 +900,7 @@ var PaymentMethods = class {
|
|
|
900
900
|
* @returns Array of payment methods.
|
|
901
901
|
*/
|
|
902
902
|
async list(params) {
|
|
903
|
-
return this.request("GET", "/
|
|
903
|
+
return this.request("GET", "/payment-methods", {
|
|
904
904
|
query: params
|
|
905
905
|
});
|
|
906
906
|
}
|
|
@@ -921,7 +921,7 @@ var PaymentMethods = class {
|
|
|
921
921
|
* ```
|
|
922
922
|
*/
|
|
923
923
|
async listForCustomer(customerId, params) {
|
|
924
|
-
return this.request("GET", `/customers/${encodeURIComponent(customerId)}/
|
|
924
|
+
return this.request("GET", `/customers/${encodeURIComponent(customerId)}/payment-methods`, {
|
|
925
925
|
query: params
|
|
926
926
|
});
|
|
927
927
|
}
|
|
@@ -935,55 +935,55 @@ var PaymentMethods = class {
|
|
|
935
935
|
async setDefault(customerId, methodId) {
|
|
936
936
|
return this.request(
|
|
937
937
|
"POST",
|
|
938
|
-
`/customers/${encodeURIComponent(customerId)}/
|
|
938
|
+
`/customers/${encodeURIComponent(customerId)}/payment-methods/${encodeURIComponent(methodId)}/default`
|
|
939
939
|
);
|
|
940
940
|
}
|
|
941
941
|
// --- Advanced operations (Task 3.3) ---
|
|
942
|
-
/** Migrate a payment method. `POST /
|
|
942
|
+
/** Migrate a payment method. `POST /payment-methods/migrate` */
|
|
943
943
|
async migrate(params) {
|
|
944
|
-
return this.request("POST", "/
|
|
944
|
+
return this.request("POST", "/payment-methods/migrate", { body: params });
|
|
945
945
|
}
|
|
946
|
-
/** Batch migrate payment methods. `POST /
|
|
946
|
+
/** Batch migrate payment methods. `POST /payment-methods/migrate-batch` */
|
|
947
947
|
async migrateBatch(params) {
|
|
948
|
-
return this.request("POST", "/
|
|
948
|
+
return this.request("POST", "/payment-methods/migrate-batch", { body: params });
|
|
949
949
|
}
|
|
950
|
-
/** Batch update payment methods. `POST /
|
|
950
|
+
/** Batch update payment methods. `POST /payment-methods/update-batch` */
|
|
951
951
|
async updateBatch(params) {
|
|
952
|
-
return this.request("POST", "/
|
|
952
|
+
return this.request("POST", "/payment-methods/update-batch", { body: params });
|
|
953
953
|
}
|
|
954
|
-
/** Batch retrieve payment methods. `GET /
|
|
954
|
+
/** Batch retrieve payment methods. `GET /payment-methods/batch` */
|
|
955
955
|
async batchRetrieve(params) {
|
|
956
|
-
return this.request("GET", "/
|
|
956
|
+
return this.request("GET", "/payment-methods/batch", { query: params });
|
|
957
957
|
}
|
|
958
|
-
/** Tokenize a card. `POST /
|
|
958
|
+
/** Tokenize a card. `POST /payment-methods/tokenize-card` */
|
|
959
959
|
async tokenizeCard(params) {
|
|
960
|
-
return this.request("POST", "/
|
|
960
|
+
return this.request("POST", "/payment-methods/tokenize-card", { body: params });
|
|
961
961
|
}
|
|
962
|
-
/** Batch tokenize cards. `POST /
|
|
962
|
+
/** Batch tokenize cards. `POST /payment-methods/tokenize-card-batch` */
|
|
963
963
|
async tokenizeCardBatch(params) {
|
|
964
|
-
return this.request("POST", "/
|
|
964
|
+
return this.request("POST", "/payment-methods/tokenize-card-batch", { body: params });
|
|
965
965
|
}
|
|
966
|
-
/** Initiate payment method collect link flow. `POST /
|
|
966
|
+
/** Initiate payment method collect link flow. `POST /payment-methods/collect` */
|
|
967
967
|
async collect(params) {
|
|
968
|
-
return this.request("POST", "/
|
|
968
|
+
return this.request("POST", "/payment-methods/collect", { body: params });
|
|
969
969
|
}
|
|
970
|
-
/** Save a payment method. `POST /
|
|
970
|
+
/** Save a payment method. `POST /payment-methods/{methodId}/save` */
|
|
971
971
|
async save(methodId, params) {
|
|
972
|
-
return this.request("POST", `/
|
|
972
|
+
return this.request("POST", `/payment-methods/${encodeURIComponent(methodId)}/save`, {
|
|
973
973
|
body: params
|
|
974
974
|
});
|
|
975
975
|
}
|
|
976
|
-
/** Create payment method auth link token. `POST /
|
|
976
|
+
/** Create payment method auth link token. `POST /payment-methods/auth/link` */
|
|
977
977
|
async createAuthLink(params) {
|
|
978
|
-
return this.request("POST", "/
|
|
978
|
+
return this.request("POST", "/payment-methods/auth/link", { body: params });
|
|
979
979
|
}
|
|
980
|
-
/** Exchange payment method auth token. `POST /
|
|
980
|
+
/** Exchange payment method auth token. `POST /payment-methods/auth/exchange` */
|
|
981
981
|
async exchangeAuthToken(params) {
|
|
982
|
-
return this.request("POST", "/
|
|
982
|
+
return this.request("POST", "/payment-methods/auth/exchange", { body: params });
|
|
983
983
|
}
|
|
984
|
-
/** Tokenize card using existing PM. `POST /
|
|
984
|
+
/** Tokenize card using existing PM. `POST /payment-methods/{methodId}/tokenize-card` */
|
|
985
985
|
async tokenizeCardForMethod(methodId, params) {
|
|
986
|
-
return this.request("POST", `/
|
|
986
|
+
return this.request("POST", `/payment-methods/${encodeURIComponent(methodId)}/tokenize-card`, {
|
|
987
987
|
body: params
|
|
988
988
|
});
|
|
989
989
|
}
|
|
@@ -1108,57 +1108,57 @@ var Payments = class {
|
|
|
1108
1108
|
});
|
|
1109
1109
|
}
|
|
1110
1110
|
// --- Advanced operations (Task 3.2) ---
|
|
1111
|
-
/** Generate session tokens. `POST /payments/
|
|
1111
|
+
/** Generate session tokens. `POST /payments/session-tokens` */
|
|
1112
1112
|
async sessionTokens(params) {
|
|
1113
|
-
return this.request("POST", "/payments/
|
|
1113
|
+
return this.request("POST", "/payments/session-tokens", { body: params });
|
|
1114
1114
|
}
|
|
1115
1115
|
/** Retrieve payment with gateway credentials. `POST /payments/sync` */
|
|
1116
1116
|
async sync(params) {
|
|
1117
1117
|
return this.request("POST", "/payments/sync", { body: params });
|
|
1118
1118
|
}
|
|
1119
|
-
/** Cancel after partial capture. `POST /payments/{paymentId}/
|
|
1119
|
+
/** Cancel after partial capture. `POST /payments/{paymentId}/cancel-post-capture` */
|
|
1120
1120
|
async cancelPostCapture(paymentId, params) {
|
|
1121
|
-
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/
|
|
1121
|
+
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/cancel-post-capture`, {
|
|
1122
1122
|
body: params
|
|
1123
1123
|
});
|
|
1124
1124
|
}
|
|
1125
|
-
/** Incrementally authorize more funds. `POST /payments/{paymentId}/
|
|
1125
|
+
/** Incrementally authorize more funds. `POST /payments/{paymentId}/incremental-authorization` */
|
|
1126
1126
|
async incrementalAuthorization(paymentId, params) {
|
|
1127
1127
|
return this.request(
|
|
1128
1128
|
"POST",
|
|
1129
|
-
`/payments/${encodeURIComponent(paymentId)}/
|
|
1129
|
+
`/payments/${encodeURIComponent(paymentId)}/incremental-authorization`,
|
|
1130
1130
|
{
|
|
1131
1131
|
body: params
|
|
1132
1132
|
}
|
|
1133
1133
|
);
|
|
1134
1134
|
}
|
|
1135
|
-
/** Extend authorization window. `POST /payments/{paymentId}/
|
|
1135
|
+
/** Extend authorization window. `POST /payments/{paymentId}/extend-authorization` */
|
|
1136
1136
|
async extendAuthorization(paymentId, params) {
|
|
1137
|
-
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/
|
|
1137
|
+
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/extend-authorization`, {
|
|
1138
1138
|
body: params
|
|
1139
1139
|
});
|
|
1140
1140
|
}
|
|
1141
|
-
/** Complete authorization. `POST /payments/{paymentId}/
|
|
1141
|
+
/** Complete authorization. `POST /payments/{paymentId}/complete-authorize` */
|
|
1142
1142
|
async completeAuthorize(paymentId, params) {
|
|
1143
|
-
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/
|
|
1143
|
+
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/complete-authorize`, {
|
|
1144
1144
|
body: params
|
|
1145
1145
|
});
|
|
1146
1146
|
}
|
|
1147
|
-
/** Dynamic tax calculation. `POST /payments/{paymentId}/
|
|
1147
|
+
/** Dynamic tax calculation. `POST /payments/{paymentId}/calculate-tax` */
|
|
1148
1148
|
async calculateTax(paymentId, params) {
|
|
1149
|
-
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/
|
|
1149
|
+
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/calculate-tax`, {
|
|
1150
1150
|
body: params
|
|
1151
1151
|
});
|
|
1152
1152
|
}
|
|
1153
|
-
/** Update payment metadata. `POST /payments/{paymentId}/
|
|
1153
|
+
/** Update payment metadata. `POST /payments/{paymentId}/update-metadata` */
|
|
1154
1154
|
async updateMetadata(paymentId, params) {
|
|
1155
|
-
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/
|
|
1155
|
+
return this.request("POST", `/payments/${encodeURIComponent(paymentId)}/update-metadata`, {
|
|
1156
1156
|
body: params
|
|
1157
1157
|
});
|
|
1158
1158
|
}
|
|
1159
|
-
/** Retrieve extended card info. `GET /payments/{paymentId}/
|
|
1159
|
+
/** Retrieve extended card info. `GET /payments/{paymentId}/extended-card-info` */
|
|
1160
1160
|
async extendedCardInfo(paymentId) {
|
|
1161
|
-
return this.request("GET", `/payments/${encodeURIComponent(paymentId)}/
|
|
1161
|
+
return this.request("GET", `/payments/${encodeURIComponent(paymentId)}/extended-card-info`);
|
|
1162
1162
|
}
|
|
1163
1163
|
// --- OLAP extensions (Task 4.2) ---
|
|
1164
1164
|
/** List payments (profile-scoped). `GET /payments/profile/list` */
|
|
@@ -1349,12 +1349,12 @@ var ProfileAcquirers = class {
|
|
|
1349
1349
|
this.request = request;
|
|
1350
1350
|
}
|
|
1351
1351
|
async create(params) {
|
|
1352
|
-
return this.request("POST", "/
|
|
1352
|
+
return this.request("POST", "/profile-acquirer", { body: params });
|
|
1353
1353
|
}
|
|
1354
1354
|
async update(profileId, profileAcquirerId, params) {
|
|
1355
1355
|
return this.request(
|
|
1356
1356
|
"POST",
|
|
1357
|
-
`/
|
|
1357
|
+
`/profile-acquirer/${encodeURIComponent(profileId)}/${encodeURIComponent(profileAcquirerId)}`,
|
|
1358
1358
|
{
|
|
1359
1359
|
body: params
|
|
1360
1360
|
}
|
|
@@ -1368,23 +1368,23 @@ var Profiles = class {
|
|
|
1368
1368
|
this.request = request;
|
|
1369
1369
|
}
|
|
1370
1370
|
async create(accountId, params) {
|
|
1371
|
-
return this.request("POST", `/account/${encodeURIComponent(accountId)}/
|
|
1371
|
+
return this.request("POST", `/account/${encodeURIComponent(accountId)}/business-profile`, {
|
|
1372
1372
|
body: params
|
|
1373
1373
|
});
|
|
1374
1374
|
}
|
|
1375
1375
|
async retrieve(accountId, profileId) {
|
|
1376
1376
|
return this.request(
|
|
1377
1377
|
"GET",
|
|
1378
|
-
`/account/${encodeURIComponent(accountId)}/
|
|
1378
|
+
`/account/${encodeURIComponent(accountId)}/business-profile/${encodeURIComponent(profileId)}`
|
|
1379
1379
|
);
|
|
1380
1380
|
}
|
|
1381
1381
|
async list(accountId) {
|
|
1382
|
-
return this.request("GET", `/account/${encodeURIComponent(accountId)}/
|
|
1382
|
+
return this.request("GET", `/account/${encodeURIComponent(accountId)}/business-profile`);
|
|
1383
1383
|
}
|
|
1384
1384
|
async update(accountId, profileId, params) {
|
|
1385
1385
|
return this.request(
|
|
1386
1386
|
"POST",
|
|
1387
|
-
`/account/${encodeURIComponent(accountId)}/
|
|
1387
|
+
`/account/${encodeURIComponent(accountId)}/business-profile/${encodeURIComponent(profileId)}`,
|
|
1388
1388
|
{
|
|
1389
1389
|
body: params
|
|
1390
1390
|
}
|
|
@@ -1393,22 +1393,22 @@ var Profiles = class {
|
|
|
1393
1393
|
async delete(accountId, profileId) {
|
|
1394
1394
|
return this.request(
|
|
1395
1395
|
"DELETE",
|
|
1396
|
-
`/account/${encodeURIComponent(accountId)}/
|
|
1396
|
+
`/account/${encodeURIComponent(accountId)}/business-profile/${encodeURIComponent(profileId)}`
|
|
1397
1397
|
);
|
|
1398
1398
|
}
|
|
1399
1399
|
// --- Advanced operations (Task 4.8) ---
|
|
1400
|
-
/** Toggle extended card info for a profile. `POST /account/{accountId}/
|
|
1400
|
+
/** Toggle extended card info for a profile. `POST /account/{accountId}/business-profile/{profileId}/toggle-extended-card-info` */
|
|
1401
1401
|
async toggleExtendedCardInfo(accountId, profileId) {
|
|
1402
1402
|
return this.request(
|
|
1403
1403
|
"POST",
|
|
1404
|
-
`/account/${encodeURIComponent(accountId)}/
|
|
1404
|
+
`/account/${encodeURIComponent(accountId)}/business-profile/${encodeURIComponent(profileId)}/toggle-extended-card-info`
|
|
1405
1405
|
);
|
|
1406
1406
|
}
|
|
1407
|
-
/** Toggle connector agnostic MIT. `POST /account/{accountId}/
|
|
1407
|
+
/** Toggle connector agnostic MIT. `POST /account/{accountId}/business-profile/{profileId}/toggle-connector-agnostic-mit` */
|
|
1408
1408
|
async toggleConnectorAgnosticMit(accountId, profileId) {
|
|
1409
1409
|
return this.request(
|
|
1410
1410
|
"POST",
|
|
1411
|
-
`/account/${encodeURIComponent(accountId)}/
|
|
1411
|
+
`/account/${encodeURIComponent(accountId)}/business-profile/${encodeURIComponent(profileId)}/toggle-connector-agnostic-mit`
|
|
1412
1412
|
);
|
|
1413
1413
|
}
|
|
1414
1414
|
};
|
|
@@ -1919,23 +1919,23 @@ var StripeConnect = class {
|
|
|
1919
1919
|
this.request = request;
|
|
1920
1920
|
}
|
|
1921
1921
|
async createAccount(params) {
|
|
1922
|
-
return this.request("POST", "/
|
|
1922
|
+
return this.request("POST", "/connector-onboarding/stripe/accounts", { body: params });
|
|
1923
1923
|
}
|
|
1924
1924
|
async createAccountLink(params) {
|
|
1925
|
-
return this.request("POST", "/
|
|
1925
|
+
return this.request("POST", "/connector-onboarding/stripe/account-links", { body: params });
|
|
1926
1926
|
}
|
|
1927
1927
|
// --- Generic connector onboarding (Task 4.11) ---
|
|
1928
|
-
/** Get onboarding action URL. `POST /
|
|
1928
|
+
/** Get onboarding action URL. `POST /connector-onboarding/action-url` */
|
|
1929
1929
|
async getActionUrl(params) {
|
|
1930
|
-
return this.request("POST", "/
|
|
1930
|
+
return this.request("POST", "/connector-onboarding/action-url", { body: params });
|
|
1931
1931
|
}
|
|
1932
|
-
/** Sync onboarding status. `POST /
|
|
1932
|
+
/** Sync onboarding status. `POST /connector-onboarding/sync` */
|
|
1933
1933
|
async syncOnboarding(params) {
|
|
1934
|
-
return this.request("POST", "/
|
|
1934
|
+
return this.request("POST", "/connector-onboarding/sync", { body: params });
|
|
1935
1935
|
}
|
|
1936
|
-
/** Reset tracking ID. `POST /
|
|
1936
|
+
/** Reset tracking ID. `POST /connector-onboarding/reset-tracking-id` */
|
|
1937
1937
|
async resetTrackingId(params) {
|
|
1938
|
-
return this.request("POST", "/
|
|
1938
|
+
return this.request("POST", "/connector-onboarding/reset-tracking-id", { body: params });
|
|
1939
1939
|
}
|
|
1940
1940
|
};
|
|
1941
1941
|
|
|
@@ -1945,7 +1945,7 @@ var ThreeDsRules = class {
|
|
|
1945
1945
|
this.request = request;
|
|
1946
1946
|
}
|
|
1947
1947
|
async execute(params) {
|
|
1948
|
-
return this.request("POST", "/
|
|
1948
|
+
return this.request("POST", "/three-ds-decision/execute", { body: params });
|
|
1949
1949
|
}
|
|
1950
1950
|
};
|
|
1951
1951
|
|
|
@@ -2034,13 +2034,13 @@ var Users = class {
|
|
|
2034
2034
|
return this.request("DELETE", "/user/account", { body: params });
|
|
2035
2035
|
}
|
|
2036
2036
|
async changePassword(params) {
|
|
2037
|
-
return this.request("POST", "/user/
|
|
2037
|
+
return this.request("POST", "/user/change-password", { body: params });
|
|
2038
2038
|
}
|
|
2039
2039
|
async rotatePassword(params) {
|
|
2040
|
-
return this.request("POST", "/user/
|
|
2040
|
+
return this.request("POST", "/user/rotate-password", { body: params });
|
|
2041
2041
|
}
|
|
2042
2042
|
async forgotPassword(params) {
|
|
2043
|
-
return this.request("POST", "/user/
|
|
2043
|
+
return this.request("POST", "/user/forgot-password", { body: params });
|
|
2044
2044
|
}
|
|
2045
2045
|
/**
|
|
2046
2046
|
* Commit a password reset.
|
|
@@ -2054,7 +2054,7 @@ var Users = class {
|
|
|
2054
2054
|
* decodes it a second time to find the user.
|
|
2055
2055
|
*/
|
|
2056
2056
|
async resetPassword(params) {
|
|
2057
|
-
return this.request("POST", "/user/
|
|
2057
|
+
return this.request("POST", "/user/reset-password", { body: params });
|
|
2058
2058
|
}
|
|
2059
2059
|
/**
|
|
2060
2060
|
* Exchange an email-link token (`EmailToken`) for a single-purpose JWT
|
|
@@ -2064,16 +2064,16 @@ var Users = class {
|
|
|
2064
2064
|
* The `token_type` in the response tells you which step to run next.
|
|
2065
2065
|
*/
|
|
2066
2066
|
async fromEmail(params) {
|
|
2067
|
-
return this.request("POST", "/user/
|
|
2067
|
+
return this.request("POST", "/user/from-email", { body: params });
|
|
2068
2068
|
}
|
|
2069
2069
|
async verifyEmail(params) {
|
|
2070
|
-
return this.request("POST", "/user/
|
|
2070
|
+
return this.request("POST", "/user/verify-email", { body: params });
|
|
2071
2071
|
}
|
|
2072
2072
|
async sendVerificationEmail(params) {
|
|
2073
|
-
return this.request("POST", "/user/
|
|
2073
|
+
return this.request("POST", "/user/verify-email-request", { body: params });
|
|
2074
2074
|
}
|
|
2075
2075
|
async createMerchant(params) {
|
|
2076
|
-
return this.request("POST", "/user/
|
|
2076
|
+
return this.request("POST", "/user/create-merchant", { body: params });
|
|
2077
2077
|
}
|
|
2078
2078
|
async switchMerchant(params) {
|
|
2079
2079
|
return this.request("POST", "/user/switch/merchant", { body: params });
|
|
@@ -2088,10 +2088,10 @@ var Users = class {
|
|
|
2088
2088
|
return this.request("GET", "/user/list/profile");
|
|
2089
2089
|
}
|
|
2090
2090
|
async inviteUsers(params) {
|
|
2091
|
-
return this.request("POST", "/user/
|
|
2091
|
+
return this.request("POST", "/user/employees/invite", { body: params });
|
|
2092
2092
|
}
|
|
2093
2093
|
async acceptInvitation(params) {
|
|
2094
|
-
return this.request("POST", "/user/
|
|
2094
|
+
return this.request("POST", "/user/invite/accept", { body: params });
|
|
2095
2095
|
}
|
|
2096
2096
|
/**
|
|
2097
2097
|
* Accept an invitation via the email-link flow.
|
|
@@ -2104,7 +2104,7 @@ var Users = class {
|
|
|
2104
2104
|
* invitee and the entity lineage.
|
|
2105
2105
|
*/
|
|
2106
2106
|
async acceptInviteFromEmail(params) {
|
|
2107
|
-
return this.request("POST", "/user/
|
|
2107
|
+
return this.request("POST", "/user/accept-invite-from-email", { body: params });
|
|
2108
2108
|
}
|
|
2109
2109
|
/**
|
|
2110
2110
|
* Start TOTP setup (or no-op if already set).
|
|
@@ -2131,10 +2131,10 @@ var Users = class {
|
|
|
2131
2131
|
return this.request("GET", "/user/2fa/totp/reset");
|
|
2132
2132
|
}
|
|
2133
2133
|
async generateRecoveryCodes() {
|
|
2134
|
-
return this.request("GET", "/user/2fa/
|
|
2134
|
+
return this.request("GET", "/user/2fa/recovery-code/generate");
|
|
2135
2135
|
}
|
|
2136
2136
|
async verifyRecoveryCode(params) {
|
|
2137
|
-
return this.request("POST", "/user/2fa/
|
|
2137
|
+
return this.request("POST", "/user/2fa/recovery-code/verify", { body: params });
|
|
2138
2138
|
}
|
|
2139
2139
|
async sendPhoneOtp(params) {
|
|
2140
2140
|
return this.request("POST", "/user/phone/send-otp", { body: params });
|
|
@@ -2146,13 +2146,13 @@ var Users = class {
|
|
|
2146
2146
|
return this.request("GET", "/user/role/list");
|
|
2147
2147
|
}
|
|
2148
2148
|
async listUserRoles(params) {
|
|
2149
|
-
return this.request("POST", "/user/
|
|
2149
|
+
return this.request("POST", "/user/employees", { body: params });
|
|
2150
2150
|
}
|
|
2151
2151
|
async updateUserRole(params) {
|
|
2152
|
-
return this.request("POST", "/user/
|
|
2152
|
+
return this.request("POST", "/user/employees/update-role", { body: params });
|
|
2153
2153
|
}
|
|
2154
2154
|
async deleteUserRole(params) {
|
|
2155
|
-
return this.request("DELETE", "/user/
|
|
2155
|
+
return this.request("DELETE", "/user/employees/delete", { body: params });
|
|
2156
2156
|
}
|
|
2157
2157
|
/** Sign in via OIDC. `POST /user/oidc` */
|
|
2158
2158
|
async signInOidc(params) {
|
|
@@ -2214,13 +2214,13 @@ var Users = class {
|
|
|
2214
2214
|
async selectAuth(params) {
|
|
2215
2215
|
return this.request("POST", "/user/auth/select", { body: params });
|
|
2216
2216
|
}
|
|
2217
|
-
/** List users in lineage. `GET /user/
|
|
2217
|
+
/** List users in lineage. `GET /user/employees/list` */
|
|
2218
2218
|
async listUsersInLineage() {
|
|
2219
|
-
return this.request("GET", "/user/
|
|
2219
|
+
return this.request("GET", "/user/employees/list");
|
|
2220
2220
|
}
|
|
2221
|
-
/** Resend invite. `POST /user/
|
|
2221
|
+
/** Resend invite. `POST /user/employees/resend-invite` */
|
|
2222
2222
|
async resendInvite(params) {
|
|
2223
|
-
return this.request("POST", "/user/
|
|
2223
|
+
return this.request("POST", "/user/employees/resend-invite", { body: params });
|
|
2224
2224
|
}
|
|
2225
2225
|
/**
|
|
2226
2226
|
* Get the caller's parent permission groups + scopes.
|
|
@@ -2249,9 +2249,9 @@ var Users = class {
|
|
|
2249
2249
|
async listUpdatableRoles() {
|
|
2250
2250
|
return this.request("GET", "/user/role/list/update");
|
|
2251
2251
|
}
|
|
2252
|
-
/** Get permission info. `GET /user/
|
|
2252
|
+
/** Get permission info. `GET /user/permission-info` */
|
|
2253
2253
|
async getPermissionInfo() {
|
|
2254
|
-
return this.request("GET", "/user/
|
|
2254
|
+
return this.request("GET", "/user/permission-info");
|
|
2255
2255
|
}
|
|
2256
2256
|
/** Get module list. `GET /user/module/list` */
|
|
2257
2257
|
async getModuleList() {
|
|
@@ -2281,12 +2281,12 @@ var Verification = class {
|
|
|
2281
2281
|
this.request = request;
|
|
2282
2282
|
}
|
|
2283
2283
|
async registerApplePayDomains(merchantId, params) {
|
|
2284
|
-
return this.request("POST", `/verify/
|
|
2284
|
+
return this.request("POST", `/verify/apple-pay/${encodeURIComponent(merchantId)}`, {
|
|
2285
2285
|
body: params
|
|
2286
2286
|
});
|
|
2287
2287
|
}
|
|
2288
2288
|
async getApplePayVerifiedDomains(params) {
|
|
2289
|
-
return this.request("GET", "/verify/
|
|
2289
|
+
return this.request("GET", "/verify/applepay-verified-domains", {
|
|
2290
2290
|
query: params
|
|
2291
2291
|
});
|
|
2292
2292
|
}
|
|
@@ -2387,28 +2387,28 @@ var AnalyticsDomain = class {
|
|
|
2387
2387
|
}
|
|
2388
2388
|
/** Get metrics. `POST /analytics/metrics/{domain}` */
|
|
2389
2389
|
async metrics(params, scope) {
|
|
2390
|
-
const prefix = scope ? `/analytics/${scope}` : "/analytics
|
|
2390
|
+
const prefix = scope ? `/analytics/${scope}` : "/analytics";
|
|
2391
2391
|
return this.request("POST", `${prefix}/metrics/${encodeURIComponent(this.domain)}`, {
|
|
2392
2392
|
body: [params]
|
|
2393
2393
|
});
|
|
2394
2394
|
}
|
|
2395
2395
|
/** Get filters. `POST /analytics/filters/{domain}` */
|
|
2396
2396
|
async filters(params, scope) {
|
|
2397
|
-
const prefix = scope ? `/analytics/${scope}` : "/analytics
|
|
2397
|
+
const prefix = scope ? `/analytics/${scope}` : "/analytics";
|
|
2398
2398
|
return this.request("POST", `${prefix}/filters/${encodeURIComponent(this.domain)}`, {
|
|
2399
2399
|
body: params
|
|
2400
2400
|
});
|
|
2401
2401
|
}
|
|
2402
2402
|
/** Generate report. `POST /analytics/report/{domain}` */
|
|
2403
2403
|
async report(params, scope) {
|
|
2404
|
-
const prefix = scope ? `/analytics/${scope}` : "/analytics
|
|
2404
|
+
const prefix = scope ? `/analytics/${scope}` : "/analytics";
|
|
2405
2405
|
return this.request("POST", `${prefix}/report/${encodeURIComponent(this.domain)}`, {
|
|
2406
2406
|
body: params
|
|
2407
2407
|
});
|
|
2408
2408
|
}
|
|
2409
2409
|
/** Sankey chart data. `POST /analytics/metrics/{domain}/sankey` */
|
|
2410
2410
|
async sankey(params, scope) {
|
|
2411
|
-
const prefix = scope ? `/analytics/${scope}` : "/analytics
|
|
2411
|
+
const prefix = scope ? `/analytics/${scope}` : "/analytics";
|
|
2412
2412
|
return this.request("POST", `${prefix}/metrics/${encodeURIComponent(this.domain)}/sankey`, {
|
|
2413
2413
|
body: params
|
|
2414
2414
|
});
|
|
@@ -2440,25 +2440,25 @@ var Analytics = class {
|
|
|
2440
2440
|
async getInfo(domain) {
|
|
2441
2441
|
return this.request("GET", `/analytics/${encodeURIComponent(domain)}/info`);
|
|
2442
2442
|
}
|
|
2443
|
-
/** Get API event logs. `GET /analytics/
|
|
2443
|
+
/** Get API event logs. `GET /analytics/api-event-logs` */
|
|
2444
2444
|
async apiEventLogs(params) {
|
|
2445
|
-
return this.request("GET", "/analytics/
|
|
2445
|
+
return this.request("GET", "/analytics/api-event-logs", { query: params });
|
|
2446
2446
|
}
|
|
2447
|
-
/** Get SDK event logs. `POST /analytics/
|
|
2447
|
+
/** Get SDK event logs. `POST /analytics/sdk-event-logs` */
|
|
2448
2448
|
async sdkEventLogs(params) {
|
|
2449
|
-
return this.request("POST", "/analytics/
|
|
2449
|
+
return this.request("POST", "/analytics/sdk-event-logs", { body: params });
|
|
2450
2450
|
}
|
|
2451
|
-
/** Get connector event logs. `GET /analytics/
|
|
2451
|
+
/** Get connector event logs. `GET /analytics/connector-event-logs` */
|
|
2452
2452
|
async connectorEventLogs(params) {
|
|
2453
|
-
return this.request("GET", "/analytics/
|
|
2453
|
+
return this.request("GET", "/analytics/connector-event-logs", { query: params });
|
|
2454
2454
|
}
|
|
2455
|
-
/** Get routing event logs. `GET /analytics/
|
|
2455
|
+
/** Get routing event logs. `GET /analytics/routing-event-logs` */
|
|
2456
2456
|
async routingEventLogs(params) {
|
|
2457
|
-
return this.request("GET", "/analytics/
|
|
2457
|
+
return this.request("GET", "/analytics/routing-event-logs", { query: params });
|
|
2458
2458
|
}
|
|
2459
|
-
/** Get outgoing webhook event logs. `GET /analytics/
|
|
2459
|
+
/** Get outgoing webhook event logs. `GET /analytics/outgoing-webhook-event-logs` */
|
|
2460
2460
|
async outgoingWebhookEventLogs(params) {
|
|
2461
|
-
return this.request("GET", "/analytics/
|
|
2461
|
+
return this.request("GET", "/analytics/outgoing-webhook-event-logs", { query: params });
|
|
2462
2462
|
}
|
|
2463
2463
|
};
|
|
2464
2464
|
|
|
@@ -2512,18 +2512,18 @@ var FeatureMatrix = class {
|
|
|
2512
2512
|
constructor(request) {
|
|
2513
2513
|
this.request = request;
|
|
2514
2514
|
}
|
|
2515
|
-
/** Retrieve the feature matrix. `GET /
|
|
2515
|
+
/** Retrieve the feature matrix. `GET /feature-matrix` */
|
|
2516
2516
|
async retrieve() {
|
|
2517
|
-
return this.request("GET", "/
|
|
2517
|
+
return this.request("GET", "/feature-matrix");
|
|
2518
2518
|
}
|
|
2519
2519
|
/**
|
|
2520
2520
|
* Retrieve the feature matrix scoped to a merchant. Beta connectors
|
|
2521
2521
|
* are filtered against the merchant's allowlist so the dashboard only
|
|
2522
2522
|
* surfaces connectors the merchant can actually attach.
|
|
2523
|
-
* `GET /
|
|
2523
|
+
* `GET /feature-matrix/{merchantId}`
|
|
2524
2524
|
*/
|
|
2525
2525
|
async retrieveForMerchant(merchantId) {
|
|
2526
|
-
return this.request("GET", `/
|
|
2526
|
+
return this.request("GET", `/feature-matrix/${encodeURIComponent(merchantId)}`);
|
|
2527
2527
|
}
|
|
2528
2528
|
};
|
|
2529
2529
|
|
|
@@ -2555,9 +2555,9 @@ var Forex = class {
|
|
|
2555
2555
|
async getRates(params) {
|
|
2556
2556
|
return this.request("GET", "/forex/rates", { query: params });
|
|
2557
2557
|
}
|
|
2558
|
-
/** Convert from minor currency. `GET /forex/
|
|
2558
|
+
/** Convert from minor currency. `GET /forex/convert-from-minor` */
|
|
2559
2559
|
async convertFromMinor(params) {
|
|
2560
|
-
return this.request("GET", "/forex/
|
|
2560
|
+
return this.request("GET", "/forex/convert-from-minor", { query: params });
|
|
2561
2561
|
}
|
|
2562
2562
|
};
|
|
2563
2563
|
|