@alphawebai/hs-prism 0.1.0-rc.52 → 0.1.0-rc.53
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/src/alphaweb/manifest.d.ts +1 -1
- package/dist/src/alphaweb/manifest.js +1 -1
- package/dist/src/alphaweb/stripe-connector.js +6 -2
- package/dist/src/payments/generated/libconnector_service_ffi.so +1 -1
- package/dist/src/payments/generated/linux-arm64/libconnector_service_ffi.so +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export declare const ALPHAWEB_STRIPE_WEBHOOK_EVENTS: readonly ["charge.dispute.closed", "charge.dispute.created", "charge.dispute.funds_reinstated", "charge.dispute.funds_withdrawn", "charge.dispute.updated", "mandate.updated", "payment_intent.amount_capturable_updated", "payment_intent.canceled", "payment_intent.payment_failed", "payment_intent.processing", "payment_intent.requires_action", "payment_intent.succeeded", "payment_method.attached", "payment_method.automatically_updated", "payment_method.detached", "payment_method.updated", "refund.created", "refund.failed", "refund.updated", "setup_intent.canceled", "setup_intent.requires_action", "setup_intent.setup_failed", "setup_intent.succeeded"];
|
|
2
2
|
export declare const ALPHAWEB_PAYPAL_WEBHOOK_EVENTS: readonly ["CHECKOUT.ORDER.APPROVED", "CHECKOUT.ORDER.COMPLETED", "CHECKOUT.ORDER.PROCESSED", "CHECKOUT.PAYMENT-APPROVAL.REVERSED", "CUSTOMER.DISPUTE.CREATED", "CUSTOMER.DISPUTE.RESOLVED", "CUSTOMER.DISPUTE.UPDATED", "PAYMENT.AUTHORIZATION.CREATED", "PAYMENT.AUTHORIZATION.VOIDED", "PAYMENT.CAPTURE.COMPLETED", "PAYMENT.CAPTURE.DECLINED", "PAYMENT.CAPTURE.PENDING", "PAYMENT.CAPTURE.REFUNDED", "PAYMENT.CAPTURE.REVERSED", "PAYMENT.REFUND.FAILED", "PAYMENT.REFUND.PENDING", "RISK.DISPUTE.CREATED", "VAULT.PAYMENT-TOKEN.CREATED", "VAULT.PAYMENT-TOKEN.DELETED", "VAULT.PAYMENT-TOKEN.DELETION-INITIATED"];
|
|
3
3
|
export declare const ALPHAWEB_PRISM_COMPATIBILITY_MANIFEST: Readonly<{
|
|
4
|
-
readonly release: "0.1.0-rc.
|
|
4
|
+
readonly release: "0.1.0-rc.53";
|
|
5
5
|
readonly upstreamCommit: "b07af7d9dac271de729548e74217ddcf895c602b";
|
|
6
6
|
readonly medusaRange: ">=2.17.2 <2.18.0";
|
|
7
7
|
readonly stripeApiVersion: "2026-06-24.dahlia";
|
|
@@ -49,7 +49,7 @@ exports.ALPHAWEB_PAYPAL_WEBHOOK_EVENTS = Object.freeze([
|
|
|
49
49
|
'VAULT.PAYMENT-TOKEN.DELETION-INITIATED',
|
|
50
50
|
]);
|
|
51
51
|
exports.ALPHAWEB_PRISM_COMPATIBILITY_MANIFEST = Object.freeze({
|
|
52
|
-
release: '0.1.0-rc.
|
|
52
|
+
release: '0.1.0-rc.53',
|
|
53
53
|
upstreamCommit: 'b07af7d9dac271de729548e74217ddcf895c602b',
|
|
54
54
|
medusaRange: '>=2.17.2 <2.18.0',
|
|
55
55
|
stripeApiVersion: '2026-06-24.dahlia',
|
|
@@ -629,6 +629,10 @@ function parseWebhookDocument(input, binding) {
|
|
|
629
629
|
}
|
|
630
630
|
return { status: 'normalized', event: normalized };
|
|
631
631
|
}
|
|
632
|
+
function stripeSecretKeyMatchesMode(key, test) {
|
|
633
|
+
const mode = test ? 'test' : 'live';
|
|
634
|
+
return key.startsWith(`sk_${mode}_`) || key.startsWith(`rk_${mode}_`);
|
|
635
|
+
}
|
|
632
636
|
class PrismStripeConnector {
|
|
633
637
|
options;
|
|
634
638
|
dependencies;
|
|
@@ -653,7 +657,7 @@ class PrismStripeConnector {
|
|
|
653
657
|
assertIdentifier(this.options.credentialBindingId, 'credentialBindingId');
|
|
654
658
|
assertIdentifier(this.options.providerAccountId, 'providerAccountId');
|
|
655
659
|
const test = this.options.environment === 'test';
|
|
656
|
-
if (!this.options.secretKey
|
|
660
|
+
if (!stripeSecretKeyMatchesMode(this.options.secretKey, test)) {
|
|
657
661
|
throw configurationError('Stripe secret key mode does not match Prism environment.', 'PRISM_KEY_MODE');
|
|
658
662
|
}
|
|
659
663
|
if (this.options.publishableKey &&
|
|
@@ -1397,7 +1401,7 @@ exports.PrismStripeConnector = PrismStripeConnector;
|
|
|
1397
1401
|
*/
|
|
1398
1402
|
async function verifyPrismStripeRuntimeCredential(input, dependencies) {
|
|
1399
1403
|
const test = input.environment === 'test';
|
|
1400
|
-
if (!input.secretKey
|
|
1404
|
+
if (!stripeSecretKeyMatchesMode(input.secretKey, test)) {
|
|
1401
1405
|
throw configurationError('Stripe secret key mode does not match Prism environment.', 'PRISM_KEY_MODE');
|
|
1402
1406
|
}
|
|
1403
1407
|
if (input.publishableKey &&
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
[diffend] Oversized file quarantined before diffing.
|
|
2
2
|
name: package/dist/src/payments/generated/libconnector_service_ffi.so
|
|
3
3
|
size: 105660624 bytes
|
|
4
|
-
sha256:
|
|
4
|
+
sha256: 0deb3df064b83f7762a007f206fe4934c0a7765707b2ed7fad4b9b3e190fb6ee
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
[diffend] Oversized file quarantined before diffing.
|
|
2
2
|
name: package/dist/src/payments/generated/linux-arm64/libconnector_service_ffi.so
|
|
3
3
|
size: 97990184 bytes
|
|
4
|
-
sha256:
|
|
4
|
+
sha256: 604d7cfa9e552f70800bf56dd1233f8aa126fc6ecababdb463edb633f72c81f5
|
package/package.json
CHANGED