@astrasyncai/verification-gateway 3.8.0 → 3.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.
Files changed (108) hide show
  1. package/dist/adapter-interface/interface.d.mts +2 -2
  2. package/dist/adapter-interface/interface.d.ts +2 -2
  3. package/dist/adapters/express.d.mts +2 -2
  4. package/dist/adapters/express.d.ts +2 -2
  5. package/dist/adapters/express.js +2 -1
  6. package/dist/adapters/express.js.map +1 -1
  7. package/dist/adapters/express.mjs +2 -1
  8. package/dist/adapters/express.mjs.map +1 -1
  9. package/dist/adapters/http-pdlss.d.mts +81 -0
  10. package/dist/adapters/http-pdlss.d.ts +81 -0
  11. package/dist/adapters/http-pdlss.js +117 -0
  12. package/dist/adapters/http-pdlss.js.map +1 -0
  13. package/dist/adapters/http-pdlss.mjs +87 -0
  14. package/dist/adapters/http-pdlss.mjs.map +1 -0
  15. package/dist/adapters/mcp.d.mts +1 -1
  16. package/dist/adapters/mcp.d.ts +1 -1
  17. package/dist/adapters/mcp.js +2 -1
  18. package/dist/adapters/mcp.js.map +1 -1
  19. package/dist/adapters/mcp.mjs +2 -1
  20. package/dist/adapters/mcp.mjs.map +1 -1
  21. package/dist/adapters/nextjs.d.mts +2 -2
  22. package/dist/adapters/nextjs.d.ts +2 -2
  23. package/dist/adapters/nextjs.js +2 -1
  24. package/dist/adapters/nextjs.js.map +1 -1
  25. package/dist/adapters/nextjs.mjs +2 -1
  26. package/dist/adapters/nextjs.mjs.map +1 -1
  27. package/dist/adapters/sdk.d.mts +2 -2
  28. package/dist/adapters/sdk.d.ts +2 -2
  29. package/dist/adapters/sdk.js +2 -1
  30. package/dist/adapters/sdk.js.map +1 -1
  31. package/dist/adapters/sdk.mjs +2 -1
  32. package/dist/adapters/sdk.mjs.map +1 -1
  33. package/dist/agent/index.d.mts +2 -2
  34. package/dist/agent/index.d.ts +2 -2
  35. package/dist/bin/astrasync-claude-hook.js +14 -1
  36. package/dist/bin/astrasync-guard.js +14 -1
  37. package/dist/bin/astrasync.js +31 -1
  38. package/dist/browser/background.js +14 -1
  39. package/dist/browser/background.js.map +1 -1
  40. package/dist/browser/background.mjs +14 -1
  41. package/dist/browser/background.mjs.map +1 -1
  42. package/dist/browser/browser-adapter.d.mts +2 -2
  43. package/dist/browser/browser-adapter.d.ts +2 -2
  44. package/dist/claude-code/claude-code-adapter.d.mts +2 -2
  45. package/dist/claude-code/claude-code-adapter.d.ts +2 -2
  46. package/dist/cli/index.d.mts +2 -2
  47. package/dist/cli/index.d.ts +2 -2
  48. package/dist/cursor/cursor-adapter.d.mts +2 -2
  49. package/dist/cursor/cursor-adapter.d.ts +2 -2
  50. package/dist/cursor/extension.d.mts +2 -2
  51. package/dist/cursor/extension.d.ts +2 -2
  52. package/dist/cursor/extension.js +14 -1
  53. package/dist/cursor/extension.js.map +1 -1
  54. package/dist/cursor/extension.mjs +14 -1
  55. package/dist/cursor/extension.mjs.map +1 -1
  56. package/dist/edge-config.d.mts +130 -0
  57. package/dist/edge-config.d.ts +130 -0
  58. package/dist/edge-config.js +162 -0
  59. package/dist/edge-config.js.map +1 -0
  60. package/dist/edge-config.mjs +131 -0
  61. package/dist/edge-config.mjs.map +1 -0
  62. package/dist/{express-Di_hnZZS.d.mts → express-DXUyvv7t.d.mts} +1 -1
  63. package/dist/{express-C8nJGi5P.d.ts → express-sGXhDdd0.d.ts} +1 -1
  64. package/dist/gateway/gateway.d.mts +2 -2
  65. package/dist/gateway/gateway.d.ts +2 -2
  66. package/dist/gateway/gateway.js +14 -1
  67. package/dist/gateway/gateway.js.map +1 -1
  68. package/dist/gateway/gateway.mjs +14 -1
  69. package/dist/gateway/gateway.mjs.map +1 -1
  70. package/dist/git-trigger/git-hooks.d.mts +2 -2
  71. package/dist/git-trigger/git-hooks.d.ts +2 -2
  72. package/dist/{index-CuCkjT7B.d.ts → index-C61VL_OW.d.ts} +1 -1
  73. package/dist/{index-CBQr4FGs.d.ts → index-CMg-vjEK.d.ts} +1 -1
  74. package/dist/{index-CXcvO9Au.d.mts → index-Dalih3EB.d.mts} +1 -1
  75. package/dist/{index-DALAqct7.d.mts → index-DmmdehNu.d.mts} +1 -1
  76. package/dist/index.d.mts +26 -82
  77. package/dist/index.d.ts +26 -82
  78. package/dist/index.js +226 -10
  79. package/dist/index.js.map +1 -1
  80. package/dist/index.mjs +215 -10
  81. package/dist/index.mjs.map +1 -1
  82. package/dist/local-evaluator/evaluator.d.mts +2 -2
  83. package/dist/local-evaluator/evaluator.d.ts +2 -2
  84. package/dist/{nextjs-IyXWW2KL.d.ts → nextjs-DwUW-Nm1.d.ts} +1 -1
  85. package/dist/{nextjs-BMAe8ode.d.mts → nextjs-F_2pbPIA.d.mts} +1 -1
  86. package/dist/platform-signatures.d.mts +47 -0
  87. package/dist/platform-signatures.d.ts +47 -0
  88. package/dist/platform-signatures.js +89 -0
  89. package/dist/platform-signatures.js.map +1 -0
  90. package/dist/platform-signatures.mjs +63 -0
  91. package/dist/platform-signatures.mjs.map +1 -0
  92. package/dist/{sdk-ThdA_NtL.d.ts → sdk-CfHANs4A.d.ts} +1 -1
  93. package/dist/{sdk-Cn4KcZ5G.d.mts → sdk-Clob2-0A.d.mts} +1 -1
  94. package/dist/transport/index.d.mts +2 -2
  95. package/dist/transport/index.d.ts +2 -2
  96. package/dist/{types-DedAJbNI.d.mts → types-ACMsV07B.d.mts} +76 -1
  97. package/dist/{types-DedAJbNI.d.ts → types-ACMsV07B.d.ts} +76 -1
  98. package/dist/{types-CSFci5zD.d.mts → types-BtqUvK8v.d.mts} +1 -1
  99. package/dist/{types-D1kyMiml.d.ts → types-DmSDgPpG.d.ts} +1 -1
  100. package/dist/ui/index.d.mts +1 -1
  101. package/dist/ui/index.d.ts +1 -1
  102. package/dist/verify.d.mts +144 -0
  103. package/dist/verify.d.ts +144 -0
  104. package/dist/verify.js +593 -0
  105. package/dist/verify.js.map +1 -0
  106. package/dist/verify.mjs +557 -0
  107. package/dist/verify.mjs.map +1 -0
  108. package/package.json +21 -1
@@ -1,5 +1,5 @@
1
- import { L as LocalPolicy, P as PDLSSContext, V as VerificationDecision, b as LocalPurposeRule } from '../types-CSFci5zD.mjs';
2
- import '../types-DedAJbNI.mjs';
1
+ import { L as LocalPolicy, P as PDLSSContext, V as VerificationDecision, b as LocalPurposeRule } from '../types-BtqUvK8v.mjs';
2
+ import '../types-ACMsV07B.mjs';
3
3
 
4
4
  /**
5
5
  * Local PDLSS Evaluator
@@ -1,5 +1,5 @@
1
- import { L as LocalPolicy, P as PDLSSContext, V as VerificationDecision, b as LocalPurposeRule } from '../types-D1kyMiml.js';
2
- import '../types-DedAJbNI.js';
1
+ import { L as LocalPolicy, P as PDLSSContext, V as VerificationDecision, b as LocalPurposeRule } from '../types-DmSDgPpG.js';
2
+ import '../types-ACMsV07B.js';
3
3
 
4
4
  /**
5
5
  * Local PDLSS Evaluator
@@ -1,6 +1,6 @@
1
1
  import * as next_server from 'next/server';
2
2
  import { NextRequest } from 'next/server';
3
- import { N as NextJsMiddlewareOptions } from './types-DedAJbNI.js';
3
+ import { N as NextJsMiddlewareOptions } from './types-ACMsV07B.js';
4
4
 
5
5
  /**
6
6
  * Create Next.js middleware for agent verification.
@@ -1,6 +1,6 @@
1
1
  import * as next_server from 'next/server';
2
2
  import { NextRequest } from 'next/server';
3
- import { N as NextJsMiddlewareOptions } from './types-DedAJbNI.mjs';
3
+ import { N as NextJsMiddlewareOptions } from './types-ACMsV07B.mjs';
4
4
 
5
5
  /**
6
6
  * Create Next.js middleware for agent verification.
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Platform-agent fingerprint signatures — the shared registry of known
3
+ * platform-agent UA / agent-card patterns (Claude / ChatGPT / Gemini /
4
+ * Cursor / Goose).
5
+ *
6
+ * Single source of truth, lifted verbatim from the backend's
7
+ * `platform-agent-detector.service` (which now imports detection from
8
+ * here): the backend's verify-access anonymous handler and the edge
9
+ * adapter (`@astrasyncai/adapter-lambda`) must classify identically or
10
+ * the three-tier visibility numbers drift between capture points.
11
+ *
12
+ * Pure regex — no Node built-ins, edge-safe. Detection is regex-only for
13
+ * v2.9 — TLS fingerprinting / behavioural signatures are deferred
14
+ * (recorded in adapter requirements doc).
15
+ */
16
+ type PlatformAgentVendor = 'claude' | 'chatgpt' | 'gemini' | 'cursor' | 'goose' | 'unknown';
17
+ interface PlatformFingerprint {
18
+ vendor: PlatformAgentVendor;
19
+ /** A stable identifier used as the orphan-agent dedup key. */
20
+ fingerprintKey: string;
21
+ /** Human-readable name surfaced in the admin panel. */
22
+ displayName: string;
23
+ }
24
+ interface PlatformDetectionInput {
25
+ userAgent?: string;
26
+ agentCardUrl?: string;
27
+ }
28
+ /**
29
+ * Registry of known platform-agent signatures. Order matters — first match wins.
30
+ *
31
+ * Patterns are intentionally permissive (case-insensitive substring match) since
32
+ * platform UA strings drift between versions. False positives are tolerable —
33
+ * the orphan record is informational, not enforcement.
34
+ */
35
+ declare const PLATFORM_AGENT_SIGNATURES: ReadonlyArray<{
36
+ vendor: PlatformAgentVendor;
37
+ displayName: string;
38
+ uaPatterns?: RegExp[];
39
+ agentCardPatterns?: RegExp[];
40
+ }>;
41
+ /**
42
+ * Inspect caller metadata for a known platform-agent fingerprint.
43
+ * Returns undefined if no signature matches.
44
+ */
45
+ declare function detectPlatformFingerprint(input: PlatformDetectionInput): PlatformFingerprint | undefined;
46
+
47
+ export { PLATFORM_AGENT_SIGNATURES, type PlatformAgentVendor, type PlatformDetectionInput, type PlatformFingerprint, detectPlatformFingerprint };
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Platform-agent fingerprint signatures — the shared registry of known
3
+ * platform-agent UA / agent-card patterns (Claude / ChatGPT / Gemini /
4
+ * Cursor / Goose).
5
+ *
6
+ * Single source of truth, lifted verbatim from the backend's
7
+ * `platform-agent-detector.service` (which now imports detection from
8
+ * here): the backend's verify-access anonymous handler and the edge
9
+ * adapter (`@astrasyncai/adapter-lambda`) must classify identically or
10
+ * the three-tier visibility numbers drift between capture points.
11
+ *
12
+ * Pure regex — no Node built-ins, edge-safe. Detection is regex-only for
13
+ * v2.9 — TLS fingerprinting / behavioural signatures are deferred
14
+ * (recorded in adapter requirements doc).
15
+ */
16
+ type PlatformAgentVendor = 'claude' | 'chatgpt' | 'gemini' | 'cursor' | 'goose' | 'unknown';
17
+ interface PlatformFingerprint {
18
+ vendor: PlatformAgentVendor;
19
+ /** A stable identifier used as the orphan-agent dedup key. */
20
+ fingerprintKey: string;
21
+ /** Human-readable name surfaced in the admin panel. */
22
+ displayName: string;
23
+ }
24
+ interface PlatformDetectionInput {
25
+ userAgent?: string;
26
+ agentCardUrl?: string;
27
+ }
28
+ /**
29
+ * Registry of known platform-agent signatures. Order matters — first match wins.
30
+ *
31
+ * Patterns are intentionally permissive (case-insensitive substring match) since
32
+ * platform UA strings drift between versions. False positives are tolerable —
33
+ * the orphan record is informational, not enforcement.
34
+ */
35
+ declare const PLATFORM_AGENT_SIGNATURES: ReadonlyArray<{
36
+ vendor: PlatformAgentVendor;
37
+ displayName: string;
38
+ uaPatterns?: RegExp[];
39
+ agentCardPatterns?: RegExp[];
40
+ }>;
41
+ /**
42
+ * Inspect caller metadata for a known platform-agent fingerprint.
43
+ * Returns undefined if no signature matches.
44
+ */
45
+ declare function detectPlatformFingerprint(input: PlatformDetectionInput): PlatformFingerprint | undefined;
46
+
47
+ export { PLATFORM_AGENT_SIGNATURES, type PlatformAgentVendor, type PlatformDetectionInput, type PlatformFingerprint, detectPlatformFingerprint };
@@ -0,0 +1,89 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/platform-signatures.ts
21
+ var platform_signatures_exports = {};
22
+ __export(platform_signatures_exports, {
23
+ PLATFORM_AGENT_SIGNATURES: () => PLATFORM_AGENT_SIGNATURES,
24
+ detectPlatformFingerprint: () => detectPlatformFingerprint
25
+ });
26
+ module.exports = __toCommonJS(platform_signatures_exports);
27
+ var PLATFORM_AGENT_SIGNATURES = [
28
+ {
29
+ vendor: "claude",
30
+ displayName: "Anthropic Claude",
31
+ uaPatterns: [/claude/i, /anthropic/i],
32
+ agentCardPatterns: [/anthropic\.com/i, /claude\.ai/i]
33
+ },
34
+ {
35
+ vendor: "chatgpt",
36
+ displayName: "OpenAI ChatGPT",
37
+ uaPatterns: [/chatgpt/i, /openai/i, /gpt-?\d/i],
38
+ agentCardPatterns: [/openai\.com/i, /chatgpt\.com/i]
39
+ },
40
+ {
41
+ vendor: "gemini",
42
+ displayName: "Google Gemini",
43
+ uaPatterns: [/gemini/i, /google-gemini/i, /bard/i],
44
+ agentCardPatterns: [/gemini\.google\.com/i, /ai\.google\.dev/i]
45
+ },
46
+ {
47
+ vendor: "cursor",
48
+ displayName: "Cursor",
49
+ uaPatterns: [/cursor/i],
50
+ agentCardPatterns: [/cursor\.sh/i, /cursor\.com/i]
51
+ },
52
+ {
53
+ vendor: "goose",
54
+ displayName: "Block Goose",
55
+ uaPatterns: [/goose/i, /block-goose/i],
56
+ agentCardPatterns: [/block\.xyz\/goose/i, /goose\.tools/i]
57
+ }
58
+ ];
59
+ function detectPlatformFingerprint(input) {
60
+ const ua = input.userAgent ?? "";
61
+ const cardUrl = input.agentCardUrl ?? "";
62
+ for (const sig of PLATFORM_AGENT_SIGNATURES) {
63
+ const uaMatch = sig.uaPatterns?.some((p) => p.test(ua));
64
+ const cardMatch = sig.agentCardPatterns?.some((p) => p.test(cardUrl));
65
+ if (uaMatch || cardMatch) {
66
+ const uaBase = ua.split(/[\s/]/)[0]?.toLowerCase() ?? "";
67
+ const cardHost = (() => {
68
+ try {
69
+ return cardUrl ? new URL(cardUrl).host : "";
70
+ } catch {
71
+ return "";
72
+ }
73
+ })();
74
+ const fingerprintKey = `${sig.vendor}:${uaBase || cardHost || "unknown"}`;
75
+ return {
76
+ vendor: sig.vendor,
77
+ fingerprintKey,
78
+ displayName: sig.displayName
79
+ };
80
+ }
81
+ }
82
+ return void 0;
83
+ }
84
+ // Annotate the CommonJS export names for ESM import in node:
85
+ 0 && (module.exports = {
86
+ PLATFORM_AGENT_SIGNATURES,
87
+ detectPlatformFingerprint
88
+ });
89
+ //# sourceMappingURL=platform-signatures.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/platform-signatures.ts"],"sourcesContent":["/**\n * Platform-agent fingerprint signatures — the shared registry of known\n * platform-agent UA / agent-card patterns (Claude / ChatGPT / Gemini /\n * Cursor / Goose).\n *\n * Single source of truth, lifted verbatim from the backend's\n * `platform-agent-detector.service` (which now imports detection from\n * here): the backend's verify-access anonymous handler and the edge\n * adapter (`@astrasyncai/adapter-lambda`) must classify identically or\n * the three-tier visibility numbers drift between capture points.\n *\n * Pure regex — no Node built-ins, edge-safe. Detection is regex-only for\n * v2.9 — TLS fingerprinting / behavioural signatures are deferred\n * (recorded in adapter requirements doc).\n */\n\nexport type PlatformAgentVendor = 'claude' | 'chatgpt' | 'gemini' | 'cursor' | 'goose' | 'unknown';\n\nexport interface PlatformFingerprint {\n vendor: PlatformAgentVendor;\n /** A stable identifier used as the orphan-agent dedup key. */\n fingerprintKey: string;\n /** Human-readable name surfaced in the admin panel. */\n displayName: string;\n}\n\nexport interface PlatformDetectionInput {\n userAgent?: string;\n agentCardUrl?: string;\n}\n\n/**\n * Registry of known platform-agent signatures. Order matters — first match wins.\n *\n * Patterns are intentionally permissive (case-insensitive substring match) since\n * platform UA strings drift between versions. False positives are tolerable —\n * the orphan record is informational, not enforcement.\n */\nexport const PLATFORM_AGENT_SIGNATURES: ReadonlyArray<{\n vendor: PlatformAgentVendor;\n displayName: string;\n uaPatterns?: RegExp[];\n agentCardPatterns?: RegExp[];\n}> = [\n {\n vendor: 'claude',\n displayName: 'Anthropic Claude',\n uaPatterns: [/claude/i, /anthropic/i],\n agentCardPatterns: [/anthropic\\.com/i, /claude\\.ai/i],\n },\n {\n vendor: 'chatgpt',\n displayName: 'OpenAI ChatGPT',\n uaPatterns: [/chatgpt/i, /openai/i, /gpt-?\\d/i],\n agentCardPatterns: [/openai\\.com/i, /chatgpt\\.com/i],\n },\n {\n vendor: 'gemini',\n displayName: 'Google Gemini',\n uaPatterns: [/gemini/i, /google-gemini/i, /bard/i],\n agentCardPatterns: [/gemini\\.google\\.com/i, /ai\\.google\\.dev/i],\n },\n {\n vendor: 'cursor',\n displayName: 'Cursor',\n uaPatterns: [/cursor/i],\n agentCardPatterns: [/cursor\\.sh/i, /cursor\\.com/i],\n },\n {\n vendor: 'goose',\n displayName: 'Block Goose',\n uaPatterns: [/goose/i, /block-goose/i],\n agentCardPatterns: [/block\\.xyz\\/goose/i, /goose\\.tools/i],\n },\n];\n\n/**\n * Inspect caller metadata for a known platform-agent fingerprint.\n * Returns undefined if no signature matches.\n */\nexport function detectPlatformFingerprint(\n input: PlatformDetectionInput\n): PlatformFingerprint | undefined {\n const ua = input.userAgent ?? '';\n const cardUrl = input.agentCardUrl ?? '';\n\n for (const sig of PLATFORM_AGENT_SIGNATURES) {\n const uaMatch = sig.uaPatterns?.some((p) => p.test(ua));\n const cardMatch = sig.agentCardPatterns?.some((p) => p.test(cardUrl));\n if (uaMatch || cardMatch) {\n // Stable dedup key: vendor + lowercased UA basename (before first slash/space).\n // For requests without UA, fall back to vendor + agent-card host.\n const uaBase = ua.split(/[\\s/]/)[0]?.toLowerCase() ?? '';\n const cardHost = (() => {\n try {\n return cardUrl ? new URL(cardUrl).host : '';\n } catch {\n return '';\n }\n })();\n const fingerprintKey = `${sig.vendor}:${uaBase || cardHost || 'unknown'}`;\n return {\n vendor: sig.vendor,\n fingerprintKey,\n displayName: sig.displayName,\n };\n }\n }\n\n return undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAsCO,IAAM,4BAKR;AAAA,EACH;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,WAAW,YAAY;AAAA,IACpC,mBAAmB,CAAC,mBAAmB,aAAa;AAAA,EACtD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,YAAY,WAAW,UAAU;AAAA,IAC9C,mBAAmB,CAAC,gBAAgB,eAAe;AAAA,EACrD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,WAAW,kBAAkB,OAAO;AAAA,IACjD,mBAAmB,CAAC,wBAAwB,kBAAkB;AAAA,EAChE;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,SAAS;AAAA,IACtB,mBAAmB,CAAC,eAAe,cAAc;AAAA,EACnD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,UAAU,cAAc;AAAA,IACrC,mBAAmB,CAAC,sBAAsB,eAAe;AAAA,EAC3D;AACF;AAMO,SAAS,0BACd,OACiC;AACjC,QAAM,KAAK,MAAM,aAAa;AAC9B,QAAM,UAAU,MAAM,gBAAgB;AAEtC,aAAW,OAAO,2BAA2B;AAC3C,UAAM,UAAU,IAAI,YAAY,KAAK,CAAC,MAAM,EAAE,KAAK,EAAE,CAAC;AACtD,UAAM,YAAY,IAAI,mBAAmB,KAAK,CAAC,MAAM,EAAE,KAAK,OAAO,CAAC;AACpE,QAAI,WAAW,WAAW;AAGxB,YAAM,SAAS,GAAG,MAAM,OAAO,EAAE,CAAC,GAAG,YAAY,KAAK;AACtD,YAAM,YAAY,MAAM;AACtB,YAAI;AACF,iBAAO,UAAU,IAAI,IAAI,OAAO,EAAE,OAAO;AAAA,QAC3C,QAAQ;AACN,iBAAO;AAAA,QACT;AAAA,MACF,GAAG;AACH,YAAM,iBAAiB,GAAG,IAAI,MAAM,IAAI,UAAU,YAAY,SAAS;AACvE,aAAO;AAAA,QACL,QAAQ,IAAI;AAAA,QACZ;AAAA,QACA,aAAa,IAAI;AAAA,MACnB;AAAA,IACF;AAAA,EACF;AAEA,SAAO;AACT;","names":[]}
@@ -0,0 +1,63 @@
1
+ // src/platform-signatures.ts
2
+ var PLATFORM_AGENT_SIGNATURES = [
3
+ {
4
+ vendor: "claude",
5
+ displayName: "Anthropic Claude",
6
+ uaPatterns: [/claude/i, /anthropic/i],
7
+ agentCardPatterns: [/anthropic\.com/i, /claude\.ai/i]
8
+ },
9
+ {
10
+ vendor: "chatgpt",
11
+ displayName: "OpenAI ChatGPT",
12
+ uaPatterns: [/chatgpt/i, /openai/i, /gpt-?\d/i],
13
+ agentCardPatterns: [/openai\.com/i, /chatgpt\.com/i]
14
+ },
15
+ {
16
+ vendor: "gemini",
17
+ displayName: "Google Gemini",
18
+ uaPatterns: [/gemini/i, /google-gemini/i, /bard/i],
19
+ agentCardPatterns: [/gemini\.google\.com/i, /ai\.google\.dev/i]
20
+ },
21
+ {
22
+ vendor: "cursor",
23
+ displayName: "Cursor",
24
+ uaPatterns: [/cursor/i],
25
+ agentCardPatterns: [/cursor\.sh/i, /cursor\.com/i]
26
+ },
27
+ {
28
+ vendor: "goose",
29
+ displayName: "Block Goose",
30
+ uaPatterns: [/goose/i, /block-goose/i],
31
+ agentCardPatterns: [/block\.xyz\/goose/i, /goose\.tools/i]
32
+ }
33
+ ];
34
+ function detectPlatformFingerprint(input) {
35
+ const ua = input.userAgent ?? "";
36
+ const cardUrl = input.agentCardUrl ?? "";
37
+ for (const sig of PLATFORM_AGENT_SIGNATURES) {
38
+ const uaMatch = sig.uaPatterns?.some((p) => p.test(ua));
39
+ const cardMatch = sig.agentCardPatterns?.some((p) => p.test(cardUrl));
40
+ if (uaMatch || cardMatch) {
41
+ const uaBase = ua.split(/[\s/]/)[0]?.toLowerCase() ?? "";
42
+ const cardHost = (() => {
43
+ try {
44
+ return cardUrl ? new URL(cardUrl).host : "";
45
+ } catch {
46
+ return "";
47
+ }
48
+ })();
49
+ const fingerprintKey = `${sig.vendor}:${uaBase || cardHost || "unknown"}`;
50
+ return {
51
+ vendor: sig.vendor,
52
+ fingerprintKey,
53
+ displayName: sig.displayName
54
+ };
55
+ }
56
+ }
57
+ return void 0;
58
+ }
59
+ export {
60
+ PLATFORM_AGENT_SIGNATURES,
61
+ detectPlatformFingerprint
62
+ };
63
+ //# sourceMappingURL=platform-signatures.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/platform-signatures.ts"],"sourcesContent":["/**\n * Platform-agent fingerprint signatures — the shared registry of known\n * platform-agent UA / agent-card patterns (Claude / ChatGPT / Gemini /\n * Cursor / Goose).\n *\n * Single source of truth, lifted verbatim from the backend's\n * `platform-agent-detector.service` (which now imports detection from\n * here): the backend's verify-access anonymous handler and the edge\n * adapter (`@astrasyncai/adapter-lambda`) must classify identically or\n * the three-tier visibility numbers drift between capture points.\n *\n * Pure regex — no Node built-ins, edge-safe. Detection is regex-only for\n * v2.9 — TLS fingerprinting / behavioural signatures are deferred\n * (recorded in adapter requirements doc).\n */\n\nexport type PlatformAgentVendor = 'claude' | 'chatgpt' | 'gemini' | 'cursor' | 'goose' | 'unknown';\n\nexport interface PlatformFingerprint {\n vendor: PlatformAgentVendor;\n /** A stable identifier used as the orphan-agent dedup key. */\n fingerprintKey: string;\n /** Human-readable name surfaced in the admin panel. */\n displayName: string;\n}\n\nexport interface PlatformDetectionInput {\n userAgent?: string;\n agentCardUrl?: string;\n}\n\n/**\n * Registry of known platform-agent signatures. Order matters — first match wins.\n *\n * Patterns are intentionally permissive (case-insensitive substring match) since\n * platform UA strings drift between versions. False positives are tolerable —\n * the orphan record is informational, not enforcement.\n */\nexport const PLATFORM_AGENT_SIGNATURES: ReadonlyArray<{\n vendor: PlatformAgentVendor;\n displayName: string;\n uaPatterns?: RegExp[];\n agentCardPatterns?: RegExp[];\n}> = [\n {\n vendor: 'claude',\n displayName: 'Anthropic Claude',\n uaPatterns: [/claude/i, /anthropic/i],\n agentCardPatterns: [/anthropic\\.com/i, /claude\\.ai/i],\n },\n {\n vendor: 'chatgpt',\n displayName: 'OpenAI ChatGPT',\n uaPatterns: [/chatgpt/i, /openai/i, /gpt-?\\d/i],\n agentCardPatterns: [/openai\\.com/i, /chatgpt\\.com/i],\n },\n {\n vendor: 'gemini',\n displayName: 'Google Gemini',\n uaPatterns: [/gemini/i, /google-gemini/i, /bard/i],\n agentCardPatterns: [/gemini\\.google\\.com/i, /ai\\.google\\.dev/i],\n },\n {\n vendor: 'cursor',\n displayName: 'Cursor',\n uaPatterns: [/cursor/i],\n agentCardPatterns: [/cursor\\.sh/i, /cursor\\.com/i],\n },\n {\n vendor: 'goose',\n displayName: 'Block Goose',\n uaPatterns: [/goose/i, /block-goose/i],\n agentCardPatterns: [/block\\.xyz\\/goose/i, /goose\\.tools/i],\n },\n];\n\n/**\n * Inspect caller metadata for a known platform-agent fingerprint.\n * Returns undefined if no signature matches.\n */\nexport function detectPlatformFingerprint(\n input: PlatformDetectionInput\n): PlatformFingerprint | undefined {\n const ua = input.userAgent ?? '';\n const cardUrl = input.agentCardUrl ?? '';\n\n for (const sig of PLATFORM_AGENT_SIGNATURES) {\n const uaMatch = sig.uaPatterns?.some((p) => p.test(ua));\n const cardMatch = sig.agentCardPatterns?.some((p) => p.test(cardUrl));\n if (uaMatch || cardMatch) {\n // Stable dedup key: vendor + lowercased UA basename (before first slash/space).\n // For requests without UA, fall back to vendor + agent-card host.\n const uaBase = ua.split(/[\\s/]/)[0]?.toLowerCase() ?? '';\n const cardHost = (() => {\n try {\n return cardUrl ? new URL(cardUrl).host : '';\n } catch {\n return '';\n }\n })();\n const fingerprintKey = `${sig.vendor}:${uaBase || cardHost || 'unknown'}`;\n return {\n vendor: sig.vendor,\n fingerprintKey,\n displayName: sig.displayName,\n };\n }\n }\n\n return undefined;\n}\n"],"mappings":";AAsCO,IAAM,4BAKR;AAAA,EACH;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,WAAW,YAAY;AAAA,IACpC,mBAAmB,CAAC,mBAAmB,aAAa;AAAA,EACtD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,YAAY,WAAW,UAAU;AAAA,IAC9C,mBAAmB,CAAC,gBAAgB,eAAe;AAAA,EACrD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,WAAW,kBAAkB,OAAO;AAAA,IACjD,mBAAmB,CAAC,wBAAwB,kBAAkB;AAAA,EAChE;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,SAAS;AAAA,IACtB,mBAAmB,CAAC,eAAe,cAAc;AAAA,EACnD;AAAA,EACA;AAAA,IACE,QAAQ;AAAA,IACR,aAAa;AAAA,IACb,YAAY,CAAC,UAAU,cAAc;AAAA,IACrC,mBAAmB,CAAC,sBAAsB,eAAe;AAAA,EAC3D;AACF;AAMO,SAAS,0BACd,OACiC;AACjC,QAAM,KAAK,MAAM,aAAa;AAC9B,QAAM,UAAU,MAAM,gBAAgB;AAEtC,aAAW,OAAO,2BAA2B;AAC3C,UAAM,UAAU,IAAI,YAAY,KAAK,CAAC,MAAM,EAAE,KAAK,EAAE,CAAC;AACtD,UAAM,YAAY,IAAI,mBAAmB,KAAK,CAAC,MAAM,EAAE,KAAK,OAAO,CAAC;AACpE,QAAI,WAAW,WAAW;AAGxB,YAAM,SAAS,GAAG,MAAM,OAAO,EAAE,CAAC,GAAG,YAAY,KAAK;AACtD,YAAM,YAAY,MAAM;AACtB,YAAI;AACF,iBAAO,UAAU,IAAI,IAAI,OAAO,EAAE,OAAO;AAAA,QAC3C,QAAQ;AACN,iBAAO;AAAA,QACT;AAAA,MACF,GAAG;AACH,YAAM,iBAAiB,GAAG,IAAI,MAAM,IAAI,UAAU,YAAY,SAAS;AACvE,aAAO;AAAA,QACL,QAAQ,IAAI;AAAA,QACZ;AAAA,QACA,aAAa,IAAI;AAAA,MACnB;AAAA,IACF;AAAA,EACF;AAEA,SAAO;AACT;","names":[]}
@@ -1,4 +1,4 @@
1
- import { a as AccessLevel, p as TrustLevel, S as SDKOptions, q as VerificationResult } from './types-DedAJbNI.js';
1
+ import { a as AccessLevel, q as TrustLevel, S as SDKOptions, r as VerificationResult } from './types-ACMsV07B.js';
2
2
 
3
3
  /**
4
4
  * AstraSync Universal Verification Gateway - Access Level Definitions
@@ -1,4 +1,4 @@
1
- import { a as AccessLevel, p as TrustLevel, S as SDKOptions, q as VerificationResult } from './types-DedAJbNI.mjs';
1
+ import { a as AccessLevel, q as TrustLevel, S as SDKOptions, r as VerificationResult } from './types-ACMsV07B.mjs';
2
2
 
3
3
  /**
4
4
  * AstraSync Universal Verification Gateway - Access Level Definitions
@@ -1,3 +1,3 @@
1
- import '../types-DedAJbNI.mjs';
2
- export { A as ACPEndpoint, a as ACPPaymentTokenType, b as ACPRequestContext, c as ACPRequestLike, d as ACPSignatureAlgorithm, e as ACPTotal, f as ACPVerifyInput, g as ACPVerifyResult, h as AP2CartMandateClaims, i as AP2ChainResult, j as AP2IntentMandateClaims, k as AP2MandateClaims, l as AP2MandateTriple, m as AP2MandateTripleInput, n as AP2MandateType, o as AP2PaymentDetailsTotal, p as AP2PaymentMandateClaims, q as AP2PaymentMandateForValue, r as AP2VerifyInput, C as CommerceContext, s as CommercePipelineInput, t as CommerceProtocol, u as CommercePurpose, v as CommerceSignatureStack, w as ConstraintEvalResult, x as ConstraintKey, y as ConstraintResult, E as ExtractorRequestLike, I as IdentityBindingResult, z as IdentityClaim, B as IdentityResolver, M as MPPChallengeForValue, D as MPPChallengeSummary, F as MPPCredentialSummary, G as MPPIntent, H as MPPKind, J as MPPReceiptSummary, K as MPPRequestContext, L as MPPRequestLike, N as MPPResponseLike, O as MPPVerifyInput, P as MPPVerifyResult, Q as ParsedRFC9421, R as PaymentMethodAllowlistInput, S as RFC9421SignatureParams, T as RFC9421Tag, U as RFC9421VerifyOptions, V as RFC9421VerifyRequest, W as RFC9421VerifyResult, X as RegistryName, Y as RegistryResolver, Z as ResolveContext, _ as STRIPE_WEBHOOK_INFORMATIONAL_EVENTS, $ as SpendingLimitInput, a0 as StripeWebhookInformationalEvent, a1 as TransactionContext, a2 as TransactionValueContext, a3 as TransportExtractor, a4 as UCPCheckoutContext, a5 as UCPManifestValidationResult, a6 as UCPRequestLike, a7 as UCPTotal, a8 as VIAllowedParty, a9 as VIBudgetLimit, aa as VIClaimsForValue, ab as VIConstraintEvalInput, ac as VIConstraints, ad as VIExecutionMode, ae as VIExtractedClaims, af as VILayer, ag as VILineItem, ah as VIMandateType, ai as VIPaymentAmount, aj as VIRecurrence, ak as VIVerifyInput, al as VIVerifyResult, am as VerifyStripeWebhookOptions, an as VerifyStripeWebhookResult, ao as X402Kind, ap as X402RequestContext, aq as X402RequestForValue, ar as X402RequestLike, as as X402RequirementsSummary, at as X402ResponseLike, au as applyCredentials, av as bindIdentity, aw as claim, ax as clearTransportExtractors, ay as createMastercardRegistry, az as createVisaRegistry, aA as createWebBotAuthRegistry, aB as detectProtocol, aC as evaluatePaymentMethodAllowlist, aD as evaluateSpendingLimit, aE as evaluateVIConstraints, aF as extractA2ACredentials, aG as extractACPContext, aH as extractACPTransactionValue, aI as extractAP2Mandate, aJ as extractAP2Mandates, aK as extractAP2TransactionValue, aL as extractCredentialsFromProtocol, aM as extractHttpCredentials, aN as extractMPPContext, aO as extractMPPFromRequest, aP as extractMPPFromResponse, aQ as extractMPPTransactionValue, aR as extractMcpCredentials, aS as extractUCPContext, aT as extractUCPTransactionValue, aU as extractVIClaims, aV as extractVITransactionValue, aW as extractX402Context, aX as extractX402FromRequest, aY as extractX402FromResponse, aZ as extractX402TransactionValue, a_ as fetchUCPManifest, a$ as getTransportExtractor, b0 as getTransportExtractors, b2 as isStripeWebhookInformational, b3 as mapACPRequestToPurpose, b4 as mapAP2MandateToPurpose, b5 as mapMPPRequestToPurpose, b6 as mapRFC9421TagToPurpose, b7 as mapUCPRequestToPurpose, b8 as mapVIMandateToPurpose, b9 as mapX402RequestToPurpose, ba as parseRFC9421, bb as registerTransportExtractor, bc as runCommercePipeline, bd as runMatchingExtractors, be as setA2AMetadata, bf as setHttpHeaders, bg as setMcpMeta, bh as validateUCPManifest, bi as verifyACPSignature, bj as verifyAP2Chain, bk as verifyMPP, bl as verifyRFC9421, bm as verifyStripeWebhook, bn as verifyVIChain } from '../index-CXcvO9Au.mjs';
1
+ import '../types-ACMsV07B.mjs';
2
+ export { A as ACPEndpoint, a as ACPPaymentTokenType, b as ACPRequestContext, c as ACPRequestLike, d as ACPSignatureAlgorithm, e as ACPTotal, f as ACPVerifyInput, g as ACPVerifyResult, h as AP2CartMandateClaims, i as AP2ChainResult, j as AP2IntentMandateClaims, k as AP2MandateClaims, l as AP2MandateTriple, m as AP2MandateTripleInput, n as AP2MandateType, o as AP2PaymentDetailsTotal, p as AP2PaymentMandateClaims, q as AP2PaymentMandateForValue, r as AP2VerifyInput, C as CommerceContext, s as CommercePipelineInput, t as CommerceProtocol, u as CommercePurpose, v as CommerceSignatureStack, w as ConstraintEvalResult, x as ConstraintKey, y as ConstraintResult, E as ExtractorRequestLike, I as IdentityBindingResult, z as IdentityClaim, B as IdentityResolver, M as MPPChallengeForValue, D as MPPChallengeSummary, F as MPPCredentialSummary, G as MPPIntent, H as MPPKind, J as MPPReceiptSummary, K as MPPRequestContext, L as MPPRequestLike, N as MPPResponseLike, O as MPPVerifyInput, P as MPPVerifyResult, Q as ParsedRFC9421, R as PaymentMethodAllowlistInput, S as RFC9421SignatureParams, T as RFC9421Tag, U as RFC9421VerifyOptions, V as RFC9421VerifyRequest, W as RFC9421VerifyResult, X as RegistryName, Y as RegistryResolver, Z as ResolveContext, _ as STRIPE_WEBHOOK_INFORMATIONAL_EVENTS, $ as SpendingLimitInput, a0 as StripeWebhookInformationalEvent, a1 as TransactionContext, a2 as TransactionValueContext, a3 as TransportExtractor, a4 as UCPCheckoutContext, a5 as UCPManifestValidationResult, a6 as UCPRequestLike, a7 as UCPTotal, a8 as VIAllowedParty, a9 as VIBudgetLimit, aa as VIClaimsForValue, ab as VIConstraintEvalInput, ac as VIConstraints, ad as VIExecutionMode, ae as VIExtractedClaims, af as VILayer, ag as VILineItem, ah as VIMandateType, ai as VIPaymentAmount, aj as VIRecurrence, ak as VIVerifyInput, al as VIVerifyResult, am as VerifyStripeWebhookOptions, an as VerifyStripeWebhookResult, ao as X402Kind, ap as X402RequestContext, aq as X402RequestForValue, ar as X402RequestLike, as as X402RequirementsSummary, at as X402ResponseLike, au as applyCredentials, av as bindIdentity, aw as claim, ax as clearTransportExtractors, ay as createMastercardRegistry, az as createVisaRegistry, aA as createWebBotAuthRegistry, aB as detectProtocol, aC as evaluatePaymentMethodAllowlist, aD as evaluateSpendingLimit, aE as evaluateVIConstraints, aF as extractA2ACredentials, aG as extractACPContext, aH as extractACPTransactionValue, aI as extractAP2Mandate, aJ as extractAP2Mandates, aK as extractAP2TransactionValue, aL as extractCredentialsFromProtocol, aM as extractHttpCredentials, aN as extractMPPContext, aO as extractMPPFromRequest, aP as extractMPPFromResponse, aQ as extractMPPTransactionValue, aR as extractMcpCredentials, aS as extractUCPContext, aT as extractUCPTransactionValue, aU as extractVIClaims, aV as extractVITransactionValue, aW as extractX402Context, aX as extractX402FromRequest, aY as extractX402FromResponse, aZ as extractX402TransactionValue, a_ as fetchUCPManifest, a$ as getTransportExtractor, b0 as getTransportExtractors, b2 as isStripeWebhookInformational, b3 as mapACPRequestToPurpose, b4 as mapAP2MandateToPurpose, b5 as mapMPPRequestToPurpose, b6 as mapRFC9421TagToPurpose, b7 as mapUCPRequestToPurpose, b8 as mapVIMandateToPurpose, b9 as mapX402RequestToPurpose, ba as parseRFC9421, bb as registerTransportExtractor, bc as runCommercePipeline, bd as runMatchingExtractors, be as setA2AMetadata, bf as setHttpHeaders, bg as setMcpMeta, bh as validateUCPManifest, bi as verifyACPSignature, bj as verifyAP2Chain, bk as verifyMPP, bl as verifyRFC9421, bm as verifyStripeWebhook, bn as verifyVIChain } from '../index-Dalih3EB.mjs';
3
3
  import 'jose';
@@ -1,3 +1,3 @@
1
- import '../types-DedAJbNI.js';
2
- export { A as ACPEndpoint, a as ACPPaymentTokenType, b as ACPRequestContext, c as ACPRequestLike, d as ACPSignatureAlgorithm, e as ACPTotal, f as ACPVerifyInput, g as ACPVerifyResult, h as AP2CartMandateClaims, i as AP2ChainResult, j as AP2IntentMandateClaims, k as AP2MandateClaims, l as AP2MandateTriple, m as AP2MandateTripleInput, n as AP2MandateType, o as AP2PaymentDetailsTotal, p as AP2PaymentMandateClaims, q as AP2PaymentMandateForValue, r as AP2VerifyInput, C as CommerceContext, s as CommercePipelineInput, t as CommerceProtocol, u as CommercePurpose, v as CommerceSignatureStack, w as ConstraintEvalResult, x as ConstraintKey, y as ConstraintResult, E as ExtractorRequestLike, I as IdentityBindingResult, z as IdentityClaim, B as IdentityResolver, M as MPPChallengeForValue, D as MPPChallengeSummary, F as MPPCredentialSummary, G as MPPIntent, H as MPPKind, J as MPPReceiptSummary, K as MPPRequestContext, L as MPPRequestLike, N as MPPResponseLike, O as MPPVerifyInput, P as MPPVerifyResult, Q as ParsedRFC9421, R as PaymentMethodAllowlistInput, S as RFC9421SignatureParams, T as RFC9421Tag, U as RFC9421VerifyOptions, V as RFC9421VerifyRequest, W as RFC9421VerifyResult, X as RegistryName, Y as RegistryResolver, Z as ResolveContext, _ as STRIPE_WEBHOOK_INFORMATIONAL_EVENTS, $ as SpendingLimitInput, a0 as StripeWebhookInformationalEvent, a1 as TransactionContext, a2 as TransactionValueContext, a3 as TransportExtractor, a4 as UCPCheckoutContext, a5 as UCPManifestValidationResult, a6 as UCPRequestLike, a7 as UCPTotal, a8 as VIAllowedParty, a9 as VIBudgetLimit, aa as VIClaimsForValue, ab as VIConstraintEvalInput, ac as VIConstraints, ad as VIExecutionMode, ae as VIExtractedClaims, af as VILayer, ag as VILineItem, ah as VIMandateType, ai as VIPaymentAmount, aj as VIRecurrence, ak as VIVerifyInput, al as VIVerifyResult, am as VerifyStripeWebhookOptions, an as VerifyStripeWebhookResult, ao as X402Kind, ap as X402RequestContext, aq as X402RequestForValue, ar as X402RequestLike, as as X402RequirementsSummary, at as X402ResponseLike, au as applyCredentials, av as bindIdentity, aw as claim, ax as clearTransportExtractors, ay as createMastercardRegistry, az as createVisaRegistry, aA as createWebBotAuthRegistry, aB as detectProtocol, aC as evaluatePaymentMethodAllowlist, aD as evaluateSpendingLimit, aE as evaluateVIConstraints, aF as extractA2ACredentials, aG as extractACPContext, aH as extractACPTransactionValue, aI as extractAP2Mandate, aJ as extractAP2Mandates, aK as extractAP2TransactionValue, aL as extractCredentialsFromProtocol, aM as extractHttpCredentials, aN as extractMPPContext, aO as extractMPPFromRequest, aP as extractMPPFromResponse, aQ as extractMPPTransactionValue, aR as extractMcpCredentials, aS as extractUCPContext, aT as extractUCPTransactionValue, aU as extractVIClaims, aV as extractVITransactionValue, aW as extractX402Context, aX as extractX402FromRequest, aY as extractX402FromResponse, aZ as extractX402TransactionValue, a_ as fetchUCPManifest, a$ as getTransportExtractor, b0 as getTransportExtractors, b2 as isStripeWebhookInformational, b3 as mapACPRequestToPurpose, b4 as mapAP2MandateToPurpose, b5 as mapMPPRequestToPurpose, b6 as mapRFC9421TagToPurpose, b7 as mapUCPRequestToPurpose, b8 as mapVIMandateToPurpose, b9 as mapX402RequestToPurpose, ba as parseRFC9421, bb as registerTransportExtractor, bc as runCommercePipeline, bd as runMatchingExtractors, be as setA2AMetadata, bf as setHttpHeaders, bg as setMcpMeta, bh as validateUCPManifest, bi as verifyACPSignature, bj as verifyAP2Chain, bk as verifyMPP, bl as verifyRFC9421, bm as verifyStripeWebhook, bn as verifyVIChain } from '../index-CBQr4FGs.js';
1
+ import '../types-ACMsV07B.js';
2
+ export { A as ACPEndpoint, a as ACPPaymentTokenType, b as ACPRequestContext, c as ACPRequestLike, d as ACPSignatureAlgorithm, e as ACPTotal, f as ACPVerifyInput, g as ACPVerifyResult, h as AP2CartMandateClaims, i as AP2ChainResult, j as AP2IntentMandateClaims, k as AP2MandateClaims, l as AP2MandateTriple, m as AP2MandateTripleInput, n as AP2MandateType, o as AP2PaymentDetailsTotal, p as AP2PaymentMandateClaims, q as AP2PaymentMandateForValue, r as AP2VerifyInput, C as CommerceContext, s as CommercePipelineInput, t as CommerceProtocol, u as CommercePurpose, v as CommerceSignatureStack, w as ConstraintEvalResult, x as ConstraintKey, y as ConstraintResult, E as ExtractorRequestLike, I as IdentityBindingResult, z as IdentityClaim, B as IdentityResolver, M as MPPChallengeForValue, D as MPPChallengeSummary, F as MPPCredentialSummary, G as MPPIntent, H as MPPKind, J as MPPReceiptSummary, K as MPPRequestContext, L as MPPRequestLike, N as MPPResponseLike, O as MPPVerifyInput, P as MPPVerifyResult, Q as ParsedRFC9421, R as PaymentMethodAllowlistInput, S as RFC9421SignatureParams, T as RFC9421Tag, U as RFC9421VerifyOptions, V as RFC9421VerifyRequest, W as RFC9421VerifyResult, X as RegistryName, Y as RegistryResolver, Z as ResolveContext, _ as STRIPE_WEBHOOK_INFORMATIONAL_EVENTS, $ as SpendingLimitInput, a0 as StripeWebhookInformationalEvent, a1 as TransactionContext, a2 as TransactionValueContext, a3 as TransportExtractor, a4 as UCPCheckoutContext, a5 as UCPManifestValidationResult, a6 as UCPRequestLike, a7 as UCPTotal, a8 as VIAllowedParty, a9 as VIBudgetLimit, aa as VIClaimsForValue, ab as VIConstraintEvalInput, ac as VIConstraints, ad as VIExecutionMode, ae as VIExtractedClaims, af as VILayer, ag as VILineItem, ah as VIMandateType, ai as VIPaymentAmount, aj as VIRecurrence, ak as VIVerifyInput, al as VIVerifyResult, am as VerifyStripeWebhookOptions, an as VerifyStripeWebhookResult, ao as X402Kind, ap as X402RequestContext, aq as X402RequestForValue, ar as X402RequestLike, as as X402RequirementsSummary, at as X402ResponseLike, au as applyCredentials, av as bindIdentity, aw as claim, ax as clearTransportExtractors, ay as createMastercardRegistry, az as createVisaRegistry, aA as createWebBotAuthRegistry, aB as detectProtocol, aC as evaluatePaymentMethodAllowlist, aD as evaluateSpendingLimit, aE as evaluateVIConstraints, aF as extractA2ACredentials, aG as extractACPContext, aH as extractACPTransactionValue, aI as extractAP2Mandate, aJ as extractAP2Mandates, aK as extractAP2TransactionValue, aL as extractCredentialsFromProtocol, aM as extractHttpCredentials, aN as extractMPPContext, aO as extractMPPFromRequest, aP as extractMPPFromResponse, aQ as extractMPPTransactionValue, aR as extractMcpCredentials, aS as extractUCPContext, aT as extractUCPTransactionValue, aU as extractVIClaims, aV as extractVITransactionValue, aW as extractX402Context, aX as extractX402FromRequest, aY as extractX402FromResponse, aZ as extractX402TransactionValue, a_ as fetchUCPManifest, a$ as getTransportExtractor, b0 as getTransportExtractors, b2 as isStripeWebhookInformational, b3 as mapACPRequestToPurpose, b4 as mapAP2MandateToPurpose, b5 as mapMPPRequestToPurpose, b6 as mapRFC9421TagToPurpose, b7 as mapUCPRequestToPurpose, b8 as mapVIMandateToPurpose, b9 as mapX402RequestToPurpose, ba as parseRFC9421, bb as registerTransportExtractor, bc as runCommercePipeline, bd as runMatchingExtractors, be as setA2AMetadata, bf as setHttpHeaders, bg as setMcpMeta, bh as validateUCPManifest, bi as verifyACPSignature, bj as verifyAP2Chain, bk as verifyMPP, bl as verifyRFC9421, bm as verifyStripeWebhook, bn as verifyVIChain } from '../index-CMg-vjEK.js';
3
3
  import 'jose';
@@ -560,6 +560,81 @@ interface VerificationRequest {
560
560
  * visibility into transport-vs-intent.
561
561
  */
562
562
  invocationProtocol?: 'rest' | 'mcp' | 'a2a' | 'acp' | 'ap2' | 'mpp' | 'ucp';
563
+ /**
564
+ * 3.9.0 (§33.5 #1) — raw commerce-protocol artifacts forwarded verbatim
565
+ * to verify-access, whose Step 0.5 commerce pipeline runs the full
566
+ * cryptographic verification SERVER-side and persists commerce_context on
567
+ * the session. Adapters forward artifacts, they never verify them locally
568
+ * (bridge-is-transport: verify-access is the sole verification sink, so
569
+ * every decision is recorded once, with events). Shape mirrors the
570
+ * backend's `commerceArtifacts` schema 1:1.
571
+ */
572
+ commerceArtifacts?: CommerceArtifactsPayload;
573
+ }
574
+ /**
575
+ * Raw commerce-protocol artifacts as verify-access accepts them (backend
576
+ * `validation.ts` → `commerceArtifacts`). All optional; send what was
577
+ * detected on the wire.
578
+ */
579
+ interface CommerceArtifactsPayload {
580
+ /** Compact VI SD-JWT. */
581
+ viSdJwt?: string;
582
+ /** AP2 mandate triple as compact SD-JWTs. */
583
+ ap2Mandates?: {
584
+ intent?: string;
585
+ cart?: string;
586
+ payment?: string;
587
+ };
588
+ /** RFC 9421 signed request (Agent Pay / TAP / Web Bot Auth). */
589
+ rfc9421?: {
590
+ headers: Record<string, string | string[]>;
591
+ method: string;
592
+ url: string;
593
+ body?: string;
594
+ tag?: string;
595
+ };
596
+ /** UCP checkout session request. */
597
+ ucpRequest?: {
598
+ method: string;
599
+ url: string;
600
+ body?: unknown;
601
+ };
602
+ /** ACP request (HMAC-signed webhook or checkout body). */
603
+ acpRequest?: {
604
+ method: string;
605
+ url: string;
606
+ headers?: Record<string, string | string[]>;
607
+ body?: unknown;
608
+ rawBody?: string;
609
+ };
610
+ mppRequest?: {
611
+ method: string;
612
+ url: string;
613
+ headers: Record<string, string | string[]>;
614
+ body?: unknown;
615
+ rawBody?: string;
616
+ };
617
+ mppResponse?: {
618
+ status: number;
619
+ headers: Record<string, string | string[]>;
620
+ body?: unknown;
621
+ };
622
+ x402Request?: {
623
+ method?: string;
624
+ url?: string;
625
+ headers?: Record<string, string | string[]>;
626
+ body?: unknown;
627
+ };
628
+ x402Response?: {
629
+ status?: number;
630
+ headers?: Record<string, string | string[]>;
631
+ body?: unknown;
632
+ };
633
+ stripeWebhook?: {
634
+ payload: string;
635
+ signatureHeader: string;
636
+ secret: string;
637
+ };
563
638
  }
564
639
  /**
565
640
  * Route-specific access configuration
@@ -842,4 +917,4 @@ interface CommerceShieldProps {
842
917
  className?: string;
843
918
  }
844
919
 
845
- export type { AccessFailure as A, CommerceShieldProps as C, EnhancedVerificationResult as E, FiatSettlementBinding as F, GatewayConfig as G, NextJsMiddlewareOptions as N, PDLSSInfo as P, RouteAccessConfig as R, SDKOptions as S, TokenGuidance as T, VerificationRequest as V, AccessLevel as a, AgentCredentials as b, AstraSyncCredentials as c, CounterpartyType as d, ExpressMiddlewareOptions as e, GuidanceInfo as f, ProtocolTransport as g, RuntimeChallengeResult as h, SettlementArtifact as i, SettlementArtifactBinding as j, SettlementArtifactBindingBase as k, StablecoinSettlementBinding as l, StepUpApprovalInfo as m, StepUpApprovalStatus as n, StepUpOutcome as o, TrustLevel as p, VerificationResult as q, VerifiedAgent as r, VerifiedDeveloper as s, VerifiedOrganization as t };
920
+ export type { AccessFailure as A, CommerceArtifactsPayload as C, EnhancedVerificationResult as E, FiatSettlementBinding as F, GatewayConfig as G, NextJsMiddlewareOptions as N, PDLSSInfo as P, RouteAccessConfig as R, SDKOptions as S, TokenGuidance as T, VerificationRequest as V, AccessLevel as a, AgentCredentials as b, AstraSyncCredentials as c, CommerceShieldProps as d, CounterpartyType as e, ExpressMiddlewareOptions as f, GuidanceInfo as g, ProtocolTransport as h, RuntimeChallengeResult as i, SettlementArtifact as j, SettlementArtifactBinding as k, SettlementArtifactBindingBase as l, StablecoinSettlementBinding as m, StepUpApprovalInfo as n, StepUpApprovalStatus as o, StepUpOutcome as p, TrustLevel as q, VerificationResult as r, VerifiedAgent as s, VerifiedDeveloper as t, VerifiedOrganization as u };
@@ -560,6 +560,81 @@ interface VerificationRequest {
560
560
  * visibility into transport-vs-intent.
561
561
  */
562
562
  invocationProtocol?: 'rest' | 'mcp' | 'a2a' | 'acp' | 'ap2' | 'mpp' | 'ucp';
563
+ /**
564
+ * 3.9.0 (§33.5 #1) — raw commerce-protocol artifacts forwarded verbatim
565
+ * to verify-access, whose Step 0.5 commerce pipeline runs the full
566
+ * cryptographic verification SERVER-side and persists commerce_context on
567
+ * the session. Adapters forward artifacts, they never verify them locally
568
+ * (bridge-is-transport: verify-access is the sole verification sink, so
569
+ * every decision is recorded once, with events). Shape mirrors the
570
+ * backend's `commerceArtifacts` schema 1:1.
571
+ */
572
+ commerceArtifacts?: CommerceArtifactsPayload;
573
+ }
574
+ /**
575
+ * Raw commerce-protocol artifacts as verify-access accepts them (backend
576
+ * `validation.ts` → `commerceArtifacts`). All optional; send what was
577
+ * detected on the wire.
578
+ */
579
+ interface CommerceArtifactsPayload {
580
+ /** Compact VI SD-JWT. */
581
+ viSdJwt?: string;
582
+ /** AP2 mandate triple as compact SD-JWTs. */
583
+ ap2Mandates?: {
584
+ intent?: string;
585
+ cart?: string;
586
+ payment?: string;
587
+ };
588
+ /** RFC 9421 signed request (Agent Pay / TAP / Web Bot Auth). */
589
+ rfc9421?: {
590
+ headers: Record<string, string | string[]>;
591
+ method: string;
592
+ url: string;
593
+ body?: string;
594
+ tag?: string;
595
+ };
596
+ /** UCP checkout session request. */
597
+ ucpRequest?: {
598
+ method: string;
599
+ url: string;
600
+ body?: unknown;
601
+ };
602
+ /** ACP request (HMAC-signed webhook or checkout body). */
603
+ acpRequest?: {
604
+ method: string;
605
+ url: string;
606
+ headers?: Record<string, string | string[]>;
607
+ body?: unknown;
608
+ rawBody?: string;
609
+ };
610
+ mppRequest?: {
611
+ method: string;
612
+ url: string;
613
+ headers: Record<string, string | string[]>;
614
+ body?: unknown;
615
+ rawBody?: string;
616
+ };
617
+ mppResponse?: {
618
+ status: number;
619
+ headers: Record<string, string | string[]>;
620
+ body?: unknown;
621
+ };
622
+ x402Request?: {
623
+ method?: string;
624
+ url?: string;
625
+ headers?: Record<string, string | string[]>;
626
+ body?: unknown;
627
+ };
628
+ x402Response?: {
629
+ status?: number;
630
+ headers?: Record<string, string | string[]>;
631
+ body?: unknown;
632
+ };
633
+ stripeWebhook?: {
634
+ payload: string;
635
+ signatureHeader: string;
636
+ secret: string;
637
+ };
563
638
  }
564
639
  /**
565
640
  * Route-specific access configuration
@@ -842,4 +917,4 @@ interface CommerceShieldProps {
842
917
  className?: string;
843
918
  }
844
919
 
845
- export type { AccessFailure as A, CommerceShieldProps as C, EnhancedVerificationResult as E, FiatSettlementBinding as F, GatewayConfig as G, NextJsMiddlewareOptions as N, PDLSSInfo as P, RouteAccessConfig as R, SDKOptions as S, TokenGuidance as T, VerificationRequest as V, AccessLevel as a, AgentCredentials as b, AstraSyncCredentials as c, CounterpartyType as d, ExpressMiddlewareOptions as e, GuidanceInfo as f, ProtocolTransport as g, RuntimeChallengeResult as h, SettlementArtifact as i, SettlementArtifactBinding as j, SettlementArtifactBindingBase as k, StablecoinSettlementBinding as l, StepUpApprovalInfo as m, StepUpApprovalStatus as n, StepUpOutcome as o, TrustLevel as p, VerificationResult as q, VerifiedAgent as r, VerifiedDeveloper as s, VerifiedOrganization as t };
920
+ export type { AccessFailure as A, CommerceArtifactsPayload as C, EnhancedVerificationResult as E, FiatSettlementBinding as F, GatewayConfig as G, NextJsMiddlewareOptions as N, PDLSSInfo as P, RouteAccessConfig as R, SDKOptions as S, TokenGuidance as T, VerificationRequest as V, AccessLevel as a, AgentCredentials as b, AstraSyncCredentials as c, CommerceShieldProps as d, CounterpartyType as e, ExpressMiddlewareOptions as f, GuidanceInfo as g, ProtocolTransport as h, RuntimeChallengeResult as i, SettlementArtifact as j, SettlementArtifactBinding as k, SettlementArtifactBindingBase as l, StablecoinSettlementBinding as m, StepUpApprovalInfo as n, StepUpApprovalStatus as o, StepUpOutcome as p, TrustLevel as q, VerificationResult as r, VerifiedAgent as s, VerifiedDeveloper as t, VerifiedOrganization as u };
@@ -1,4 +1,4 @@
1
- import { a as AccessLevel, d as CounterpartyType, T as TokenGuidance } from './types-DedAJbNI.mjs';
1
+ import { a as AccessLevel, e as CounterpartyType, T as TokenGuidance } from './types-ACMsV07B.mjs';
2
2
 
3
3
  /**
4
4
  * AstraSync Gateway - Types for gateway modes, local evaluation, and adapter interface.
@@ -1,4 +1,4 @@
1
- import { a as AccessLevel, d as CounterpartyType, T as TokenGuidance } from './types-DedAJbNI.js';
1
+ import { a as AccessLevel, e as CounterpartyType, T as TokenGuidance } from './types-ACMsV07B.js';
2
2
 
3
3
  /**
4
4
  * AstraSync Gateway - Types for gateway modes, local evaluation, and adapter interface.
@@ -1,4 +1,4 @@
1
- import { C as CommerceShieldProps, q as VerificationResult, b as AgentCredentials, f as GuidanceInfo, p as TrustLevel } from '../types-DedAJbNI.mjs';
1
+ import { d as CommerceShieldProps, r as VerificationResult, b as AgentCredentials, g as GuidanceInfo, q as TrustLevel } from '../types-ACMsV07B.mjs';
2
2
 
3
3
  /**
4
4
  * AstraSync Commerce Shield Component
@@ -1,4 +1,4 @@
1
- import { C as CommerceShieldProps, q as VerificationResult, b as AgentCredentials, f as GuidanceInfo, p as TrustLevel } from '../types-DedAJbNI.js';
1
+ import { d as CommerceShieldProps, r as VerificationResult, b as AgentCredentials, g as GuidanceInfo, q as TrustLevel } from '../types-ACMsV07B.js';
2
2
 
3
3
  /**
4
4
  * AstraSync Commerce Shield Component