@nextera.one/axis-server-sdk 1.3.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  import { ModuleRef, DiscoveryService, MetadataScanner, Reflector } from '@nestjs/core';
2
- import { A as AxisFrame$2 } from './index-B5xzROld.js';
3
- export { a as AxisBinaryFrame, b as AxisFrameZ, c as computeReceiptHash, d as computeSignaturePayload, i as core, e as decodeFrame, f as encodeFrame, g as generateEd25519KeyPair, h as getSignTarget, s as sha256, j as signFrame, v as verifyFrameSignature } from './index-B5xzROld.js';
2
+ import { A as AxisFrame$2 } from './index-1uEwnW-w.js';
3
+ export { a as AxisBinaryFrame, b as AxisError, c as AxisFrameZ, d as computeReceiptHash, e as computeSignaturePayload, i as core, f as decodeFrame, g as encodeFrame, h as generateEd25519KeyPair, j as getSignTarget, s as sha256, k as signFrame, v as verifyFrameSignature } from './index-1uEwnW-w.js';
4
4
  import { PROOF_LOOM, TLV_LOOM_PRESENCE_ID, TLV_LOOM_THREAD_HASH, TLV_LOOM_WRIT } from '@nextera.one/axis-protocol';
5
5
  export { AXIS_MAGIC, AXIS_VERSION, TLV as AxisTlvType, BodyProfile, ERR_BAD_SIGNATURE, ERR_CONTRACT_VIOLATION, ERR_INVALID_PACKET, ERR_REPLAY_DETECTED, FLAG_BODY_TLV, FLAG_CHAIN_REQ, FLAG_HAS_WITNESS, MAX_BODY_LEN, MAX_FRAME_LEN, MAX_HDR_LEN, MAX_SIG_LEN, NCERT_ALG, NCERT_EXP, NCERT_ISSUER_KID, NCERT_KID, NCERT_NBF, NCERT_NODE_ID, NCERT_PAYLOAD, NCERT_PUB, NCERT_SCOPE, NCERT_SIG, PROOF_CAPSULE, PROOF_JWT, PROOF_LOOM, PROOF_MTLS, PROOF_NONE, PROOF_WITNESS, ProofType, TLV, TLV_ACTOR_ID, TLV_AUD, TLV_BODY_ARR, TLV_BODY_OBJ, TLV_CAPSULE, TLV_EFFECT, TLV_ERROR_CODE, TLV_ERROR_MSG, TLV_INDEX, TLV_INTENT, TLV_KID, TLV_LOOM_PRESENCE_ID, TLV_LOOM_THREAD_HASH, TLV_LOOM_WRIT, TLV_NODE, TLV_NODE_CERT_HASH, TLV_NODE_KID, TLV_NONCE, TLV_OFFSET, TLV_OK, TLV_PID, TLV_PREV_HASH, TLV_PROOF_REF, TLV_PROOF_TYPE, TLV_REALM, TLV_RECEIPT_HASH, TLV_RID, TLV_SHA256_CHUNK, TLV_TRACE_ID, TLV_TS, TLV_UPLOAD_ID, decodeArray, decodeObject, decodeTLVs, decodeTLVsList, decodeVarint, encodeTLVs, encodeVarint, varintLength } from '@nextera.one/axis-protocol';
6
- import * as z from 'zod';
7
6
  import { OnModuleInit, OnApplicationBootstrap } from '@nestjs/common';
8
7
  import { ConfigService } from '@nestjs/config';
8
+ import * as z from 'zod';
9
9
 
10
10
  declare const HANDLER_METADATA_KEY = "axis:handler";
11
11
  declare function Handler(intent?: string): ClassDecorator;
@@ -48,6 +48,16 @@ declare function IntentBody(decoder: (buf: Buffer) => any): MethodDecorator;
48
48
  declare const INTENT_SENSORS_KEY = "axis:intent:sensors";
49
49
  declare function IntentSensors(sensors: Function[]): MethodDecorator;
50
50
 
51
+ declare const HANDLER_SENSORS_KEY = "axis:handler:sensors";
52
+ declare function HandlerSensors(sensors: Function[]): ClassDecorator;
53
+
54
+ declare const SENSOR_METADATA_KEY = "axis:sensor";
55
+ type SensorPhase = 'PRE_DECODE' | 'POST_DECODE';
56
+ interface SensorOptions {
57
+ phase?: SensorPhase;
58
+ }
59
+ declare function Sensor(options?: SensorOptions): ClassDecorator;
60
+
51
61
  declare const TLV_FIELDS_KEY = "axis:tlv:fields";
52
62
  declare const TLV_VALIDATORS_KEY = "axis:tlv:validators";
53
63
  type TlvFieldKind = 'utf8' | 'u64' | 'bytes' | 'bytes16' | 'bool' | 'obj' | 'arr';
@@ -108,15 +118,15 @@ declare abstract class AxisResponseDto extends AxisTlvDto {
108
118
  interface IntentSchema$1 {
109
119
  intent: string;
110
120
  version: number;
111
- bodyProfile: 'TLV_MAP' | 'RAW' | 'TLV_OBJ' | 'TLV_ARR';
121
+ bodyProfile: "TLV_MAP" | "RAW" | "TLV_OBJ" | "TLV_ARR";
112
122
  fields: Array<{
113
123
  name: string;
114
124
  tlv: number;
115
- kind: IntentTlvField['kind'];
125
+ kind: IntentTlvField["kind"];
116
126
  required?: boolean;
117
127
  maxLen?: number;
118
128
  max?: string;
119
- scope?: 'header' | 'body';
129
+ scope?: "header" | "body";
120
130
  }>;
121
131
  }
122
132
  interface AxisEffect {
@@ -152,11 +162,136 @@ declare class IntentRouter {
152
162
  registerHandler(instance: any): void;
153
163
  route(frame: AxisFrame$2): Promise<AxisEffect>;
154
164
  private logIntent;
155
- registerIntentMeta(intent: string, proto: object, methodName: string): void;
165
+ registerIntentMeta(intent: string, proto: object, methodName: string, handlerSensors?: Function[]): void;
156
166
  private runIntentSensors;
157
167
  private storeSchema;
158
168
  }
159
169
 
170
+ declare const BAND: {
171
+ readonly WIRE: 0;
172
+ readonly IDENTITY: 40;
173
+ readonly POLICY: 90;
174
+ readonly CONTENT: 140;
175
+ readonly BUSINESS: 200;
176
+ readonly AUDIT: 900;
177
+ };
178
+ type SensorBand = keyof typeof BAND;
179
+ declare const PRE_DECODE_BOUNDARY = 40;
180
+
181
+ declare function stableJsonStringify(value: unknown): string;
182
+
183
+ interface ObservationStage {
184
+ name: string;
185
+ status: 'ok' | 'fail' | 'skip';
186
+ startMs: number;
187
+ endMs?: number;
188
+ durationMs?: number;
189
+ reason?: string;
190
+ code?: string;
191
+ }
192
+ interface ObservationSensor {
193
+ name: string;
194
+ allowed: boolean;
195
+ riskScore: number;
196
+ durationMs: number;
197
+ reasons: string[];
198
+ code?: string;
199
+ }
200
+ interface AxisObservation {
201
+ id: string;
202
+ startMs: number;
203
+ transport: 'http' | 'ws';
204
+ ip?: string;
205
+ intent?: string;
206
+ actorId?: string;
207
+ capsuleId?: string;
208
+ stages: ObservationStage[];
209
+ sensors: ObservationSensor[];
210
+ decision?: 'ALLOW' | 'DENY';
211
+ resultCode?: string;
212
+ statusCode?: number;
213
+ endMs?: number;
214
+ durationMs?: number;
215
+ facts: Record<string, unknown>;
216
+ }
217
+ declare function createObservation(transport: 'http' | 'ws', ip?: string): AxisObservation;
218
+ declare function startStage(obs: AxisObservation, name: string): ObservationStage;
219
+ declare function endStage(stage: ObservationStage, status?: 'ok' | 'fail' | 'skip', reason?: string, code?: string): void;
220
+ declare function recordSensor(obs: AxisObservation, name: string, allowed: boolean, riskScore: number, durationMs: number, reasons: string[], code?: string): void;
221
+ declare function finalizeObservation(obs: AxisObservation, decision: 'ALLOW' | 'DENY', statusCode: number, resultCode?: string): void;
222
+
223
+ interface ObservationQueueMessage {
224
+ v: 1;
225
+ observation: AxisObservation;
226
+ attempts: number;
227
+ firstEnqueuedAt: number;
228
+ lastEnqueuedAt: number;
229
+ sourceNodeId: string;
230
+ lastError?: string;
231
+ }
232
+ interface ObservationQueueConfig {
233
+ enabled: boolean;
234
+ workerEnabled: boolean;
235
+ streamKey: string;
236
+ deadLetterStreamKey: string;
237
+ groupName: string;
238
+ consumerName: string;
239
+ readBlockMs: number;
240
+ readBatchSize: number;
241
+ reclaimIdleMs: number;
242
+ reclaimBatchSize: number;
243
+ maxRetries: number;
244
+ maxStreamLength: number;
245
+ workerConcurrency: number;
246
+ }
247
+
248
+ interface ObservationStreamEntry {
249
+ id: string;
250
+ message: ObservationQueueMessage;
251
+ }
252
+ declare function buildQueueMessage(observation: AxisObservation, sourceNodeId: string, previous?: ObservationQueueMessage, lastError?: string): ObservationQueueMessage;
253
+ declare function encodeQueueMessage(message: ObservationQueueMessage): string;
254
+ declare function decodeQueueMessage(raw: string): ObservationQueueMessage | null;
255
+ declare function parseStreamEntries(raw: any): ObservationStreamEntry[];
256
+ declare function parseAutoClaimEntries(raw: any): ObservationStreamEntry[];
257
+
258
+ interface ObservationWitnessSummary {
259
+ intent?: string;
260
+ actorId?: string;
261
+ decision?: string;
262
+ statusCode?: number;
263
+ durationMs?: number;
264
+ sensorCount: number;
265
+ stageCount: number;
266
+ }
267
+ interface UnsignedObservationWitness {
268
+ v: 1;
269
+ observationId: string;
270
+ payloadHash: string;
271
+ sealedAt: number;
272
+ summary: ObservationWitnessSummary;
273
+ }
274
+ declare function canonicalizeObservation(obs: AxisObservation): string;
275
+ declare function hashObservation(obs: AxisObservation): string;
276
+ declare function buildUnsignedWitness(obs: AxisObservation): UnsignedObservationWitness | null;
277
+
278
+ interface ResponseObserverContext {
279
+ actorId: string;
280
+ intent: string;
281
+ }
282
+ interface ResponseContract {
283
+ ok: boolean;
284
+ effect: string;
285
+ body?: Uint8Array;
286
+ headers?: Map<number, Uint8Array>;
287
+ }
288
+ interface ObserverVerdict {
289
+ passed: boolean;
290
+ code?: string;
291
+ reason?: string;
292
+ }
293
+ declare function verifyResponse(ctx: ResponseObserverContext, response: ResponseContract): ObserverVerdict;
294
+
160
295
  declare const ATS1_HDR: {
161
296
  readonly INTENT_ID: 1;
162
297
  readonly ACTOR_KEY_ID: 2;
@@ -986,78 +1121,6 @@ declare class DiskUploadFileStore implements UploadFileStore {
986
1121
  createTempReadStream(fileId: string): NodeJS.ReadableStream;
987
1122
  }
988
1123
 
989
- type ProofType$1 = 1 | 2 | 3 | 4;
990
- interface ProofVerificationResult {
991
- valid: boolean;
992
- actorId?: string;
993
- error?: string;
994
- metadata?: Record<string, any>;
995
- }
996
- interface MTLSContext {
997
- clientCertPem?: string;
998
- clientCertFingerprint?: string;
999
- clientCertSubject?: string;
1000
- clientCertIssuer?: string;
1001
- verified?: boolean;
1002
- }
1003
- interface DeviceSEContext {
1004
- deviceId: string;
1005
- signature: Uint8Array;
1006
- publicKey: Uint8Array;
1007
- challenge?: Uint8Array;
1008
- }
1009
- declare class ProofVerificationService {
1010
- private readonly logger;
1011
- private readonly deviceKeys;
1012
- private readonly trustedCerts;
1013
- verifyProof(proofType: ProofType$1, proofRef: Uint8Array, context: {
1014
- signTarget?: Uint8Array;
1015
- signature?: Uint8Array;
1016
- mtls?: MTLSContext;
1017
- deviceSE?: DeviceSEContext;
1018
- }): Promise<ProofVerificationResult>;
1019
- private verifyCapsuleProof;
1020
- private verifyJWTProof;
1021
- private verifyMTLSProof;
1022
- private verifyDeviceSEProof;
1023
- registerDeviceKey(deviceId: string, publicKey: Uint8Array): void;
1024
- unregisterDevice(deviceId: string): boolean;
1025
- registerMTLSCert(fingerprint: string, actorId: string): void;
1026
- revokeMTLSCert(fingerprint: string): boolean;
1027
- static calculateFingerprint(certPem: string): string;
1028
- }
1029
-
1030
- type index$7_ActorKeyRecord = ActorKeyRecord;
1031
- type index$7_AxisCapsule = AxisCapsule;
1032
- type index$7_AxisCapsuleConstraints = AxisCapsuleConstraints;
1033
- type index$7_AxisCapsulePayload = AxisCapsulePayload;
1034
- type index$7_CapsuleBatchBody = CapsuleBatchBody;
1035
- type index$7_CapsuleBatchResult = CapsuleBatchResult;
1036
- type index$7_CapsuleIssueBody = CapsuleIssueBody;
1037
- type index$7_CapsuleIssueResult = CapsuleIssueResult;
1038
- type index$7_CapsuleMode = CapsuleMode;
1039
- type index$7_CapsuleRecord = CapsuleRecord;
1040
- type index$7_CapsuleRevokeBody = CapsuleRevokeBody;
1041
- type index$7_CapsuleStatus = CapsuleStatus;
1042
- type index$7_DeviceSEContext = DeviceSEContext;
1043
- type index$7_IntentExecBody = IntentExecBody;
1044
- type index$7_IssuerKeyRecord = IssuerKeyRecord;
1045
- type index$7_KeyStatus = KeyStatus;
1046
- type index$7_MTLSContext = MTLSContext;
1047
- type index$7_ProofVerificationResult = ProofVerificationResult;
1048
- type index$7_ProofVerificationService = ProofVerificationService;
1049
- declare const index$7_ProofVerificationService: typeof ProofVerificationService;
1050
- type index$7_TickWindow = TickWindow;
1051
- declare const index$7_b64urlDecode: typeof b64urlDecode;
1052
- declare const index$7_b64urlDecodeString: typeof b64urlDecodeString;
1053
- declare const index$7_b64urlEncode: typeof b64urlEncode;
1054
- declare const index$7_b64urlEncodeString: typeof b64urlEncodeString;
1055
- declare const index$7_canonicalJson: typeof canonicalJson;
1056
- declare const index$7_canonicalJsonExcluding: typeof canonicalJsonExcluding;
1057
- declare namespace index$7 {
1058
- export { type index$7_ActorKeyRecord as ActorKeyRecord, type AxisAlg$1 as AxisAlg, type index$7_AxisCapsule as AxisCapsule, type index$7_AxisCapsuleConstraints as AxisCapsuleConstraints, type index$7_AxisCapsulePayload as AxisCapsulePayload, type AxisPacket$1 as AxisPacket, type AxisResponse$1 as AxisResponse, type AxisSig$1 as AxisSig, type index$7_CapsuleBatchBody as CapsuleBatchBody, type index$7_CapsuleBatchResult as CapsuleBatchResult, type index$7_CapsuleIssueBody as CapsuleIssueBody, type index$7_CapsuleIssueResult as CapsuleIssueResult, type index$7_CapsuleMode as CapsuleMode, type index$7_CapsuleRecord as CapsuleRecord, type index$7_CapsuleRevokeBody as CapsuleRevokeBody, type index$7_CapsuleStatus as CapsuleStatus, type index$7_DeviceSEContext as DeviceSEContext, type index$7_IntentExecBody as IntentExecBody, type index$7_IssuerKeyRecord as IssuerKeyRecord, type index$7_KeyStatus as KeyStatus, type index$7_MTLSContext as MTLSContext, type ProofType$1 as ProofType, type index$7_ProofVerificationResult as ProofVerificationResult, index$7_ProofVerificationService as ProofVerificationService, type index$7_TickWindow as TickWindow, index$7_b64urlDecode as b64urlDecode, index$7_b64urlDecodeString as b64urlDecodeString, index$7_b64urlEncode as b64urlEncode, index$7_b64urlEncodeString as b64urlEncodeString, index$7_canonicalJson as canonicalJson, index$7_canonicalJsonExcluding as canonicalJsonExcluding };
1059
- }
1060
-
1061
1124
  interface AxisRequestData {
1062
1125
  raw: Buffer;
1063
1126
  ip: string | undefined;
@@ -1070,53 +1133,40 @@ declare const AxisContext$1: (...dataOrPipes: unknown[]) => ParameterDecorator;
1070
1133
  declare const AxisDemoPubkey: (...dataOrPipes: unknown[]) => ParameterDecorator;
1071
1134
  declare const AxisFrame: (...dataOrPipes: unknown[]) => ParameterDecorator;
1072
1135
 
1073
- declare const SENSOR_METADATA_KEY = "axis:sensor";
1074
- type SensorPhase = 'PRE_DECODE' | 'POST_DECODE';
1075
- interface SensorOptions {
1076
- phase?: SensorPhase;
1136
+ declare class HandlerDiscoveryService implements OnModuleInit {
1137
+ private readonly discovery;
1138
+ private readonly scanner;
1139
+ private readonly router;
1140
+ private readonly logger;
1141
+ constructor(discovery: DiscoveryService, scanner: MetadataScanner, router: IntentRouter);
1142
+ onModuleInit(): void;
1077
1143
  }
1078
- declare function Sensor(options?: SensorOptions): ClassDecorator;
1079
1144
 
1080
- declare const index$6_AxisDemoPubkey: typeof AxisDemoPubkey;
1081
- declare const index$6_AxisFrame: typeof AxisFrame;
1082
- declare const index$6_AxisIp: typeof AxisIp;
1083
- declare const index$6_AxisRaw: typeof AxisRaw;
1084
- type index$6_AxisRequestData = AxisRequestData;
1085
- type index$6_DtoSchema = DtoSchema;
1086
- declare const index$6_HANDLER_METADATA_KEY: typeof HANDLER_METADATA_KEY;
1087
- declare const index$6_Handler: typeof Handler;
1088
- declare const index$6_INTENT_BODY_KEY: typeof INTENT_BODY_KEY;
1089
- declare const index$6_INTENT_METADATA_KEY: typeof INTENT_METADATA_KEY;
1090
- declare const index$6_INTENT_ROUTES_KEY: typeof INTENT_ROUTES_KEY;
1091
- declare const index$6_INTENT_SENSORS_KEY: typeof INTENT_SENSORS_KEY;
1092
- declare const index$6_Intent: typeof Intent;
1093
- declare const index$6_IntentBody: typeof IntentBody;
1094
- type index$6_IntentKind = IntentKind;
1095
- type index$6_IntentOptions = IntentOptions;
1096
- type index$6_IntentRoute = IntentRoute;
1097
- declare const index$6_IntentSensors: typeof IntentSensors;
1098
- type index$6_IntentTlvField = IntentTlvField;
1099
- declare const index$6_SENSOR_METADATA_KEY: typeof SENSOR_METADATA_KEY;
1100
- declare const index$6_Sensor: typeof Sensor;
1101
- type index$6_SensorOptions = SensorOptions;
1102
- type index$6_SensorPhase = SensorPhase;
1103
- declare const index$6_TLV_FIELDS_KEY: typeof TLV_FIELDS_KEY;
1104
- declare const index$6_TLV_VALIDATORS_KEY: typeof TLV_VALIDATORS_KEY;
1105
- declare const index$6_TlvEnum: typeof TlvEnum;
1106
- declare const index$6_TlvField: typeof TlvField;
1107
- type index$6_TlvFieldKind = TlvFieldKind;
1108
- type index$6_TlvFieldMeta = TlvFieldMeta;
1109
- type index$6_TlvFieldOptions = TlvFieldOptions;
1110
- declare const index$6_TlvMinLen: typeof TlvMinLen;
1111
- declare const index$6_TlvRange: typeof TlvRange;
1112
- declare const index$6_TlvUtf8Pattern: typeof TlvUtf8Pattern;
1113
- declare const index$6_TlvValidate: typeof TlvValidate;
1114
- type index$6_TlvValidatorFn = TlvValidatorFn;
1115
- type index$6_TlvValidatorMeta = TlvValidatorMeta;
1116
- declare const index$6_buildDtoDecoder: typeof buildDtoDecoder;
1117
- declare const index$6_extractDtoSchema: typeof extractDtoSchema;
1118
- declare namespace index$6 {
1119
- export { AxisContext$1 as AxisContext, index$6_AxisDemoPubkey as AxisDemoPubkey, index$6_AxisFrame as AxisFrame, index$6_AxisIp as AxisIp, index$6_AxisRaw as AxisRaw, type index$6_AxisRequestData as AxisRequestData, type index$6_DtoSchema as DtoSchema, index$6_HANDLER_METADATA_KEY as HANDLER_METADATA_KEY, index$6_Handler as Handler, index$6_INTENT_BODY_KEY as INTENT_BODY_KEY, index$6_INTENT_METADATA_KEY as INTENT_METADATA_KEY, index$6_INTENT_ROUTES_KEY as INTENT_ROUTES_KEY, index$6_INTENT_SENSORS_KEY as INTENT_SENSORS_KEY, index$6_Intent as Intent, index$6_IntentBody as IntentBody, type index$6_IntentKind as IntentKind, type index$6_IntentOptions as IntentOptions, type index$6_IntentRoute as IntentRoute, index$6_IntentSensors as IntentSensors, type index$6_IntentTlvField as IntentTlvField, index$6_SENSOR_METADATA_KEY as SENSOR_METADATA_KEY, index$6_Sensor as Sensor, type index$6_SensorOptions as SensorOptions, type index$6_SensorPhase as SensorPhase, index$6_TLV_FIELDS_KEY as TLV_FIELDS_KEY, index$6_TLV_VALIDATORS_KEY as TLV_VALIDATORS_KEY, index$6_TlvEnum as TlvEnum, index$6_TlvField as TlvField, type index$6_TlvFieldKind as TlvFieldKind, type index$6_TlvFieldMeta as TlvFieldMeta, type index$6_TlvFieldOptions as TlvFieldOptions, index$6_TlvMinLen as TlvMinLen, index$6_TlvRange as TlvRange, index$6_TlvUtf8Pattern as TlvUtf8Pattern, index$6_TlvValidate as TlvValidate, type index$6_TlvValidatorFn as TlvValidatorFn, type index$6_TlvValidatorMeta as TlvValidatorMeta, index$6_buildDtoDecoder as buildDtoDecoder, index$6_extractDtoSchema as extractDtoSchema };
1145
+ declare class SensorRegistry {
1146
+ private readonly configService;
1147
+ private sensors;
1148
+ private readonly logger;
1149
+ constructor(configService: ConfigService);
1150
+ register(sensor: AxisSensor): void;
1151
+ list(): AxisSensor[];
1152
+ getPreDecodeSensors(): AxisPreSensor[];
1153
+ getPostDecodeSensors(): AxisPostSensor[];
1154
+ private isPreDecodeSensor;
1155
+ private isPostDecodeSensor;
1156
+ getSensorCountByPhase(): {
1157
+ preDecodeCount: number;
1158
+ postDecodeCount: number;
1159
+ };
1160
+ clear(): void;
1161
+ }
1162
+
1163
+ declare class SensorDiscoveryService implements OnApplicationBootstrap {
1164
+ private readonly discovery;
1165
+ private readonly reflector;
1166
+ private readonly registry;
1167
+ private readonly logger;
1168
+ constructor(discovery: DiscoveryService, reflector: Reflector, registry: SensorRegistry);
1169
+ onApplicationBootstrap(): void;
1120
1170
  }
1121
1171
 
1122
1172
  declare const SensorDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
@@ -1566,7 +1616,7 @@ declare const ChunkHashInputZ: z.ZodObject<{
1566
1616
  intent: z.ZodString;
1567
1617
  }, z.core.$strip>;
1568
1618
  type ChunkHashInput = z.infer<typeof ChunkHashInputZ>;
1569
- declare enum ProofType {
1619
+ declare enum ProofType$1 {
1570
1620
  CAPSULE = 1,
1571
1621
  JWT = 2,
1572
1622
  MTLS_ID = 3,
@@ -1578,7 +1628,7 @@ declare const AxisContextZ: z.ZodObject<{
1578
1628
  ts: z.ZodBigInt;
1579
1629
  intent: z.ZodString;
1580
1630
  actorId: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1581
- proofType: z.ZodEnum<typeof ProofType>;
1631
+ proofType: z.ZodEnum<typeof ProofType$1>;
1582
1632
  proofRef: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1583
1633
  nonce: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1584
1634
  ip: z.ZodString;
@@ -1623,46 +1673,6 @@ declare const AxisErrorZ: z.ZodObject<{
1623
1673
  }, z.core.$strip>;
1624
1674
  type AxisError = z.infer<typeof AxisErrorZ>;
1625
1675
 
1626
- interface ObservationStage {
1627
- name: string;
1628
- status: 'ok' | 'fail' | 'skip';
1629
- startMs: number;
1630
- endMs?: number;
1631
- durationMs?: number;
1632
- reason?: string;
1633
- code?: string;
1634
- }
1635
- interface ObservationSensor {
1636
- name: string;
1637
- allowed: boolean;
1638
- riskScore: number;
1639
- durationMs: number;
1640
- reasons: string[];
1641
- code?: string;
1642
- }
1643
- interface AxisObservation {
1644
- id: string;
1645
- startMs: number;
1646
- transport: 'http' | 'ws';
1647
- ip?: string;
1648
- intent?: string;
1649
- actorId?: string;
1650
- capsuleId?: string;
1651
- stages: ObservationStage[];
1652
- sensors: ObservationSensor[];
1653
- decision?: 'ALLOW' | 'DENY';
1654
- resultCode?: string;
1655
- statusCode?: number;
1656
- endMs?: number;
1657
- durationMs?: number;
1658
- facts: Record<string, unknown>;
1659
- }
1660
- declare function createObservation(transport: 'http' | 'ws', ip?: string): AxisObservation;
1661
- declare function startStage(obs: AxisObservation, name: string): ObservationStage;
1662
- declare function endStage(stage: ObservationStage, status?: 'ok' | 'fail' | 'skip', reason?: string, code?: string): void;
1663
- declare function recordSensor(obs: AxisObservation, name: string, allowed: boolean, riskScore: number, durationMs: number, reasons: string[], code?: string): void;
1664
- declare function finalizeObservation(obs: AxisObservation, decision: 'ALLOW' | 'DENY', statusCode: number, resultCode?: string): void;
1665
-
1666
1676
  interface AxisDecoded {
1667
1677
  frame: Axis1DecodedFrame;
1668
1678
  packet: AxisPacket;
@@ -1677,51 +1687,157 @@ interface AxisDecoded {
1677
1687
  observation: AxisObservation;
1678
1688
  }
1679
1689
 
1680
- declare class HandlerDiscoveryService implements OnModuleInit {
1681
- private readonly discovery;
1682
- private readonly scanner;
1683
- private readonly router;
1684
- private readonly logger;
1685
- constructor(discovery: DiscoveryService, scanner: MetadataScanner, router: IntentRouter);
1686
- onModuleInit(): void;
1690
+ interface ChainResult {
1691
+ allowed: boolean;
1692
+ scoreDelta: number;
1693
+ statusCode: number;
1694
+ body?: string | Buffer | Uint8Array;
1695
+ headers?: Map<number, Uint8Array>;
1696
+ }
1697
+ declare class AxisSensorChainService {
1698
+ private readonly registry;
1699
+ constructor(registry: SensorRegistry);
1700
+ evaluate(input: SensorInput, phase?: 'PRE_DECODE' | 'POST_DECODE' | 'BOTH', baseDecision?: SensorDecision): Promise<SensorDecision>;
1701
+ evaluatePre(input: SensorInput): Promise<SensorDecision>;
1702
+ evaluatePost(input: SensorInput, baseDecision?: SensorDecision): Promise<SensorDecision>;
1703
+ private evaluateSensors;
1687
1704
  }
1688
1705
 
1689
- declare const BAND: {
1690
- readonly WIRE: 0;
1691
- readonly IDENTITY: 40;
1692
- readonly POLICY: 90;
1693
- readonly CONTENT: 140;
1694
- readonly BUSINESS: 200;
1695
- readonly AUDIT: 900;
1696
- };
1697
- type SensorBand = keyof typeof BAND;
1698
- declare const PRE_DECODE_BOUNDARY = 40;
1699
-
1700
- declare class SensorRegistry {
1701
- private readonly configService;
1702
- private sensors;
1706
+ type ProofType = 1 | 2 | 3 | 4;
1707
+ interface ProofVerificationResult {
1708
+ valid: boolean;
1709
+ actorId?: string;
1710
+ error?: string;
1711
+ metadata?: Record<string, any>;
1712
+ }
1713
+ interface MTLSContext {
1714
+ clientCertPem?: string;
1715
+ clientCertFingerprint?: string;
1716
+ clientCertSubject?: string;
1717
+ clientCertIssuer?: string;
1718
+ verified?: boolean;
1719
+ }
1720
+ interface DeviceSEContext {
1721
+ deviceId: string;
1722
+ signature: Uint8Array;
1723
+ publicKey: Uint8Array;
1724
+ challenge?: Uint8Array;
1725
+ }
1726
+ declare class ProofVerificationService {
1703
1727
  private readonly logger;
1704
- constructor(configService: ConfigService);
1705
- register(sensor: AxisSensor): void;
1706
- list(): AxisSensor[];
1707
- getPreDecodeSensors(): AxisPreSensor[];
1708
- getPostDecodeSensors(): AxisPostSensor[];
1709
- private isPreDecodeSensor;
1710
- private isPostDecodeSensor;
1711
- getSensorCountByPhase(): {
1712
- preDecodeCount: number;
1713
- postDecodeCount: number;
1714
- };
1715
- clear(): void;
1728
+ private readonly deviceKeys;
1729
+ private readonly trustedCerts;
1730
+ verifyProof(proofType: ProofType, proofRef: Uint8Array, context: {
1731
+ signTarget?: Uint8Array;
1732
+ signature?: Uint8Array;
1733
+ mtls?: MTLSContext;
1734
+ deviceSE?: DeviceSEContext;
1735
+ }): Promise<ProofVerificationResult>;
1736
+ private verifyCapsuleProof;
1737
+ private verifyJWTProof;
1738
+ private verifyMTLSProof;
1739
+ private verifyDeviceSEProof;
1740
+ registerDeviceKey(deviceId: string, publicKey: Uint8Array): void;
1741
+ unregisterDevice(deviceId: string): boolean;
1742
+ registerMTLSCert(fingerprint: string, actorId: string): void;
1743
+ revokeMTLSCert(fingerprint: string): boolean;
1744
+ static calculateFingerprint(certPem: string): string;
1716
1745
  }
1717
1746
 
1718
- declare class SensorDiscoveryService implements OnApplicationBootstrap {
1719
- private readonly discovery;
1720
- private readonly reflector;
1721
- private readonly registry;
1722
- private readonly logger;
1723
- constructor(discovery: DiscoveryService, reflector: Reflector, registry: SensorRegistry);
1724
- onApplicationBootstrap(): void;
1747
+ type index$8_ActorKeyRecord = ActorKeyRecord;
1748
+ type index$8_AxisCapsule = AxisCapsule;
1749
+ type index$8_AxisCapsuleConstraints = AxisCapsuleConstraints;
1750
+ type index$8_AxisCapsulePayload = AxisCapsulePayload;
1751
+ type index$8_CapsuleBatchBody = CapsuleBatchBody;
1752
+ type index$8_CapsuleBatchResult = CapsuleBatchResult;
1753
+ type index$8_CapsuleIssueBody = CapsuleIssueBody;
1754
+ type index$8_CapsuleIssueResult = CapsuleIssueResult;
1755
+ type index$8_CapsuleMode = CapsuleMode;
1756
+ type index$8_CapsuleRecord = CapsuleRecord;
1757
+ type index$8_CapsuleRevokeBody = CapsuleRevokeBody;
1758
+ type index$8_CapsuleStatus = CapsuleStatus;
1759
+ type index$8_DeviceSEContext = DeviceSEContext;
1760
+ type index$8_IntentExecBody = IntentExecBody;
1761
+ type index$8_IssuerKeyRecord = IssuerKeyRecord;
1762
+ type index$8_KeyStatus = KeyStatus;
1763
+ type index$8_MTLSContext = MTLSContext;
1764
+ type index$8_ProofType = ProofType;
1765
+ type index$8_ProofVerificationResult = ProofVerificationResult;
1766
+ type index$8_ProofVerificationService = ProofVerificationService;
1767
+ declare const index$8_ProofVerificationService: typeof ProofVerificationService;
1768
+ type index$8_TickWindow = TickWindow;
1769
+ declare const index$8_b64urlDecode: typeof b64urlDecode;
1770
+ declare const index$8_b64urlDecodeString: typeof b64urlDecodeString;
1771
+ declare const index$8_b64urlEncode: typeof b64urlEncode;
1772
+ declare const index$8_b64urlEncodeString: typeof b64urlEncodeString;
1773
+ declare const index$8_canonicalJson: typeof canonicalJson;
1774
+ declare const index$8_canonicalJsonExcluding: typeof canonicalJsonExcluding;
1775
+ declare namespace index$8 {
1776
+ export { type index$8_ActorKeyRecord as ActorKeyRecord, type AxisAlg$1 as AxisAlg, type index$8_AxisCapsule as AxisCapsule, type index$8_AxisCapsuleConstraints as AxisCapsuleConstraints, type index$8_AxisCapsulePayload as AxisCapsulePayload, type AxisPacket$1 as AxisPacket, type AxisResponse$1 as AxisResponse, type AxisSig$1 as AxisSig, type index$8_CapsuleBatchBody as CapsuleBatchBody, type index$8_CapsuleBatchResult as CapsuleBatchResult, type index$8_CapsuleIssueBody as CapsuleIssueBody, type index$8_CapsuleIssueResult as CapsuleIssueResult, type index$8_CapsuleMode as CapsuleMode, type index$8_CapsuleRecord as CapsuleRecord, type index$8_CapsuleRevokeBody as CapsuleRevokeBody, type index$8_CapsuleStatus as CapsuleStatus, type index$8_DeviceSEContext as DeviceSEContext, type index$8_IntentExecBody as IntentExecBody, type index$8_IssuerKeyRecord as IssuerKeyRecord, type index$8_KeyStatus as KeyStatus, type index$8_MTLSContext as MTLSContext, type index$8_ProofType as ProofType, type index$8_ProofVerificationResult as ProofVerificationResult, index$8_ProofVerificationService as ProofVerificationService, type index$8_TickWindow as TickWindow, index$8_b64urlDecode as b64urlDecode, index$8_b64urlDecodeString as b64urlDecodeString, index$8_b64urlEncode as b64urlEncode, index$8_b64urlEncodeString as b64urlEncodeString, index$8_canonicalJson as canonicalJson, index$8_canonicalJsonExcluding as canonicalJsonExcluding };
1777
+ }
1778
+
1779
+ declare const index$7_AxisDemoPubkey: typeof AxisDemoPubkey;
1780
+ declare const index$7_AxisFrame: typeof AxisFrame;
1781
+ declare const index$7_AxisIp: typeof AxisIp;
1782
+ declare const index$7_AxisRaw: typeof AxisRaw;
1783
+ type index$7_AxisRequestData = AxisRequestData;
1784
+ type index$7_DtoSchema = DtoSchema;
1785
+ declare const index$7_HANDLER_METADATA_KEY: typeof HANDLER_METADATA_KEY;
1786
+ declare const index$7_Handler: typeof Handler;
1787
+ declare const index$7_INTENT_BODY_KEY: typeof INTENT_BODY_KEY;
1788
+ declare const index$7_INTENT_METADATA_KEY: typeof INTENT_METADATA_KEY;
1789
+ declare const index$7_INTENT_ROUTES_KEY: typeof INTENT_ROUTES_KEY;
1790
+ declare const index$7_INTENT_SENSORS_KEY: typeof INTENT_SENSORS_KEY;
1791
+ declare const index$7_Intent: typeof Intent;
1792
+ declare const index$7_IntentBody: typeof IntentBody;
1793
+ type index$7_IntentKind = IntentKind;
1794
+ type index$7_IntentOptions = IntentOptions;
1795
+ type index$7_IntentRoute = IntentRoute;
1796
+ declare const index$7_IntentSensors: typeof IntentSensors;
1797
+ type index$7_IntentTlvField = IntentTlvField;
1798
+ declare const index$7_SENSOR_METADATA_KEY: typeof SENSOR_METADATA_KEY;
1799
+ declare const index$7_Sensor: typeof Sensor;
1800
+ type index$7_SensorOptions = SensorOptions;
1801
+ type index$7_SensorPhase = SensorPhase;
1802
+ declare const index$7_TLV_FIELDS_KEY: typeof TLV_FIELDS_KEY;
1803
+ declare const index$7_TLV_VALIDATORS_KEY: typeof TLV_VALIDATORS_KEY;
1804
+ declare const index$7_TlvEnum: typeof TlvEnum;
1805
+ declare const index$7_TlvField: typeof TlvField;
1806
+ type index$7_TlvFieldKind = TlvFieldKind;
1807
+ type index$7_TlvFieldMeta = TlvFieldMeta;
1808
+ type index$7_TlvFieldOptions = TlvFieldOptions;
1809
+ declare const index$7_TlvMinLen: typeof TlvMinLen;
1810
+ declare const index$7_TlvRange: typeof TlvRange;
1811
+ declare const index$7_TlvUtf8Pattern: typeof TlvUtf8Pattern;
1812
+ declare const index$7_TlvValidate: typeof TlvValidate;
1813
+ type index$7_TlvValidatorFn = TlvValidatorFn;
1814
+ type index$7_TlvValidatorMeta = TlvValidatorMeta;
1815
+ declare const index$7_buildDtoDecoder: typeof buildDtoDecoder;
1816
+ declare const index$7_extractDtoSchema: typeof extractDtoSchema;
1817
+ declare namespace index$7 {
1818
+ export { AxisContext$1 as AxisContext, index$7_AxisDemoPubkey as AxisDemoPubkey, index$7_AxisFrame as AxisFrame, index$7_AxisIp as AxisIp, index$7_AxisRaw as AxisRaw, type index$7_AxisRequestData as AxisRequestData, type index$7_DtoSchema as DtoSchema, index$7_HANDLER_METADATA_KEY as HANDLER_METADATA_KEY, index$7_Handler as Handler, index$7_INTENT_BODY_KEY as INTENT_BODY_KEY, index$7_INTENT_METADATA_KEY as INTENT_METADATA_KEY, index$7_INTENT_ROUTES_KEY as INTENT_ROUTES_KEY, index$7_INTENT_SENSORS_KEY as INTENT_SENSORS_KEY, index$7_Intent as Intent, index$7_IntentBody as IntentBody, type index$7_IntentKind as IntentKind, type index$7_IntentOptions as IntentOptions, type index$7_IntentRoute as IntentRoute, index$7_IntentSensors as IntentSensors, type index$7_IntentTlvField as IntentTlvField, index$7_SENSOR_METADATA_KEY as SENSOR_METADATA_KEY, index$7_Sensor as Sensor, type index$7_SensorOptions as SensorOptions, type index$7_SensorPhase as SensorPhase, index$7_TLV_FIELDS_KEY as TLV_FIELDS_KEY, index$7_TLV_VALIDATORS_KEY as TLV_VALIDATORS_KEY, index$7_TlvEnum as TlvEnum, index$7_TlvField as TlvField, type index$7_TlvFieldKind as TlvFieldKind, type index$7_TlvFieldMeta as TlvFieldMeta, type index$7_TlvFieldOptions as TlvFieldOptions, index$7_TlvMinLen as TlvMinLen, index$7_TlvRange as TlvRange, index$7_TlvUtf8Pattern as TlvUtf8Pattern, index$7_TlvValidate as TlvValidate, type index$7_TlvValidatorFn as TlvValidatorFn, type index$7_TlvValidatorMeta as TlvValidatorMeta, index$7_buildDtoDecoder as buildDtoDecoder, index$7_extractDtoSchema as extractDtoSchema };
1819
+ }
1820
+
1821
+ type index$6_ObservationQueueConfig = ObservationQueueConfig;
1822
+ type index$6_ObservationQueueMessage = ObservationQueueMessage;
1823
+ type index$6_ObservationStreamEntry = ObservationStreamEntry;
1824
+ type index$6_ObservationWitnessSummary = ObservationWitnessSummary;
1825
+ type index$6_ObserverVerdict = ObserverVerdict;
1826
+ type index$6_ResponseContract = ResponseContract;
1827
+ type index$6_ResponseObserverContext = ResponseObserverContext;
1828
+ type index$6_UnsignedObservationWitness = UnsignedObservationWitness;
1829
+ declare const index$6_buildQueueMessage: typeof buildQueueMessage;
1830
+ declare const index$6_buildUnsignedWitness: typeof buildUnsignedWitness;
1831
+ declare const index$6_canonicalizeObservation: typeof canonicalizeObservation;
1832
+ declare const index$6_decodeQueueMessage: typeof decodeQueueMessage;
1833
+ declare const index$6_encodeQueueMessage: typeof encodeQueueMessage;
1834
+ declare const index$6_hashObservation: typeof hashObservation;
1835
+ declare const index$6_parseAutoClaimEntries: typeof parseAutoClaimEntries;
1836
+ declare const index$6_parseStreamEntries: typeof parseStreamEntries;
1837
+ declare const index$6_stableJsonStringify: typeof stableJsonStringify;
1838
+ declare const index$6_verifyResponse: typeof verifyResponse;
1839
+ declare namespace index$6 {
1840
+ export { type index$6_ObservationQueueConfig as ObservationQueueConfig, type index$6_ObservationQueueMessage as ObservationQueueMessage, type index$6_ObservationStreamEntry as ObservationStreamEntry, type index$6_ObservationWitnessSummary as ObservationWitnessSummary, type index$6_ObserverVerdict as ObserverVerdict, type index$6_ResponseContract as ResponseContract, type index$6_ResponseObserverContext as ResponseObserverContext, type index$6_UnsignedObservationWitness as UnsignedObservationWitness, index$6_buildQueueMessage as buildQueueMessage, index$6_buildUnsignedWitness as buildUnsignedWitness, index$6_canonicalizeObservation as canonicalizeObservation, index$6_decodeQueueMessage as decodeQueueMessage, index$6_encodeQueueMessage as encodeQueueMessage, index$6_hashObservation as hashObservation, index$6_parseAutoClaimEntries as parseAutoClaimEntries, index$6_parseStreamEntries as parseStreamEntries, index$6_stableJsonStringify as stableJsonStringify, index$6_verifyResponse as verifyResponse };
1725
1841
  }
1726
1842
 
1727
1843
  type index$5_AxisDecoded = AxisDecoded;
@@ -1746,7 +1862,7 @@ declare const index$5_finalizeObservation: typeof finalizeObservation;
1746
1862
  declare const index$5_recordSensor: typeof recordSensor;
1747
1863
  declare const index$5_startStage: typeof startStage;
1748
1864
  declare namespace index$5 {
1749
- export { type index$5_AxisDecoded as AxisDecoded, type index$5_AxisEffect as AxisEffect, type index$5_AxisObservation as AxisObservation, index$5_BAND as BAND, index$5_HandlerDiscoveryService as HandlerDiscoveryService, index$5_IntentRouter as IntentRouter, type IntentSchema$1 as IntentSchema, type index$5_ObservationSensor as ObservationSensor, type index$5_ObservationStage as ObservationStage, index$5_PRE_DECODE_BOUNDARY as PRE_DECODE_BOUNDARY, type index$5_SensorBand as SensorBand, index$5_SensorDiscoveryService as SensorDiscoveryService, index$5_SensorRegistry as SensorRegistry, index$5_createObservation as createObservation, index$5_endStage as endStage, index$5_finalizeObservation as finalizeObservation, index$5_recordSensor as recordSensor, index$5_startStage as startStage };
1865
+ export { type index$5_AxisDecoded as AxisDecoded, type index$5_AxisEffect as AxisEffect, type index$5_AxisObservation as AxisObservation, index$5_BAND as BAND, index$5_HandlerDiscoveryService as HandlerDiscoveryService, index$5_IntentRouter as IntentRouter, type IntentSchema$1 as IntentSchema, type index$5_ObservationSensor as ObservationSensor, type index$5_ObservationStage as ObservationStage, index$5_PRE_DECODE_BOUNDARY as PRE_DECODE_BOUNDARY, type index$5_SensorBand as SensorBand, index$5_SensorDiscoveryService as SensorDiscoveryService, index$5_SensorRegistry as SensorRegistry, index$5_createObservation as createObservation, index$5_endStage as endStage, index$5_finalizeObservation as finalizeObservation, index$6 as observation, index$5_recordSensor as recordSensor, index$5_startStage as startStage };
1750
1866
  }
1751
1867
 
1752
1868
  interface PresenceDeclaration {
@@ -1988,8 +2104,6 @@ type index$3_ProofKind = ProofKind;
1988
2104
  declare const index$3_ProofKindZ: typeof ProofKindZ;
1989
2105
  type index$3_ProofPresenceInput = ProofPresenceInput;
1990
2106
  declare const index$3_ProofPresenceInputZ: typeof ProofPresenceInputZ;
1991
- type index$3_ProofType = ProofType;
1992
- declare const index$3_ProofType: typeof ProofType;
1993
2107
  type index$3_ProtocolStrictInput = ProtocolStrictInput;
1994
2108
  declare const index$3_ProtocolStrictInputZ: typeof ProtocolStrictInputZ;
1995
2109
  type index$3_RateLimitConfig = RateLimitConfig;
@@ -2025,18 +2139,23 @@ declare const index$3_WsHandshakeDecisionZ: typeof WsHandshakeDecisionZ;
2025
2139
  type index$3_WsHandshakeInput = WsHandshakeInput;
2026
2140
  declare const index$3_WsHandshakeInputZ: typeof WsHandshakeInputZ;
2027
2141
  declare namespace index$3 {
2028
- export { type index$3_AccessProfile as AccessProfile, index$3_AccessProfileZ as AccessProfileZ, type index$3_AxisContext as AxisContext, index$3_AxisContextZ as AxisContextZ, type index$3_AxisError as AxisError, index$3_AxisErrorZ as AxisErrorZ, type index$3_BodyBudgetInput as BodyBudgetInput, index$3_BodyBudgetInputZ as BodyBudgetInputZ, type index$3_BodyBudgetPolicy as BodyBudgetPolicy, index$3_BodyBudgetPolicyZ as BodyBudgetPolicyZ, index$3_BodyProfile as BodyProfile, type index$3_BodyProfileValidation as BodyProfileValidation, index$3_BodyProfileValidator as BodyProfileValidator, index$3_BodyProfileZ as BodyProfileZ, type index$3_Capsule as Capsule, type index$3_CapsuleClaims as CapsuleClaims, index$3_CapsuleClaimsZ as CapsuleClaimsZ, type index$3_CapsuleValidationResult as CapsuleValidationResult, index$3_CapsuleValidationResultZ as CapsuleValidationResultZ, type index$3_CapsuleVerifyResult as CapsuleVerifyResult, index$3_CapsuleVerifyResultZ as CapsuleVerifyResultZ, type index$3_CapsuleVerifySensorInput as CapsuleVerifySensorInput, index$3_CapsuleVerifySensorInputZ as CapsuleVerifySensorInputZ, index$3_CapsuleZ as CapsuleZ, type index$3_ChunkHashInput as ChunkHashInput, index$3_ChunkHashInputZ as ChunkHashInputZ, type index$3_CountryBlockDecision as CountryBlockDecision, index$3_CountryBlockDecisionZ as CountryBlockDecisionZ, type index$3_CountryBlockSensorInput as CountryBlockSensorInput, index$3_CountryBlockSensorInputZ as CountryBlockSensorInputZ, type index$3_EntropySensorInput as EntropySensorInput, index$3_EntropySensorInputZ as EntropySensorInputZ, index$3_ExecutionMetricsZ as ExecutionMetricsZ, type index$3_IPReputation as IPReputation, type index$3_IPReputationInput as IPReputationInput, index$3_IPReputationInputZ as IPReputationInputZ, index$3_IPReputationZ as IPReputationZ, type index$3_IntentPolicy as IntentPolicy, type index$3_IntentPolicyDecision as IntentPolicyDecision, index$3_IntentPolicyDecisionZ as IntentPolicyDecisionZ, type index$3_IntentPolicySensorInput as IntentPolicySensorInput, index$3_IntentPolicySensorInputZ as IntentPolicySensorInputZ, index$3_IntentPolicyZ as IntentPolicyZ, type index$3_IntentSchema as IntentSchema, index$3_IntentSchemaZ as IntentSchemaZ, type index$3_Passport as Passport, index$3_PassportZ as PassportZ, type index$3_ProofKind as ProofKind, index$3_ProofKindZ as ProofKindZ, type index$3_ProofPresenceInput as ProofPresenceInput, index$3_ProofPresenceInputZ as ProofPresenceInputZ, index$3_ProofType as ProofType, type index$3_ProtocolStrictInput as ProtocolStrictInput, index$3_ProtocolStrictInputZ as ProtocolStrictInputZ, type index$3_RateLimitConfig as RateLimitConfig, index$3_RateLimitConfigZ as RateLimitConfigZ, type index$3_RateLimitInput as RateLimitInput, index$3_RateLimitInputZ as RateLimitInputZ, type index$3_RateLimitProfile as RateLimitProfile, index$3_RateLimitProfileZ as RateLimitProfileZ, type index$3_ScanBurstDecision as ScanBurstDecision, index$3_ScanBurstDecisionZ as ScanBurstDecisionZ, type index$3_ScanBurstSensorInput as ScanBurstSensorInput, index$3_ScanBurstSensorInputZ as ScanBurstSensorInputZ, type index$3_SchemaField as SchemaField, type index$3_SchemaFieldKind as SchemaFieldKind, index$3_SchemaFieldKindZ as SchemaFieldKindZ, index$3_SchemaFieldZ as SchemaFieldZ, type index$3_Scope as Scope, index$3_ScopeZ as ScopeZ, type index$3_SensitivityLevel as SensitivityLevel, index$3_SensitivityLevelZ as SensitivityLevelZ, type index$3_SensorChainInput as SensorChainInput, index$3_SensorChainInputZ as SensorChainInputZ, index$3_SensorDecisionWithMetadataZ as SensorDecisionWithMetadataZ, index$3_SensorDecisionZ as SensorDecisionZ, type index$3_SensorResult as SensorResult, index$3_SensorResultZ as SensorResultZ, type index$3_UploadSession as UploadSession, index$3_UploadSessionZ as UploadSessionZ, type index$3_UploadStatus as UploadStatus, index$3_UploadStatusZ as UploadStatusZ, type index$3_WsHandshakeDecision as WsHandshakeDecision, index$3_WsHandshakeDecisionZ as WsHandshakeDecisionZ, type index$3_WsHandshakeInput as WsHandshakeInput, index$3_WsHandshakeInputZ as WsHandshakeInputZ };
2142
+ export { type index$3_AccessProfile as AccessProfile, index$3_AccessProfileZ as AccessProfileZ, type index$3_AxisContext as AxisContext, index$3_AxisContextZ as AxisContextZ, type index$3_AxisError as AxisError, index$3_AxisErrorZ as AxisErrorZ, type index$3_BodyBudgetInput as BodyBudgetInput, index$3_BodyBudgetInputZ as BodyBudgetInputZ, type index$3_BodyBudgetPolicy as BodyBudgetPolicy, index$3_BodyBudgetPolicyZ as BodyBudgetPolicyZ, index$3_BodyProfile as BodyProfile, type index$3_BodyProfileValidation as BodyProfileValidation, index$3_BodyProfileValidator as BodyProfileValidator, index$3_BodyProfileZ as BodyProfileZ, type index$3_Capsule as Capsule, type index$3_CapsuleClaims as CapsuleClaims, index$3_CapsuleClaimsZ as CapsuleClaimsZ, type index$3_CapsuleValidationResult as CapsuleValidationResult, index$3_CapsuleValidationResultZ as CapsuleValidationResultZ, type index$3_CapsuleVerifyResult as CapsuleVerifyResult, index$3_CapsuleVerifyResultZ as CapsuleVerifyResultZ, type index$3_CapsuleVerifySensorInput as CapsuleVerifySensorInput, index$3_CapsuleVerifySensorInputZ as CapsuleVerifySensorInputZ, index$3_CapsuleZ as CapsuleZ, type index$3_ChunkHashInput as ChunkHashInput, index$3_ChunkHashInputZ as ChunkHashInputZ, type index$3_CountryBlockDecision as CountryBlockDecision, index$3_CountryBlockDecisionZ as CountryBlockDecisionZ, type index$3_CountryBlockSensorInput as CountryBlockSensorInput, index$3_CountryBlockSensorInputZ as CountryBlockSensorInputZ, type index$3_EntropySensorInput as EntropySensorInput, index$3_EntropySensorInputZ as EntropySensorInputZ, index$3_ExecutionMetricsZ as ExecutionMetricsZ, type index$3_IPReputation as IPReputation, type index$3_IPReputationInput as IPReputationInput, index$3_IPReputationInputZ as IPReputationInputZ, index$3_IPReputationZ as IPReputationZ, type index$3_IntentPolicy as IntentPolicy, type index$3_IntentPolicyDecision as IntentPolicyDecision, index$3_IntentPolicyDecisionZ as IntentPolicyDecisionZ, type index$3_IntentPolicySensorInput as IntentPolicySensorInput, index$3_IntentPolicySensorInputZ as IntentPolicySensorInputZ, index$3_IntentPolicyZ as IntentPolicyZ, type index$3_IntentSchema as IntentSchema, index$3_IntentSchemaZ as IntentSchemaZ, type index$3_Passport as Passport, index$3_PassportZ as PassportZ, type index$3_ProofKind as ProofKind, index$3_ProofKindZ as ProofKindZ, type index$3_ProofPresenceInput as ProofPresenceInput, index$3_ProofPresenceInputZ as ProofPresenceInputZ, ProofType$1 as ProofType, type index$3_ProtocolStrictInput as ProtocolStrictInput, index$3_ProtocolStrictInputZ as ProtocolStrictInputZ, type index$3_RateLimitConfig as RateLimitConfig, index$3_RateLimitConfigZ as RateLimitConfigZ, type index$3_RateLimitInput as RateLimitInput, index$3_RateLimitInputZ as RateLimitInputZ, type index$3_RateLimitProfile as RateLimitProfile, index$3_RateLimitProfileZ as RateLimitProfileZ, type index$3_ScanBurstDecision as ScanBurstDecision, index$3_ScanBurstDecisionZ as ScanBurstDecisionZ, type index$3_ScanBurstSensorInput as ScanBurstSensorInput, index$3_ScanBurstSensorInputZ as ScanBurstSensorInputZ, type index$3_SchemaField as SchemaField, type index$3_SchemaFieldKind as SchemaFieldKind, index$3_SchemaFieldKindZ as SchemaFieldKindZ, index$3_SchemaFieldZ as SchemaFieldZ, type index$3_Scope as Scope, index$3_ScopeZ as ScopeZ, type index$3_SensitivityLevel as SensitivityLevel, index$3_SensitivityLevelZ as SensitivityLevelZ, type index$3_SensorChainInput as SensorChainInput, index$3_SensorChainInputZ as SensorChainInputZ, index$3_SensorDecisionWithMetadataZ as SensorDecisionWithMetadataZ, index$3_SensorDecisionZ as SensorDecisionZ, type index$3_SensorResult as SensorResult, index$3_SensorResultZ as SensorResultZ, type index$3_UploadSession as UploadSession, index$3_UploadSessionZ as UploadSessionZ, type index$3_UploadStatus as UploadStatus, index$3_UploadStatusZ as UploadStatusZ, type index$3_WsHandshakeDecision as WsHandshakeDecision, index$3_WsHandshakeDecisionZ as WsHandshakeDecisionZ, type index$3_WsHandshakeInput as WsHandshakeInput, index$3_WsHandshakeInputZ as WsHandshakeInputZ };
2029
2143
  }
2030
2144
 
2145
+ type index$2_AxisSensorChainService = AxisSensorChainService;
2146
+ declare const index$2_AxisSensorChainService: typeof AxisSensorChainService;
2031
2147
  declare const index$2_CAPABILITIES: typeof CAPABILITIES;
2032
2148
  type index$2_Capability = Capability;
2149
+ type index$2_ChainResult = ChainResult;
2033
2150
  declare const index$2_INTENT_REQUIREMENTS: typeof INTENT_REQUIREMENTS;
2034
2151
  declare const index$2_PROOF_CAPABILITIES: typeof PROOF_CAPABILITIES;
2152
+ type index$2_SensorDecision = SensorDecision;
2153
+ type index$2_SensorInput = SensorInput;
2035
2154
  declare const index$2_canAccessResource: typeof canAccessResource;
2036
2155
  declare const index$2_hasScope: typeof hasScope;
2037
2156
  declare const index$2_parseScope: typeof parseScope;
2038
2157
  declare namespace index$2 {
2039
- export { index$2_CAPABILITIES as CAPABILITIES, type index$2_Capability as Capability, index$2_INTENT_REQUIREMENTS as INTENT_REQUIREMENTS, index$2_PROOF_CAPABILITIES as PROOF_CAPABILITIES, index$2_canAccessResource as canAccessResource, index$2_hasScope as hasScope, index$2_parseScope as parseScope };
2158
+ export { index$2_AxisSensorChainService as AxisSensorChainService, index$2_CAPABILITIES as CAPABILITIES, type index$2_Capability as Capability, type index$2_ChainResult as ChainResult, index$2_INTENT_REQUIREMENTS as INTENT_REQUIREMENTS, index$2_PROOF_CAPABILITIES as PROOF_CAPABILITIES, type index$2_SensorDecision as SensorDecision, type index$2_SensorInput as SensorInput, index$2_canAccessResource as canAccessResource, index$2_hasScope as hasScope, index$2_parseScope as parseScope };
2040
2159
  }
2041
2160
 
2042
2161
  declare class AccessProfileResolverSensor implements AxisSensor {
@@ -2257,4 +2376,4 @@ declare namespace index {
2257
2376
  export { index_encodeAxisTlvDto as encodeAxisTlvDto };
2258
2377
  }
2259
2378
 
2260
- export { ATS1_HDR, ATS1_SCHEMA, AXIS_OPCODES, AXIS_UPLOAD_FILE_STORE, AXIS_UPLOAD_RECEIPT_SIGNER, AXIS_UPLOAD_SESSION_STORE, ats1 as Ats1Codec, type Axis1DecodedFrame, type Axis1FrameToEncode, type AxisAlg$1 as AxisAlg, type AxisPacket as AxisBinaryPacket, type AxisCapsule, type AxisCapsuleConstraints, type AxisCapsulePayload, type AxisCrudHandler, type AxisEffect, AxisFilesDownloadHandler, AxisFilesFinalizeHandler, AxisFrame$2 as AxisFrame, type AxisHandler, type AxisHandlerInit, AxisIdDto, type AxisAlg as AxisJsonAlg, type AxisFrame$1 as AxisJsonFrame, type AxisResponse as AxisJsonResponse, type AxisSig as AxisJsonSig, type AxisObservedContext, type AxisPacket$1 as AxisPacket, T as AxisPacketTags, AxisPartialType, type AxisPostSensor, type AxisPreSensor, type AxisRequestContext, AxisResponseDto, type AxisSensor, type AxisSensorInit, type AxisSig$1 as AxisSig, AxisTlvDto, CAPABILITIES, type Capability, type CapsuleMode, ContractViolationError, DEFAULT_CONTRACTS, DEFAULT_TIMEOUT, Decision, DiskUploadFileStore, type DtoSchema, type ExecutionContract, ExecutionMeter, type ExecutionMetrics, FALLBACK_CONTRACT, HANDLER_METADATA_KEY, Handler, INTENT_BODY_KEY, INTENT_METADATA_KEY, INTENT_REQUIREMENTS, INTENT_ROUTES_KEY, INTENT_SENSITIVITY_MAP, INTENT_SENSORS_KEY, INTENT_TIMEOUTS, Intent, IntentBody, type IntentDefinition, type IntentKind, type IntentOptions, type IntentRoute, IntentRouter, IntentSensitivity, IntentSensors, type IntentTlvField, type KeyStatus, PROOF_CAPABILITIES, RESPONSE_TAG_CREATED_AT, RESPONSE_TAG_CREATED_BY, RESPONSE_TAG_ID, RESPONSE_TAG_UPDATED_AT, RESPONSE_TAG_UPDATED_BY, type ReceiptEffect, RiskDecision, type RiskEvaluation, type RiskSignal, Schema2002_PasskeyLoginOptionsRes, Schema2011_PasskeyLoginVerifyReq, Schema2012_PasskeyLoginVerifyRes, Schema2021_PasskeyRegisterOptionsReq, type SensorDecision, SensorDecisions, type SensorInput, type SensorMinifiedDecision, type SensorPhaseMetadata, TLV_FIELDS_KEY, TLV_VALIDATORS_KEY, TlvEnum, TlvField, type TlvFieldKind, type TlvFieldMeta, type TlvFieldOptions, TlvMinLen, TlvRange, TlvUtf8Pattern, TlvValidate, type TlvValidatorFn, type TlvValidatorMeta, type UploadFileStat, type UploadFileStore, type UploadReceiptSigner, type UploadSessionRecord, type UploadSessionStatus, type UploadSessionStore, axis1SigningBytes, b64urlDecode, b64urlDecodeString, b64urlEncode, b64urlEncodeString, buildAts1Hdr, buildDtoDecoder, buildPacket, buildReceiptHash, buildTLVs, bytes, canAccessResource, canonicalJson, canonicalJsonExcluding, classifyIntent, index$7 as crypto, decodeAxis1Frame, index$6 as decorators, encVarint, encodeAxis1Frame, index$5 as engine, extractDtoSchema, hasScope, isAdminOpcode, isKnownOpcode, isTimestampValid, index$4 as loom, nonce16, normalizeSensorDecision, packPasskeyLoginOptionsReq, packPasskeyLoginOptionsRes, packPasskeyLoginVerifyReq, packPasskeyLoginVerifyRes, packPasskeyRegisterOptionsReq, parseScope, resolveTimeout, index$3 as schemas, index$2 as security, sensitivityName, index$1 as sensors, tlv, u64be, unpackPasskeyLoginOptionsReq, unpackPasskeyLoginVerifyReq, unpackPasskeyRegisterOptionsReq, utf8, index as utils, validateFrameShape, varintU };
2379
+ export { ATS1_HDR, ATS1_SCHEMA, AXIS_OPCODES, AXIS_UPLOAD_FILE_STORE, AXIS_UPLOAD_RECEIPT_SIGNER, AXIS_UPLOAD_SESSION_STORE, ats1 as Ats1Codec, type Axis1DecodedFrame, type Axis1FrameToEncode, type AxisAlg$1 as AxisAlg, type AxisPacket as AxisBinaryPacket, type AxisCapsule, type AxisCapsuleConstraints, type AxisCapsulePayload, AxisContext$1 as AxisContext, type AxisCrudHandler, type AxisDecoded, AxisDemoPubkey, type AxisEffect, AxisFilesDownloadHandler, AxisFilesFinalizeHandler, AxisFrame$2 as AxisFrame, type AxisHandler, type AxisHandlerInit, AxisIdDto, AxisIp, type AxisAlg as AxisJsonAlg, type AxisFrame$1 as AxisJsonFrame, type AxisResponse as AxisJsonResponse, type AxisSig as AxisJsonSig, type AxisObservation, type AxisObservedContext, type AxisPacket$1 as AxisPacket, T as AxisPacketTags, AxisPartialType, type AxisPostSensor, type AxisPreSensor, AxisRaw, type AxisRequestContext, type AxisRequestData, AxisResponseDto, type AxisSensor, AxisSensorChainService, type AxisSensorInit, type AxisSig$1 as AxisSig, AxisTlvDto, BAND, CAPABILITIES, type Capability, type CapsuleMode, type ChainResult, ContractViolationError, DEFAULT_CONTRACTS, DEFAULT_TIMEOUT, Decision, DiskUploadFileStore, type DtoSchema, type ExecutionContract, ExecutionMeter, type ExecutionMetrics, FALLBACK_CONTRACT, HANDLER_METADATA_KEY, HANDLER_SENSORS_KEY, Handler, HandlerDiscoveryService, HandlerSensors, INTENT_BODY_KEY, INTENT_METADATA_KEY, INTENT_REQUIREMENTS, INTENT_ROUTES_KEY, INTENT_SENSITIVITY_MAP, INTENT_SENSORS_KEY, INTENT_TIMEOUTS, Intent, IntentBody, type IntentDefinition, type IntentKind, type IntentOptions, type IntentRoute, IntentRouter, IntentSensitivity, IntentSensors, type IntentTlvField, type KeyStatus, type ObservationQueueConfig, type ObservationQueueMessage, type ObservationSensor, type ObservationStage, type ObservationStreamEntry, type ObservationWitnessSummary, type ObserverVerdict, PRE_DECODE_BOUNDARY, PROOF_CAPABILITIES, RESPONSE_TAG_CREATED_AT, RESPONSE_TAG_CREATED_BY, RESPONSE_TAG_ID, RESPONSE_TAG_UPDATED_AT, RESPONSE_TAG_UPDATED_BY, type ReceiptEffect, type ResponseContract, type ResponseObserverContext, RiskDecision, type RiskEvaluation, type RiskSignal, SENSOR_METADATA_KEY, Schema2002_PasskeyLoginOptionsRes, Schema2011_PasskeyLoginVerifyReq, Schema2012_PasskeyLoginVerifyRes, Schema2021_PasskeyRegisterOptionsReq, Sensor, type SensorBand, type SensorDecision, SensorDecisions, SensorDiscoveryService, type SensorInput, type SensorMinifiedDecision, type SensorOptions, type SensorPhase, type SensorPhaseMetadata, SensorRegistry, TLV_FIELDS_KEY, TLV_VALIDATORS_KEY, TlvEnum, TlvField, type TlvFieldKind, type TlvFieldMeta, type TlvFieldOptions, TlvMinLen, TlvRange, TlvUtf8Pattern, TlvValidate, type TlvValidatorFn, type TlvValidatorMeta, type UnsignedObservationWitness, type UploadFileStat, type UploadFileStore, type UploadReceiptSigner, type UploadSessionRecord, type UploadSessionStatus, type UploadSessionStore, axis1SigningBytes, b64urlDecode, b64urlDecodeString, b64urlEncode, b64urlEncodeString, buildAts1Hdr, buildDtoDecoder, buildPacket, buildQueueMessage, buildReceiptHash, buildTLVs, buildUnsignedWitness, bytes, canAccessResource, canonicalJson, canonicalJsonExcluding, canonicalizeObservation, classifyIntent, createObservation, index$8 as crypto, decodeAxis1Frame, decodeQueueMessage, index$7 as decorators, encVarint, encodeAxis1Frame, encodeQueueMessage, endStage, index$5 as engine, extractDtoSchema, finalizeObservation, hasScope, hashObservation, isAdminOpcode, isKnownOpcode, isTimestampValid, index$4 as loom, nonce16, normalizeSensorDecision, packPasskeyLoginOptionsReq, packPasskeyLoginOptionsRes, packPasskeyLoginVerifyReq, packPasskeyLoginVerifyRes, packPasskeyRegisterOptionsReq, parseAutoClaimEntries, parseScope, parseStreamEntries, recordSensor, resolveTimeout, index$3 as schemas, index$2 as security, sensitivityName, index$1 as sensors, stableJsonStringify, startStage, tlv, u64be, unpackPasskeyLoginOptionsReq, unpackPasskeyLoginVerifyReq, unpackPasskeyRegisterOptionsReq, utf8, index as utils, validateFrameShape, varintU, verifyResponse };