@vorionsys/contracts 0.1.0 → 0.1.2
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 +44 -0
- package/LICENSE +190 -0
- package/README.md +435 -0
- package/dist/aci/index.d.ts +6 -62
- package/dist/aci/index.d.ts.map +1 -1
- package/dist/aci/index.js +22 -152
- package/dist/aci/index.js.map +1 -1
- package/dist/canonical/agent.d.ts +2 -2
- package/dist/canonical/agent.d.ts.map +1 -1
- package/dist/canonical/agent.js +146 -130
- package/dist/canonical/agent.js.map +1 -1
- package/dist/canonical/governance.d.ts +1 -1
- package/dist/canonical/governance.js +134 -120
- package/dist/canonical/governance.js.map +1 -1
- package/dist/canonical/index.d.ts +1 -0
- package/dist/canonical/index.d.ts.map +1 -1
- package/dist/canonical/index.js +26 -8
- package/dist/canonical/index.js.map +1 -1
- package/dist/canonical/intent.d.ts +8 -15
- package/dist/canonical/intent.d.ts.map +1 -1
- package/dist/canonical/intent.js +91 -82
- package/dist/canonical/intent.js.map +1 -1
- package/dist/canonical/middleware.d.ts +513 -0
- package/dist/canonical/middleware.d.ts.map +1 -0
- package/dist/canonical/middleware.js +218 -0
- package/dist/canonical/middleware.js.map +1 -0
- package/dist/canonical/risk-level.d.ts +1 -1
- package/dist/canonical/risk-level.js +66 -46
- package/dist/canonical/risk-level.js.map +1 -1
- package/dist/canonical/trust-band.d.ts +1 -1
- package/dist/canonical/trust-band.js +39 -28
- package/dist/canonical/trust-band.js.map +1 -1
- package/dist/canonical/trust-score.d.ts +1 -1
- package/dist/canonical/trust-score.js +46 -29
- package/dist/canonical/trust-score.js.map +1 -1
- package/dist/canonical/trust-signal.d.ts +13 -13
- package/dist/canonical/trust-signal.js +91 -78
- package/dist/canonical/trust-signal.js.map +1 -1
- package/dist/canonical/validation.js +148 -102
- package/dist/canonical/validation.js.map +1 -1
- package/dist/{aci → car}/attestation.d.ts +73 -73
- package/dist/{aci → car}/attestation.d.ts.map +1 -1
- package/dist/{aci → car}/attestation.js +69 -59
- package/dist/car/attestation.js.map +1 -0
- package/dist/car/car-string.d.ts +846 -0
- package/dist/car/car-string.d.ts.map +1 -0
- package/dist/car/car-string.js +734 -0
- package/dist/car/car-string.js.map +1 -0
- package/dist/{aci → car}/domains.d.ts +3 -3
- package/dist/{aci → car}/domains.d.ts.map +1 -1
- package/dist/{aci → car}/domains.js +57 -39
- package/dist/car/domains.js.map +1 -0
- package/dist/{aci → car}/effective-permission.d.ts +8 -8
- package/dist/{aci → car}/effective-permission.d.ts.map +1 -1
- package/dist/{aci → car}/effective-permission.js +59 -46
- package/dist/car/effective-permission.js.map +1 -0
- package/dist/{aci → car}/identity.d.ts +235 -129
- package/dist/car/identity.d.ts.map +1 -0
- package/dist/{aci → car}/identity.js +125 -105
- package/dist/car/identity.js.map +1 -0
- package/dist/car/index.d.ts +104 -0
- package/dist/car/index.d.ts.map +1 -0
- package/dist/car/index.js +401 -0
- package/dist/car/index.js.map +1 -0
- package/dist/car/jwt-claims.d.ts +1364 -0
- package/dist/car/jwt-claims.d.ts.map +1 -0
- package/dist/car/jwt-claims.js +388 -0
- package/dist/car/jwt-claims.js.map +1 -0
- package/dist/{aci → car}/levels.d.ts +5 -5
- package/dist/{aci → car}/levels.d.ts.map +1 -1
- package/dist/{aci → car}/levels.js +81 -62
- package/dist/car/levels.js.map +1 -0
- package/dist/{aci → car}/mapping.d.ts +5 -5
- package/dist/{aci → car}/mapping.d.ts.map +1 -1
- package/dist/{aci → car}/mapping.js +96 -76
- package/dist/car/mapping.js.map +1 -0
- package/dist/{aci → car}/skills.d.ts +4 -4
- package/dist/{aci → car}/skills.d.ts.map +1 -1
- package/dist/{aci → car}/skills.js +72 -50
- package/dist/car/skills.js.map +1 -0
- package/dist/{aci → car}/tiers.d.ts +3 -3
- package/dist/{aci → car}/tiers.d.ts.map +1 -1
- package/dist/{aci → car}/tiers.js +140 -113
- package/dist/car/tiers.js.map +1 -0
- package/dist/common/index.d.ts +1 -0
- package/dist/common/index.d.ts.map +1 -1
- package/dist/common/index.js +18 -1
- package/dist/common/index.js.map +1 -1
- package/dist/common/primitives.d.ts +9 -7
- package/dist/common/primitives.d.ts.map +1 -1
- package/dist/common/primitives.js +30 -25
- package/dist/common/primitives.js.map +1 -1
- package/dist/common/types.d.ts +328 -0
- package/dist/common/types.d.ts.map +1 -0
- package/dist/common/types.js +61 -0
- package/dist/common/types.js.map +1 -0
- package/dist/db/agents.d.ts +1914 -0
- package/dist/db/agents.d.ts.map +1 -0
- package/dist/db/agents.js +283 -0
- package/dist/db/agents.js.map +1 -0
- package/dist/db/api-keys.d.ts +506 -0
- package/dist/db/api-keys.d.ts.map +1 -0
- package/dist/db/api-keys.js +101 -0
- package/dist/db/api-keys.js.map +1 -0
- package/dist/db/escalations.d.ts +554 -0
- package/dist/db/escalations.d.ts.map +1 -0
- package/dist/db/escalations.js +100 -0
- package/dist/db/escalations.js.map +1 -0
- package/dist/db/index.d.ts +20 -0
- package/dist/db/index.d.ts.map +1 -0
- package/dist/db/index.js +47 -0
- package/dist/db/index.js.map +1 -0
- package/dist/db/intents.d.ts +535 -0
- package/dist/db/intents.d.ts.map +1 -0
- package/dist/db/intents.js +93 -0
- package/dist/db/intents.js.map +1 -0
- package/dist/db/merkle.d.ts +475 -0
- package/dist/db/merkle.d.ts.map +1 -0
- package/dist/db/merkle.js +103 -0
- package/dist/db/merkle.js.map +1 -0
- package/dist/db/operations.d.ts +256 -0
- package/dist/db/operations.d.ts.map +1 -0
- package/dist/db/operations.js +68 -0
- package/dist/db/operations.js.map +1 -0
- package/dist/db/policy-versions.d.ts +149 -0
- package/dist/db/policy-versions.d.ts.map +1 -0
- package/dist/db/policy-versions.js +44 -0
- package/dist/db/policy-versions.js.map +1 -0
- package/dist/db/proofs.d.ts +412 -0
- package/dist/db/proofs.d.ts.map +1 -0
- package/dist/db/proofs.js +66 -0
- package/dist/db/proofs.js.map +1 -0
- package/dist/db/rbac.d.ts +882 -0
- package/dist/db/rbac.d.ts.map +1 -0
- package/dist/db/rbac.js +189 -0
- package/dist/db/rbac.js.map +1 -0
- package/dist/db/service-accounts.d.ts +783 -0
- package/dist/db/service-accounts.d.ts.map +1 -0
- package/dist/db/service-accounts.js +179 -0
- package/dist/db/service-accounts.js.map +1 -0
- package/dist/db/trust.d.ts +603 -0
- package/dist/db/trust.d.ts.map +1 -0
- package/dist/db/trust.js +111 -0
- package/dist/db/trust.js.map +1 -0
- package/dist/db/webhooks.d.ts +382 -0
- package/dist/db/webhooks.d.ts.map +1 -0
- package/dist/db/webhooks.js +94 -0
- package/dist/db/webhooks.js.map +1 -0
- package/dist/flags.d.ts +214 -0
- package/dist/flags.d.ts.map +1 -0
- package/dist/flags.js +443 -0
- package/dist/flags.js.map +1 -0
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +47 -4
- package/dist/index.js.map +1 -1
- package/dist/v2/canary-probe.js +10 -7
- package/dist/v2/canary-probe.js.map +1 -1
- package/dist/v2/component.js +2 -1
- package/dist/v2/component.js.map +1 -1
- package/dist/v2/decision.js +5 -2
- package/dist/v2/decision.js.map +1 -1
- package/dist/v2/enums.js +28 -25
- package/dist/v2/enums.js.map +1 -1
- package/dist/v2/evidence.js +75 -72
- package/dist/v2/evidence.js.map +1 -1
- package/dist/v2/execution.js +2 -1
- package/dist/v2/execution.js.map +1 -1
- package/dist/v2/index.js +29 -13
- package/dist/v2/index.js.map +1 -1
- package/dist/v2/intent.js +2 -1
- package/dist/v2/intent.js.map +1 -1
- package/dist/v2/policy-bundle.js +5 -2
- package/dist/v2/policy-bundle.js.map +1 -1
- package/dist/v2/pre-action-gate.js +10 -7
- package/dist/v2/pre-action-gate.js.map +1 -1
- package/dist/v2/proof-event.d.ts +3 -1
- package/dist/v2/proof-event.d.ts.map +1 -1
- package/dist/v2/proof-event.js +2 -1
- package/dist/v2/proof-event.js.map +1 -1
- package/dist/v2/retention.js +104 -101
- package/dist/v2/retention.js.map +1 -1
- package/dist/v2/trust-delta.js +5 -2
- package/dist/v2/trust-delta.js.map +1 -1
- package/dist/v2/trust-profile.js +12 -9
- package/dist/v2/trust-profile.js.map +1 -1
- package/dist/validators/decision.d.ts +2 -2
- package/dist/validators/decision.js +49 -46
- package/dist/validators/decision.js.map +1 -1
- package/dist/validators/enums.js +14 -11
- package/dist/validators/enums.js.map +1 -1
- package/dist/validators/index.js +30 -9
- package/dist/validators/index.js.map +1 -1
- package/dist/validators/intent.js +40 -37
- package/dist/validators/intent.js.map +1 -1
- package/dist/validators/proof-event.d.ts +3 -0
- package/dist/validators/proof-event.d.ts.map +1 -1
- package/dist/validators/proof-event.js +103 -99
- package/dist/validators/proof-event.js.map +1 -1
- package/dist/validators/trust-profile.js +40 -37
- package/dist/validators/trust-profile.js.map +1 -1
- package/package.json +81 -15
- package/dist/aci/aci-string.d.ts +0 -539
- package/dist/aci/aci-string.d.ts.map +0 -1
- package/dist/aci/aci-string.js +0 -563
- package/dist/aci/aci-string.js.map +0 -1
- package/dist/aci/attestation.js.map +0 -1
- package/dist/aci/domains.js.map +0 -1
- package/dist/aci/effective-permission.js.map +0 -1
- package/dist/aci/identity.d.ts.map +0 -1
- package/dist/aci/identity.js.map +0 -1
- package/dist/aci/jwt-claims.d.ts +0 -756
- package/dist/aci/jwt-claims.d.ts.map +0 -1
- package/dist/aci/jwt-claims.js +0 -335
- package/dist/aci/jwt-claims.js.map +0 -1
- package/dist/aci/levels.js.map +0 -1
- package/dist/aci/mapping.js.map +0 -1
- package/dist/aci/skills.js.map +0 -1
- package/dist/aci/tiers.js.map +0 -1
|
@@ -0,0 +1,846 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @fileoverview CAR String Parser and Generator
|
|
3
|
+
*
|
|
4
|
+
* Provides parsing, generation, and validation for Categorical Agent
|
|
5
|
+
* Registry (CAR) strings. CAR strings follow the format:
|
|
6
|
+
*
|
|
7
|
+
* `{registry}.{organization}.{agentClass}:{domains}-L{level}@{version}[#extensions]`
|
|
8
|
+
*
|
|
9
|
+
* Example: `a3i.acme-corp.invoice-bot:ABF-L3@1.0.0`
|
|
10
|
+
*
|
|
11
|
+
* **CRITICAL DESIGN PRINCIPLE:**
|
|
12
|
+
* The CAR is an IMMUTABLE identifier (like a certificate or passport number).
|
|
13
|
+
* Trust is NOT encoded in the CAR - it is computed at RUNTIME based on:
|
|
14
|
+
* - Attestations (stored separately)
|
|
15
|
+
* - Behavioral signals
|
|
16
|
+
* - Deployment context policies
|
|
17
|
+
*
|
|
18
|
+
* The optional extensions (section 5+) are mutable and can be defined by
|
|
19
|
+
* industry or community standards.
|
|
20
|
+
*
|
|
21
|
+
* @module @vorionsys/contracts/car/car-string
|
|
22
|
+
*/
|
|
23
|
+
import { z } from 'zod';
|
|
24
|
+
import { type DomainCode } from './domains.js';
|
|
25
|
+
import { CapabilityLevel } from './levels.js';
|
|
26
|
+
/**
|
|
27
|
+
* Regular expression for parsing CAR strings.
|
|
28
|
+
*
|
|
29
|
+
* Format: `{registry}.{organization}.{agentClass}:{domains}-L{level}@{version}[#extensions]`
|
|
30
|
+
*
|
|
31
|
+
* Groups:
|
|
32
|
+
* 1. registry - Certifying registry (e.g., 'a3i')
|
|
33
|
+
* 2. organization - Operating organization (e.g., 'acme-corp')
|
|
34
|
+
* 3. agentClass - Agent classification (e.g., 'invoice-bot')
|
|
35
|
+
* 4. domains - Capability domain codes (e.g., 'ABF')
|
|
36
|
+
* 5. level - Autonomy level (0-5)
|
|
37
|
+
* 6. version - Semantic version (e.g., '1.0.0')
|
|
38
|
+
* 7. extensions - Optional comma-separated extensions (e.g., 'gov,audit')
|
|
39
|
+
*
|
|
40
|
+
* NOTE: Trust tier is NOT part of the CAR. Trust is computed at runtime
|
|
41
|
+
* from attestations, behavioral signals, and deployment context.
|
|
42
|
+
*/
|
|
43
|
+
export declare const CAR_REGEX: RegExp;
|
|
44
|
+
/**
|
|
45
|
+
* Looser regex for partial CAR validation.
|
|
46
|
+
*/
|
|
47
|
+
export declare const CAR_PARTIAL_REGEX: RegExp;
|
|
48
|
+
/**
|
|
49
|
+
* Legacy regex for parsing old-format CAR strings that include trust tier.
|
|
50
|
+
* Used for migration/compatibility only.
|
|
51
|
+
* @deprecated Use CAR_REGEX instead - trust tier should not be in the identifier
|
|
52
|
+
*/
|
|
53
|
+
export declare const CAR_LEGACY_REGEX: RegExp;
|
|
54
|
+
/** @deprecated Use CAR_REGEX instead */
|
|
55
|
+
export declare const ACI_REGEX: RegExp;
|
|
56
|
+
/** @deprecated Use CAR_PARTIAL_REGEX instead */
|
|
57
|
+
export declare const ACI_PARTIAL_REGEX: RegExp;
|
|
58
|
+
/** @deprecated Use CAR_LEGACY_REGEX instead */
|
|
59
|
+
export declare const ACI_LEGACY_REGEX: RegExp;
|
|
60
|
+
/**
|
|
61
|
+
* Parsed components of a CAR string.
|
|
62
|
+
*
|
|
63
|
+
* NOTE: Trust tier is NOT included because the CAR is an immutable identifier.
|
|
64
|
+
* Trust is computed at runtime from:
|
|
65
|
+
* - Attestations (external certifications)
|
|
66
|
+
* - Behavioral signals (runtime observations)
|
|
67
|
+
* - Deployment context policies
|
|
68
|
+
*/
|
|
69
|
+
export interface ParsedCAR {
|
|
70
|
+
/** Full CAR string */
|
|
71
|
+
readonly car: string;
|
|
72
|
+
/** Certifying registry (e.g., 'a3i') */
|
|
73
|
+
readonly registry: string;
|
|
74
|
+
/** Operating organization */
|
|
75
|
+
readonly organization: string;
|
|
76
|
+
/** Agent classification */
|
|
77
|
+
readonly agentClass: string;
|
|
78
|
+
/** Capability domain codes */
|
|
79
|
+
readonly domains: readonly DomainCode[];
|
|
80
|
+
/** Domain bitmask for efficient queries */
|
|
81
|
+
readonly domainsBitmask: number;
|
|
82
|
+
/** Autonomy/capability level */
|
|
83
|
+
readonly level: CapabilityLevel;
|
|
84
|
+
/** Semantic version string */
|
|
85
|
+
readonly version: string;
|
|
86
|
+
/** Optional extensions (mutable, industry/community defined) */
|
|
87
|
+
readonly extensions: readonly string[];
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* @deprecated Use ParsedCAR instead
|
|
91
|
+
*/
|
|
92
|
+
export interface ParsedACI extends ParsedCAR {
|
|
93
|
+
/** @deprecated Use car instead */
|
|
94
|
+
readonly aci: string;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Unique identity portion of the CAR (immutable core).
|
|
98
|
+
* Format: {registry}.{organization}.{agentClass}
|
|
99
|
+
*/
|
|
100
|
+
export type CARIdentity = `${string}.${string}.${string}`;
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use CARIdentity instead
|
|
103
|
+
*/
|
|
104
|
+
export type ACIIdentity = CARIdentity;
|
|
105
|
+
/**
|
|
106
|
+
* Extracts the identity portion from a parsed CAR.
|
|
107
|
+
*/
|
|
108
|
+
export declare function getCARIdentity(parsed: ParsedCAR): CARIdentity;
|
|
109
|
+
/**
|
|
110
|
+
* @deprecated Use getCARIdentity instead
|
|
111
|
+
*/
|
|
112
|
+
export declare function getACIIdentity(parsed: ParsedCAR): CARIdentity;
|
|
113
|
+
/**
|
|
114
|
+
* Zod schema for ParsedCAR validation.
|
|
115
|
+
*/
|
|
116
|
+
export declare const parsedCARSchema: z.ZodObject<{
|
|
117
|
+
car: z.ZodString;
|
|
118
|
+
registry: z.ZodString;
|
|
119
|
+
organization: z.ZodString;
|
|
120
|
+
agentClass: z.ZodString;
|
|
121
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
122
|
+
domainsBitmask: z.ZodNumber;
|
|
123
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
124
|
+
version: z.ZodString;
|
|
125
|
+
extensions: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
126
|
+
}, "strip", z.ZodTypeAny, {
|
|
127
|
+
version: string;
|
|
128
|
+
level: CapabilityLevel;
|
|
129
|
+
registry: string;
|
|
130
|
+
organization: string;
|
|
131
|
+
agentClass: string;
|
|
132
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
133
|
+
domainsBitmask: number;
|
|
134
|
+
car: string;
|
|
135
|
+
extensions: string[];
|
|
136
|
+
}, {
|
|
137
|
+
version: string;
|
|
138
|
+
level: CapabilityLevel;
|
|
139
|
+
registry: string;
|
|
140
|
+
organization: string;
|
|
141
|
+
agentClass: string;
|
|
142
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
143
|
+
domainsBitmask: number;
|
|
144
|
+
car: string;
|
|
145
|
+
extensions?: string[] | undefined;
|
|
146
|
+
}>;
|
|
147
|
+
/** @deprecated Use parsedCARSchema instead */
|
|
148
|
+
export declare const parsedACISchema: z.ZodObject<{
|
|
149
|
+
car: z.ZodString;
|
|
150
|
+
registry: z.ZodString;
|
|
151
|
+
organization: z.ZodString;
|
|
152
|
+
agentClass: z.ZodString;
|
|
153
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
154
|
+
domainsBitmask: z.ZodNumber;
|
|
155
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
156
|
+
version: z.ZodString;
|
|
157
|
+
extensions: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
158
|
+
}, "strip", z.ZodTypeAny, {
|
|
159
|
+
version: string;
|
|
160
|
+
level: CapabilityLevel;
|
|
161
|
+
registry: string;
|
|
162
|
+
organization: string;
|
|
163
|
+
agentClass: string;
|
|
164
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
165
|
+
domainsBitmask: number;
|
|
166
|
+
car: string;
|
|
167
|
+
extensions: string[];
|
|
168
|
+
}, {
|
|
169
|
+
version: string;
|
|
170
|
+
level: CapabilityLevel;
|
|
171
|
+
registry: string;
|
|
172
|
+
organization: string;
|
|
173
|
+
agentClass: string;
|
|
174
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
175
|
+
domainsBitmask: number;
|
|
176
|
+
car: string;
|
|
177
|
+
extensions?: string[] | undefined;
|
|
178
|
+
}>;
|
|
179
|
+
/**
|
|
180
|
+
* Error thrown when CAR parsing fails.
|
|
181
|
+
*/
|
|
182
|
+
export declare class CARParseError extends Error {
|
|
183
|
+
/** The invalid CAR string that caused the error */
|
|
184
|
+
readonly car: string;
|
|
185
|
+
/** Error code for programmatic handling */
|
|
186
|
+
readonly code: CARParseErrorCode;
|
|
187
|
+
constructor(message: string, car: string, code?: CARParseErrorCode);
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* @deprecated Use CARParseError instead
|
|
191
|
+
*/
|
|
192
|
+
export declare class ACIParseError extends CARParseError {
|
|
193
|
+
/** @deprecated Use car instead */
|
|
194
|
+
readonly aci: string;
|
|
195
|
+
constructor(message: string, aci: string, code?: CARParseErrorCode);
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* Error codes for CAR parse errors.
|
|
199
|
+
*/
|
|
200
|
+
export type CARParseErrorCode = 'INVALID_FORMAT' | 'INVALID_REGISTRY' | 'INVALID_ORGANIZATION' | 'INVALID_AGENT_CLASS' | 'INVALID_DOMAINS' | 'NO_DOMAINS' | 'INVALID_LEVEL' | 'INVALID_VERSION' | 'INVALID_EXTENSIONS' | 'LEGACY_FORMAT';
|
|
201
|
+
/** @deprecated Use CARParseErrorCode instead */
|
|
202
|
+
export type ACIParseErrorCode = CARParseErrorCode;
|
|
203
|
+
/**
|
|
204
|
+
* Parses a CAR string into its components.
|
|
205
|
+
*
|
|
206
|
+
* @param car - The CAR string to parse
|
|
207
|
+
* @returns Parsed CAR components
|
|
208
|
+
* @throws CARParseError if the CAR string is invalid
|
|
209
|
+
*
|
|
210
|
+
* @example
|
|
211
|
+
* ```typescript
|
|
212
|
+
* const parsed = parseCAR('a3i.acme-corp.invoice-bot:ABF-L3@1.0.0');
|
|
213
|
+
* // {
|
|
214
|
+
* // car: 'a3i.acme-corp.invoice-bot:ABF-L3@1.0.0',
|
|
215
|
+
* // registry: 'a3i',
|
|
216
|
+
* // organization: 'acme-corp',
|
|
217
|
+
* // agentClass: 'invoice-bot',
|
|
218
|
+
* // domains: ['A', 'B', 'F'],
|
|
219
|
+
* // domainsBitmask: 0x023,
|
|
220
|
+
* // level: CapabilityLevel.L3_EXECUTE,
|
|
221
|
+
* // version: '1.0.0',
|
|
222
|
+
* // extensions: []
|
|
223
|
+
* // }
|
|
224
|
+
* ```
|
|
225
|
+
*/
|
|
226
|
+
export declare function parseCAR(car: string): ParsedCAR;
|
|
227
|
+
/**
|
|
228
|
+
* @deprecated Use parseCAR instead
|
|
229
|
+
*/
|
|
230
|
+
export declare function parseACI(aci: string): ParsedCAR & {
|
|
231
|
+
aci: string;
|
|
232
|
+
};
|
|
233
|
+
/**
|
|
234
|
+
* Parses a legacy CAR string that includes trust tier.
|
|
235
|
+
* Returns the parsed CAR (without tier) plus the extracted tier value.
|
|
236
|
+
*
|
|
237
|
+
* @deprecated Use parseCAR() - trust should not be in the identifier
|
|
238
|
+
* @param car - Legacy CAR string with embedded tier
|
|
239
|
+
* @returns Parsed CAR plus extracted tier
|
|
240
|
+
*/
|
|
241
|
+
export declare function parseLegacyCAR(car: string): {
|
|
242
|
+
parsed: ParsedCAR;
|
|
243
|
+
legacyTier: number;
|
|
244
|
+
};
|
|
245
|
+
/**
|
|
246
|
+
* @deprecated Use parseLegacyCAR instead
|
|
247
|
+
*/
|
|
248
|
+
export declare function parseLegacyACI(aci: string): {
|
|
249
|
+
parsed: ParsedCAR & {
|
|
250
|
+
aci: string;
|
|
251
|
+
};
|
|
252
|
+
legacyTier: number;
|
|
253
|
+
};
|
|
254
|
+
/**
|
|
255
|
+
* Safely parses a CAR string, returning null on failure.
|
|
256
|
+
*
|
|
257
|
+
* @param car - The CAR string to parse
|
|
258
|
+
* @returns Parsed CAR or null if invalid
|
|
259
|
+
*/
|
|
260
|
+
export declare function tryParseCAR(car: string): ParsedCAR | null;
|
|
261
|
+
/**
|
|
262
|
+
* @deprecated Use tryParseCAR instead
|
|
263
|
+
*/
|
|
264
|
+
export declare function tryParseACI(aci: string): (ParsedCAR & {
|
|
265
|
+
aci: string;
|
|
266
|
+
}) | null;
|
|
267
|
+
/**
|
|
268
|
+
* Safely parses a CAR string, returning a result object.
|
|
269
|
+
*
|
|
270
|
+
* @param car - The CAR string to parse
|
|
271
|
+
* @returns Result object with success flag and parsed CAR or error
|
|
272
|
+
*/
|
|
273
|
+
export declare function safeParseCAR(car: string): {
|
|
274
|
+
success: true;
|
|
275
|
+
data: ParsedCAR;
|
|
276
|
+
} | {
|
|
277
|
+
success: false;
|
|
278
|
+
error: CARParseError;
|
|
279
|
+
};
|
|
280
|
+
/**
|
|
281
|
+
* @deprecated Use safeParseCAR instead
|
|
282
|
+
*/
|
|
283
|
+
export declare function safeParseACI(aci: string): {
|
|
284
|
+
success: true;
|
|
285
|
+
data: ParsedCAR & {
|
|
286
|
+
aci: string;
|
|
287
|
+
};
|
|
288
|
+
} | {
|
|
289
|
+
success: false;
|
|
290
|
+
error: CARParseError;
|
|
291
|
+
};
|
|
292
|
+
/**
|
|
293
|
+
* Options for generating a CAR string.
|
|
294
|
+
*
|
|
295
|
+
* NOTE: Trust tier is NOT included because CAR is an immutable identifier.
|
|
296
|
+
* Trust is computed at runtime from attestations and behavioral signals.
|
|
297
|
+
*/
|
|
298
|
+
export interface GenerateCAROptions {
|
|
299
|
+
/** Certifying registry (e.g., 'a3i') */
|
|
300
|
+
registry: string;
|
|
301
|
+
/** Operating organization */
|
|
302
|
+
organization: string;
|
|
303
|
+
/** Agent classification */
|
|
304
|
+
agentClass: string;
|
|
305
|
+
/** Capability domains */
|
|
306
|
+
domains: readonly DomainCode[];
|
|
307
|
+
/** Autonomy level */
|
|
308
|
+
level: CapabilityLevel;
|
|
309
|
+
/** Semantic version */
|
|
310
|
+
version: string;
|
|
311
|
+
/** Optional extensions (mutable, industry/community defined) */
|
|
312
|
+
extensions?: readonly string[];
|
|
313
|
+
}
|
|
314
|
+
/** @deprecated Use GenerateCAROptions instead */
|
|
315
|
+
export type GenerateACIOptions = GenerateCAROptions;
|
|
316
|
+
/**
|
|
317
|
+
* Generates a CAR string from components.
|
|
318
|
+
*
|
|
319
|
+
* @param options - CAR components
|
|
320
|
+
* @returns Generated CAR string
|
|
321
|
+
*
|
|
322
|
+
* @example
|
|
323
|
+
* ```typescript
|
|
324
|
+
* const car = generateCAR({
|
|
325
|
+
* registry: 'a3i',
|
|
326
|
+
* organization: 'acme-corp',
|
|
327
|
+
* agentClass: 'invoice-bot',
|
|
328
|
+
* domains: ['A', 'B', 'F'],
|
|
329
|
+
* level: CapabilityLevel.L3_EXECUTE,
|
|
330
|
+
* version: '1.0.0',
|
|
331
|
+
* });
|
|
332
|
+
* // 'a3i.acme-corp.invoice-bot:ABF-L3@1.0.0'
|
|
333
|
+
*
|
|
334
|
+
* // With extensions:
|
|
335
|
+
* const carWithExt = generateCAR({
|
|
336
|
+
* registry: 'a3i',
|
|
337
|
+
* organization: 'acme-corp',
|
|
338
|
+
* agentClass: 'invoice-bot',
|
|
339
|
+
* domains: ['A', 'B', 'F'],
|
|
340
|
+
* level: CapabilityLevel.L3_EXECUTE,
|
|
341
|
+
* version: '1.0.0',
|
|
342
|
+
* extensions: ['gov', 'audit'],
|
|
343
|
+
* });
|
|
344
|
+
* // 'a3i.acme-corp.invoice-bot:ABF-L3@1.0.0#gov,audit'
|
|
345
|
+
* ```
|
|
346
|
+
*/
|
|
347
|
+
export declare function generateCAR(options: GenerateCAROptions): string;
|
|
348
|
+
/**
|
|
349
|
+
* @deprecated Use generateCAR instead
|
|
350
|
+
*/
|
|
351
|
+
export declare function generateACI(options: GenerateCAROptions): string;
|
|
352
|
+
/**
|
|
353
|
+
* Generates a CAR string from individual parameters.
|
|
354
|
+
*
|
|
355
|
+
* @param registry - Certifying registry
|
|
356
|
+
* @param organization - Operating organization
|
|
357
|
+
* @param agentClass - Agent classification
|
|
358
|
+
* @param domains - Capability domains
|
|
359
|
+
* @param level - Autonomy level
|
|
360
|
+
* @param version - Semantic version
|
|
361
|
+
* @param extensions - Optional extensions
|
|
362
|
+
* @returns Generated CAR string
|
|
363
|
+
*/
|
|
364
|
+
export declare function generateCARString(registry: string, organization: string, agentClass: string, domains: readonly DomainCode[], level: CapabilityLevel, version: string, extensions?: readonly string[]): string;
|
|
365
|
+
/**
|
|
366
|
+
* @deprecated Use generateCARString instead
|
|
367
|
+
*/
|
|
368
|
+
export declare function generateACIString(registry: string, organization: string, agentClass: string, domains: readonly DomainCode[], level: CapabilityLevel, version: string, extensions?: readonly string[]): string;
|
|
369
|
+
/**
|
|
370
|
+
* Validation error for CAR strings.
|
|
371
|
+
*/
|
|
372
|
+
export interface CARValidationError {
|
|
373
|
+
/** Error code */
|
|
374
|
+
code: string;
|
|
375
|
+
/** Human-readable message */
|
|
376
|
+
message: string;
|
|
377
|
+
/** Path to the error (if applicable) */
|
|
378
|
+
path?: string;
|
|
379
|
+
}
|
|
380
|
+
/** @deprecated Use CARValidationError instead */
|
|
381
|
+
export type ACIValidationError = CARValidationError;
|
|
382
|
+
/**
|
|
383
|
+
* Validation warning for CAR strings.
|
|
384
|
+
*/
|
|
385
|
+
export interface CARValidationWarning {
|
|
386
|
+
/** Warning code */
|
|
387
|
+
code: string;
|
|
388
|
+
/** Human-readable message */
|
|
389
|
+
message: string;
|
|
390
|
+
/** Path to the warning (if applicable) */
|
|
391
|
+
path?: string;
|
|
392
|
+
}
|
|
393
|
+
/** @deprecated Use CARValidationWarning instead */
|
|
394
|
+
export type ACIValidationWarning = CARValidationWarning;
|
|
395
|
+
/**
|
|
396
|
+
* Result of CAR validation.
|
|
397
|
+
*/
|
|
398
|
+
export interface CARValidationResult {
|
|
399
|
+
/** Whether the CAR is valid */
|
|
400
|
+
valid: boolean;
|
|
401
|
+
/** Validation errors */
|
|
402
|
+
errors: CARValidationError[];
|
|
403
|
+
/** Validation warnings */
|
|
404
|
+
warnings: CARValidationWarning[];
|
|
405
|
+
/** Parsed CAR if valid */
|
|
406
|
+
parsed?: ParsedCAR;
|
|
407
|
+
}
|
|
408
|
+
/** @deprecated Use CARValidationResult instead */
|
|
409
|
+
export type ACIValidationResult = CARValidationResult;
|
|
410
|
+
/**
|
|
411
|
+
* Validates a CAR string.
|
|
412
|
+
*
|
|
413
|
+
* @param car - The CAR string to validate
|
|
414
|
+
* @returns Validation result
|
|
415
|
+
*
|
|
416
|
+
* @example
|
|
417
|
+
* ```typescript
|
|
418
|
+
* const result = validateCAR('a3i.acme-corp.bot:A-L5@1.0.0');
|
|
419
|
+
* // {
|
|
420
|
+
* // valid: true,
|
|
421
|
+
* // errors: [],
|
|
422
|
+
* // warnings: [],
|
|
423
|
+
* // parsed: { ... }
|
|
424
|
+
* // }
|
|
425
|
+
* ```
|
|
426
|
+
*/
|
|
427
|
+
export declare function validateCAR(car: string): CARValidationResult;
|
|
428
|
+
/**
|
|
429
|
+
* @deprecated Use validateCAR instead
|
|
430
|
+
*/
|
|
431
|
+
export declare function validateACI(aci: string): CARValidationResult;
|
|
432
|
+
/**
|
|
433
|
+
* Checks if a string is a valid CAR format.
|
|
434
|
+
*
|
|
435
|
+
* @param car - String to check
|
|
436
|
+
* @returns True if the string is a valid CAR
|
|
437
|
+
*/
|
|
438
|
+
export declare function isValidCAR(car: string): boolean;
|
|
439
|
+
/**
|
|
440
|
+
* @deprecated Use isValidCAR instead
|
|
441
|
+
*/
|
|
442
|
+
export declare function isValidACI(aci: string): boolean;
|
|
443
|
+
/**
|
|
444
|
+
* Type guard to check if a value is a valid CAR string.
|
|
445
|
+
*
|
|
446
|
+
* @param value - Value to check
|
|
447
|
+
* @returns True if value is a valid CAR string
|
|
448
|
+
*/
|
|
449
|
+
export declare function isCARString(value: unknown): value is string;
|
|
450
|
+
/**
|
|
451
|
+
* @deprecated Use isCARString instead
|
|
452
|
+
*/
|
|
453
|
+
export declare function isACIString(value: unknown): value is string;
|
|
454
|
+
/**
|
|
455
|
+
* Updates specific fields in a CAR and returns a new CAR string.
|
|
456
|
+
*
|
|
457
|
+
* @param car - Original CAR string
|
|
458
|
+
* @param updates - Fields to update
|
|
459
|
+
* @returns New CAR string with updates applied
|
|
460
|
+
*/
|
|
461
|
+
export declare function updateCAR(car: string, updates: Partial<Omit<GenerateCAROptions, 'registry' | 'organization' | 'agentClass'>>): string;
|
|
462
|
+
/**
|
|
463
|
+
* @deprecated Use updateCAR instead
|
|
464
|
+
*/
|
|
465
|
+
export declare function updateACI(aci: string, updates: Partial<Omit<GenerateCAROptions, 'registry' | 'organization' | 'agentClass'>>): string;
|
|
466
|
+
/**
|
|
467
|
+
* Adds extensions to a CAR string.
|
|
468
|
+
*
|
|
469
|
+
* @param car - Original CAR string
|
|
470
|
+
* @param newExtensions - Extensions to add
|
|
471
|
+
* @returns New CAR string with extensions added
|
|
472
|
+
*/
|
|
473
|
+
export declare function addCARExtensions(car: string, newExtensions: readonly string[]): string;
|
|
474
|
+
/**
|
|
475
|
+
* @deprecated Use addCARExtensions instead
|
|
476
|
+
*/
|
|
477
|
+
export declare function addACIExtensions(aci: string, newExtensions: readonly string[]): string;
|
|
478
|
+
/**
|
|
479
|
+
* Removes extensions from a CAR string.
|
|
480
|
+
*
|
|
481
|
+
* @param car - Original CAR string
|
|
482
|
+
* @param extensionsToRemove - Extensions to remove
|
|
483
|
+
* @returns New CAR string with extensions removed
|
|
484
|
+
*/
|
|
485
|
+
export declare function removeCARExtensions(car: string, extensionsToRemove: readonly string[]): string;
|
|
486
|
+
/**
|
|
487
|
+
* @deprecated Use removeCARExtensions instead
|
|
488
|
+
*/
|
|
489
|
+
export declare function removeACIExtensions(aci: string, extensionsToRemove: readonly string[]): string;
|
|
490
|
+
/**
|
|
491
|
+
* Increments the version in a CAR string.
|
|
492
|
+
*
|
|
493
|
+
* @param car - Original CAR string
|
|
494
|
+
* @param type - Version component to increment ('major' | 'minor' | 'patch')
|
|
495
|
+
* @returns New CAR string with incremented version
|
|
496
|
+
*/
|
|
497
|
+
export declare function incrementCARVersion(car: string, type?: 'major' | 'minor' | 'patch'): string;
|
|
498
|
+
/**
|
|
499
|
+
* @deprecated Use incrementCARVersion instead
|
|
500
|
+
*/
|
|
501
|
+
export declare function incrementACIVersion(aci: string, type?: 'major' | 'minor' | 'patch'): string;
|
|
502
|
+
/**
|
|
503
|
+
* Zod schema for CAR string validation.
|
|
504
|
+
*/
|
|
505
|
+
export declare const carStringSchema: z.ZodEffects<z.ZodString, string, string>;
|
|
506
|
+
/** @deprecated Use carStringSchema instead */
|
|
507
|
+
export declare const aciStringSchema: z.ZodEffects<z.ZodString, string, string>;
|
|
508
|
+
/**
|
|
509
|
+
* Zod schema for CAR string with parsing transform.
|
|
510
|
+
*/
|
|
511
|
+
export declare const carSchema: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, ParsedCAR, string>;
|
|
512
|
+
/** @deprecated Use carSchema instead */
|
|
513
|
+
export declare const aciSchema: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, ParsedCAR & {
|
|
514
|
+
aci: string;
|
|
515
|
+
}, string>;
|
|
516
|
+
/**
|
|
517
|
+
* Zod schema for GenerateCAROptions.
|
|
518
|
+
*/
|
|
519
|
+
export declare const generateCAROptionsSchema: z.ZodObject<{
|
|
520
|
+
registry: z.ZodString;
|
|
521
|
+
organization: z.ZodString;
|
|
522
|
+
agentClass: z.ZodString;
|
|
523
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
524
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
525
|
+
version: z.ZodString;
|
|
526
|
+
extensions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
527
|
+
}, "strip", z.ZodTypeAny, {
|
|
528
|
+
version: string;
|
|
529
|
+
level: CapabilityLevel;
|
|
530
|
+
registry: string;
|
|
531
|
+
organization: string;
|
|
532
|
+
agentClass: string;
|
|
533
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
534
|
+
extensions?: string[] | undefined;
|
|
535
|
+
}, {
|
|
536
|
+
version: string;
|
|
537
|
+
level: CapabilityLevel;
|
|
538
|
+
registry: string;
|
|
539
|
+
organization: string;
|
|
540
|
+
agentClass: string;
|
|
541
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
542
|
+
extensions?: string[] | undefined;
|
|
543
|
+
}>;
|
|
544
|
+
/** @deprecated Use generateCAROptionsSchema instead */
|
|
545
|
+
export declare const generateACIOptionsSchema: z.ZodObject<{
|
|
546
|
+
registry: z.ZodString;
|
|
547
|
+
organization: z.ZodString;
|
|
548
|
+
agentClass: z.ZodString;
|
|
549
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
550
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
551
|
+
version: z.ZodString;
|
|
552
|
+
extensions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
553
|
+
}, "strip", z.ZodTypeAny, {
|
|
554
|
+
version: string;
|
|
555
|
+
level: CapabilityLevel;
|
|
556
|
+
registry: string;
|
|
557
|
+
organization: string;
|
|
558
|
+
agentClass: string;
|
|
559
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
560
|
+
extensions?: string[] | undefined;
|
|
561
|
+
}, {
|
|
562
|
+
version: string;
|
|
563
|
+
level: CapabilityLevel;
|
|
564
|
+
registry: string;
|
|
565
|
+
organization: string;
|
|
566
|
+
agentClass: string;
|
|
567
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
568
|
+
extensions?: string[] | undefined;
|
|
569
|
+
}>;
|
|
570
|
+
/**
|
|
571
|
+
* Zod schema for CARValidationError.
|
|
572
|
+
*/
|
|
573
|
+
export declare const carValidationErrorSchema: z.ZodObject<{
|
|
574
|
+
code: z.ZodString;
|
|
575
|
+
message: z.ZodString;
|
|
576
|
+
path: z.ZodOptional<z.ZodString>;
|
|
577
|
+
}, "strip", z.ZodTypeAny, {
|
|
578
|
+
code: string;
|
|
579
|
+
message: string;
|
|
580
|
+
path?: string | undefined;
|
|
581
|
+
}, {
|
|
582
|
+
code: string;
|
|
583
|
+
message: string;
|
|
584
|
+
path?: string | undefined;
|
|
585
|
+
}>;
|
|
586
|
+
/** @deprecated Use carValidationErrorSchema instead */
|
|
587
|
+
export declare const aciValidationErrorSchema: z.ZodObject<{
|
|
588
|
+
code: z.ZodString;
|
|
589
|
+
message: z.ZodString;
|
|
590
|
+
path: z.ZodOptional<z.ZodString>;
|
|
591
|
+
}, "strip", z.ZodTypeAny, {
|
|
592
|
+
code: string;
|
|
593
|
+
message: string;
|
|
594
|
+
path?: string | undefined;
|
|
595
|
+
}, {
|
|
596
|
+
code: string;
|
|
597
|
+
message: string;
|
|
598
|
+
path?: string | undefined;
|
|
599
|
+
}>;
|
|
600
|
+
/**
|
|
601
|
+
* Zod schema for CARValidationWarning.
|
|
602
|
+
*/
|
|
603
|
+
export declare const carValidationWarningSchema: z.ZodObject<{
|
|
604
|
+
code: z.ZodString;
|
|
605
|
+
message: z.ZodString;
|
|
606
|
+
path: z.ZodOptional<z.ZodString>;
|
|
607
|
+
}, "strip", z.ZodTypeAny, {
|
|
608
|
+
code: string;
|
|
609
|
+
message: string;
|
|
610
|
+
path?: string | undefined;
|
|
611
|
+
}, {
|
|
612
|
+
code: string;
|
|
613
|
+
message: string;
|
|
614
|
+
path?: string | undefined;
|
|
615
|
+
}>;
|
|
616
|
+
/** @deprecated Use carValidationWarningSchema instead */
|
|
617
|
+
export declare const aciValidationWarningSchema: z.ZodObject<{
|
|
618
|
+
code: z.ZodString;
|
|
619
|
+
message: z.ZodString;
|
|
620
|
+
path: z.ZodOptional<z.ZodString>;
|
|
621
|
+
}, "strip", z.ZodTypeAny, {
|
|
622
|
+
code: string;
|
|
623
|
+
message: string;
|
|
624
|
+
path?: string | undefined;
|
|
625
|
+
}, {
|
|
626
|
+
code: string;
|
|
627
|
+
message: string;
|
|
628
|
+
path?: string | undefined;
|
|
629
|
+
}>;
|
|
630
|
+
/**
|
|
631
|
+
* Zod schema for CARValidationResult.
|
|
632
|
+
*/
|
|
633
|
+
export declare const carValidationResultSchema: z.ZodObject<{
|
|
634
|
+
valid: z.ZodBoolean;
|
|
635
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
636
|
+
code: z.ZodString;
|
|
637
|
+
message: z.ZodString;
|
|
638
|
+
path: z.ZodOptional<z.ZodString>;
|
|
639
|
+
}, "strip", z.ZodTypeAny, {
|
|
640
|
+
code: string;
|
|
641
|
+
message: string;
|
|
642
|
+
path?: string | undefined;
|
|
643
|
+
}, {
|
|
644
|
+
code: string;
|
|
645
|
+
message: string;
|
|
646
|
+
path?: string | undefined;
|
|
647
|
+
}>, "many">;
|
|
648
|
+
warnings: z.ZodArray<z.ZodObject<{
|
|
649
|
+
code: z.ZodString;
|
|
650
|
+
message: z.ZodString;
|
|
651
|
+
path: z.ZodOptional<z.ZodString>;
|
|
652
|
+
}, "strip", z.ZodTypeAny, {
|
|
653
|
+
code: string;
|
|
654
|
+
message: string;
|
|
655
|
+
path?: string | undefined;
|
|
656
|
+
}, {
|
|
657
|
+
code: string;
|
|
658
|
+
message: string;
|
|
659
|
+
path?: string | undefined;
|
|
660
|
+
}>, "many">;
|
|
661
|
+
parsed: z.ZodOptional<z.ZodObject<{
|
|
662
|
+
car: z.ZodString;
|
|
663
|
+
registry: z.ZodString;
|
|
664
|
+
organization: z.ZodString;
|
|
665
|
+
agentClass: z.ZodString;
|
|
666
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
667
|
+
domainsBitmask: z.ZodNumber;
|
|
668
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
669
|
+
version: z.ZodString;
|
|
670
|
+
extensions: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
671
|
+
}, "strip", z.ZodTypeAny, {
|
|
672
|
+
version: string;
|
|
673
|
+
level: CapabilityLevel;
|
|
674
|
+
registry: string;
|
|
675
|
+
organization: string;
|
|
676
|
+
agentClass: string;
|
|
677
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
678
|
+
domainsBitmask: number;
|
|
679
|
+
car: string;
|
|
680
|
+
extensions: string[];
|
|
681
|
+
}, {
|
|
682
|
+
version: string;
|
|
683
|
+
level: CapabilityLevel;
|
|
684
|
+
registry: string;
|
|
685
|
+
organization: string;
|
|
686
|
+
agentClass: string;
|
|
687
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
688
|
+
domainsBitmask: number;
|
|
689
|
+
car: string;
|
|
690
|
+
extensions?: string[] | undefined;
|
|
691
|
+
}>>;
|
|
692
|
+
}, "strip", z.ZodTypeAny, {
|
|
693
|
+
valid: boolean;
|
|
694
|
+
errors: {
|
|
695
|
+
code: string;
|
|
696
|
+
message: string;
|
|
697
|
+
path?: string | undefined;
|
|
698
|
+
}[];
|
|
699
|
+
warnings: {
|
|
700
|
+
code: string;
|
|
701
|
+
message: string;
|
|
702
|
+
path?: string | undefined;
|
|
703
|
+
}[];
|
|
704
|
+
parsed?: {
|
|
705
|
+
version: string;
|
|
706
|
+
level: CapabilityLevel;
|
|
707
|
+
registry: string;
|
|
708
|
+
organization: string;
|
|
709
|
+
agentClass: string;
|
|
710
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
711
|
+
domainsBitmask: number;
|
|
712
|
+
car: string;
|
|
713
|
+
extensions: string[];
|
|
714
|
+
} | undefined;
|
|
715
|
+
}, {
|
|
716
|
+
valid: boolean;
|
|
717
|
+
errors: {
|
|
718
|
+
code: string;
|
|
719
|
+
message: string;
|
|
720
|
+
path?: string | undefined;
|
|
721
|
+
}[];
|
|
722
|
+
warnings: {
|
|
723
|
+
code: string;
|
|
724
|
+
message: string;
|
|
725
|
+
path?: string | undefined;
|
|
726
|
+
}[];
|
|
727
|
+
parsed?: {
|
|
728
|
+
version: string;
|
|
729
|
+
level: CapabilityLevel;
|
|
730
|
+
registry: string;
|
|
731
|
+
organization: string;
|
|
732
|
+
agentClass: string;
|
|
733
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
734
|
+
domainsBitmask: number;
|
|
735
|
+
car: string;
|
|
736
|
+
extensions?: string[] | undefined;
|
|
737
|
+
} | undefined;
|
|
738
|
+
}>;
|
|
739
|
+
/** @deprecated Use carValidationResultSchema instead */
|
|
740
|
+
export declare const aciValidationResultSchema: z.ZodObject<{
|
|
741
|
+
valid: z.ZodBoolean;
|
|
742
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
743
|
+
code: z.ZodString;
|
|
744
|
+
message: z.ZodString;
|
|
745
|
+
path: z.ZodOptional<z.ZodString>;
|
|
746
|
+
}, "strip", z.ZodTypeAny, {
|
|
747
|
+
code: string;
|
|
748
|
+
message: string;
|
|
749
|
+
path?: string | undefined;
|
|
750
|
+
}, {
|
|
751
|
+
code: string;
|
|
752
|
+
message: string;
|
|
753
|
+
path?: string | undefined;
|
|
754
|
+
}>, "many">;
|
|
755
|
+
warnings: z.ZodArray<z.ZodObject<{
|
|
756
|
+
code: z.ZodString;
|
|
757
|
+
message: z.ZodString;
|
|
758
|
+
path: z.ZodOptional<z.ZodString>;
|
|
759
|
+
}, "strip", z.ZodTypeAny, {
|
|
760
|
+
code: string;
|
|
761
|
+
message: string;
|
|
762
|
+
path?: string | undefined;
|
|
763
|
+
}, {
|
|
764
|
+
code: string;
|
|
765
|
+
message: string;
|
|
766
|
+
path?: string | undefined;
|
|
767
|
+
}>, "many">;
|
|
768
|
+
parsed: z.ZodOptional<z.ZodObject<{
|
|
769
|
+
car: z.ZodString;
|
|
770
|
+
registry: z.ZodString;
|
|
771
|
+
organization: z.ZodString;
|
|
772
|
+
agentClass: z.ZodString;
|
|
773
|
+
domains: z.ZodArray<z.ZodEnum<["A", "B", "C", "D", "E", "F", "G", "H", "I", "S"]>, "many">;
|
|
774
|
+
domainsBitmask: z.ZodNumber;
|
|
775
|
+
level: z.ZodNativeEnum<typeof CapabilityLevel>;
|
|
776
|
+
version: z.ZodString;
|
|
777
|
+
extensions: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
|
|
778
|
+
}, "strip", z.ZodTypeAny, {
|
|
779
|
+
version: string;
|
|
780
|
+
level: CapabilityLevel;
|
|
781
|
+
registry: string;
|
|
782
|
+
organization: string;
|
|
783
|
+
agentClass: string;
|
|
784
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
785
|
+
domainsBitmask: number;
|
|
786
|
+
car: string;
|
|
787
|
+
extensions: string[];
|
|
788
|
+
}, {
|
|
789
|
+
version: string;
|
|
790
|
+
level: CapabilityLevel;
|
|
791
|
+
registry: string;
|
|
792
|
+
organization: string;
|
|
793
|
+
agentClass: string;
|
|
794
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
795
|
+
domainsBitmask: number;
|
|
796
|
+
car: string;
|
|
797
|
+
extensions?: string[] | undefined;
|
|
798
|
+
}>>;
|
|
799
|
+
}, "strip", z.ZodTypeAny, {
|
|
800
|
+
valid: boolean;
|
|
801
|
+
errors: {
|
|
802
|
+
code: string;
|
|
803
|
+
message: string;
|
|
804
|
+
path?: string | undefined;
|
|
805
|
+
}[];
|
|
806
|
+
warnings: {
|
|
807
|
+
code: string;
|
|
808
|
+
message: string;
|
|
809
|
+
path?: string | undefined;
|
|
810
|
+
}[];
|
|
811
|
+
parsed?: {
|
|
812
|
+
version: string;
|
|
813
|
+
level: CapabilityLevel;
|
|
814
|
+
registry: string;
|
|
815
|
+
organization: string;
|
|
816
|
+
agentClass: string;
|
|
817
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
818
|
+
domainsBitmask: number;
|
|
819
|
+
car: string;
|
|
820
|
+
extensions: string[];
|
|
821
|
+
} | undefined;
|
|
822
|
+
}, {
|
|
823
|
+
valid: boolean;
|
|
824
|
+
errors: {
|
|
825
|
+
code: string;
|
|
826
|
+
message: string;
|
|
827
|
+
path?: string | undefined;
|
|
828
|
+
}[];
|
|
829
|
+
warnings: {
|
|
830
|
+
code: string;
|
|
831
|
+
message: string;
|
|
832
|
+
path?: string | undefined;
|
|
833
|
+
}[];
|
|
834
|
+
parsed?: {
|
|
835
|
+
version: string;
|
|
836
|
+
level: CapabilityLevel;
|
|
837
|
+
registry: string;
|
|
838
|
+
organization: string;
|
|
839
|
+
agentClass: string;
|
|
840
|
+
domains: ("A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "S")[];
|
|
841
|
+
domainsBitmask: number;
|
|
842
|
+
car: string;
|
|
843
|
+
extensions?: string[] | undefined;
|
|
844
|
+
} | undefined;
|
|
845
|
+
}>;
|
|
846
|
+
//# sourceMappingURL=car-string.d.ts.map
|