@betterstore/sdk 0.3.39 → 0.3.40
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/CHANGELOG.md +6 -0
- package/dist/index.d.mts +4 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +5 -4
- package/dist/index.mjs +5 -4
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -202,7 +202,10 @@ declare class Client {
|
|
|
202
202
|
/**
|
|
203
203
|
* Generate payment secret for a checkout session
|
|
204
204
|
*/
|
|
205
|
-
generateCheckoutsPaymentSecret(clientSecret: string, checkoutId: string): Promise<
|
|
205
|
+
generateCheckoutsPaymentSecret(clientSecret: string, checkoutId: string): Promise<{
|
|
206
|
+
paymentSecret: string;
|
|
207
|
+
publicKey: string;
|
|
208
|
+
}>;
|
|
206
209
|
/**
|
|
207
210
|
* Create a new customer
|
|
208
211
|
*/
|
package/dist/index.d.ts
CHANGED
|
@@ -202,7 +202,10 @@ declare class Client {
|
|
|
202
202
|
/**
|
|
203
203
|
* Generate payment secret for a checkout session
|
|
204
204
|
*/
|
|
205
|
-
generateCheckoutsPaymentSecret(clientSecret: string, checkoutId: string): Promise<
|
|
205
|
+
generateCheckoutsPaymentSecret(clientSecret: string, checkoutId: string): Promise<{
|
|
206
|
+
paymentSecret: string;
|
|
207
|
+
publicKey: string;
|
|
208
|
+
}>;
|
|
206
209
|
/**
|
|
207
210
|
* Create a new customer
|
|
208
211
|
*/
|
package/dist/index.js
CHANGED
|
@@ -238,10 +238,11 @@ var Client = class {
|
|
|
238
238
|
generateCheckoutsPaymentSecret(clientSecret, checkoutId) {
|
|
239
239
|
return __async(this, null, function* () {
|
|
240
240
|
const apiClient = createApiClient(clientSecret, this.proxy);
|
|
241
|
-
const data = yield apiClient.post(
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
241
|
+
const data = yield apiClient.post(`/checkout/payment/${checkoutId}`);
|
|
242
|
+
return {
|
|
243
|
+
paymentSecret: data.paymentSecret,
|
|
244
|
+
publicKey: data.publicKey
|
|
245
|
+
};
|
|
245
246
|
});
|
|
246
247
|
}
|
|
247
248
|
/**
|
package/dist/index.mjs
CHANGED
|
@@ -202,10 +202,11 @@ var Client = class {
|
|
|
202
202
|
generateCheckoutsPaymentSecret(clientSecret, checkoutId) {
|
|
203
203
|
return __async(this, null, function* () {
|
|
204
204
|
const apiClient = createApiClient(clientSecret, this.proxy);
|
|
205
|
-
const data = yield apiClient.post(
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
205
|
+
const data = yield apiClient.post(`/checkout/payment/${checkoutId}`);
|
|
206
|
+
return {
|
|
207
|
+
paymentSecret: data.paymentSecret,
|
|
208
|
+
publicKey: data.publicKey
|
|
209
|
+
};
|
|
209
210
|
});
|
|
210
211
|
}
|
|
211
212
|
/**
|