@astrasyncai/verification-gateway 5.9.0 → 5.10.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 (71) hide show
  1. package/dist/adapters/express.js +19 -1
  2. package/dist/adapters/express.js.map +1 -1
  3. package/dist/adapters/express.mjs +19 -1
  4. package/dist/adapters/express.mjs.map +1 -1
  5. package/dist/adapters/mcp.js +19 -1
  6. package/dist/adapters/mcp.js.map +1 -1
  7. package/dist/adapters/mcp.mjs +19 -1
  8. package/dist/adapters/mcp.mjs.map +1 -1
  9. package/dist/adapters/nextjs.js +19 -1
  10. package/dist/adapters/nextjs.js.map +1 -1
  11. package/dist/adapters/nextjs.mjs +19 -1
  12. package/dist/adapters/nextjs.mjs.map +1 -1
  13. package/dist/adapters/sdk.js +19 -1
  14. package/dist/adapters/sdk.js.map +1 -1
  15. package/dist/adapters/sdk.mjs +19 -1
  16. package/dist/adapters/sdk.mjs.map +1 -1
  17. package/dist/agent/index.js +1 -1
  18. package/dist/agent/index.js.map +1 -1
  19. package/dist/agent/index.mjs +1 -1
  20. package/dist/agent/index.mjs.map +1 -1
  21. package/dist/bin/astrasync-claude-hook.js +19 -1
  22. package/dist/bin/astrasync-codex-hook.js +19 -1
  23. package/dist/bin/astrasync-guard.js +19 -1
  24. package/dist/bin/astrasync.js +19 -1
  25. package/dist/browser/background.js +19 -1
  26. package/dist/browser/background.js.map +1 -1
  27. package/dist/browser/background.mjs +19 -1
  28. package/dist/browser/background.mjs.map +1 -1
  29. package/dist/cli/index.js +1 -1
  30. package/dist/cli/index.js.map +1 -1
  31. package/dist/cli/index.mjs +1 -1
  32. package/dist/cli/index.mjs.map +1 -1
  33. package/dist/codex/index.js +19 -1
  34. package/dist/codex/index.js.map +1 -1
  35. package/dist/codex/index.mjs +19 -1
  36. package/dist/codex/index.mjs.map +1 -1
  37. package/dist/cursor/extension.js +19 -1
  38. package/dist/cursor/extension.js.map +1 -1
  39. package/dist/cursor/extension.mjs +19 -1
  40. package/dist/cursor/extension.mjs.map +1 -1
  41. package/dist/edge-config.js +1 -1
  42. package/dist/edge-config.js.map +1 -1
  43. package/dist/edge-config.mjs +1 -1
  44. package/dist/edge-config.mjs.map +1 -1
  45. package/dist/edge-core/index.js +20 -2
  46. package/dist/edge-core/index.js.map +1 -1
  47. package/dist/edge-core/index.mjs +20 -2
  48. package/dist/edge-core/index.mjs.map +1 -1
  49. package/dist/gateway/gateway.js +19 -1
  50. package/dist/gateway/gateway.js.map +1 -1
  51. package/dist/gateway/gateway.mjs +19 -1
  52. package/dist/gateway/gateway.mjs.map +1 -1
  53. package/dist/index.d.mts +2 -2
  54. package/dist/index.d.ts +2 -2
  55. package/dist/index.js +19 -1
  56. package/dist/index.js.map +1 -1
  57. package/dist/index.mjs +19 -1
  58. package/dist/index.mjs.map +1 -1
  59. package/dist/registration/index.js +1 -1
  60. package/dist/registration/index.js.map +1 -1
  61. package/dist/registration/index.mjs +1 -1
  62. package/dist/registration/index.mjs.map +1 -1
  63. package/dist/transport/index.js +1 -1
  64. package/dist/transport/index.js.map +1 -1
  65. package/dist/transport/index.mjs +1 -1
  66. package/dist/transport/index.mjs.map +1 -1
  67. package/dist/verify.js +19 -1
  68. package/dist/verify.js.map +1 -1
  69. package/dist/verify.mjs +19 -1
  70. package/dist/verify.mjs.map +1 -1
  71. package/package.json +1 -1
@@ -3750,7 +3750,7 @@ function getTrustLevel(score) {
3750
3750
  }
3751
3751
 
3752
3752
  // src/version.ts
3753
- var SDK_VERSION = "5.9.0";
3753
+ var SDK_VERSION = "5.10.0";
3754
3754
 
3755
3755
  // src/http.ts
3756
3756
  var SDK_USER_AGENT = `astrasync-sdk/${SDK_VERSION}`;
@@ -4069,6 +4069,24 @@ async function callVerifyAccessAPI(config, request) {
4069
4069
  }
4070
4070
  };
4071
4071
  }
4072
+ if (response.status === 400 && data?.error === "INVALID_AGENT_ID") {
4073
+ const message = typeof data?.message === "string" ? data.message : "Agent identifier must be a canonical ASTRA-* id.";
4074
+ return {
4075
+ success: true,
4076
+ attemptId: typeof data?.attemptId === "string" ? data.attemptId : void 0,
4077
+ access: {
4078
+ allowed: false,
4079
+ reason: "invalid_agent_id",
4080
+ failures: [
4081
+ {
4082
+ dimension: "identity.invalid_agent_id",
4083
+ message,
4084
+ guidance: typeof data?.guidance === "string" ? data.guidance : "Present your canonical ASTRA-* id (discover it via GET /api/agents/request-registration/{requestId} after owner approval)."
4085
+ }
4086
+ ]
4087
+ }
4088
+ };
4089
+ }
4072
4090
  if (!response.ok) {
4073
4091
  if (response.status === 401) {
4074
4092
  return {
@@ -3713,7 +3713,7 @@ Policy saved to ${outputPath}`);
3713
3713
  };
3714
3714
 
3715
3715
  // src/version.ts
3716
- var SDK_VERSION = "5.9.0";
3716
+ var SDK_VERSION = "5.10.0";
3717
3717
 
3718
3718
  // src/http.ts
3719
3719
  var SDK_USER_AGENT = `astrasync-sdk/${SDK_VERSION}`;
@@ -4978,6 +4978,24 @@ async function callVerifyAccessAPI(config, request2) {
4978
4978
  }
4979
4979
  };
4980
4980
  }
4981
+ if (response.status === 400 && data?.error === "INVALID_AGENT_ID") {
4982
+ const message = typeof data?.message === "string" ? data.message : "Agent identifier must be a canonical ASTRA-* id.";
4983
+ return {
4984
+ success: true,
4985
+ attemptId: typeof data?.attemptId === "string" ? data.attemptId : void 0,
4986
+ access: {
4987
+ allowed: false,
4988
+ reason: "invalid_agent_id",
4989
+ failures: [
4990
+ {
4991
+ dimension: "identity.invalid_agent_id",
4992
+ message,
4993
+ guidance: typeof data?.guidance === "string" ? data.guidance : "Present your canonical ASTRA-* id (discover it via GET /api/agents/request-registration/{requestId} after owner approval)."
4994
+ }
4995
+ ]
4996
+ }
4997
+ };
4998
+ }
4981
4999
  if (!response.ok) {
4982
5000
  if (response.status === 401) {
4983
5001
  return {
@@ -36,7 +36,7 @@ var SDK_VERSION;
36
36
  var init_version = __esm({
37
37
  "src/version.ts"() {
38
38
  "use strict";
39
- SDK_VERSION = "5.9.0";
39
+ SDK_VERSION = "5.10.0";
40
40
  }
41
41
  });
42
42
 
@@ -5379,6 +5379,24 @@ async function callVerifyAccessAPI(config, request2) {
5379
5379
  }
5380
5380
  };
5381
5381
  }
5382
+ if (response.status === 400 && data?.error === "INVALID_AGENT_ID") {
5383
+ const message = typeof data?.message === "string" ? data.message : "Agent identifier must be a canonical ASTRA-* id.";
5384
+ return {
5385
+ success: true,
5386
+ attemptId: typeof data?.attemptId === "string" ? data.attemptId : void 0,
5387
+ access: {
5388
+ allowed: false,
5389
+ reason: "invalid_agent_id",
5390
+ failures: [
5391
+ {
5392
+ dimension: "identity.invalid_agent_id",
5393
+ message,
5394
+ guidance: typeof data?.guidance === "string" ? data.guidance : "Present your canonical ASTRA-* id (discover it via GET /api/agents/request-registration/{requestId} after owner approval)."
5395
+ }
5396
+ ]
5397
+ }
5398
+ };
5399
+ }
5382
5400
  if (!response.ok) {
5383
5401
  if (response.status === 401) {
5384
5402
  return {
@@ -3988,7 +3988,7 @@ function getTrustLevel(score) {
3988
3988
  }
3989
3989
 
3990
3990
  // src/version.ts
3991
- var SDK_VERSION = "5.9.0";
3991
+ var SDK_VERSION = "5.10.0";
3992
3992
 
3993
3993
  // src/http.ts
3994
3994
  var SDK_USER_AGENT = `astrasync-sdk/${SDK_VERSION}`;
@@ -4307,6 +4307,24 @@ async function callVerifyAccessAPI(config, request) {
4307
4307
  }
4308
4308
  };
4309
4309
  }
4310
+ if (response.status === 400 && data?.error === "INVALID_AGENT_ID") {
4311
+ const message = typeof data?.message === "string" ? data.message : "Agent identifier must be a canonical ASTRA-* id.";
4312
+ return {
4313
+ success: true,
4314
+ attemptId: typeof data?.attemptId === "string" ? data.attemptId : void 0,
4315
+ access: {
4316
+ allowed: false,
4317
+ reason: "invalid_agent_id",
4318
+ failures: [
4319
+ {
4320
+ dimension: "identity.invalid_agent_id",
4321
+ message,
4322
+ guidance: typeof data?.guidance === "string" ? data.guidance : "Present your canonical ASTRA-* id (discover it via GET /api/agents/request-registration/{requestId} after owner approval)."
4323
+ }
4324
+ ]
4325
+ }
4326
+ };
4327
+ }
4310
4328
  if (!response.ok) {
4311
4329
  if (response.status === 401) {
4312
4330
  return {