@agent-cards/checkout 0.8.0 → 0.9.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/CHANGELOG.md +7 -0
- package/PREFLIGHT.md +294 -0
- package/README.md +7 -3
- package/dist/cdp.js +2 -2
- package/dist/playwright.d.ts +3 -0
- package/dist/playwright.js +3 -0
- package/dist/preflight-capabilities.generated.d.ts +1165 -0
- package/dist/preflight-capabilities.generated.js +1799 -0
- package/dist/preflight-catalog.json +3892 -0
- package/dist/preflight-playwright.d.ts +34 -0
- package/dist/preflight-playwright.js +262 -0
- package/dist/preflight-schemas.json +1063 -0
- package/dist/preflight.d.ts +1 -0
- package/dist/preflight.generated.d.ts +1867 -0
- package/dist/preflight.generated.js +482 -0
- package/dist/preflight.js +2 -0
- package/examples/preflight/classify-direct.mjs +21 -0
- package/examples/preflight/classify-kernel.mjs +30 -0
- package/examples/preflight/inspect-browser.mjs +44 -0
- package/examples/preflight/kernel-profile.empty.json +11 -0
- package/examples/preflight/mollie-hosted.observations.json +23 -0
- package/examples/preflight/mollie-hosted.result.json +103 -0
- package/examples/preflight/stripe-script.direct.result.json +92 -0
- package/examples/preflight/stripe-script.observations.json +16 -0
- package/examples/preflight/stripe-script.result.json +87 -0
- package/package.json +14 -6
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// Run from an installed SDK or from this package after npm run build.
|
|
2
|
+
// Optional argument: observations JSON path. Uses this SDK's bundled capabilities.
|
|
3
|
+
import { readFile } from 'node:fs/promises';
|
|
4
|
+
import {
|
|
5
|
+
normalizeCheckoutSignals,
|
|
6
|
+
assessCheckoutSupport,
|
|
7
|
+
} from '@agent-cards/checkout/preflight';
|
|
8
|
+
|
|
9
|
+
try {
|
|
10
|
+
const observations = JSON.parse(await readFile(
|
|
11
|
+
process.argv[2] ?? new URL('./stripe-script.observations.json', import.meta.url), 'utf8',
|
|
12
|
+
));
|
|
13
|
+
const snapshot = normalizeCheckoutSignals(observations);
|
|
14
|
+
const result = assessCheckoutSupport(snapshot, { scenario: 'one_time' });
|
|
15
|
+
|
|
16
|
+
// Read support_scope and checkout_flow_status with status before continuing.
|
|
17
|
+
console.log(JSON.stringify({ snapshot, result }, null, 2));
|
|
18
|
+
} catch {
|
|
19
|
+
console.error('Could not assess the observations. Check the JSON file against PREFLIGHT.md.');
|
|
20
|
+
process.exitCode = 1;
|
|
21
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// Run from an installed SDK or from this package after npm run build.
|
|
2
|
+
// Optional arguments: observations JSON path, profile JSON path, adapter version.
|
|
3
|
+
import { readFile } from 'node:fs/promises';
|
|
4
|
+
import {
|
|
5
|
+
normalizeCheckoutSignals,
|
|
6
|
+
assessCheckoutSupport,
|
|
7
|
+
} from '@agent-cards/checkout/preflight';
|
|
8
|
+
|
|
9
|
+
const [observationsPath, profilePath, adapterVersion = 'example-native-adapter'] = process.argv.slice(2);
|
|
10
|
+
|
|
11
|
+
try {
|
|
12
|
+
const observations = JSON.parse(await readFile(
|
|
13
|
+
observationsPath ?? new URL('./stripe-script.observations.json', import.meta.url), 'utf8',
|
|
14
|
+
));
|
|
15
|
+
const profile = JSON.parse(await readFile(
|
|
16
|
+
profilePath ?? new URL('./kernel-profile.empty.json', import.meta.url), 'utf8',
|
|
17
|
+
));
|
|
18
|
+
const snapshot = normalizeCheckoutSignals(observations);
|
|
19
|
+
const result = assessCheckoutSupport(snapshot, {
|
|
20
|
+
scenario: 'one_time',
|
|
21
|
+
integration: { id: 'kernel_native', version: adapterVersion },
|
|
22
|
+
profile,
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
// Normalized snapshots contain reviewed rule IDs rather than raw asset URLs.
|
|
26
|
+
console.log(JSON.stringify({ snapshot, result }, null, 2));
|
|
27
|
+
} catch {
|
|
28
|
+
console.error('Could not assess the observations. Check the JSON files and adapter version against PREFLIGHT.md.');
|
|
29
|
+
process.exitCode = 1;
|
|
30
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
// Read an existing checkout tab. Does not navigate, click, fill, or attach payment interception.
|
|
2
|
+
// Install playwright-core in the consuming project before running this example.
|
|
3
|
+
import { readFile } from 'node:fs/promises';
|
|
4
|
+
import { chromium } from 'playwright-core';
|
|
5
|
+
import { inspectCheckout } from '@agent-cards/checkout/playwright';
|
|
6
|
+
|
|
7
|
+
let browser;
|
|
8
|
+
try {
|
|
9
|
+
if (!process.env.CHECKOUT_CDP_URL) throw new Error('missing_connection');
|
|
10
|
+
const integration = process.env.CHECKOUT_INTEGRATION ?? 'kernel_native';
|
|
11
|
+
if (!['kernel_native', 'direct_sdk'].includes(integration)) throw new Error('invalid_integration');
|
|
12
|
+
const pageIndex = Number(process.env.CHECKOUT_PAGE_INDEX ?? 0);
|
|
13
|
+
if (!Number.isSafeInteger(pageIndex) || pageIndex < 0) throw new Error('invalid_page_index');
|
|
14
|
+
|
|
15
|
+
const profile = integration === 'kernel_native' && process.env.CHECKOUT_PROFILE
|
|
16
|
+
? JSON.parse(await readFile(process.env.CHECKOUT_PROFILE, 'utf8'))
|
|
17
|
+
: undefined;
|
|
18
|
+
const options = integration === 'direct_sdk'
|
|
19
|
+
? { scenario: 'one_time' }
|
|
20
|
+
: {
|
|
21
|
+
scenario: 'one_time',
|
|
22
|
+
integration: { id: 'kernel_native', version: process.env.CHECKOUT_ADAPTER_VERSION ?? null },
|
|
23
|
+
profile,
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
browser = await chromium.connectOverCDP(process.env.CHECKOUT_CDP_URL, { timeout: 15_000 });
|
|
27
|
+
const page = browser.contexts()[0]?.pages()[pageIndex];
|
|
28
|
+
if (!page) throw new Error('page_not_found');
|
|
29
|
+
|
|
30
|
+
const result = await inspectCheckout(page, options);
|
|
31
|
+
console.log(JSON.stringify(result, null, 2));
|
|
32
|
+
} catch {
|
|
33
|
+
// A browser connection URL can contain a credential. Do not print connection errors.
|
|
34
|
+
console.error('Could not inspect the checkout. Check the CDP connection, page index, integration, and optional profile.');
|
|
35
|
+
process.exitCode = 1;
|
|
36
|
+
} finally {
|
|
37
|
+
if (browser) {
|
|
38
|
+
// Disconnect this CDP client; the existing agent keeps its browser session.
|
|
39
|
+
await browser.close().catch(() => {
|
|
40
|
+
console.error('Could not disconnect the inspection client. Close this local process before inspecting again.');
|
|
41
|
+
process.exitCode = 1;
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"signals": [
|
|
3
|
+
{
|
|
4
|
+
"kind": "document",
|
|
5
|
+
"url": "https://www.mollie.com/checkout/credit-card/session/synthetic-example",
|
|
6
|
+
"frame_id": 0,
|
|
7
|
+
"parent_frame_id": null,
|
|
8
|
+
"visible": true
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"kind": "script",
|
|
12
|
+
"url": "https://js.mollie.com/v2/mollie.js",
|
|
13
|
+
"frame_id": 0,
|
|
14
|
+
"parent_frame_id": null,
|
|
15
|
+
"visible": null
|
|
16
|
+
}
|
|
17
|
+
],
|
|
18
|
+
"observation": {
|
|
19
|
+
"complete": true,
|
|
20
|
+
"truncated": false,
|
|
21
|
+
"reasons": []
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
{
|
|
2
|
+
"snapshot": {
|
|
3
|
+
"schema_version": 1,
|
|
4
|
+
"catalog_version": "2026-09-11.2",
|
|
5
|
+
"signals": [
|
|
6
|
+
{
|
|
7
|
+
"rule_id": "mollie-hosted-credit-card",
|
|
8
|
+
"kind": "document",
|
|
9
|
+
"frame_id": 0,
|
|
10
|
+
"parent_frame_id": null,
|
|
11
|
+
"visible": true
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"rule_id": "mollie-components-script",
|
|
15
|
+
"kind": "script",
|
|
16
|
+
"frame_id": 0,
|
|
17
|
+
"parent_frame_id": null,
|
|
18
|
+
"visible": null
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"rule_id": "mollie-components-v2",
|
|
22
|
+
"kind": "script",
|
|
23
|
+
"frame_id": 0,
|
|
24
|
+
"parent_frame_id": null,
|
|
25
|
+
"visible": null
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
"observation": {
|
|
29
|
+
"complete": true,
|
|
30
|
+
"truncated": false,
|
|
31
|
+
"reasons": []
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"result": {
|
|
35
|
+
"schema_version": 1,
|
|
36
|
+
"catalog_version": "2026-09-11.2",
|
|
37
|
+
"integration": {
|
|
38
|
+
"id": "kernel_native",
|
|
39
|
+
"version": "example-native-adapter"
|
|
40
|
+
},
|
|
41
|
+
"scenario": "one_time",
|
|
42
|
+
"scenario_defaulted": false,
|
|
43
|
+
"psp": "mollie",
|
|
44
|
+
"flow": "mollie.hosted_components",
|
|
45
|
+
"mode": "token",
|
|
46
|
+
"status": "unknown",
|
|
47
|
+
"support_scope": null,
|
|
48
|
+
"checkout_flow_status": "identified",
|
|
49
|
+
"candidates": [
|
|
50
|
+
{
|
|
51
|
+
"psp": "mollie",
|
|
52
|
+
"relevance": "active",
|
|
53
|
+
"evidence": [
|
|
54
|
+
{
|
|
55
|
+
"rule_id": "mollie-hosted-credit-card",
|
|
56
|
+
"kind": "document",
|
|
57
|
+
"frame_id": 0,
|
|
58
|
+
"parent_frame_id": null,
|
|
59
|
+
"visible": true,
|
|
60
|
+
"origin": "https://www.mollie.com",
|
|
61
|
+
"path_pattern": "/checkout/credit-card/session/:session"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"rule_id": "mollie-components-script",
|
|
65
|
+
"kind": "script",
|
|
66
|
+
"frame_id": 0,
|
|
67
|
+
"parent_frame_id": null,
|
|
68
|
+
"visible": null,
|
|
69
|
+
"origin": "https://js.mollie.com",
|
|
70
|
+
"path_pattern": "/v2/mollie.js"
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"rule_id": "mollie-components-v2",
|
|
74
|
+
"kind": "script",
|
|
75
|
+
"frame_id": 0,
|
|
76
|
+
"parent_frame_id": null,
|
|
77
|
+
"visible": null,
|
|
78
|
+
"origin": "https://js.mollie.com",
|
|
79
|
+
"path_pattern": "^/v2/mollie\\.js$"
|
|
80
|
+
}
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
],
|
|
84
|
+
"reason_codes": [
|
|
85
|
+
"integration_flow_undeclared"
|
|
86
|
+
],
|
|
87
|
+
"limitations": [
|
|
88
|
+
"The payment request must match the supported Mollie Components card-token format.",
|
|
89
|
+
"Authentication and merchant confirmation must finish in the merchant browser.",
|
|
90
|
+
"Merchant configuration, card eligibility and processor approval still determine whether the purchase succeeds."
|
|
91
|
+
],
|
|
92
|
+
"missing_evidence": [
|
|
93
|
+
"integration_flow_capability"
|
|
94
|
+
],
|
|
95
|
+
"observation": {
|
|
96
|
+
"complete": true,
|
|
97
|
+
"truncated": false,
|
|
98
|
+
"reasons": []
|
|
99
|
+
},
|
|
100
|
+
"scope": "preflight_hint",
|
|
101
|
+
"merchant_confirmation_required": true
|
|
102
|
+
}
|
|
103
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
{
|
|
2
|
+
"snapshot": {
|
|
3
|
+
"schema_version": 1,
|
|
4
|
+
"catalog_version": "2026-09-11.2",
|
|
5
|
+
"signals": [
|
|
6
|
+
{
|
|
7
|
+
"rule_id": "stripe-js-v3",
|
|
8
|
+
"kind": "script",
|
|
9
|
+
"frame_id": 0,
|
|
10
|
+
"parent_frame_id": null,
|
|
11
|
+
"visible": null
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"rule_id": "stripe-js-script",
|
|
15
|
+
"kind": "script",
|
|
16
|
+
"frame_id": 0,
|
|
17
|
+
"parent_frame_id": null,
|
|
18
|
+
"visible": null
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"observation": {
|
|
22
|
+
"complete": true,
|
|
23
|
+
"truncated": false,
|
|
24
|
+
"reasons": []
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"result": {
|
|
28
|
+
"schema_version": 1,
|
|
29
|
+
"catalog_version": "2026-09-11.2",
|
|
30
|
+
"integration": {
|
|
31
|
+
"id": "direct_sdk",
|
|
32
|
+
"version": "bundled"
|
|
33
|
+
},
|
|
34
|
+
"scenario": "one_time",
|
|
35
|
+
"scenario_defaulted": false,
|
|
36
|
+
"psp": "stripe",
|
|
37
|
+
"flow": null,
|
|
38
|
+
"mode": "token",
|
|
39
|
+
"status": "supported",
|
|
40
|
+
"support_scope": "processor_integration",
|
|
41
|
+
"checkout_flow_status": "unknown",
|
|
42
|
+
"candidates": [
|
|
43
|
+
{
|
|
44
|
+
"psp": "stripe",
|
|
45
|
+
"relevance": "undetermined",
|
|
46
|
+
"evidence": [
|
|
47
|
+
{
|
|
48
|
+
"rule_id": "stripe-js-v3",
|
|
49
|
+
"kind": "script",
|
|
50
|
+
"frame_id": 0,
|
|
51
|
+
"parent_frame_id": null,
|
|
52
|
+
"visible": null,
|
|
53
|
+
"origin": "https://js.stripe.com",
|
|
54
|
+
"path_pattern": "/v3/*"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"rule_id": "stripe-js-script",
|
|
58
|
+
"kind": "script",
|
|
59
|
+
"frame_id": 0,
|
|
60
|
+
"parent_frame_id": null,
|
|
61
|
+
"visible": null,
|
|
62
|
+
"origin": "https://js.stripe.com",
|
|
63
|
+
"path_pattern": "^/v3/?$"
|
|
64
|
+
}
|
|
65
|
+
]
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"reason_codes": [
|
|
69
|
+
"checkout_flow_unidentified",
|
|
70
|
+
"processor_supported_by_integration"
|
|
71
|
+
],
|
|
72
|
+
"limitations": [
|
|
73
|
+
"Processor assets alone do not establish the active card payment flow.",
|
|
74
|
+
"Tokenization replays a token response; it does not authorize a later PaymentIntent confirm.",
|
|
75
|
+
"Direct PaymentIntent confirms require a card-bearing template; the intent’s amount is read from Stripe and a hint sent as amount with currency must agree with it.",
|
|
76
|
+
"Direct SetupIntent confirms require a card-bearing template and save a card without charging it; future charges are merchant-managed.",
|
|
77
|
+
"Automatic token-to-PaymentIntent or token-to-SetupIntent continuation is unsupported; tokenization does not bind a later intent.",
|
|
78
|
+
"A token response does not bind a later PaymentIntent confirmation.",
|
|
79
|
+
"A token response does not bind a later SetupIntent confirmation."
|
|
80
|
+
],
|
|
81
|
+
"missing_evidence": [
|
|
82
|
+
"active_checkout_flow"
|
|
83
|
+
],
|
|
84
|
+
"observation": {
|
|
85
|
+
"complete": true,
|
|
86
|
+
"truncated": false,
|
|
87
|
+
"reasons": []
|
|
88
|
+
},
|
|
89
|
+
"scope": "preflight_hint",
|
|
90
|
+
"merchant_confirmation_required": true
|
|
91
|
+
}
|
|
92
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"signals": [
|
|
3
|
+
{
|
|
4
|
+
"kind": "script",
|
|
5
|
+
"url": "https://js.stripe.com/v3/?example=discard-this-query",
|
|
6
|
+
"frame_id": 0,
|
|
7
|
+
"parent_frame_id": null,
|
|
8
|
+
"visible": null
|
|
9
|
+
}
|
|
10
|
+
],
|
|
11
|
+
"observation": {
|
|
12
|
+
"complete": true,
|
|
13
|
+
"truncated": false,
|
|
14
|
+
"reasons": []
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
{
|
|
2
|
+
"snapshot": {
|
|
3
|
+
"schema_version": 1,
|
|
4
|
+
"catalog_version": "2026-09-11.2",
|
|
5
|
+
"signals": [
|
|
6
|
+
{
|
|
7
|
+
"rule_id": "stripe-js-v3",
|
|
8
|
+
"kind": "script",
|
|
9
|
+
"frame_id": 0,
|
|
10
|
+
"parent_frame_id": null,
|
|
11
|
+
"visible": null
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"rule_id": "stripe-js-script",
|
|
15
|
+
"kind": "script",
|
|
16
|
+
"frame_id": 0,
|
|
17
|
+
"parent_frame_id": null,
|
|
18
|
+
"visible": null
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"observation": {
|
|
22
|
+
"complete": true,
|
|
23
|
+
"truncated": false,
|
|
24
|
+
"reasons": []
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"result": {
|
|
28
|
+
"schema_version": 1,
|
|
29
|
+
"catalog_version": "2026-09-11.2",
|
|
30
|
+
"integration": {
|
|
31
|
+
"id": "kernel_native",
|
|
32
|
+
"version": "example-native-adapter"
|
|
33
|
+
},
|
|
34
|
+
"scenario": "one_time",
|
|
35
|
+
"scenario_defaulted": false,
|
|
36
|
+
"psp": "stripe",
|
|
37
|
+
"flow": null,
|
|
38
|
+
"mode": "token",
|
|
39
|
+
"status": "unknown",
|
|
40
|
+
"support_scope": null,
|
|
41
|
+
"checkout_flow_status": "unknown",
|
|
42
|
+
"candidates": [
|
|
43
|
+
{
|
|
44
|
+
"psp": "stripe",
|
|
45
|
+
"relevance": "undetermined",
|
|
46
|
+
"evidence": [
|
|
47
|
+
{
|
|
48
|
+
"rule_id": "stripe-js-v3",
|
|
49
|
+
"kind": "script",
|
|
50
|
+
"frame_id": 0,
|
|
51
|
+
"parent_frame_id": null,
|
|
52
|
+
"visible": null,
|
|
53
|
+
"origin": "https://js.stripe.com",
|
|
54
|
+
"path_pattern": "/v3/*"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"rule_id": "stripe-js-script",
|
|
58
|
+
"kind": "script",
|
|
59
|
+
"frame_id": 0,
|
|
60
|
+
"parent_frame_id": null,
|
|
61
|
+
"visible": null,
|
|
62
|
+
"origin": "https://js.stripe.com",
|
|
63
|
+
"path_pattern": "^/v3/?$"
|
|
64
|
+
}
|
|
65
|
+
]
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"reason_codes": [
|
|
69
|
+
"checkout_flow_unidentified",
|
|
70
|
+
"integration_processor_undeclared"
|
|
71
|
+
],
|
|
72
|
+
"limitations": [
|
|
73
|
+
"Processor assets alone do not establish the active card payment flow."
|
|
74
|
+
],
|
|
75
|
+
"missing_evidence": [
|
|
76
|
+
"active_checkout_flow",
|
|
77
|
+
"integration_processor_capability"
|
|
78
|
+
],
|
|
79
|
+
"observation": {
|
|
80
|
+
"complete": true,
|
|
81
|
+
"truncated": false,
|
|
82
|
+
"reasons": []
|
|
83
|
+
},
|
|
84
|
+
"scope": "preflight_hint",
|
|
85
|
+
"merchant_confirmation_required": true
|
|
86
|
+
}
|
|
87
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agent-cards/checkout",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"description": "Let browser agents pay with the user's own card, without your infrastructure ever touching card data.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -8,24 +8,32 @@
|
|
|
8
8
|
"exports": {
|
|
9
9
|
".": "./dist/index.js",
|
|
10
10
|
"./cdp": "./dist/cdp.js",
|
|
11
|
-
"./playwright": "./dist/
|
|
11
|
+
"./playwright": "./dist/playwright.js",
|
|
12
|
+
"./preflight": "./dist/preflight.js",
|
|
13
|
+
"./preflight/catalog.json": "./dist/preflight-catalog.json",
|
|
14
|
+
"./preflight/schemas.json": "./dist/preflight-schemas.json"
|
|
12
15
|
},
|
|
13
16
|
"files": [
|
|
14
17
|
"dist",
|
|
15
18
|
"README.md",
|
|
16
19
|
"CHANGELOG.md",
|
|
17
|
-
"examples"
|
|
20
|
+
"examples",
|
|
21
|
+
"PREFLIGHT.md"
|
|
18
22
|
],
|
|
19
23
|
"publishConfig": {
|
|
20
24
|
"access": "public"
|
|
21
25
|
},
|
|
22
26
|
"scripts": {
|
|
23
27
|
"_comment_build": "The public SDK keeps zero runtime dependencies. Its build vendors deterministic metadata and substitution artifacts from the internal payment core; TypeScript remains pinned.",
|
|
24
|
-
"build": "node ../payment-core/scripts/build.mjs && node scripts/generate-payment-core.mjs && npx -y -p typescript@5.9.3 tsc",
|
|
28
|
+
"build": "node ../payment-core/scripts/build.mjs && node scripts/generate-payment-core.mjs && npx -y -p typescript@5.9.3 tsc && node scripts/generate-preflight-contract.mjs",
|
|
25
29
|
"prepublishOnly": "pnpm build",
|
|
26
|
-
"test": "node test.mjs && node --test lifecycle.test.mjs merchant-abort.test.mjs preparation.test.mjs braintree.test.mjs autopilot.test.mjs payment-core.test.mjs prepared-processor.test.mjs minimum-delay.test.mjs paysafe.test.mjs attachment.test.mjs",
|
|
30
|
+
"test": "node test.mjs && node --test lifecycle.test.mjs merchant-abort.test.mjs preparation.test.mjs braintree.test.mjs autopilot.test.mjs payment-core.test.mjs prepared-processor.test.mjs minimum-delay.test.mjs paysafe.test.mjs attachment.test.mjs && node --test preflight-package.test.mjs preflight-collector.test.mjs",
|
|
27
31
|
"test:browser": "node browser.test.mjs && node stripe-browser.test.mjs && node preparation-browser.test.mjs && node owned-shop-browser.test.mjs",
|
|
28
|
-
"check:payment-core": "node scripts/generate-payment-core.mjs --check"
|
|
32
|
+
"check:payment-core": "node scripts/generate-payment-core.mjs --check",
|
|
33
|
+
"test:preflight": "node --test preflight-package.test.mjs preflight-collector.test.mjs",
|
|
34
|
+
"test:preflight:browser": "node preflight-browser.test.mjs",
|
|
35
|
+
"pack:preview": "node scripts/pack-preflight-preview.mjs",
|
|
36
|
+
"test:preflight:schemas": "node --test preflight-schemas.test.mjs"
|
|
29
37
|
},
|
|
30
38
|
"keywords": [
|
|
31
39
|
"payments",
|