@agentaos/core 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/LICENSE +199 -0
  2. package/README.md +66 -0
  3. package/dist/criteria/catalog.d.ts +18 -0
  4. package/dist/criteria/catalog.d.ts.map +1 -0
  5. package/dist/criteria/catalog.js +380 -0
  6. package/dist/criteria/catalog.js.map +1 -0
  7. package/dist/criteria/index.d.ts +3 -0
  8. package/dist/criteria/index.d.ts.map +1 -0
  9. package/dist/criteria/index.js +2 -0
  10. package/dist/criteria/index.js.map +1 -0
  11. package/dist/criteria/types.d.ts +32 -0
  12. package/dist/criteria/types.d.ts.map +1 -0
  13. package/dist/criteria/types.js +3 -0
  14. package/dist/criteria/types.js.map +1 -0
  15. package/dist/enums/chain-name.d.ts +4 -0
  16. package/dist/enums/chain-name.d.ts.map +1 -0
  17. package/dist/enums/chain-name.js +5 -0
  18. package/dist/enums/chain-name.js.map +1 -0
  19. package/dist/enums/curve-name.d.ts +4 -0
  20. package/dist/enums/curve-name.d.ts.map +1 -0
  21. package/dist/enums/curve-name.js +5 -0
  22. package/dist/enums/curve-name.js.map +1 -0
  23. package/dist/enums/index.d.ts +11 -0
  24. package/dist/enums/index.d.ts.map +1 -0
  25. package/dist/enums/index.js +11 -0
  26. package/dist/enums/index.js.map +1 -0
  27. package/dist/enums/network-name.d.ts +7 -0
  28. package/dist/enums/network-name.d.ts.map +1 -0
  29. package/dist/enums/network-name.js +8 -0
  30. package/dist/enums/network-name.js.map +1 -0
  31. package/dist/enums/policy-type.d.ts +13 -0
  32. package/dist/enums/policy-type.d.ts.map +1 -0
  33. package/dist/enums/policy-type.js +14 -0
  34. package/dist/enums/policy-type.js.map +1 -0
  35. package/dist/enums/request-status.d.ts +8 -0
  36. package/dist/enums/request-status.d.ts.map +1 -0
  37. package/dist/enums/request-status.js +9 -0
  38. package/dist/enums/request-status.js.map +1 -0
  39. package/dist/enums/request-type.d.ts +5 -0
  40. package/dist/enums/request-type.d.ts.map +1 -0
  41. package/dist/enums/request-type.js +6 -0
  42. package/dist/enums/request-type.js.map +1 -0
  43. package/dist/enums/scheme-name.d.ts +4 -0
  44. package/dist/enums/scheme-name.d.ts.map +1 -0
  45. package/dist/enums/scheme-name.js +5 -0
  46. package/dist/enums/scheme-name.js.map +1 -0
  47. package/dist/enums/signer-status.d.ts +6 -0
  48. package/dist/enums/signer-status.d.ts.map +1 -0
  49. package/dist/enums/signer-status.js +7 -0
  50. package/dist/enums/signer-status.js.map +1 -0
  51. package/dist/enums/signer-type.d.ts +9 -0
  52. package/dist/enums/signer-type.d.ts.map +1 -0
  53. package/dist/enums/signer-type.js +10 -0
  54. package/dist/enums/signer-type.js.map +1 -0
  55. package/dist/enums/signing-path.d.ts +5 -0
  56. package/dist/enums/signing-path.d.ts.map +1 -0
  57. package/dist/enums/signing-path.js +6 -0
  58. package/dist/enums/signing-path.js.map +1 -0
  59. package/dist/index.d.ts +6 -0
  60. package/dist/index.d.ts.map +1 -0
  61. package/dist/index.js +3 -0
  62. package/dist/index.js.map +1 -0
  63. package/dist/interfaces/chain.interface.d.ts +46 -0
  64. package/dist/interfaces/chain.interface.d.ts.map +1 -0
  65. package/dist/interfaces/chain.interface.js +2 -0
  66. package/dist/interfaces/chain.interface.js.map +1 -0
  67. package/dist/interfaces/index.d.ts +6 -0
  68. package/dist/interfaces/index.d.ts.map +1 -0
  69. package/dist/interfaces/index.js +2 -0
  70. package/dist/interfaces/index.js.map +1 -0
  71. package/dist/interfaces/kms-provider.interface.d.ts +13 -0
  72. package/dist/interfaces/kms-provider.interface.d.ts.map +1 -0
  73. package/dist/interfaces/kms-provider.interface.js +2 -0
  74. package/dist/interfaces/kms-provider.interface.js.map +1 -0
  75. package/dist/interfaces/policy-engine.interface.d.ts +43 -0
  76. package/dist/interfaces/policy-engine.interface.d.ts.map +1 -0
  77. package/dist/interfaces/policy-engine.interface.js +2 -0
  78. package/dist/interfaces/policy-engine.interface.js.map +1 -0
  79. package/dist/interfaces/share-store.interface.d.ts +9 -0
  80. package/dist/interfaces/share-store.interface.d.ts.map +1 -0
  81. package/dist/interfaces/share-store.interface.js +2 -0
  82. package/dist/interfaces/share-store.interface.js.map +1 -0
  83. package/dist/interfaces/threshold-scheme.interface.d.ts +105 -0
  84. package/dist/interfaces/threshold-scheme.interface.d.ts.map +1 -0
  85. package/dist/interfaces/threshold-scheme.interface.js +2 -0
  86. package/dist/interfaces/threshold-scheme.interface.js.map +1 -0
  87. package/dist/types/dkg.d.ts +2 -0
  88. package/dist/types/dkg.d.ts.map +1 -0
  89. package/dist/types/dkg.js +2 -0
  90. package/dist/types/dkg.js.map +1 -0
  91. package/dist/types/encrypted-envelope.d.ts +11 -0
  92. package/dist/types/encrypted-envelope.d.ts.map +1 -0
  93. package/dist/types/encrypted-envelope.js +2 -0
  94. package/dist/types/encrypted-envelope.js.map +1 -0
  95. package/dist/types/index.d.ts +9 -0
  96. package/dist/types/index.d.ts.map +1 -0
  97. package/dist/types/index.js +2 -0
  98. package/dist/types/index.js.map +1 -0
  99. package/dist/types/key-material.d.ts +12 -0
  100. package/dist/types/key-material.d.ts.map +1 -0
  101. package/dist/types/key-material.js +2 -0
  102. package/dist/types/key-material.js.map +1 -0
  103. package/dist/types/policy.d.ts +13 -0
  104. package/dist/types/policy.d.ts.map +1 -0
  105. package/dist/types/policy.js +2 -0
  106. package/dist/types/policy.js.map +1 -0
  107. package/dist/types/rules.d.ts +101 -0
  108. package/dist/types/rules.d.ts.map +1 -0
  109. package/dist/types/rules.js +3 -0
  110. package/dist/types/rules.js.map +1 -0
  111. package/dist/types/share.d.ts +40 -0
  112. package/dist/types/share.d.ts.map +1 -0
  113. package/dist/types/share.js +2 -0
  114. package/dist/types/share.js.map +1 -0
  115. package/dist/types/signature.d.ts +8 -0
  116. package/dist/types/signature.d.ts.map +1 -0
  117. package/dist/types/signature.js +2 -0
  118. package/dist/types/signature.js.map +1 -0
  119. package/dist/types/signer.d.ts +25 -0
  120. package/dist/types/signer.d.ts.map +1 -0
  121. package/dist/types/signer.js +2 -0
  122. package/dist/types/signer.js.map +1 -0
  123. package/dist/types/signing-request.d.ts +23 -0
  124. package/dist/types/signing-request.d.ts.map +1 -0
  125. package/dist/types/signing-request.js +2 -0
  126. package/dist/types/signing-request.js.map +1 -0
  127. package/package.json +50 -0
@@ -0,0 +1,105 @@
1
+ import type { CurveName } from '../enums/curve-name.js';
2
+ import type { SchemeName } from '../enums/scheme-name.js';
3
+ export interface DKGRoundResult {
4
+ readonly outgoing: Uint8Array[];
5
+ readonly finished: boolean;
6
+ readonly publicKey?: Uint8Array;
7
+ readonly shares?: Uint8Array[];
8
+ }
9
+ /** Result from an aux-info generation round (CGGMP24 two-phase DKG). */
10
+ export interface AuxInfoRoundResult {
11
+ readonly outgoing: Uint8Array[];
12
+ readonly finished: boolean;
13
+ /** Serialised AuxInfo blobs (one per party) — present when finished=true. */
14
+ readonly auxInfos?: Uint8Array[];
15
+ }
16
+ export interface IThresholdScheme {
17
+ readonly name: SchemeName;
18
+ readonly curve: CurveName;
19
+ /**
20
+ * Run one round of the auxiliary info generation ceremony.
21
+ * Phase A of the CGGMP24 two-phase DKG — generates Paillier key pairs
22
+ * and ring-Pedersen parameters needed for signing.
23
+ */
24
+ auxInfoGen(sessionId: string, round: number, incoming: Uint8Array[]): Promise<AuxInfoRoundResult>;
25
+ /**
26
+ * Run one round of the key generation ceremony.
27
+ * Phase B of the CGGMP24 two-phase DKG — generates CoreKeyShares.
28
+ */
29
+ dkg(sessionId: string, round: number, incoming: Uint8Array[]): Promise<DKGRoundResult>;
30
+ /** Derive an Ethereum address from a compressed or uncompressed public key. */
31
+ deriveAddress(publicKey: Uint8Array): string;
32
+ /**
33
+ * Extract the shared public key from a serialised CoreKeyShare.
34
+ * Returns 33-byte compressed secp256k1 public key.
35
+ * Optional — not all scheme implementations may support this.
36
+ */
37
+ extractPublicKey?(keyShareBytes: Uint8Array): Uint8Array;
38
+ /**
39
+ * Create an interactive signing session from key material.
40
+ *
41
+ * @param keyMaterialBytes - [coreShare, auxInfo] — two serialised blobs
42
+ * @param messageHash - 32-byte hash to sign (required upfront in CGGMP24)
43
+ * @param options - Optional party config for the signing session
44
+ */
45
+ createSignSession(keyMaterialBytes: Uint8Array[], messageHash: Uint8Array, options?: {
46
+ partyIndex?: number;
47
+ partiesAtKeygen?: number[];
48
+ eid?: Uint8Array;
49
+ /** Force WASM backend for cross-compatibility with browser signing. */
50
+ forceWasm?: boolean;
51
+ }): Promise<{
52
+ sessionId: string;
53
+ firstMessages: Uint8Array[];
54
+ }>;
55
+ /**
56
+ * Process one round of the interactive signing protocol.
57
+ *
58
+ * @returns outgoingMessages and whether the protocol is complete.
59
+ */
60
+ processSignRound(sessionId: string, incomingMessages: Uint8Array[]): Promise<{
61
+ outgoingMessages: Uint8Array[];
62
+ complete: boolean;
63
+ }>;
64
+ /**
65
+ * Extract the final signature from a completed signing session.
66
+ * No lastMessage step — CGGMP24 produces the signature when the
67
+ * protocol completes.
68
+ */
69
+ finalizeSign(sessionId: string): Promise<{
70
+ r: Uint8Array;
71
+ s: Uint8Array;
72
+ v: number;
73
+ }>;
74
+ /**
75
+ * Create a presignature session — produces a reusable presignature
76
+ * that enables instant non-interactive signing later.
77
+ */
78
+ createPresignSession(keyMaterialBytes: Uint8Array[]): {
79
+ sessionId: string;
80
+ firstMessages: Uint8Array[];
81
+ };
82
+ /** Process one round of the presignature generation protocol. */
83
+ processPresignRound(sessionId: string, incomingMessages: Uint8Array[]): {
84
+ outgoingMessages: Uint8Array[];
85
+ complete: boolean;
86
+ };
87
+ /** Extract the presignature and commitment from a completed session. */
88
+ extractPresignature(sessionId: string): {
89
+ presignature: Uint8Array;
90
+ commitment: Uint8Array;
91
+ };
92
+ /**
93
+ * Issue a partial signature from a presignature (non-interactive, instant).
94
+ */
95
+ issuePartialSignature(presignature: Uint8Array, messageHash: Uint8Array): Uint8Array;
96
+ /**
97
+ * Combine partial signatures into a full ECDSA signature.
98
+ */
99
+ combinePartialSignatures(partials: Uint8Array[], commitment: Uint8Array, messageHash: Uint8Array): {
100
+ r: Uint8Array;
101
+ s: Uint8Array;
102
+ v: number;
103
+ };
104
+ }
105
+ //# sourceMappingURL=threshold-scheme.interface.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"threshold-scheme.interface.d.ts","sourceRoot":"","sources":["../../src/interfaces/threshold-scheme.interface.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAE1D,MAAM,WAAW,cAAc;IAC9B,QAAQ,CAAC,QAAQ,EAAE,UAAU,EAAE,CAAC;IAChC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,SAAS,CAAC,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,MAAM,CAAC,EAAE,UAAU,EAAE,CAAC;CAC/B;AAED,wEAAwE;AACxE,MAAM,WAAW,kBAAkB;IAClC,QAAQ,CAAC,QAAQ,EAAE,UAAU,EAAE,CAAC;IAChC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,6EAA6E;IAC7E,QAAQ,CAAC,QAAQ,CAAC,EAAE,UAAU,EAAE,CAAC;CACjC;AAED,MAAM,WAAW,gBAAgB;IAChC,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,KAAK,EAAE,SAAS,CAAC;IAI1B;;;;OAIG;IACH,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAC;IAElG;;;OAGG;IACH,GAAG,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC,cAAc,CAAC,C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EAAwE;IACxE,mBAAmB,CAAC,SAAS,EAAE,MAAM,GAAG;QACvC,YAAY,EAAE,UAAU,CAAC;QACzB,UAAU,EAAE,UAAU,CAAC;KACvB,CAAC;IAEF;;OAEG;IACH,qBAAqB,CAAC,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,GAAG,UAAU,CAAC;IAErF;;OAEG;IACH,wBAAwB,CACvB,QAAQ,EAAE,UAAU,EAAE,EACtB,UAAU,EAAE,UAAU,EACtB,WAAW,EAAE,UAAU,GACrB;QACF,CAAC,EAAE,UAAU,CAAC;QACd,CAAC,EAAE,UAAU,CAAC;QACd,CAAC,EAAE,MAAM,CAAC;KACV,CAAC;CACF"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=threshold-scheme.interface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"threshold-scheme.interface.js","sourceRoot":"","sources":["../../src/interfaces/threshold-scheme.interface.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export type DKGState = 'initialized' | 'round1' | 'round2' | 'round3' | 'completed' | 'failed';
2
+ //# sourceMappingURL=dkg.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dkg.d.ts","sourceRoot":"","sources":["../../src/types/dkg.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,GAAG,aAAa,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,WAAW,GAAG,QAAQ,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=dkg.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dkg.js","sourceRoot":"","sources":["../../src/types/dkg.ts"],"names":[],"mappings":""}
@@ -0,0 +1,11 @@
1
+ export interface EncryptedEnvelope {
2
+ readonly version: 1;
3
+ readonly keyId: string;
4
+ readonly encryptedDek: string;
5
+ readonly iv: string;
6
+ readonly ciphertext: string;
7
+ readonly authTag: string;
8
+ readonly algorithm: 'aes-256-gcm';
9
+ readonly aadPath: string;
10
+ }
11
+ //# sourceMappingURL=encrypted-envelope.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"encrypted-envelope.d.ts","sourceRoot":"","sources":["../../src/types/encrypted-envelope.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,iBAAiB;IACjC,QAAQ,CAAC,OAAO,EAAE,CAAC,CAAC;IACpB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,SAAS,EAAE,aAAa,CAAC;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CACzB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=encrypted-envelope.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"encrypted-envelope.js","sourceRoot":"","sources":["../../src/types/encrypted-envelope.ts"],"names":[],"mappings":""}
@@ -0,0 +1,9 @@
1
+ export type { KeyMaterial } from './key-material.js';
2
+ export type { Share, ShareFile } from './share.js';
3
+ export type { Signer } from './signer.js';
4
+ export type { Policy } from './policy.js';
5
+ export type { SigningRequest } from './signing-request.js';
6
+ export type { DKGState } from './dkg.js';
7
+ export type { EncryptedEnvelope } from './encrypted-envelope.js';
8
+ export type { BlockInfiniteApprovalsCriterion, ComparisonOperator, Criterion, DailyLimitCriterion, DailyLimitUsdCriterion, EthValueCriterion, EvmAddressCriterion, EvmFunctionCriterion, EvmNetworkCriterion, IpAddressCriterion, MaxPerTxUsdCriterion, MaxSlippageCriterion, MevProtectionCriterion, MonthlyLimitCriterion, MonthlyLimitUsdCriterion, PolicyDocument, PolicyRule, RateLimitCriterion, RuleAction, SetOperator, TimeWindowCriterion, } from './rules.js';
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACrD,YAAY,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACnD,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,YAAY,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAC3D,YAAY,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AACzC,YAAY,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACjE,YAAY,EACX,+BAA+B,EAC/B,kBAAkB,EAClB,SAAS,EACT,mBAAmB,EACnB,sBAAsB,EACtB,iBAAiB,EACjB,mBAAmB,EACnB,oBAAoB,EACpB,mBAAmB,EACnB,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,EACpB,sBAAsB,EACtB,qBAAqB,EACrB,wBAAwB,EACxB,cAAc,EACd,UAAU,EACV,kBAAkB,EAClB,UAAU,EACV,WAAW,EACX,mBAAmB,GACnB,MAAM,YAAY,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":""}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * CGGMP24 key material is split into two parts:
3
+ * - CoreKeyShare: from the keygen ceremony (contains the secret share + public data)
4
+ * - AuxInfo: from the aux_info_gen ceremony (Paillier keys + ring-Pedersen params)
5
+ *
6
+ * Both are needed to participate in signing.
7
+ */
8
+ export interface KeyMaterial {
9
+ readonly coreShare: Uint8Array;
10
+ readonly auxInfo: Uint8Array;
11
+ }
12
+ //# sourceMappingURL=key-material.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"key-material.d.ts","sourceRoot":"","sources":["../../src/types/key-material.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,MAAM,WAAW,WAAW;IAC3B,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;IAC/B,QAAQ,CAAC,OAAO,EAAE,UAAU,CAAC;CAC7B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=key-material.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"key-material.js","sourceRoot":"","sources":["../../src/types/key-material.ts"],"names":[],"mappings":""}
@@ -0,0 +1,13 @@
1
+ import type { PolicyType } from '../enums/policy-type.js';
2
+ export interface Policy {
3
+ readonly id: string;
4
+ readonly signerId: string;
5
+ readonly type: PolicyType;
6
+ readonly config: Record<string, unknown>;
7
+ readonly enabled: boolean;
8
+ readonly appliesTo?: readonly string[];
9
+ readonly timesTriggered: number;
10
+ readonly createdAt: string;
11
+ readonly updatedAt: string;
12
+ }
13
+ //# sourceMappingURL=policy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"policy.d.ts","sourceRoot":"","sources":["../../src/types/policy.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAE1D,MAAM,WAAW,MAAM;IACtB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACzC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC3B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=policy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"policy.js","sourceRoot":"","sources":["../../src/types/policy.ts"],"names":[],"mappings":""}
@@ -0,0 +1,101 @@
1
+ /** Rules engine types — composable, ordered policy rules. */
2
+ export type ComparisonOperator = '<=' | '<' | '>=' | '>' | '=';
3
+ export type SetOperator = 'in' | 'not_in';
4
+ export interface EthValueCriterion {
5
+ readonly type: 'ethValue';
6
+ readonly operator: ComparisonOperator;
7
+ /** Wei amount as decimal string (avoids JSON BigInt issues). */
8
+ readonly value: string;
9
+ }
10
+ export interface EvmAddressCriterion {
11
+ readonly type: 'evmAddress';
12
+ readonly operator: SetOperator;
13
+ readonly addresses: readonly string[];
14
+ /** Allow contract deployment (to=null). Default false. */
15
+ readonly allowDeploy?: boolean;
16
+ }
17
+ export interface EvmNetworkCriterion {
18
+ readonly type: 'evmNetwork';
19
+ readonly operator: SetOperator;
20
+ readonly chainIds: readonly number[];
21
+ }
22
+ export interface EvmFunctionCriterion {
23
+ readonly type: 'evmFunction';
24
+ /** 4-byte hex function selectors (e.g. "0xa9059cbb"). */
25
+ readonly selectors: readonly string[];
26
+ /** Allow plain ETH transfer (no calldata). Default true. */
27
+ readonly allowPlainTransfer?: boolean;
28
+ }
29
+ export interface IpAddressCriterion {
30
+ readonly type: 'ipAddress';
31
+ readonly operator: SetOperator;
32
+ /** IPv4 or CIDR notation (e.g. "10.0.0.0/8"). */
33
+ readonly ips: readonly string[];
34
+ }
35
+ export interface RateLimitCriterion {
36
+ readonly type: 'rateLimit';
37
+ readonly maxPerHour: number;
38
+ }
39
+ export interface TimeWindowCriterion {
40
+ readonly type: 'timeWindow';
41
+ /** 0–23 UTC hour. */
42
+ readonly startHour: number;
43
+ /** 0–23 UTC hour. Overnight ranges supported (e.g. 22 → 6). */
44
+ readonly endHour: number;
45
+ }
46
+ export interface DailyLimitCriterion {
47
+ readonly type: 'dailyLimit';
48
+ /** Rolling 24h spend cap in wei (decimal string). */
49
+ readonly maxWei: string;
50
+ }
51
+ export interface MonthlyLimitCriterion {
52
+ readonly type: 'monthlyLimit';
53
+ /** Rolling 30-day spend cap in wei (decimal string). */
54
+ readonly maxWei: string;
55
+ }
56
+ export interface MaxPerTxUsdCriterion {
57
+ readonly type: 'maxPerTxUsd';
58
+ /** Max outgoing value per transaction in USD. */
59
+ readonly maxUsd: number;
60
+ }
61
+ export interface DailyLimitUsdCriterion {
62
+ readonly type: 'dailyLimitUsd';
63
+ /** Rolling 24h spend cap in USD. */
64
+ readonly maxUsd: number;
65
+ }
66
+ export interface MonthlyLimitUsdCriterion {
67
+ readonly type: 'monthlyLimitUsd';
68
+ /** Rolling 30-day spend cap in USD. */
69
+ readonly maxUsd: number;
70
+ }
71
+ export interface BlockInfiniteApprovalsCriterion {
72
+ readonly type: 'blockInfiniteApprovals';
73
+ readonly enabled: boolean;
74
+ }
75
+ export interface MaxSlippageCriterion {
76
+ readonly type: 'maxSlippage';
77
+ /** Max allowed slippage percentage (e.g. 2 = 2%). */
78
+ readonly maxPercent: number;
79
+ }
80
+ export interface MevProtectionCriterion {
81
+ readonly type: 'mevProtection';
82
+ readonly enabled: boolean;
83
+ }
84
+ export type Criterion = EthValueCriterion | EvmAddressCriterion | EvmNetworkCriterion | EvmFunctionCriterion | IpAddressCriterion | RateLimitCriterion | TimeWindowCriterion | DailyLimitCriterion | MonthlyLimitCriterion | MaxPerTxUsdCriterion | DailyLimitUsdCriterion | MonthlyLimitUsdCriterion | BlockInfiniteApprovalsCriterion | MaxSlippageCriterion | MevProtectionCriterion;
85
+ export type RuleAction = 'accept' | 'reject';
86
+ export interface PolicyRule {
87
+ readonly action: RuleAction;
88
+ readonly criteria: readonly Criterion[];
89
+ readonly description?: string;
90
+ readonly enabled?: boolean;
91
+ }
92
+ export interface PolicyDocument {
93
+ readonly id: string;
94
+ readonly signerId: string;
95
+ readonly description?: string;
96
+ readonly rules: readonly PolicyRule[];
97
+ readonly version: number;
98
+ readonly createdAt: string;
99
+ readonly updatedAt: string;
100
+ }
101
+ //# sourceMappingURL=rules.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rules.d.ts","sourceRoot":"","sources":["../../src/types/rules.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAI7D,MAAM,MAAM,kBAAkB,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,GAAG,CAAC;AAC/D,MAAM,MAAM,WAAW,GAAG,IAAI,GAAG,QAAQ,CAAC;AAI1C,MAAM,WAAW,iBAAiB;IACjC,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,QAAQ,EAAE,kBAAkB,CAAC;IACtC,gEAAgE;IAChE,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,mBAAmB;IACnC,QAAQ,CAAC,IAAI,EAAE,YAAY,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,WAAW,CAAC;IAC/B,QAAQ,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC,0DAA0D;IAC1D,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAC/B;AAED,MAAM,WAAW,mBAAmB;IACnC,QAAQ,CAAC,IAAI,EAAE,YAAY,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,WAAW,CAAC;IAC/B,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC;AAED,MAAM,WAAW,oBAAoB;IACpC,QAAQ,CAAC,IAAI,EAAE,aAAa,CAAC;IAC7B,yDAAyD;IACzD,QAAQ,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IACtC,4DAA4D;IAC5D,QAAQ,CAAC,kBAAkB,CAAC,EAAE,OAAO,CAAC;CACtC;AAED,MAAM,WAAW,kBAAkB;IAClC,QAAQ,CAA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export {};
3
+ //# sourceMappingURL=rules.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rules.js","sourceRoot":"","sources":["../../src/types/rules.ts"],"names":[],"mappings":"AAAA,6DAA6D"}
@@ -0,0 +1,40 @@
1
+ import type { ChainName } from '../enums/chain-name.js';
2
+ import type { CurveName } from '../enums/curve-name.js';
3
+ import type { NetworkName } from '../enums/network-name.js';
4
+ import type { SchemeName } from '../enums/scheme-name.js';
5
+ export interface Share {
6
+ readonly data: Uint8Array;
7
+ readonly participantIndex: 1 | 2 | 3;
8
+ readonly publicKey: Uint8Array;
9
+ readonly scheme: SchemeName;
10
+ readonly curve: CurveName;
11
+ }
12
+ export interface ShareFileEncryption {
13
+ readonly algorithm: 'aes-256-gcm';
14
+ readonly iv: string;
15
+ readonly tag: string;
16
+ readonly kdf: 'scrypt' | 'argon2id';
17
+ readonly kdfParams: {
18
+ readonly memory: number;
19
+ readonly iterations: number;
20
+ readonly parallelism: number;
21
+ readonly saltBase64: string;
22
+ };
23
+ }
24
+ export interface ShareFileMetadata {
25
+ readonly signerName: string;
26
+ readonly participantIndex: 1 | 2 | 3;
27
+ readonly scheme: SchemeName;
28
+ readonly curve: CurveName;
29
+ readonly ethAddress: string;
30
+ readonly chain: ChainName;
31
+ readonly network?: NetworkName;
32
+ readonly createdAt: string;
33
+ }
34
+ export interface ShareFile {
35
+ readonly version: number;
36
+ readonly encryption: ShareFileEncryption;
37
+ readonly ciphertextBase64: string;
38
+ readonly metadata: ShareFileMetadata;
39
+ }
40
+ //# sourceMappingURL=share.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"share.d.ts","sourceRoot":"","sources":["../../src/types/share.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,O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EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,EAAE,mBAAmB,CAAC;IACzC,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;IAClC,QAAQ,CAAC,QAAQ,EAAE,iBAAiB,CAAC;CACrC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=share.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"share.js","sourceRoot":"","sources":["../../src/types/share.ts"],"names":[],"mappings":""}
@@ -0,0 +1,8 @@
1
+ import type { SchemeName } from '../enums/scheme-name.js';
2
+ export interface Signature {
3
+ readonly r: Uint8Array;
4
+ readonly s: Uint8Array;
5
+ readonly v?: number;
6
+ readonly scheme: SchemeName;
7
+ }
8
+ //# sourceMappingURL=signature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signature.d.ts","sourceRoot":"","sources":["../../src/types/signature.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAE1D,MAAM,WAAW,SAAS;IACzB,QAAQ,CAAC,CAAC,EAAE,UAAU,CAAC;IACvB,QAAQ,CAAC,CAAC,EAAE,UAAU,CAAC;IACvB,QAAQ,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAC;CAC5B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=signature.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signature.js","sourceRoot":"","sources":["../../src/types/signature.ts"],"names":[],"mappings":""}
@@ -0,0 +1,25 @@
1
+ import type { ChainName } from '../enums/chain-name.js';
2
+ import type { NetworkName } from '../enums/network-name.js';
3
+ import type { SchemeName } from '../enums/scheme-name.js';
4
+ import type { SignerStatus } from '../enums/signer-status.js';
5
+ import type { SignerType } from '../enums/signer-type.js';
6
+ export interface Signer {
7
+ readonly id: string;
8
+ readonly name: string;
9
+ readonly description?: string;
10
+ readonly type: SignerType;
11
+ readonly ethAddress: string;
12
+ readonly chain: ChainName;
13
+ readonly scheme: SchemeName;
14
+ readonly network?: NetworkName;
15
+ readonly status: SignerStatus;
16
+ readonly ownerId: string;
17
+ readonly apiKeyHash: string;
18
+ readonly vaultSharePath: string;
19
+ readonly dkgCompleted: boolean;
20
+ readonly createdAt: string;
21
+ readonly updatedAt: string;
22
+ readonly lastActiveAt?: string;
23
+ readonly revokedAt?: string;
24
+ }
25
+ //# sourceMappingURL=signer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signer.d.ts","sourceRoot":"","sources":["../../src/types/signer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAE1D,MAAM,WAAW,MAAM;IACtB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAC1B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,KAAK,EAAE,SAAS,CAAC;IAC1B,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAC;IAC5B,QAAQ,CAAC,OAAO,CAAC,EAAE,WAAW,CAAC;IAC/B,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAC9B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,YAAY,EAAE,OAAO,CAAC;IAC/B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;CAC5B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=signer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signer.js","sourceRoot":"","sources":["../../src/types/signer.ts"],"names":[],"mappings":""}
@@ -0,0 +1,23 @@
1
+ import type { RequestStatus } from '../enums/request-status.js';
2
+ import type { RequestType } from '../enums/request-type.js';
3
+ import type { SigningPath } from '../enums/signing-path.js';
4
+ import type { PolicyViolation } from '../interfaces/policy-engine.interface.js';
5
+ export interface SigningRequest {
6
+ readonly id: string;
7
+ readonly signerId: string;
8
+ readonly requestType: RequestType;
9
+ readonly signingPath: SigningPath;
10
+ readonly status: RequestStatus;
11
+ readonly toAddress?: string;
12
+ readonly valueWei: string;
13
+ readonly chainId: number;
14
+ readonly txData?: string;
15
+ readonly decodedAction?: string;
16
+ readonly txHash?: string;
17
+ readonly nonce?: number;
18
+ readonly policyViolations?: readonly PolicyViolation[];
19
+ readonly policiesEvaluated: number;
20
+ readonly evaluationTimeMs: number;
21
+ readonly createdAt: string;
22
+ }
23
+ //# sourceMappingURL=signing-request.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signing-request.d.ts","sourceRoot":"","sources":["../../src/types/signing-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0CAA0C,CAAC;AAEhF,MAAM,WAAW,cAAc;IAC9B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAC;IAClC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAC;IAClC,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC;IAC/B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;IAChC,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,gBAAgB,CAAC,EAAE,SAAS,eAAe,EAAE,CAAC;IACvD,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;IACnC,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;IAClC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC3B"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=signing-request.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signing-request.js","sourceRoot":"","sources":["../../src/types/signing-request.ts"],"names":[],"mappings":""}
package/package.json ADDED
@@ -0,0 +1,50 @@
1
+ {
2
+ "name": "@agentaos/core",
3
+ "version": "0.2.0",
4
+ "description": "Type definitions and interfaces for AgentaOS threshold wallet",
5
+ "license": "Apache-2.0",
6
+ "author": "AgentaOS <hello@agentaos.ai>",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "https://github.com/AgentaOS/agentaos.git",
10
+ "directory": "packages/core"
11
+ },
12
+ "homepage": "https://github.com/AgentaOS/agentaos",
13
+ "bugs": "https://github.com/AgentaOS/agentaos/issues",
14
+ "keywords": [
15
+ "threshold",
16
+ "wallet",
17
+ "mpc",
18
+ "ecdsa",
19
+ "ethereum",
20
+ "agent",
21
+ "signing",
22
+ "types"
23
+ ],
24
+ "type": "module",
25
+ "main": "./dist/index.js",
26
+ "types": "./dist/index.d.ts",
27
+ "exports": {
28
+ ".": {
29
+ "types": "./dist/index.d.ts",
30
+ "import": "./dist/index.js"
31
+ }
32
+ },
33
+ "files": [
34
+ "dist"
35
+ ],
36
+ "engines": {
37
+ "node": ">=20.0.0"
38
+ },
39
+ "publishConfig": {
40
+ "access": "public"
41
+ },
42
+ "devDependencies": {},
43
+ "scripts": {
44
+ "build": "tsc",
45
+ "lint": "biome check src/",
46
+ "test": "vitest run --passWithNoTests",
47
+ "typecheck": "tsc --noEmit",
48
+ "clean": "rm -rf dist"
49
+ }
50
+ }