@nextera.one/axis-server-sdk 1.2.0 → 1.3.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,7 +1,11 @@
1
- import { AxisFrame as AxisFrame$1 } from './core/index.js';
2
- export { AxisBinaryFrame, AxisFrameZ, computeReceiptHash, computeSignaturePayload, decodeFrame, encodeFrame, generateEd25519KeyPair, getSignTarget, sha256, signFrame, verifyFrameSignature } from './core/index.js';
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';
4
+ import { PROOF_LOOM, TLV_LOOM_PRESENCE_ID, TLV_LOOM_THREAD_HASH, TLV_LOOM_WRIT } from '@nextera.one/axis-protocol';
3
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';
4
- import 'zod';
6
+ import * as z from 'zod';
7
+ import { OnModuleInit, OnApplicationBootstrap } from '@nestjs/common';
8
+ import { ConfigService } from '@nestjs/config';
5
9
 
6
10
  declare const HANDLER_METADATA_KEY = "axis:handler";
7
11
  declare function Handler(intent?: string): ClassDecorator;
@@ -38,6 +42,12 @@ interface IntentOptions {
38
42
  }
39
43
  declare function Intent(action: string, options?: IntentOptions): MethodDecorator;
40
44
 
45
+ declare const INTENT_BODY_KEY = "axis:intent:body";
46
+ declare function IntentBody(decoder: (buf: Buffer) => any): MethodDecorator;
47
+
48
+ declare const INTENT_SENSORS_KEY = "axis:intent:sensors";
49
+ declare function IntentSensors(sensors: Function[]): MethodDecorator;
50
+
41
51
  declare const TLV_FIELDS_KEY = "axis:tlv:fields";
42
52
  declare const TLV_VALIDATORS_KEY = "axis:tlv:validators";
43
53
  type TlvFieldKind = 'utf8' | 'u64' | 'bytes' | 'bytes16' | 'bool' | 'obj' | 'arr';
@@ -95,6 +105,20 @@ declare abstract class AxisResponseDto extends AxisTlvDto {
95
105
  updated_by?: string;
96
106
  }
97
107
 
108
+ interface IntentSchema$1 {
109
+ intent: string;
110
+ version: number;
111
+ bodyProfile: 'TLV_MAP' | 'RAW' | 'TLV_OBJ' | 'TLV_ARR';
112
+ fields: Array<{
113
+ name: string;
114
+ tlv: number;
115
+ kind: IntentTlvField['kind'];
116
+ required?: boolean;
117
+ maxLen?: number;
118
+ max?: string;
119
+ scope?: 'header' | 'body';
120
+ }>;
121
+ }
98
122
  interface AxisEffect {
99
123
  ok: boolean;
100
124
  effect: string;
@@ -103,11 +127,34 @@ interface AxisEffect {
103
127
  metadata?: any;
104
128
  }
105
129
  declare class IntentRouter {
130
+ private readonly moduleRef?;
131
+ private readonly logger;
132
+ private static readonly BUILTIN_INTENTS;
106
133
  private handlers;
134
+ private intentSensors;
135
+ private intentDecoders;
136
+ private intentSchemas;
137
+ private intentValidators;
138
+ private intentKinds;
139
+ constructor(moduleRef?: ModuleRef | undefined);
140
+ getSchema(intent: string): IntentSchema$1 | undefined;
141
+ getValidators(intent: string): Map<number, TlvValidatorFn[]> | undefined;
142
+ has(intent: string): boolean;
143
+ getRegisteredIntents(): string[];
144
+ getIntentEntry(intent: string): {
145
+ schema?: IntentSchema$1;
146
+ validators?: Map<number, TlvValidatorFn[]>;
147
+ hasSensors: boolean;
148
+ builtin: boolean;
149
+ kind?: IntentKind;
150
+ } | null;
107
151
  register(intent: string, handler: any): void;
108
152
  registerHandler(instance: any): void;
109
- route(frame: AxisFrame$1): Promise<AxisEffect>;
110
- private recordLatency;
153
+ route(frame: AxisFrame$2): Promise<AxisEffect>;
154
+ private logIntent;
155
+ registerIntentMeta(intent: string, proto: object, methodName: string): void;
156
+ private runIntentSensors;
157
+ private storeSchema;
111
158
  }
112
159
 
113
160
  declare const ATS1_HDR: {
@@ -385,6 +432,7 @@ declare function canonicalJson(value: any): string;
385
432
  declare function canonicalJsonExcluding(obj: Record<string, any>, exclude: string[]): string;
386
433
 
387
434
  type AxisAlg$1 = 'EdDSA' | 'ES256' | 'RS256';
435
+ type CapsuleStatus = 'ACTIVE' | 'CONSUMED' | 'REVOKED' | 'EXPIRED';
388
436
  type CapsuleMode = 'SINGLE_USE' | 'MULTI_USE';
389
437
  type KeyStatus = 'ACTIVE' | 'GRACE' | 'REVOKED' | 'RETIRED';
390
438
  interface AxisSig$1 {
@@ -438,6 +486,40 @@ interface AxisCapsulePayload {
438
486
  constraints?: AxisCapsuleConstraints;
439
487
  meta?: Record<string, unknown>;
440
488
  }
489
+ interface AxisCapsule {
490
+ payload: AxisCapsulePayload;
491
+ sig: AxisSig$1;
492
+ }
493
+ interface CapsuleIssueBody {
494
+ intent: string;
495
+ audience: string;
496
+ scopes: string[];
497
+ subject?: string;
498
+ mode: CapsuleMode;
499
+ maxUses?: number;
500
+ expSeconds?: number;
501
+ constraints?: AxisCapsuleConstraints;
502
+ hints?: {
503
+ ip?: string;
504
+ ua?: string;
505
+ deviceId?: string;
506
+ geo?: string;
507
+ };
508
+ }
509
+ interface CapsuleBatchBody extends Omit<CapsuleIssueBody, 'mode' | 'maxUses'> {
510
+ count: number;
511
+ mode: 'SINGLE_USE';
512
+ }
513
+ interface IntentExecBody {
514
+ intent: string;
515
+ capsule: AxisCapsule;
516
+ execNonce?: string;
517
+ args: Record<string, any>;
518
+ }
519
+ interface CapsuleRevokeBody {
520
+ capsuleId: string;
521
+ reason: string;
522
+ }
441
523
  interface AxisResponse$1<T = any> {
442
524
  ok: boolean;
443
525
  pid: string;
@@ -447,6 +529,71 @@ interface AxisResponse$1<T = any> {
447
529
  data?: T;
448
530
  meta?: Record<string, unknown>;
449
531
  }
532
+ interface CapsuleIssueResult {
533
+ capsule: AxisCapsule;
534
+ }
535
+ interface CapsuleBatchResult {
536
+ capsules: AxisCapsule[];
537
+ }
538
+ interface ActorKeyRecord {
539
+ id: Buffer;
540
+ actor_id: string;
541
+ key_id: string;
542
+ algorithm: string;
543
+ public_key: Buffer;
544
+ purpose: string;
545
+ status: KeyStatus;
546
+ is_primary: boolean;
547
+ not_before: Date | null;
548
+ expires_at: Date | null;
549
+ rotated_from_key_id: string | null;
550
+ revoked_at: Date | null;
551
+ revocation_reason: string | null;
552
+ metadata: any;
553
+ created_at: Date;
554
+ updated_at: Date;
555
+ }
556
+ interface IssuerKeyRecord {
557
+ id: Buffer;
558
+ kid: string;
559
+ issuer_id: string;
560
+ alg: string;
561
+ public_key_pem: string;
562
+ status: KeyStatus;
563
+ not_before: Date | null;
564
+ not_after: Date | null;
565
+ fingerprint: string | null;
566
+ metadata: any;
567
+ created_at: Date;
568
+ updated_at: Date;
569
+ }
570
+ interface CapsuleRecord {
571
+ id: Buffer;
572
+ capsule_id: string;
573
+ actor_id: string;
574
+ intent: string;
575
+ audience: string;
576
+ issuer: string;
577
+ subject: string | null;
578
+ status: CapsuleStatus;
579
+ mode: CapsuleMode;
580
+ max_uses: number;
581
+ used_count: number;
582
+ iat: Date;
583
+ nbf: Date | null;
584
+ exp: Date;
585
+ scopes_json: any;
586
+ constraints_json: any;
587
+ policy_refs_json: any;
588
+ risk_score: number | null;
589
+ payload_hash: Buffer;
590
+ sig_alg: string;
591
+ sig_kid: string;
592
+ sig_value: Buffer;
593
+ created_at: Date;
594
+ updated_at: Date;
595
+ last_used_at: Date | null;
596
+ }
450
597
 
451
598
  declare class ContractViolationError extends Error {
452
599
  code: string;
@@ -527,7 +674,7 @@ type AxisAlg = Extract<AxisAlg$1, 'EdDSA'>;
527
674
  type AxisSig = AxisSig$1 & {
528
675
  alg: AxisAlg;
529
676
  };
530
- interface AxisFrame<T = any> {
677
+ interface AxisFrame$1<T = any> {
531
678
  v: 1;
532
679
  pid: string;
533
680
  nonce: string;
@@ -758,4 +905,1356 @@ interface IntentDefinition {
758
905
  declare function validateFrameShape(frame: any): boolean;
759
906
  declare function isTimestampValid(ts: number, skewSeconds?: number): boolean;
760
907
 
761
- export { ATS1_HDR, ATS1_SCHEMA, AXIS_OPCODES, ats1 as Ats1Codec, type Axis1DecodedFrame, type Axis1FrameToEncode, type AxisAlg$1 as AxisAlg, type AxisPacket as AxisBinaryPacket, type AxisCapsuleConstraints, type AxisCapsulePayload, type AxisCrudHandler, type AxisEffect, type AxisHandler, type AxisHandlerInit, AxisIdDto, type AxisAlg as AxisJsonAlg, type AxisFrame 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, type DtoSchema, type ExecutionContract, ExecutionMeter, type ExecutionMetrics, FALLBACK_CONTRACT, HANDLER_METADATA_KEY, Handler, INTENT_METADATA_KEY, INTENT_REQUIREMENTS, INTENT_ROUTES_KEY, INTENT_SENSITIVITY_MAP, INTENT_TIMEOUTS, Intent, type IntentDefinition, type IntentKind, type IntentOptions, type IntentRoute, IntentRouter, IntentSensitivity, 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, axis1SigningBytes, b64urlDecode, b64urlDecodeString, b64urlEncode, b64urlEncodeString, buildAts1Hdr, buildDtoDecoder, buildPacket, buildReceiptHash, buildTLVs, bytes, canAccessResource, canonicalJson, canonicalJsonExcluding, classifyIntent, decodeAxis1Frame, encVarint, encodeAxis1Frame, extractDtoSchema, hasScope, isAdminOpcode, isKnownOpcode, isTimestampValid, nonce16, normalizeSensorDecision, packPasskeyLoginOptionsReq, packPasskeyLoginOptionsRes, packPasskeyLoginVerifyReq, packPasskeyLoginVerifyRes, packPasskeyRegisterOptionsReq, parseScope, resolveTimeout, sensitivityName, tlv, u64be, unpackPasskeyLoginOptionsReq, unpackPasskeyLoginVerifyReq, unpackPasskeyRegisterOptionsReq, utf8, validateFrameShape, varintU };
908
+ type UploadSessionStatus = 'ACTIVE' | 'FINALIZING' | 'COMPLETE' | 'ABORTED';
909
+ interface UploadSessionRecord {
910
+ id?: string;
911
+ fileId: string;
912
+ filename?: string;
913
+ status: UploadSessionStatus | string;
914
+ totalSize?: number;
915
+ chunkSize?: number;
916
+ totalChunks?: number;
917
+ receivedBitmap?: Uint8Array | Buffer | null;
918
+ hashState?: Uint8Array | Buffer | null;
919
+ mimeType?: string | null;
920
+ version?: number;
921
+ }
922
+ interface UploadSessionStore {
923
+ findByFileId(fileId: string): Promise<UploadSessionRecord | null>;
924
+ updateStatus(fileId: string, status: UploadSessionStatus, hashState?: Uint8Array | Buffer | null): Promise<void>;
925
+ }
926
+ interface UploadReceiptSigner {
927
+ signActive(message: Uint8Array): {
928
+ kid: string;
929
+ sig: Uint8Array;
930
+ };
931
+ }
932
+ interface UploadFileStat {
933
+ path: string;
934
+ size: number;
935
+ }
936
+ interface UploadFileStore {
937
+ getFinalPath(fileId: string, filename?: string): string;
938
+ getTempPath(fileId: string): string;
939
+ statFinal(fileId: string, filename?: string): Promise<UploadFileStat>;
940
+ readFinalRange(fileId: string, filename: string | undefined, start: number, length: number): Promise<Buffer>;
941
+ hasTemp(fileId: string): Promise<boolean>;
942
+ moveTempToFinal(fileId: string, filename?: string): Promise<string>;
943
+ createTempReadStream(fileId: string): NodeJS.ReadableStream;
944
+ }
945
+
946
+ declare class AxisFilesDownloadHandler implements AxisHandler {
947
+ private readonly sessions;
948
+ private readonly files;
949
+ private readonly logger;
950
+ readonly name = "axis.files.download";
951
+ readonly open = true;
952
+ readonly description = "File download handler";
953
+ constructor(sessions: UploadSessionStore, files: UploadFileStore);
954
+ execute(body: Uint8Array, headers?: Map<number, Uint8Array>): Promise<any>;
955
+ }
956
+ declare class AxisFilesFinalizeHandler implements AxisHandler {
957
+ private readonly sessions;
958
+ private readonly files;
959
+ private readonly keyring?;
960
+ private readonly logger;
961
+ readonly name = "axis.files.finalize";
962
+ readonly open = false;
963
+ readonly description = "File upload finalization handler";
964
+ constructor(sessions: UploadSessionStore, files: UploadFileStore, keyring?: UploadReceiptSigner | undefined);
965
+ execute(body: Uint8Array, headers?: Map<number, Uint8Array>): Promise<any>;
966
+ }
967
+
968
+ declare const AXIS_UPLOAD_SESSION_STORE = "AXIS_UPLOAD_SESSION_STORE";
969
+ declare const AXIS_UPLOAD_FILE_STORE = "AXIS_UPLOAD_FILE_STORE";
970
+ declare const AXIS_UPLOAD_RECEIPT_SIGNER = "AXIS_UPLOAD_RECEIPT_SIGNER";
971
+
972
+ interface DiskUploadFileStoreOptions {
973
+ uploadDir: string;
974
+ chunkDir: string;
975
+ }
976
+ declare class DiskUploadFileStore implements UploadFileStore {
977
+ private readonly uploadDir;
978
+ private readonly chunkDir;
979
+ constructor(options: DiskUploadFileStoreOptions);
980
+ getFinalPath(fileId: string, filename?: string): string;
981
+ getTempPath(fileId: string): string;
982
+ statFinal(fileId: string, filename?: string): Promise<UploadFileStat>;
983
+ readFinalRange(fileId: string, filename: string | undefined, start: number, length: number): Promise<Buffer>;
984
+ hasTemp(fileId: string): Promise<boolean>;
985
+ moveTempToFinal(fileId: string, filename?: string): Promise<string>;
986
+ createTempReadStream(fileId: string): NodeJS.ReadableStream;
987
+ }
988
+
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
+ interface AxisRequestData {
1062
+ raw: Buffer;
1063
+ ip: string | undefined;
1064
+ preDecodeInput: any;
1065
+ frameBytesCount: number;
1066
+ }
1067
+ declare const AxisRaw: (...dataOrPipes: unknown[]) => ParameterDecorator;
1068
+ declare const AxisIp: (...dataOrPipes: unknown[]) => ParameterDecorator;
1069
+ declare const AxisContext$1: (...dataOrPipes: unknown[]) => ParameterDecorator;
1070
+ declare const AxisDemoPubkey: (...dataOrPipes: unknown[]) => ParameterDecorator;
1071
+ declare const AxisFrame: (...dataOrPipes: unknown[]) => ParameterDecorator;
1072
+
1073
+ declare const SENSOR_METADATA_KEY = "axis:sensor";
1074
+ type SensorPhase = 'PRE_DECODE' | 'POST_DECODE';
1075
+ interface SensorOptions {
1076
+ phase?: SensorPhase;
1077
+ }
1078
+ declare function Sensor(options?: SensorOptions): ClassDecorator;
1079
+
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 };
1120
+ }
1121
+
1122
+ declare const SensorDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
1123
+ action: z.ZodLiteral<"ALLOW">;
1124
+ meta: z.ZodOptional<z.ZodAny>;
1125
+ }, z.core.$strip>, z.ZodObject<{
1126
+ action: z.ZodLiteral<"DENY">;
1127
+ code: z.ZodString;
1128
+ reason: z.ZodOptional<z.ZodString>;
1129
+ meta: z.ZodOptional<z.ZodAny>;
1130
+ }, z.core.$strip>]>;
1131
+ declare const SensorDecisionWithMetadataZ: z.ZodUnion<readonly [z.ZodObject<{
1132
+ action: z.ZodLiteral<"ALLOW">;
1133
+ meta: z.ZodOptional<z.ZodAny>;
1134
+ }, z.core.$strip>, z.ZodObject<{
1135
+ action: z.ZodLiteral<"DENY">;
1136
+ code: z.ZodString;
1137
+ reason: z.ZodOptional<z.ZodString>;
1138
+ retryAfterMs: z.ZodOptional<z.ZodNumber>;
1139
+ meta: z.ZodOptional<z.ZodAny>;
1140
+ }, z.core.$strip>]>;
1141
+ declare const CountryBlockSensorInputZ: z.ZodObject<{
1142
+ ip: z.ZodString;
1143
+ country: z.ZodOptional<z.ZodString>;
1144
+ }, z.core.$strip>;
1145
+ type CountryBlockSensorInput = z.infer<typeof CountryBlockSensorInputZ>;
1146
+ declare const CountryBlockDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
1147
+ action: z.ZodLiteral<"ALLOW">;
1148
+ meta: z.ZodOptional<z.ZodAny>;
1149
+ }, z.core.$strip>, z.ZodObject<{
1150
+ action: z.ZodLiteral<"DENY">;
1151
+ code: z.ZodString;
1152
+ reason: z.ZodOptional<z.ZodString>;
1153
+ meta: z.ZodOptional<z.ZodAny>;
1154
+ }, z.core.$strip>]>;
1155
+ type CountryBlockDecision = z.infer<typeof CountryBlockDecisionZ>;
1156
+ declare const ScanBurstSensorInputZ: z.ZodObject<{
1157
+ ip: z.ZodString;
1158
+ isFailure: z.ZodOptional<z.ZodBoolean>;
1159
+ }, z.core.$strip>;
1160
+ type ScanBurstSensorInput = z.infer<typeof ScanBurstSensorInputZ>;
1161
+ declare const ScanBurstDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
1162
+ action: z.ZodLiteral<"ALLOW">;
1163
+ meta: z.ZodOptional<z.ZodAny>;
1164
+ }, z.core.$strip>, z.ZodObject<{
1165
+ action: z.ZodLiteral<"DENY">;
1166
+ code: z.ZodString;
1167
+ reason: z.ZodOptional<z.ZodString>;
1168
+ retryAfterMs: z.ZodOptional<z.ZodNumber>;
1169
+ meta: z.ZodOptional<z.ZodAny>;
1170
+ }, z.core.$strip>]>;
1171
+ type ScanBurstDecision = z.infer<typeof ScanBurstDecisionZ>;
1172
+ declare const ProofKindZ: z.ZodEnum<{
1173
+ NONE: "NONE";
1174
+ CAPSULE: "CAPSULE";
1175
+ PASSPORT: "PASSPORT";
1176
+ MTLS: "MTLS";
1177
+ JWT: "JWT";
1178
+ }>;
1179
+ type ProofKind = z.infer<typeof ProofKindZ>;
1180
+ declare const AccessProfileZ: z.ZodEnum<{
1181
+ PUBLIC: "PUBLIC";
1182
+ PARTNER: "PARTNER";
1183
+ INTERNAL: "INTERNAL";
1184
+ NODE: "NODE";
1185
+ }>;
1186
+ type AccessProfile = z.infer<typeof AccessProfileZ>;
1187
+ declare const ProofPresenceInputZ: z.ZodObject<{
1188
+ profile: z.ZodEnum<{
1189
+ PUBLIC: "PUBLIC";
1190
+ PARTNER: "PARTNER";
1191
+ INTERNAL: "INTERNAL";
1192
+ NODE: "NODE";
1193
+ }>;
1194
+ visibility: z.ZodEnum<{
1195
+ PUBLIC: "PUBLIC";
1196
+ GUARDED: "GUARDED";
1197
+ }>;
1198
+ requiredProof: z.ZodArray<z.ZodEnum<{
1199
+ NONE: "NONE";
1200
+ CAPSULE: "CAPSULE";
1201
+ PASSPORT: "PASSPORT";
1202
+ MTLS: "MTLS";
1203
+ JWT: "JWT";
1204
+ }>>;
1205
+ hasCapsule: z.ZodBoolean;
1206
+ hasPassportSignature: z.ZodBoolean;
1207
+ intent: z.ZodString;
1208
+ }, z.core.$strip>;
1209
+ type ProofPresenceInput = z.infer<typeof ProofPresenceInputZ>;
1210
+ declare const SensitivityLevelZ: z.ZodEnum<{
1211
+ LOW: "LOW";
1212
+ MEDIUM: "MEDIUM";
1213
+ HIGH: "HIGH";
1214
+ CRITICAL: "CRITICAL";
1215
+ }>;
1216
+ type SensitivityLevel = z.infer<typeof SensitivityLevelZ>;
1217
+ declare const IntentPolicyZ: z.ZodObject<{
1218
+ intent: z.ZodString;
1219
+ sensitivity: z.ZodEnum<{
1220
+ LOW: "LOW";
1221
+ MEDIUM: "MEDIUM";
1222
+ HIGH: "HIGH";
1223
+ CRITICAL: "CRITICAL";
1224
+ }>;
1225
+ maxFrameBytes: z.ZodNumber;
1226
+ maxHeaderBytes: z.ZodNumber;
1227
+ maxBodyBytes: z.ZodNumber;
1228
+ maxSigBytes: z.ZodOptional<z.ZodNumber>;
1229
+ rateLimitPerMinute: z.ZodOptional<z.ZodNumber>;
1230
+ rateLimitPerHour: z.ZodOptional<z.ZodNumber>;
1231
+ requiresSignature: z.ZodBoolean;
1232
+ requiresCapsule: z.ZodBoolean;
1233
+ timeoutMs: z.ZodNumber;
1234
+ }, z.core.$strip>;
1235
+ type IntentPolicy = z.infer<typeof IntentPolicyZ>;
1236
+ declare const IntentPolicySensorInputZ: z.ZodObject<{
1237
+ frame: z.ZodObject<{
1238
+ flags: z.ZodNumber;
1239
+ headers: z.ZodMap<z.ZodNumber, z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
1240
+ body: z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>;
1241
+ sig: z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>;
1242
+ }, z.core.$strip>;
1243
+ intent: z.ZodString;
1244
+ rawFrameSize: z.ZodNumber;
1245
+ }, z.core.$strip>;
1246
+ type IntentPolicySensorInput = z.infer<typeof IntentPolicySensorInputZ>;
1247
+ declare const IntentPolicyDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
1248
+ action: z.ZodLiteral<"ALLOW">;
1249
+ policy: z.ZodObject<{
1250
+ intent: z.ZodString;
1251
+ sensitivity: z.ZodEnum<{
1252
+ LOW: "LOW";
1253
+ MEDIUM: "MEDIUM";
1254
+ HIGH: "HIGH";
1255
+ CRITICAL: "CRITICAL";
1256
+ }>;
1257
+ maxFrameBytes: z.ZodNumber;
1258
+ maxHeaderBytes: z.ZodNumber;
1259
+ maxBodyBytes: z.ZodNumber;
1260
+ maxSigBytes: z.ZodOptional<z.ZodNumber>;
1261
+ rateLimitPerMinute: z.ZodOptional<z.ZodNumber>;
1262
+ rateLimitPerHour: z.ZodOptional<z.ZodNumber>;
1263
+ requiresSignature: z.ZodBoolean;
1264
+ requiresCapsule: z.ZodBoolean;
1265
+ timeoutMs: z.ZodNumber;
1266
+ }, z.core.$strip>;
1267
+ }, z.core.$strip>, z.ZodObject<{
1268
+ action: z.ZodLiteral<"DENY">;
1269
+ reason: z.ZodString;
1270
+ }, z.core.$strip>]>;
1271
+ type IntentPolicyDecision = z.infer<typeof IntentPolicyDecisionZ>;
1272
+ declare const CapsuleClaimsZ: z.ZodObject<{
1273
+ capsuleId: z.ZodString;
1274
+ allowIntents: z.ZodArray<z.ZodString>;
1275
+ limits: z.ZodOptional<z.ZodObject<{
1276
+ maxBodyBytes: z.ZodOptional<z.ZodNumber>;
1277
+ }, z.core.$strip>>;
1278
+ scopes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
1279
+ }, z.core.$strip>;
1280
+ type CapsuleClaims = z.infer<typeof CapsuleClaimsZ>;
1281
+ declare const CapsuleZ: z.ZodObject<{
1282
+ id: z.ZodString;
1283
+ claims: z.ZodObject<{
1284
+ capsuleId: z.ZodString;
1285
+ allowIntents: z.ZodArray<z.ZodString>;
1286
+ limits: z.ZodOptional<z.ZodObject<{
1287
+ maxBodyBytes: z.ZodOptional<z.ZodNumber>;
1288
+ }, z.core.$strip>>;
1289
+ scopes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
1290
+ }, z.core.$strip>;
1291
+ issuedAt: z.ZodNumber;
1292
+ expiresAt: z.ZodNumber;
1293
+ tier: z.ZodEnum<{
1294
+ FREE: "FREE";
1295
+ STANDARD: "STANDARD";
1296
+ PREMIUM: "PREMIUM";
1297
+ }>;
1298
+ }, z.core.$strip>;
1299
+ type Capsule = z.infer<typeof CapsuleZ>;
1300
+ declare const CapsuleValidationResultZ: z.ZodObject<{
1301
+ valid: z.ZodBoolean;
1302
+ capsule: z.ZodOptional<z.ZodObject<{
1303
+ id: z.ZodString;
1304
+ claims: z.ZodObject<{
1305
+ capsuleId: z.ZodString;
1306
+ allowIntents: z.ZodArray<z.ZodString>;
1307
+ limits: z.ZodOptional<z.ZodObject<{
1308
+ maxBodyBytes: z.ZodOptional<z.ZodNumber>;
1309
+ }, z.core.$strip>>;
1310
+ scopes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
1311
+ }, z.core.$strip>;
1312
+ issuedAt: z.ZodNumber;
1313
+ expiresAt: z.ZodNumber;
1314
+ tier: z.ZodEnum<{
1315
+ FREE: "FREE";
1316
+ STANDARD: "STANDARD";
1317
+ PREMIUM: "PREMIUM";
1318
+ }>;
1319
+ }, z.core.$strip>>;
1320
+ reason: z.ZodOptional<z.ZodString>;
1321
+ requiresStepUp: z.ZodOptional<z.ZodBoolean>;
1322
+ }, z.core.$strip>;
1323
+ type CapsuleValidationResult = z.infer<typeof CapsuleValidationResultZ>;
1324
+ declare const CapsuleVerifySensorInputZ: z.ZodObject<{
1325
+ headers: z.ZodMap<z.ZodNumber, z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
1326
+ intent: z.ZodString;
1327
+ ctx: z.ZodAny;
1328
+ }, z.core.$strip>;
1329
+ type CapsuleVerifySensorInput = z.infer<typeof CapsuleVerifySensorInputZ>;
1330
+ declare const CapsuleVerifyResultZ: z.ZodObject<{
1331
+ ok: z.ZodLiteral<true>;
1332
+ capsule: z.ZodObject<{
1333
+ id: z.ZodString;
1334
+ claims: z.ZodObject<{
1335
+ capsuleId: z.ZodString;
1336
+ allowIntents: z.ZodArray<z.ZodString>;
1337
+ limits: z.ZodOptional<z.ZodObject<{
1338
+ maxBodyBytes: z.ZodOptional<z.ZodNumber>;
1339
+ }, z.core.$strip>>;
1340
+ scopes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
1341
+ }, z.core.$strip>;
1342
+ issuedAt: z.ZodNumber;
1343
+ expiresAt: z.ZodNumber;
1344
+ tier: z.ZodEnum<{
1345
+ FREE: "FREE";
1346
+ STANDARD: "STANDARD";
1347
+ PREMIUM: "PREMIUM";
1348
+ }>;
1349
+ }, z.core.$strip>;
1350
+ }, z.core.$strip>;
1351
+ type CapsuleVerifyResult = z.infer<typeof CapsuleVerifyResultZ>;
1352
+ declare const RateLimitProfileZ: z.ZodEnum<{
1353
+ PUBLIC: "PUBLIC";
1354
+ PARTNER: "PARTNER";
1355
+ INTERNAL: "INTERNAL";
1356
+ NODE: "NODE";
1357
+ }>;
1358
+ type RateLimitProfile = z.infer<typeof RateLimitProfileZ>;
1359
+ declare const RateLimitInputZ: z.ZodObject<{
1360
+ ip: z.ZodString;
1361
+ userAgent: z.ZodOptional<z.ZodString>;
1362
+ actorId: z.ZodOptional<z.ZodString>;
1363
+ capsuleId: z.ZodOptional<z.ZodString>;
1364
+ intent: z.ZodString;
1365
+ profile: z.ZodEnum<{
1366
+ PUBLIC: "PUBLIC";
1367
+ PARTNER: "PARTNER";
1368
+ INTERNAL: "INTERNAL";
1369
+ NODE: "NODE";
1370
+ }>;
1371
+ }, z.core.$strip>;
1372
+ type RateLimitInput = z.infer<typeof RateLimitInputZ>;
1373
+ declare const RateLimitConfigZ: z.ZodObject<{
1374
+ windowSec: z.ZodNumber;
1375
+ max: z.ZodNumber;
1376
+ key: z.ZodEnum<{
1377
+ ip_fingerprint: "ip_fingerprint";
1378
+ actor_capsule: "actor_capsule";
1379
+ }>;
1380
+ }, z.core.$strip>;
1381
+ type RateLimitConfig = z.infer<typeof RateLimitConfigZ>;
1382
+ declare const SensorResultZ: z.ZodObject<{
1383
+ ok: z.ZodLiteral<true>;
1384
+ }, z.core.$strip>;
1385
+ type SensorResult = z.infer<typeof SensorResultZ>;
1386
+ declare const PassportZ: z.ZodObject<{
1387
+ id: z.ZodString;
1388
+ public_key: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1389
+ status: z.ZodEnum<{
1390
+ ACTIVE: "ACTIVE";
1391
+ REVOKED: "REVOKED";
1392
+ EXPIRED: "EXPIRED";
1393
+ PENDING: "PENDING";
1394
+ }>;
1395
+ issuedAt: z.ZodNumber;
1396
+ expiresAt: z.ZodOptional<z.ZodNumber>;
1397
+ }, z.core.$strip>;
1398
+ declare const ExecutionMetricsZ: z.ZodObject<{
1399
+ dbWrites: z.ZodNumber;
1400
+ dbReads: z.ZodNumber;
1401
+ externalCalls: z.ZodNumber;
1402
+ elapsedMs: z.ZodOptional<z.ZodNumber>;
1403
+ }, z.core.$strip>;
1404
+ type Passport = z.infer<typeof PassportZ>;
1405
+ declare const SensorChainInputZ: z.ZodObject<{
1406
+ ip: z.ZodString;
1407
+ path: z.ZodString;
1408
+ contentLength: z.ZodNumber;
1409
+ peek: z.ZodCustom<Uint8Array<ArrayBuffer>, Uint8Array<ArrayBuffer>>;
1410
+ country: z.ZodOptional<z.ZodString>;
1411
+ }, z.core.$strip>;
1412
+ type SensorChainInput = z.infer<typeof SensorChainInputZ>;
1413
+ declare const EntropySensorInputZ: z.ZodObject<{
1414
+ pid: z.ZodOptional<z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>>;
1415
+ nonce: z.ZodOptional<z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>>;
1416
+ ip: z.ZodString;
1417
+ }, z.core.$strip>;
1418
+ type EntropySensorInput = z.infer<typeof EntropySensorInputZ>;
1419
+ declare const ProtocolStrictInputZ: z.ZodObject<{
1420
+ rawBytes: z.ZodOptional<z.ZodUnion<readonly [z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>, z.ZodCustom<Uint8Array<ArrayBuffer>, Uint8Array<ArrayBuffer>>]>>;
1421
+ ip: z.ZodString;
1422
+ path: z.ZodString;
1423
+ contentLength: z.ZodNumber;
1424
+ peek: z.ZodCustom<Uint8Array<ArrayBuffer>, Uint8Array<ArrayBuffer>>;
1425
+ country: z.ZodOptional<z.ZodString>;
1426
+ contentType: z.ZodOptional<z.ZodString>;
1427
+ }, z.core.$strip>;
1428
+ type ProtocolStrictInput = z.infer<typeof ProtocolStrictInputZ>;
1429
+ declare const SchemaFieldKindZ: z.ZodEnum<{
1430
+ utf8: "utf8";
1431
+ u64: "u64";
1432
+ bytes: "bytes";
1433
+ bytes16: "bytes16";
1434
+ bool: "bool";
1435
+ obj: "obj";
1436
+ arr: "arr";
1437
+ }>;
1438
+ type SchemaFieldKind = z.infer<typeof SchemaFieldKindZ>;
1439
+ declare const ScopeZ: z.ZodEnum<{
1440
+ header: "header";
1441
+ body: "body";
1442
+ }>;
1443
+ type Scope = z.infer<typeof ScopeZ>;
1444
+ declare const SchemaFieldZ: z.ZodObject<{
1445
+ name: z.ZodString;
1446
+ tlv: z.ZodNumber;
1447
+ kind: z.ZodEnum<{
1448
+ utf8: "utf8";
1449
+ u64: "u64";
1450
+ bytes: "bytes";
1451
+ bytes16: "bytes16";
1452
+ bool: "bool";
1453
+ obj: "obj";
1454
+ arr: "arr";
1455
+ }>;
1456
+ required: z.ZodOptional<z.ZodBoolean>;
1457
+ maxLen: z.ZodOptional<z.ZodNumber>;
1458
+ max: z.ZodOptional<z.ZodString>;
1459
+ scope: z.ZodOptional<z.ZodEnum<{
1460
+ header: "header";
1461
+ body: "body";
1462
+ }>>;
1463
+ }, z.core.$strip>;
1464
+ type SchemaField = z.infer<typeof SchemaFieldZ>;
1465
+ declare const BodyProfileZ: z.ZodEnum<{
1466
+ TLV_MAP: "TLV_MAP";
1467
+ RAW: "RAW";
1468
+ TLV_OBJ: "TLV_OBJ";
1469
+ TLV_ARR: "TLV_ARR";
1470
+ }>;
1471
+ declare const IntentSchemaZ: z.ZodObject<{
1472
+ intent: z.ZodString;
1473
+ version: z.ZodNumber;
1474
+ bodyProfile: z.ZodEnum<{
1475
+ TLV_MAP: "TLV_MAP";
1476
+ RAW: "RAW";
1477
+ TLV_OBJ: "TLV_OBJ";
1478
+ TLV_ARR: "TLV_ARR";
1479
+ }>;
1480
+ fields: z.ZodArray<z.ZodObject<{
1481
+ name: z.ZodString;
1482
+ tlv: z.ZodNumber;
1483
+ kind: z.ZodEnum<{
1484
+ utf8: "utf8";
1485
+ u64: "u64";
1486
+ bytes: "bytes";
1487
+ bytes16: "bytes16";
1488
+ bool: "bool";
1489
+ obj: "obj";
1490
+ arr: "arr";
1491
+ }>;
1492
+ required: z.ZodOptional<z.ZodBoolean>;
1493
+ maxLen: z.ZodOptional<z.ZodNumber>;
1494
+ max: z.ZodOptional<z.ZodString>;
1495
+ scope: z.ZodOptional<z.ZodEnum<{
1496
+ header: "header";
1497
+ body: "body";
1498
+ }>>;
1499
+ }, z.core.$strip>>;
1500
+ }, z.core.$strip>;
1501
+ type IntentSchema = z.infer<typeof IntentSchemaZ>;
1502
+ declare const WsHandshakeInputZ: z.ZodObject<{
1503
+ clientId: z.ZodString;
1504
+ isWs: z.ZodBoolean;
1505
+ ip: z.ZodString;
1506
+ }, z.core.$strip>;
1507
+ type WsHandshakeInput = z.infer<typeof WsHandshakeInputZ>;
1508
+ declare const WsHandshakeDecisionZ: z.ZodUnion<readonly [z.ZodObject<{
1509
+ action: z.ZodLiteral<"ALLOW">;
1510
+ }, z.core.$strip>, z.ZodObject<{
1511
+ action: z.ZodLiteral<"DENY">;
1512
+ code: z.ZodString;
1513
+ }, z.core.$strip>]>;
1514
+ type WsHandshakeDecision = z.infer<typeof WsHandshakeDecisionZ>;
1515
+ declare const IPReputationInputZ: z.ZodObject<{
1516
+ ip: z.ZodString;
1517
+ }, z.core.$strip>;
1518
+ type IPReputationInput = z.infer<typeof IPReputationInputZ>;
1519
+ declare const IPReputationZ: z.ZodObject<{
1520
+ score: z.ZodNumber;
1521
+ lastUpdated: z.ZodNumber;
1522
+ totalRequests: z.ZodNumber;
1523
+ failedRequests: z.ZodNumber;
1524
+ blockedRequests: z.ZodNumber;
1525
+ tags: z.ZodArray<z.ZodString>;
1526
+ }, z.core.$strip>;
1527
+ type IPReputation = z.infer<typeof IPReputationZ>;
1528
+ declare const UploadStatusZ: z.ZodEnum<{
1529
+ FINALIZING: "FINALIZING";
1530
+ ABORTED: "ABORTED";
1531
+ INIT: "INIT";
1532
+ UPLOADING: "UPLOADING";
1533
+ DONE: "DONE";
1534
+ }>;
1535
+ type UploadStatus = z.infer<typeof UploadStatusZ>;
1536
+ declare const UploadSessionZ: z.ZodObject<{
1537
+ uploadIdHex: z.ZodString;
1538
+ fileName: z.ZodString;
1539
+ totalSize: z.ZodNumber;
1540
+ chunkSize: z.ZodNumber;
1541
+ totalChunks: z.ZodNumber;
1542
+ receivedCount: z.ZodNumber;
1543
+ status: z.ZodEnum<{
1544
+ FINALIZING: "FINALIZING";
1545
+ ABORTED: "ABORTED";
1546
+ INIT: "INIT";
1547
+ UPLOADING: "UPLOADING";
1548
+ DONE: "DONE";
1549
+ }>;
1550
+ }, z.core.$strip>;
1551
+ type UploadSession = z.infer<typeof UploadSessionZ>;
1552
+ declare const BodyBudgetInputZ: z.ZodObject<{
1553
+ intent: z.ZodString;
1554
+ headerLen: z.ZodNumber;
1555
+ bodyLen: z.ZodNumber;
1556
+ }, z.core.$strip>;
1557
+ type BodyBudgetInput = z.infer<typeof BodyBudgetInputZ>;
1558
+ declare const BodyBudgetPolicyZ: z.ZodObject<{
1559
+ maxHeaderBytes: z.ZodNumber;
1560
+ maxBodyBytes: z.ZodNumber;
1561
+ }, z.core.$strip>;
1562
+ type BodyBudgetPolicy = z.infer<typeof BodyBudgetPolicyZ>;
1563
+ declare const ChunkHashInputZ: z.ZodObject<{
1564
+ headerTLVs: z.ZodAny;
1565
+ bodyBytes: z.ZodAny;
1566
+ intent: z.ZodString;
1567
+ }, z.core.$strip>;
1568
+ type ChunkHashInput = z.infer<typeof ChunkHashInputZ>;
1569
+ declare enum ProofType {
1570
+ CAPSULE = 1,
1571
+ JWT = 2,
1572
+ MTLS_ID = 3,
1573
+ DEVICE_SE = 4,
1574
+ WITNESS_SIG = 5
1575
+ }
1576
+ declare const AxisContextZ: z.ZodObject<{
1577
+ pid: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1578
+ ts: z.ZodBigInt;
1579
+ intent: z.ZodString;
1580
+ actorId: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1581
+ proofType: z.ZodEnum<typeof ProofType>;
1582
+ proofRef: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1583
+ nonce: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1584
+ ip: z.ZodString;
1585
+ nodeCertHash: z.ZodOptional<z.ZodString>;
1586
+ capsule: z.ZodOptional<z.ZodObject<{
1587
+ id: z.ZodString;
1588
+ claims: z.ZodObject<{
1589
+ capsuleId: z.ZodString;
1590
+ allowIntents: z.ZodArray<z.ZodString>;
1591
+ limits: z.ZodOptional<z.ZodObject<{
1592
+ maxBodyBytes: z.ZodOptional<z.ZodNumber>;
1593
+ }, z.core.$strip>>;
1594
+ scopes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
1595
+ }, z.core.$strip>;
1596
+ issuedAt: z.ZodNumber;
1597
+ expiresAt: z.ZodNumber;
1598
+ tier: z.ZodEnum<{
1599
+ FREE: "FREE";
1600
+ STANDARD: "STANDARD";
1601
+ PREMIUM: "PREMIUM";
1602
+ }>;
1603
+ }, z.core.$strip>>;
1604
+ passport: z.ZodOptional<z.ZodObject<{
1605
+ id: z.ZodString;
1606
+ public_key: z.ZodCustom<Buffer<ArrayBufferLike>, Buffer<ArrayBufferLike>>;
1607
+ status: z.ZodEnum<{
1608
+ ACTIVE: "ACTIVE";
1609
+ REVOKED: "REVOKED";
1610
+ EXPIRED: "EXPIRED";
1611
+ PENDING: "PENDING";
1612
+ }>;
1613
+ issuedAt: z.ZodNumber;
1614
+ expiresAt: z.ZodOptional<z.ZodNumber>;
1615
+ }, z.core.$strip>>;
1616
+ meter: z.ZodOptional<z.ZodAny>;
1617
+ }, z.core.$strip>;
1618
+ type AxisContext = z.infer<typeof AxisContextZ>;
1619
+ declare const AxisErrorZ: z.ZodObject<{
1620
+ code: z.ZodString;
1621
+ message: z.ZodString;
1622
+ httpStatus: z.ZodNumber;
1623
+ }, z.core.$strip>;
1624
+ type AxisError = z.infer<typeof AxisErrorZ>;
1625
+
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
+ interface AxisDecoded {
1667
+ frame: Axis1DecodedFrame;
1668
+ packet: AxisPacket;
1669
+ axisCtx: AxisContext;
1670
+ correlationId: Buffer;
1671
+ correlationIdHex: string;
1672
+ sensorInput: SensorInput;
1673
+ extra: {
1674
+ ip?: string;
1675
+ demoPubkeyHex?: string;
1676
+ };
1677
+ observation: AxisObservation;
1678
+ }
1679
+
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;
1687
+ }
1688
+
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;
1703
+ 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;
1716
+ }
1717
+
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;
1725
+ }
1726
+
1727
+ type index$5_AxisDecoded = AxisDecoded;
1728
+ type index$5_AxisEffect = AxisEffect;
1729
+ type index$5_AxisObservation = AxisObservation;
1730
+ declare const index$5_BAND: typeof BAND;
1731
+ type index$5_HandlerDiscoveryService = HandlerDiscoveryService;
1732
+ declare const index$5_HandlerDiscoveryService: typeof HandlerDiscoveryService;
1733
+ type index$5_IntentRouter = IntentRouter;
1734
+ declare const index$5_IntentRouter: typeof IntentRouter;
1735
+ type index$5_ObservationSensor = ObservationSensor;
1736
+ type index$5_ObservationStage = ObservationStage;
1737
+ declare const index$5_PRE_DECODE_BOUNDARY: typeof PRE_DECODE_BOUNDARY;
1738
+ type index$5_SensorBand = SensorBand;
1739
+ type index$5_SensorDiscoveryService = SensorDiscoveryService;
1740
+ declare const index$5_SensorDiscoveryService: typeof SensorDiscoveryService;
1741
+ type index$5_SensorRegistry = SensorRegistry;
1742
+ declare const index$5_SensorRegistry: typeof SensorRegistry;
1743
+ declare const index$5_createObservation: typeof createObservation;
1744
+ declare const index$5_endStage: typeof endStage;
1745
+ declare const index$5_finalizeObservation: typeof finalizeObservation;
1746
+ declare const index$5_recordSensor: typeof recordSensor;
1747
+ declare const index$5_startStage: typeof startStage;
1748
+ 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 };
1750
+ }
1751
+
1752
+ interface PresenceDeclaration {
1753
+ softid: string;
1754
+ device_meta?: {
1755
+ fingerprint?: string;
1756
+ platform?: string;
1757
+ user_agent?: string;
1758
+ };
1759
+ }
1760
+ interface PresenceChallenge {
1761
+ challenge_id: string;
1762
+ nonce: string;
1763
+ temporal_anchor: number;
1764
+ ttl_ms: number;
1765
+ expires_at: number;
1766
+ }
1767
+ interface PresenceProof {
1768
+ challenge_id: string;
1769
+ signature: string;
1770
+ public_key: string;
1771
+ kid?: string;
1772
+ }
1773
+ interface PresenceReceipt {
1774
+ presence_id: string;
1775
+ softid: string;
1776
+ anchor_reflection: string;
1777
+ scope: {
1778
+ ip?: string;
1779
+ device_fingerprint?: string;
1780
+ };
1781
+ issued_at: number;
1782
+ expires_at: number;
1783
+ renewed_at?: number;
1784
+ }
1785
+ type PresenceStatus = 'active' | 'expired' | 'revoked';
1786
+ interface WritHead {
1787
+ tid: string;
1788
+ seq: number;
1789
+ }
1790
+ interface WritBody {
1791
+ who: string;
1792
+ act: string;
1793
+ res: string;
1794
+ law: string;
1795
+ }
1796
+ interface WritMeta {
1797
+ iat: number;
1798
+ exp: number;
1799
+ prev: string;
1800
+ }
1801
+ interface WritSignature {
1802
+ alg: 'ed25519';
1803
+ value: string;
1804
+ kid?: string;
1805
+ }
1806
+ interface Writ {
1807
+ head: WritHead;
1808
+ body: WritBody;
1809
+ meta: WritMeta;
1810
+ sig: WritSignature;
1811
+ }
1812
+ type GrantType = 'sovereign' | 'delegated' | 'system';
1813
+ interface GrantCapability {
1814
+ oec: string;
1815
+ scope: string;
1816
+ limit?: {
1817
+ rate?: string;
1818
+ amount?: number;
1819
+ depth?: string;
1820
+ };
1821
+ }
1822
+ interface GrantMeta {
1823
+ iat: number;
1824
+ exp: number;
1825
+ revocable: boolean;
1826
+ version: number;
1827
+ contract_ref?: string;
1828
+ }
1829
+ interface Grant {
1830
+ grant_id: string;
1831
+ issuer: string;
1832
+ subject: string;
1833
+ grant_type: GrantType;
1834
+ caps: GrantCapability[];
1835
+ meta: GrantMeta;
1836
+ sig: WritSignature;
1837
+ }
1838
+ type GrantStatus = 'active' | 'revoked' | 'expired';
1839
+ interface LoomReceipt {
1840
+ receipt_id: string;
1841
+ writ_hash: string;
1842
+ thread_id: string;
1843
+ sequence: number;
1844
+ effect: string;
1845
+ hash: string;
1846
+ prev_hash: string | null;
1847
+ executed_at: number;
1848
+ metadata?: Record<string, unknown>;
1849
+ }
1850
+ interface ThreadState {
1851
+ thread_id: string;
1852
+ softid: string;
1853
+ last_receipt_hash: string;
1854
+ sequence: number;
1855
+ updated_at: number;
1856
+ }
1857
+ type RevocationTargetType = 'grant' | 'presence' | 'softid';
1858
+ interface Revocation {
1859
+ revocation_id: string;
1860
+ target_type: RevocationTargetType;
1861
+ target_id: string;
1862
+ issuer_softid: string;
1863
+ reason?: string;
1864
+ effective_at: number;
1865
+ sig_value: string;
1866
+ }
1867
+ interface LoomValidationResult {
1868
+ valid: boolean;
1869
+ error?: string;
1870
+ code?: string;
1871
+ }
1872
+ interface PresenceVerifyResult extends LoomValidationResult {
1873
+ presence?: PresenceReceipt;
1874
+ }
1875
+ interface WritValidationResult extends LoomValidationResult {
1876
+ writ?: Writ;
1877
+ gate_failed?: 'temporal' | 'causal' | 'legal' | 'authentic';
1878
+ }
1879
+ interface GrantValidationResult extends LoomValidationResult {
1880
+ grant?: Grant;
1881
+ }
1882
+
1883
+ declare function deriveAnchorReflection(softid: string, context?: string, scope?: string): string;
1884
+ declare function canonicalizeWrit(writ: Omit<Writ, 'sig'>): string;
1885
+ declare function canonicalizeGrant(grant: Omit<Grant, 'sig'>): string;
1886
+
1887
+ type index$4_Grant = Grant;
1888
+ type index$4_GrantCapability = GrantCapability;
1889
+ type index$4_GrantMeta = GrantMeta;
1890
+ type index$4_GrantStatus = GrantStatus;
1891
+ type index$4_GrantType = GrantType;
1892
+ type index$4_GrantValidationResult = GrantValidationResult;
1893
+ type index$4_LoomReceipt = LoomReceipt;
1894
+ type index$4_LoomValidationResult = LoomValidationResult;
1895
+ declare const index$4_PROOF_LOOM: typeof PROOF_LOOM;
1896
+ type index$4_PresenceChallenge = PresenceChallenge;
1897
+ type index$4_PresenceDeclaration = PresenceDeclaration;
1898
+ type index$4_PresenceProof = PresenceProof;
1899
+ type index$4_PresenceReceipt = PresenceReceipt;
1900
+ type index$4_PresenceStatus = PresenceStatus;
1901
+ type index$4_PresenceVerifyResult = PresenceVerifyResult;
1902
+ type index$4_Revocation = Revocation;
1903
+ type index$4_RevocationTargetType = RevocationTargetType;
1904
+ type index$4_ThreadState = ThreadState;
1905
+ type index$4_Writ = Writ;
1906
+ type index$4_WritBody = WritBody;
1907
+ type index$4_WritHead = WritHead;
1908
+ type index$4_WritMeta = WritMeta;
1909
+ type index$4_WritSignature = WritSignature;
1910
+ type index$4_WritValidationResult = WritValidationResult;
1911
+ declare const index$4_canonicalizeGrant: typeof canonicalizeGrant;
1912
+ declare const index$4_canonicalizeWrit: typeof canonicalizeWrit;
1913
+ declare const index$4_deriveAnchorReflection: typeof deriveAnchorReflection;
1914
+ declare namespace index$4 {
1915
+ export { type index$4_Grant as Grant, type index$4_GrantCapability as GrantCapability, type index$4_GrantMeta as GrantMeta, type index$4_GrantStatus as GrantStatus, type index$4_GrantType as GrantType, type index$4_GrantValidationResult as GrantValidationResult, type index$4_LoomReceipt as LoomReceipt, type index$4_LoomValidationResult as LoomValidationResult, index$4_PROOF_LOOM as PROOF_LOOM, type index$4_PresenceChallenge as PresenceChallenge, type index$4_PresenceDeclaration as PresenceDeclaration, type index$4_PresenceProof as PresenceProof, type index$4_PresenceReceipt as PresenceReceipt, type index$4_PresenceStatus as PresenceStatus, type index$4_PresenceVerifyResult as PresenceVerifyResult, type index$4_Revocation as Revocation, type index$4_RevocationTargetType as RevocationTargetType, TLV_LOOM_PRESENCE_ID as TLV_PRESENCE_ID, TLV_LOOM_THREAD_HASH as TLV_THREAD_HASH, TLV_LOOM_WRIT as TLV_WRIT, type index$4_ThreadState as ThreadState, type index$4_Writ as Writ, type index$4_WritBody as WritBody, type index$4_WritHead as WritHead, type index$4_WritMeta as WritMeta, type index$4_WritSignature as WritSignature, type index$4_WritValidationResult as WritValidationResult, index$4_canonicalizeGrant as canonicalizeGrant, index$4_canonicalizeWrit as canonicalizeWrit, index$4_deriveAnchorReflection as deriveAnchorReflection };
1916
+ }
1917
+
1918
+ declare enum BodyProfile {
1919
+ RAW = 0,
1920
+ TLV_MAP = 1,
1921
+ OBJ = 2,
1922
+ ARR = 3
1923
+ }
1924
+ interface BodyProfileValidation {
1925
+ valid: boolean;
1926
+ error?: string;
1927
+ profile: BodyProfile;
1928
+ }
1929
+ declare class BodyProfileValidator {
1930
+ private readonly logger;
1931
+ validate(body: Uint8Array, profile: BodyProfile): BodyProfileValidation;
1932
+ private validateRaw;
1933
+ private validateTlvMap;
1934
+ private validateObj;
1935
+ private validateArr;
1936
+ }
1937
+
1938
+ type index$3_AccessProfile = AccessProfile;
1939
+ declare const index$3_AccessProfileZ: typeof AccessProfileZ;
1940
+ type index$3_AxisContext = AxisContext;
1941
+ declare const index$3_AxisContextZ: typeof AxisContextZ;
1942
+ type index$3_AxisError = AxisError;
1943
+ declare const index$3_AxisErrorZ: typeof AxisErrorZ;
1944
+ type index$3_BodyBudgetInput = BodyBudgetInput;
1945
+ declare const index$3_BodyBudgetInputZ: typeof BodyBudgetInputZ;
1946
+ type index$3_BodyBudgetPolicy = BodyBudgetPolicy;
1947
+ declare const index$3_BodyBudgetPolicyZ: typeof BodyBudgetPolicyZ;
1948
+ type index$3_BodyProfile = BodyProfile;
1949
+ declare const index$3_BodyProfile: typeof BodyProfile;
1950
+ type index$3_BodyProfileValidation = BodyProfileValidation;
1951
+ type index$3_BodyProfileValidator = BodyProfileValidator;
1952
+ declare const index$3_BodyProfileValidator: typeof BodyProfileValidator;
1953
+ declare const index$3_BodyProfileZ: typeof BodyProfileZ;
1954
+ type index$3_Capsule = Capsule;
1955
+ type index$3_CapsuleClaims = CapsuleClaims;
1956
+ declare const index$3_CapsuleClaimsZ: typeof CapsuleClaimsZ;
1957
+ type index$3_CapsuleValidationResult = CapsuleValidationResult;
1958
+ declare const index$3_CapsuleValidationResultZ: typeof CapsuleValidationResultZ;
1959
+ type index$3_CapsuleVerifyResult = CapsuleVerifyResult;
1960
+ declare const index$3_CapsuleVerifyResultZ: typeof CapsuleVerifyResultZ;
1961
+ type index$3_CapsuleVerifySensorInput = CapsuleVerifySensorInput;
1962
+ declare const index$3_CapsuleVerifySensorInputZ: typeof CapsuleVerifySensorInputZ;
1963
+ declare const index$3_CapsuleZ: typeof CapsuleZ;
1964
+ type index$3_ChunkHashInput = ChunkHashInput;
1965
+ declare const index$3_ChunkHashInputZ: typeof ChunkHashInputZ;
1966
+ type index$3_CountryBlockDecision = CountryBlockDecision;
1967
+ declare const index$3_CountryBlockDecisionZ: typeof CountryBlockDecisionZ;
1968
+ type index$3_CountryBlockSensorInput = CountryBlockSensorInput;
1969
+ declare const index$3_CountryBlockSensorInputZ: typeof CountryBlockSensorInputZ;
1970
+ type index$3_EntropySensorInput = EntropySensorInput;
1971
+ declare const index$3_EntropySensorInputZ: typeof EntropySensorInputZ;
1972
+ declare const index$3_ExecutionMetricsZ: typeof ExecutionMetricsZ;
1973
+ type index$3_IPReputation = IPReputation;
1974
+ type index$3_IPReputationInput = IPReputationInput;
1975
+ declare const index$3_IPReputationInputZ: typeof IPReputationInputZ;
1976
+ declare const index$3_IPReputationZ: typeof IPReputationZ;
1977
+ type index$3_IntentPolicy = IntentPolicy;
1978
+ type index$3_IntentPolicyDecision = IntentPolicyDecision;
1979
+ declare const index$3_IntentPolicyDecisionZ: typeof IntentPolicyDecisionZ;
1980
+ type index$3_IntentPolicySensorInput = IntentPolicySensorInput;
1981
+ declare const index$3_IntentPolicySensorInputZ: typeof IntentPolicySensorInputZ;
1982
+ declare const index$3_IntentPolicyZ: typeof IntentPolicyZ;
1983
+ type index$3_IntentSchema = IntentSchema;
1984
+ declare const index$3_IntentSchemaZ: typeof IntentSchemaZ;
1985
+ type index$3_Passport = Passport;
1986
+ declare const index$3_PassportZ: typeof PassportZ;
1987
+ type index$3_ProofKind = ProofKind;
1988
+ declare const index$3_ProofKindZ: typeof ProofKindZ;
1989
+ type index$3_ProofPresenceInput = ProofPresenceInput;
1990
+ declare const index$3_ProofPresenceInputZ: typeof ProofPresenceInputZ;
1991
+ type index$3_ProofType = ProofType;
1992
+ declare const index$3_ProofType: typeof ProofType;
1993
+ type index$3_ProtocolStrictInput = ProtocolStrictInput;
1994
+ declare const index$3_ProtocolStrictInputZ: typeof ProtocolStrictInputZ;
1995
+ type index$3_RateLimitConfig = RateLimitConfig;
1996
+ declare const index$3_RateLimitConfigZ: typeof RateLimitConfigZ;
1997
+ type index$3_RateLimitInput = RateLimitInput;
1998
+ declare const index$3_RateLimitInputZ: typeof RateLimitInputZ;
1999
+ type index$3_RateLimitProfile = RateLimitProfile;
2000
+ declare const index$3_RateLimitProfileZ: typeof RateLimitProfileZ;
2001
+ type index$3_ScanBurstDecision = ScanBurstDecision;
2002
+ declare const index$3_ScanBurstDecisionZ: typeof ScanBurstDecisionZ;
2003
+ type index$3_ScanBurstSensorInput = ScanBurstSensorInput;
2004
+ declare const index$3_ScanBurstSensorInputZ: typeof ScanBurstSensorInputZ;
2005
+ type index$3_SchemaField = SchemaField;
2006
+ type index$3_SchemaFieldKind = SchemaFieldKind;
2007
+ declare const index$3_SchemaFieldKindZ: typeof SchemaFieldKindZ;
2008
+ declare const index$3_SchemaFieldZ: typeof SchemaFieldZ;
2009
+ type index$3_Scope = Scope;
2010
+ declare const index$3_ScopeZ: typeof ScopeZ;
2011
+ type index$3_SensitivityLevel = SensitivityLevel;
2012
+ declare const index$3_SensitivityLevelZ: typeof SensitivityLevelZ;
2013
+ type index$3_SensorChainInput = SensorChainInput;
2014
+ declare const index$3_SensorChainInputZ: typeof SensorChainInputZ;
2015
+ declare const index$3_SensorDecisionWithMetadataZ: typeof SensorDecisionWithMetadataZ;
2016
+ declare const index$3_SensorDecisionZ: typeof SensorDecisionZ;
2017
+ type index$3_SensorResult = SensorResult;
2018
+ declare const index$3_SensorResultZ: typeof SensorResultZ;
2019
+ type index$3_UploadSession = UploadSession;
2020
+ declare const index$3_UploadSessionZ: typeof UploadSessionZ;
2021
+ type index$3_UploadStatus = UploadStatus;
2022
+ declare const index$3_UploadStatusZ: typeof UploadStatusZ;
2023
+ type index$3_WsHandshakeDecision = WsHandshakeDecision;
2024
+ declare const index$3_WsHandshakeDecisionZ: typeof WsHandshakeDecisionZ;
2025
+ type index$3_WsHandshakeInput = WsHandshakeInput;
2026
+ declare const index$3_WsHandshakeInputZ: typeof WsHandshakeInputZ;
2027
+ 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 };
2029
+ }
2030
+
2031
+ declare const index$2_CAPABILITIES: typeof CAPABILITIES;
2032
+ type index$2_Capability = Capability;
2033
+ declare const index$2_INTENT_REQUIREMENTS: typeof INTENT_REQUIREMENTS;
2034
+ declare const index$2_PROOF_CAPABILITIES: typeof PROOF_CAPABILITIES;
2035
+ declare const index$2_canAccessResource: typeof canAccessResource;
2036
+ declare const index$2_hasScope: typeof hasScope;
2037
+ declare const index$2_parseScope: typeof parseScope;
2038
+ 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 };
2040
+ }
2041
+
2042
+ declare class AccessProfileResolverSensor implements AxisSensor {
2043
+ readonly name = "AccessProfileResolverSensor";
2044
+ readonly order: number;
2045
+ supports(): boolean;
2046
+ run(input: SensorInput): Promise<SensorDecision>;
2047
+ }
2048
+
2049
+ declare class BodyBudgetSensor implements AxisSensor {
2050
+ readonly name = "BodyBudgetSensor";
2051
+ readonly order: number;
2052
+ supports(input: SensorInput): boolean;
2053
+ run(input: SensorInput): Promise<SensorDecision>;
2054
+ }
2055
+
2056
+ declare class CapabilityEnforcementSensor implements AxisSensor {
2057
+ private readonly logger;
2058
+ readonly name = "CapabilityEnforcementSensor";
2059
+ readonly order: number;
2060
+ supports(input: SensorInput): boolean;
2061
+ run(input: SensorInput): Promise<SensorDecision>;
2062
+ private getRequiredCapabilities;
2063
+ }
2064
+
2065
+ declare class ChunkHashSensor implements AxisSensor {
2066
+ readonly name = "ChunkHashSensor";
2067
+ readonly order: number;
2068
+ supports(input: SensorInput): boolean;
2069
+ run(input: SensorInput): Promise<SensorDecision>;
2070
+ }
2071
+
2072
+ declare class EntropySensor implements AxisSensor {
2073
+ private readonly logger;
2074
+ private readonly MIN_ENTROPY_THRESHOLD;
2075
+ readonly name = "EntropySensor";
2076
+ readonly order: number;
2077
+ private calculateEntropy;
2078
+ private hasSequentialPattern;
2079
+ private hasRepeatedPattern;
2080
+ run(input: SensorInput): Promise<SensorDecision>;
2081
+ static generateSecureRandom(length: number): Uint8Array;
2082
+ }
2083
+
2084
+ declare class ExecutionTimeoutSensor implements AxisSensor {
2085
+ private readonly logger;
2086
+ readonly name = "ExecutionTimeoutSensor";
2087
+ readonly order: number;
2088
+ supports(input: SensorInput): boolean;
2089
+ run(input: SensorInput): Promise<SensorDecision>;
2090
+ static isExpired(ctx: {
2091
+ deadline?: number;
2092
+ }): boolean;
2093
+ static getRemainingMs(ctx: {
2094
+ deadline?: number;
2095
+ }): number;
2096
+ }
2097
+
2098
+ declare class FrameBudgetSensor implements AxisSensor {
2099
+ private readonly config;
2100
+ readonly name = "FrameBudgetSensor";
2101
+ readonly order: number;
2102
+ constructor(config: ConfigService);
2103
+ supports(input: SensorInput): boolean;
2104
+ run(input: SensorInput): Promise<SensorDecision>;
2105
+ }
2106
+
2107
+ declare class FrameHeaderSanitySensor implements AxisSensor {
2108
+ readonly name = "FrameHeaderSanitySensor";
2109
+ readonly order: number;
2110
+ supports(input: SensorInput): boolean;
2111
+ run(input: SensorInput): Promise<SensorDecision>;
2112
+ private bufferEqual;
2113
+ }
2114
+
2115
+ declare class HeaderTLVLimitSensor implements AxisSensor {
2116
+ readonly name = "HeaderTLVLimitSensor";
2117
+ readonly order: number;
2118
+ private readonly MAX_TLVS;
2119
+ supports(input: SensorInput): boolean;
2120
+ run(input: SensorInput): Promise<SensorDecision>;
2121
+ }
2122
+
2123
+ declare class IntentAllowlistSensor implements AxisSensor {
2124
+ readonly name = "IntentAllowlistSensor";
2125
+ readonly order: number;
2126
+ supports(input: SensorInput): boolean;
2127
+ run(input: SensorInput): Promise<SensorDecision>;
2128
+ }
2129
+
2130
+ declare class IntentRegistrySensor implements AxisSensor {
2131
+ private readonly router;
2132
+ readonly name = "IntentRegistrySensor";
2133
+ readonly order: number;
2134
+ constructor(router: IntentRouter);
2135
+ supports(input: SensorInput): boolean;
2136
+ run(input: SensorInput): Promise<SensorDecision>;
2137
+ }
2138
+
2139
+ declare class ProofPresenceSensor implements AxisSensor {
2140
+ readonly name = "ProofPresenceSensor";
2141
+ readonly order: number;
2142
+ supports(input: ProofPresenceInput): boolean;
2143
+ run(input: ProofPresenceInput): Promise<SensorDecision>;
2144
+ }
2145
+
2146
+ declare class ProtocolStrictSensor implements AxisSensor, OnModuleInit {
2147
+ private readonly config;
2148
+ private readonly logger;
2149
+ readonly name = "ProtocolStrictSensor";
2150
+ readonly order: number;
2151
+ private protocolMagic;
2152
+ private protocolVersion;
2153
+ constructor(config: ConfigService);
2154
+ static validateMagic(chunk: Uint8Array, expected: Uint8Array): {
2155
+ valid: boolean;
2156
+ actual?: string;
2157
+ };
2158
+ static validateVersion(version: number, expected: number): boolean;
2159
+ onModuleInit(): void;
2160
+ run(input: SensorInput): Promise<SensorDecision>;
2161
+ private buffersEqual;
2162
+ private isValidContentType;
2163
+ private isValidFlags;
2164
+ private checkVarintEncoding;
2165
+ private checkTLVOrdering;
2166
+ private checkForClientVersion;
2167
+ }
2168
+
2169
+ declare class ReceiptPolicySensor implements AxisSensor {
2170
+ readonly name = "ReceiptPolicySensor";
2171
+ readonly order: number;
2172
+ supports(): boolean;
2173
+ run(): Promise<SensorDecision>;
2174
+ }
2175
+
2176
+ declare class SchemaValidationSensor implements AxisSensor {
2177
+ readonly name = "SchemaValidationSensor";
2178
+ readonly order: number;
2179
+ supports(input: any): boolean;
2180
+ run(input: any): Promise<{
2181
+ action: 'ALLOW';
2182
+ } | {
2183
+ action: 'DENY';
2184
+ code: string;
2185
+ reason: string;
2186
+ }>;
2187
+ }
2188
+
2189
+ declare class StreamScopeSensor implements AxisSensor {
2190
+ readonly name = "StreamScopeSensor";
2191
+ readonly order: number;
2192
+ supports(): boolean;
2193
+ run(): Promise<SensorDecision>;
2194
+ }
2195
+
2196
+ declare class TLVParseSensor implements AxisSensor {
2197
+ readonly name = "TLVParseSensor";
2198
+ readonly order: number;
2199
+ supports(input: SensorInput): boolean;
2200
+ run(input: SensorInput): Promise<SensorDecision>;
2201
+ private validateCanonicalTLV;
2202
+ }
2203
+
2204
+ declare class VarintHardeningSensor implements AxisSensor {
2205
+ readonly name = "VarintHardeningSensor";
2206
+ readonly order: number;
2207
+ private readonly MAX_VARINT_BYTES;
2208
+ supports(input: SensorInput): boolean;
2209
+ run(input: SensorInput): Promise<SensorDecision>;
2210
+ }
2211
+
2212
+ type index$1_AccessProfileResolverSensor = AccessProfileResolverSensor;
2213
+ declare const index$1_AccessProfileResolverSensor: typeof AccessProfileResolverSensor;
2214
+ type index$1_BodyBudgetSensor = BodyBudgetSensor;
2215
+ declare const index$1_BodyBudgetSensor: typeof BodyBudgetSensor;
2216
+ type index$1_CapabilityEnforcementSensor = CapabilityEnforcementSensor;
2217
+ declare const index$1_CapabilityEnforcementSensor: typeof CapabilityEnforcementSensor;
2218
+ type index$1_ChunkHashSensor = ChunkHashSensor;
2219
+ declare const index$1_ChunkHashSensor: typeof ChunkHashSensor;
2220
+ type index$1_EntropySensor = EntropySensor;
2221
+ declare const index$1_EntropySensor: typeof EntropySensor;
2222
+ type index$1_ExecutionTimeoutSensor = ExecutionTimeoutSensor;
2223
+ declare const index$1_ExecutionTimeoutSensor: typeof ExecutionTimeoutSensor;
2224
+ type index$1_FrameBudgetSensor = FrameBudgetSensor;
2225
+ declare const index$1_FrameBudgetSensor: typeof FrameBudgetSensor;
2226
+ type index$1_FrameHeaderSanitySensor = FrameHeaderSanitySensor;
2227
+ declare const index$1_FrameHeaderSanitySensor: typeof FrameHeaderSanitySensor;
2228
+ type index$1_HeaderTLVLimitSensor = HeaderTLVLimitSensor;
2229
+ declare const index$1_HeaderTLVLimitSensor: typeof HeaderTLVLimitSensor;
2230
+ type index$1_IntentAllowlistSensor = IntentAllowlistSensor;
2231
+ declare const index$1_IntentAllowlistSensor: typeof IntentAllowlistSensor;
2232
+ type index$1_IntentRegistrySensor = IntentRegistrySensor;
2233
+ declare const index$1_IntentRegistrySensor: typeof IntentRegistrySensor;
2234
+ type index$1_ProofPresenceSensor = ProofPresenceSensor;
2235
+ declare const index$1_ProofPresenceSensor: typeof ProofPresenceSensor;
2236
+ type index$1_ProtocolStrictSensor = ProtocolStrictSensor;
2237
+ declare const index$1_ProtocolStrictSensor: typeof ProtocolStrictSensor;
2238
+ type index$1_ReceiptPolicySensor = ReceiptPolicySensor;
2239
+ declare const index$1_ReceiptPolicySensor: typeof ReceiptPolicySensor;
2240
+ type index$1_SchemaValidationSensor = SchemaValidationSensor;
2241
+ declare const index$1_SchemaValidationSensor: typeof SchemaValidationSensor;
2242
+ type index$1_StreamScopeSensor = StreamScopeSensor;
2243
+ declare const index$1_StreamScopeSensor: typeof StreamScopeSensor;
2244
+ type index$1_TLVParseSensor = TLVParseSensor;
2245
+ declare const index$1_TLVParseSensor: typeof TLVParseSensor;
2246
+ type index$1_VarintHardeningSensor = VarintHardeningSensor;
2247
+ declare const index$1_VarintHardeningSensor: typeof VarintHardeningSensor;
2248
+ declare namespace index$1 {
2249
+ export { index$1_AccessProfileResolverSensor as AccessProfileResolverSensor, index$1_BodyBudgetSensor as BodyBudgetSensor, index$1_CapabilityEnforcementSensor as CapabilityEnforcementSensor, index$1_ChunkHashSensor as ChunkHashSensor, index$1_EntropySensor as EntropySensor, index$1_ExecutionTimeoutSensor as ExecutionTimeoutSensor, index$1_FrameBudgetSensor as FrameBudgetSensor, index$1_FrameHeaderSanitySensor as FrameHeaderSanitySensor, index$1_HeaderTLVLimitSensor as HeaderTLVLimitSensor, index$1_IntentAllowlistSensor as IntentAllowlistSensor, index$1_IntentRegistrySensor as IntentRegistrySensor, index$1_ProofPresenceSensor as ProofPresenceSensor, index$1_ProtocolStrictSensor as ProtocolStrictSensor, index$1_ReceiptPolicySensor as ReceiptPolicySensor, index$1_SchemaValidationSensor as SchemaValidationSensor, index$1_StreamScopeSensor as StreamScopeSensor, index$1_TLVParseSensor as TLVParseSensor, index$1_VarintHardeningSensor as VarintHardeningSensor };
2250
+ }
2251
+
2252
+ type AxisTlvDtoCtor<T = object> = new (...args: never[]) => T;
2253
+ declare function encodeAxisTlvDto<T extends object>(dtoClass: AxisTlvDtoCtor<T>, data: Partial<Record<keyof T, unknown>>): Uint8Array;
2254
+
2255
+ declare const index_encodeAxisTlvDto: typeof encodeAxisTlvDto;
2256
+ declare namespace index {
2257
+ export { index_encodeAxisTlvDto as encodeAxisTlvDto };
2258
+ }
2259
+
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 };