@the-ai-company/cbio-node-runtime 1.63.6 → 1.63.8

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 (189) hide show
  1. package/README.md +2 -2
  2. package/dist/clients/agent/client.d.ts +2 -2
  3. package/dist/clients/agent/client.js +46 -49
  4. package/dist/clients/agent/client.js.map +1 -1
  5. package/dist/clients/agent/contracts.d.ts +5 -5
  6. package/dist/clients/owner/client.js +169 -176
  7. package/dist/clients/owner/client.js.map +1 -1
  8. package/dist/clients/owner/contracts.d.ts +45 -48
  9. package/dist/protocol/childSecretNaming.d.ts +1 -1
  10. package/dist/protocol/childSecretNaming.js +2 -2
  11. package/dist/protocol/childSecretNaming.js.map +1 -1
  12. package/dist/protocol/crypto.d.ts +4 -4
  13. package/dist/protocol/crypto.js +14 -14
  14. package/dist/protocol/crypto.js.map +1 -1
  15. package/dist/protocol/identity.d.ts +2 -2
  16. package/dist/protocol/identity.js +4 -4
  17. package/dist/protocol/identity.js.map +1 -1
  18. package/dist/public-types.d.ts +1 -1
  19. package/dist/public-types.js +1 -1
  20. package/dist/public-types.js.map +1 -1
  21. package/dist/runtime/bootstrap.d.ts +6 -6
  22. package/dist/runtime/bootstrap.js +26 -26
  23. package/dist/runtime/bootstrap.js.map +1 -1
  24. package/dist/runtime/identity.d.ts +6 -6
  25. package/dist/runtime/identity.js +14 -12
  26. package/dist/runtime/identity.js.map +1 -1
  27. package/dist/runtime/index.d.ts +1 -1
  28. package/dist/runtime/index.js +1 -1
  29. package/dist/runtime/index.js.map +1 -1
  30. package/dist/runtime/owner-session.d.ts +1 -5
  31. package/dist/runtime/owner-session.js +4 -5
  32. package/dist/runtime/owner-session.js.map +1 -1
  33. package/dist/runtime/vault-metadata.d.ts +2 -2
  34. package/dist/runtime/vault-metadata.js +2 -2
  35. package/dist/runtime/vault-metadata.js.map +1 -1
  36. package/dist/vault-core/contracts.d.ts +235 -238
  37. package/dist/vault-core/contracts.js +25 -34
  38. package/dist/vault-core/contracts.js.map +1 -1
  39. package/dist/vault-core/core.d.ts +41 -41
  40. package/dist/vault-core/core.js +257 -255
  41. package/dist/vault-core/core.js.map +1 -1
  42. package/dist/vault-core/defaults.d.ts +25 -25
  43. package/dist/vault-core/defaults.js +95 -95
  44. package/dist/vault-core/defaults.js.map +1 -1
  45. package/dist/vault-core/index.d.ts +2 -2
  46. package/dist/vault-core/index.js +2 -2
  47. package/dist/vault-core/index.js.map +1 -1
  48. package/dist/vault-core/persistence.d.ts +19 -19
  49. package/dist/vault-core/persistence.js +78 -66
  50. package/dist/vault-core/persistence.js.map +1 -1
  51. package/dist/vault-core/ports.d.ts +23 -23
  52. package/dist/vault-core/tool-metadata.js +6 -6
  53. package/dist/vault-core/tool-metadata.js.map +1 -1
  54. package/dist/vault-ingress/defaults.d.ts +2 -2
  55. package/dist/vault-ingress/defaults.js +10 -10
  56. package/dist/vault-ingress/defaults.js.map +1 -1
  57. package/dist/vault-ingress/index.d.ts +46 -46
  58. package/dist/vault-ingress/index.js +34 -34
  59. package/dist/vault-ingress/index.js.map +1 -1
  60. package/dist/vault-ingress/remote-transport.d.ts +2 -2
  61. package/dist/vault-ingress/remote-transport.js +27 -27
  62. package/dist/vault-ingress/remote-transport.js.map +1 -1
  63. package/docs/ARCHITECTURE.md +1 -1
  64. package/docs/CUSTODY_MODEL.md +3 -3
  65. package/docs/IDENTITY_MODEL.md +4 -4
  66. package/docs/REFERENCE.md +1 -1
  67. package/docs/api/README.md +3 -4
  68. package/docs/api/classes/IdentityError.md +1 -1
  69. package/docs/api/classes/OwnerClientError.md +1 -1
  70. package/docs/api/classes/PersistentVaultAgentIdentityRegistry.md +6 -6
  71. package/docs/api/classes/PersistentVaultAgentSecretGrantRegistry.md +12 -12
  72. package/docs/api/classes/PersistentVaultAuditLog.md +1 -1
  73. package/docs/api/classes/PersistentVaultSecretCustody.md +7 -7
  74. package/docs/api/classes/PersistentVaultSecretDestinationGrantRegistry.md +12 -12
  75. package/docs/api/classes/PersistentVaultSecretRepository.md +7 -7
  76. package/docs/api/classes/VaultCore.md +53 -53
  77. package/docs/api/classes/VaultCoreError.md +1 -1
  78. package/docs/api/enumerations/AuditOperation.md +137 -0
  79. package/docs/api/enumerations/DispatchStatus.md +1 -1
  80. package/docs/api/enumerations/IdentityErrorCode.md +1 -1
  81. package/docs/api/enumerations/OwnerClientErrorCode.md +1 -1
  82. package/docs/api/functions/createAgentClient.md +1 -1
  83. package/docs/api/functions/createIdentity.md +2 -2
  84. package/docs/api/functions/createOwnerClient.md +1 -1
  85. package/docs/api/functions/createOwnerSession.md +1 -1
  86. package/docs/api/functions/createPersistentVaultCoreDependencies.md +3 -3
  87. package/docs/api/functions/createVault.md +1 -1
  88. package/docs/api/functions/createVaultCore.md +1 -1
  89. package/docs/api/functions/createVaultCoreDependencies.md +1 -1
  90. package/docs/api/functions/createVaultService.md +1 -1
  91. package/docs/api/functions/createWorkspaceStorage.md +1 -1
  92. package/docs/api/functions/deriveRootAgentId.md +3 -3
  93. package/docs/api/functions/deriveVaultWorkingKeyFromPassword.md +4 -4
  94. package/docs/api/functions/getDefaultWorkspaceDir.md +1 -1
  95. package/docs/api/functions/handleVaultAgentControlHttp.md +1 -1
  96. package/docs/api/functions/handleVaultHttpDispatch.md +1 -1
  97. package/docs/api/functions/initializeVaultCustody.md +1 -1
  98. package/docs/api/functions/listVaults.md +1 -1
  99. package/docs/api/functions/readVaultProfile.md +3 -3
  100. package/docs/api/functions/recoverVault.md +4 -4
  101. package/docs/api/functions/recoverVaultWorkingKey.md +1 -1
  102. package/docs/api/functions/restoreIdentity.md +3 -3
  103. package/docs/api/functions/updateVaultMetadata.md +1 -1
  104. package/docs/api/functions/writeVaultProfile.md +3 -3
  105. package/docs/api/interfaces/AgentClient.md +3 -3
  106. package/docs/api/interfaces/AgentDispatchIntent.md +7 -7
  107. package/docs/api/interfaces/AgentDispatchTransport.md +1 -1
  108. package/docs/api/interfaces/AgentIdentity.md +3 -3
  109. package/docs/api/interfaces/AgentIdentityRecord.md +11 -11
  110. package/docs/api/interfaces/AgentRequestResult.md +9 -9
  111. package/docs/api/interfaces/AgentRuntimeManifest.md +13 -13
  112. package/docs/api/interfaces/AgentSecretGrant.md +11 -11
  113. package/docs/api/interfaces/AgentSigner.md +1 -1
  114. package/docs/api/interfaces/AgentVisibleRequestRecord.md +13 -13
  115. package/docs/api/interfaces/AgentVisibleSecretRecord.md +13 -13
  116. package/docs/api/interfaces/AuditEntry.md +45 -25
  117. package/docs/api/interfaces/CbioRuntime.md +10 -10
  118. package/docs/api/interfaces/CreateAgentClientOptions.md +1 -1
  119. package/docs/api/interfaces/CreateIdentityOptions.md +1 -1
  120. package/docs/api/interfaces/CreateOwnerClientOptions.md +3 -13
  121. package/docs/api/interfaces/CreateOwnerSessionOptions.md +4 -10
  122. package/docs/api/interfaces/CreatePersistentVaultCoreDependenciesOptions.md +3 -3
  123. package/docs/api/interfaces/CreateVaultOptions.md +2 -2
  124. package/docs/api/interfaces/CreatedVault.md +1 -1
  125. package/docs/api/interfaces/DefaultPolicyEngineOptions.md +9 -9
  126. package/docs/api/interfaces/DispatchAuthorization.md +11 -11
  127. package/docs/api/interfaces/DispatchInstruction.md +9 -9
  128. package/docs/api/interfaces/DispatchRequest.md +11 -11
  129. package/docs/api/interfaces/DispatchResult.md +11 -11
  130. package/docs/api/interfaces/IStorageProvider.md +1 -1
  131. package/docs/api/interfaces/InitializeVaultCustodyOptions.md +1 -1
  132. package/docs/api/interfaces/InitializedVaultCustody.md +1 -1
  133. package/docs/api/interfaces/OwnerAgentProvisionResult.md +3 -3
  134. package/docs/api/interfaces/OwnerClient.md +5 -5
  135. package/docs/api/interfaces/OwnerCreateSecretInput.md +3 -3
  136. package/docs/api/interfaces/OwnerRemoveSecretInput.md +3 -3
  137. package/docs/api/interfaces/OwnerRequestRecord.md +19 -19
  138. package/docs/api/interfaces/OwnerSensitiveActionConfirmation.md +1 -1
  139. package/docs/api/interfaces/OwnerSensitiveActionContext.md +1 -1
  140. package/docs/api/interfaces/OwnerSession.md +3 -3
  141. package/docs/api/interfaces/OwnerUpdateSecretInput.md +3 -3
  142. package/docs/api/interfaces/OwnerVisibleRequestRecord.md +21 -21
  143. package/docs/api/interfaces/RecoverVaultOptions.md +4 -4
  144. package/docs/api/interfaces/RecoveredVault.md +1 -1
  145. package/docs/api/interfaces/RequestRecord.md +19 -19
  146. package/docs/api/interfaces/RestoreIdentityOptions.md +1 -1
  147. package/docs/api/interfaces/SecretAlias.md +1 -1
  148. package/docs/api/interfaces/SecretDestinationGrant.md +11 -11
  149. package/docs/api/interfaces/SecretId.md +1 -1
  150. package/docs/api/interfaces/SecretRecord.md +13 -13
  151. package/docs/api/interfaces/Signer.md +1 -1
  152. package/docs/api/interfaces/VaultApproveDispatchInput.md +5 -5
  153. package/docs/api/interfaces/VaultAuditQueryInput.md +7 -7
  154. package/docs/api/interfaces/VaultCoreDependenciesOptions.md +5 -5
  155. package/docs/api/interfaces/VaultCreateAgentInput.md +3 -3
  156. package/docs/api/interfaces/VaultExportSecretInput.md +3 -3
  157. package/docs/api/interfaces/VaultGetRequestInput.md +5 -5
  158. package/docs/api/interfaces/VaultGrantAgentSecretInput.md +7 -7
  159. package/docs/api/interfaces/VaultGrantSecretDestinationInput.md +7 -7
  160. package/docs/api/interfaces/VaultId.md +1 -1
  161. package/docs/api/interfaces/VaultImportAgentInput.md +5 -5
  162. package/docs/api/interfaces/VaultIssueSessionTokenInput.md +5 -5
  163. package/docs/api/interfaces/VaultListAgentsInput.md +3 -3
  164. package/docs/api/interfaces/VaultListGrantsInput.md +7 -7
  165. package/docs/api/interfaces/VaultListRequestsInput.md +5 -5
  166. package/docs/api/interfaces/VaultListSecretsInput.md +3 -3
  167. package/docs/api/interfaces/VaultMetadata.md +1 -1
  168. package/docs/api/interfaces/VaultObject.md +1 -1
  169. package/docs/api/interfaces/VaultPrincipal.md +1 -1
  170. package/docs/api/interfaces/VaultProfile.md +1 -1
  171. package/docs/api/interfaces/VaultReadAgentPrivateKeyInput.md +5 -5
  172. package/docs/api/interfaces/VaultReadSecretPlaintextInput.md +3 -3
  173. package/docs/api/interfaces/VaultRevokeAgentSecretInput.md +7 -7
  174. package/docs/api/interfaces/VaultRevokeSecretDestinationInput.md +7 -7
  175. package/docs/api/interfaces/VaultRevokeSessionTokenInput.md +1 -1
  176. package/docs/api/interfaces/VaultService.md +8 -8
  177. package/docs/api/interfaces/VaultUpdateAgentInput.md +5 -5
  178. package/docs/api/type-aliases/AgentId.md +1 -1
  179. package/docs/api/type-aliases/CbioRuntimeModule.md +1 -1
  180. package/docs/api/type-aliases/DispatchApprovalDecision.md +1 -1
  181. package/docs/api/type-aliases/GrantStatus.md +1 -1
  182. package/docs/api/type-aliases/SecretLifecycleStatus.md +1 -1
  183. package/docs/api/type-aliases/VaultPrincipalKind.md +1 -1
  184. package/docs/api/variables/DEFAULT_VAULT_KEY_CUSTODY_BLOB_KEY.md +1 -1
  185. package/docs/zh/README.md +1 -1
  186. package/examples/process-isolation.ts +21 -21
  187. package/package.json +2 -2
  188. package/docs/api/enumerations/AuditAction.md +0 -143
  189. package/docs/api/enumerations/AuditOutcome.md +0 -35
@@ -18,17 +18,17 @@ export interface SecretVersion {
18
18
  }
19
19
  export type SecretLifecycleStatus = "ACTIVE" | "SUPERSEDED" | "REMOVED";
20
20
  export interface SecretRecord {
21
- vaultId: VaultId;
22
- secretId: SecretId;
21
+ vault_id: VaultId;
22
+ secret_id: SecretId;
23
23
  alias: SecretAlias;
24
24
  version: SecretVersion;
25
- lifecycleStatus: SecretLifecycleStatus;
25
+ lifecycle_status: SecretLifecycleStatus;
26
26
  previousSecretId?: SecretId;
27
27
  supersededBySecretId?: SecretId;
28
- issuerId: string | null;
28
+ issuer_id: string | null;
29
29
  source: SecretSource;
30
- createdAt: string;
31
- updatedAt: string;
30
+ created_at: string;
31
+ updated_at: string;
32
32
  supersededAt?: string;
33
33
  removedAt?: string;
34
34
  retiredAt?: string;
@@ -37,57 +37,57 @@ export type SecretSource = {
37
37
  kind: "manual";
38
38
  } | {
39
39
  kind: "request";
40
- requestId: string;
40
+ request_id: string;
41
41
  };
42
42
  export interface SecretSourceInput {
43
43
  kind: "manual" | "request";
44
- requestId?: string;
44
+ request_id?: string;
45
45
  }
46
46
  export type GrantStatus = "pending" | "approved";
47
47
  export interface AgentSecretGrant {
48
- vaultId: VaultId;
49
- rootAgentId: string;
50
- secretAlias: string;
48
+ vault_id: VaultId;
49
+ root_agent_id: string;
50
+ secret_alias: string;
51
51
  status: GrantStatus;
52
- requestedAt: string;
53
- grantedAt?: string;
52
+ requested_at: string;
53
+ granted_at?: string;
54
54
  }
55
55
  export interface SecretDestinationGrant {
56
- vaultId: VaultId;
57
- secretAlias: string;
58
- siteId: string;
56
+ vault_id: VaultId;
57
+ secret_alias: string;
58
+ site_id: string;
59
59
  status: GrantStatus;
60
- requestedAt: string;
61
- grantedAt?: string;
60
+ requested_at: string;
61
+ granted_at?: string;
62
62
  }
63
63
  export type DispatchApprovalDecision = "allow_once" | "allow_and_grant" | "deny";
64
64
  export interface OwnerCreateSecretCommand {
65
65
  kind: "owner.create_secret";
66
- vaultId: VaultId;
67
- requestId: string;
66
+ vault_id: VaultId;
67
+ request_id: string;
68
68
  owner: VaultPrincipal & {
69
69
  kind: "owner";
70
70
  };
71
71
  alias: string;
72
72
  plaintext: string;
73
73
  source?: SecretSourceInput;
74
- requestedAt: string;
74
+ requested_at: string;
75
75
  }
76
76
  export interface OwnerUpdateSecretCommand {
77
77
  kind: "owner.update_secret";
78
- vaultId: VaultId;
79
- requestId: string;
78
+ vault_id: VaultId;
79
+ request_id: string;
80
80
  owner: VaultPrincipal & {
81
81
  kind: "owner";
82
82
  };
83
83
  alias: string;
84
84
  plaintext: string;
85
85
  source?: SecretSourceInput;
86
- requestedAt: string;
86
+ requested_at: string;
87
87
  }
88
88
  export interface IssuerWriteSecretCommand {
89
89
  kind: "issuer.write_secret";
90
- vaultId: VaultId;
90
+ vault_id: VaultId;
91
91
  issuer: VaultPrincipal & {
92
92
  kind: "trusted_issuer";
93
93
  };
@@ -95,145 +95,145 @@ export interface IssuerWriteSecretCommand {
95
95
  plaintext: string;
96
96
  issuerSiteId: string;
97
97
  source?: SecretSourceInput;
98
- requestedAt: string;
98
+ requested_at: string;
99
99
  }
100
100
  export interface OwnerDeleteSecretCommand {
101
101
  kind: "owner.remove_secret";
102
- vaultId: VaultId;
103
- requestId: string;
102
+ vault_id: VaultId;
103
+ request_id: string;
104
104
  owner: VaultPrincipal & {
105
105
  kind: "owner";
106
106
  };
107
107
  alias: string;
108
- requestedAt: string;
108
+ requested_at: string;
109
109
  }
110
110
  export type VaultWriteSecretCommand = OwnerCreateSecretCommand | OwnerUpdateSecretCommand | IssuerWriteSecretCommand;
111
111
  export interface OwnerRegisterAgentIdentityCommand {
112
- vaultId: VaultId;
113
- requestId: string;
112
+ vault_id: VaultId;
113
+ request_id: string;
114
114
  owner: VaultPrincipal & {
115
115
  kind: "owner";
116
116
  };
117
117
  agentRecord: AgentIdentityRecord;
118
- requestedAt: string;
118
+ requested_at: string;
119
119
  }
120
120
  export interface OwnerUpdateAgentIdentityCommand {
121
- vaultId: VaultId;
122
- requestId: string;
121
+ vault_id: VaultId;
122
+ request_id: string;
123
123
  owner: VaultPrincipal & {
124
124
  kind: "owner";
125
125
  };
126
- rootAgentId: string;
126
+ root_agent_id: string;
127
127
  nickname?: string;
128
128
  metadata?: Record<string, any>;
129
- requestedAt: string;
129
+ requested_at: string;
130
130
  }
131
131
  export interface OwnerGrantAgentSecretCommand {
132
- vaultId: VaultId;
133
- requestId: string;
132
+ vault_id: VaultId;
133
+ request_id: string;
134
134
  actor: VaultPrincipal & {
135
135
  kind: "owner";
136
136
  };
137
- rootAgentId: string;
138
- secretAlias: string;
139
- requestedAt: string;
137
+ root_agent_id: string;
138
+ secret_alias: string;
139
+ requested_at: string;
140
140
  }
141
141
  export interface OwnerGrantSecretDestinationCommand {
142
- vaultId: VaultId;
143
- requestId: string;
142
+ vault_id: VaultId;
143
+ request_id: string;
144
144
  actor: VaultPrincipal & {
145
145
  kind: "owner";
146
146
  };
147
- secretAlias: string;
148
- siteId: string;
149
- requestedAt: string;
147
+ secret_alias: string;
148
+ site_id: string;
149
+ requested_at: string;
150
150
  }
151
151
  export interface OwnerRevokeAgentSecretCommand {
152
- vaultId: VaultId;
153
- requestId: string;
152
+ vault_id: VaultId;
153
+ request_id: string;
154
154
  actor: VaultPrincipal & {
155
155
  kind: "owner";
156
156
  };
157
- rootAgentId: string;
158
- secretAlias: string;
159
- requestedAt: string;
157
+ root_agent_id: string;
158
+ secret_alias: string;
159
+ requested_at: string;
160
160
  }
161
161
  export interface OwnerRevokeSecretDestinationCommand {
162
- vaultId: VaultId;
163
- requestId: string;
162
+ vault_id: VaultId;
163
+ request_id: string;
164
164
  actor: VaultPrincipal & {
165
165
  kind: "owner";
166
166
  };
167
- secretAlias: string;
168
- siteId: string;
169
- requestedAt: string;
167
+ secret_alias: string;
168
+ site_id: string;
169
+ requested_at: string;
170
170
  }
171
171
  export interface AgentProof {
172
- rootAgentId: string;
173
- requestId: string;
174
- requestedAt: string;
172
+ root_agent_id: string;
173
+ request_id: string;
174
+ requested_at: string;
175
175
  signature?: string;
176
176
  token?: string;
177
177
  }
178
178
  export interface AgentVisibleSecretRecord {
179
- vaultId: VaultId;
180
- secretId: SecretId;
179
+ vault_id: VaultId;
180
+ secret_id: SecretId;
181
181
  alias: SecretAlias;
182
182
  version: SecretVersion;
183
- lifecycleStatus: SecretLifecycleStatus;
184
- issuerId: string | null;
183
+ lifecycle_status: SecretLifecycleStatus;
184
+ issuer_id: string | null;
185
185
  source: SecretSource;
186
- createdAt: string;
187
- updatedAt: string;
186
+ created_at: string;
187
+ updated_at: string;
188
188
  granted: boolean;
189
189
  }
190
190
  export interface AgentGetRuntimeManifestRequest {
191
- vaultId: VaultId;
192
- requestId: string;
191
+ vault_id: VaultId;
192
+ request_id: string;
193
193
  agent: VaultPrincipal & {
194
194
  kind: "agent";
195
195
  };
196
196
  proof: AgentProof;
197
- requestedAt: string;
197
+ requested_at: string;
198
198
  }
199
199
  export interface AgentGetRuntimeManifestCommand {
200
- vaultId: VaultId;
201
- requestId: string;
200
+ vault_id: VaultId;
201
+ request_id: string;
202
202
  agent: VaultPrincipal & {
203
203
  kind: "agent";
204
204
  };
205
- requestedAt: string;
205
+ requested_at: string;
206
206
  }
207
207
  export interface AgentSelfContext {
208
- rootAgentId: string;
209
- publicKey: string;
208
+ root_agent_id: string;
209
+ public_key: string;
210
210
  nickname?: string;
211
211
  metadata?: Record<string, any>;
212
212
  }
213
213
  export interface AgentRuntimeManifest {
214
- rootAgentId: string;
215
- vaultId: string;
216
- vaultNickname?: string;
217
- issuedAt: string;
214
+ root_agent_id: string;
215
+ vault_id: string;
216
+ vault_nickname?: string;
217
+ issued_at: string;
218
218
  agent: AgentSelfContext;
219
219
  grants: {
220
- agentSecrets: readonly AgentSecretGrant[];
221
- secretDestinations: readonly SecretDestinationGrant[];
220
+ agent_secrets: readonly AgentSecretGrant[];
221
+ secret_destinations: readonly SecretDestinationGrant[];
222
222
  };
223
223
  tools: readonly VaultToolDefinition[];
224
224
  }
225
225
  export interface RequestRecord {
226
- vaultId: VaultId;
227
- requestId: string;
228
- rootAgentId: string;
226
+ vault_id: VaultId;
227
+ request_id: string;
228
+ root_agent_id: string;
229
229
  reason: string;
230
- createdAt: string;
230
+ created_at: string;
231
231
  request: {
232
- targetUrl: string;
232
+ target_url: string;
233
233
  method: string;
234
234
  headers?: Record<string, string>;
235
235
  body?: string;
236
- secretAlias?: string;
236
+ secret_alias?: string;
237
237
  };
238
238
  response?: {
239
239
  status?: number;
@@ -244,47 +244,47 @@ export interface RequestRecord {
244
244
  execution: {
245
245
  status: DispatchStatus;
246
246
  };
247
- missingGrants?: {
248
- agentSecret?: boolean;
249
- secretDestination?: boolean;
247
+ missing_grants?: {
248
+ agent_secret?: boolean;
249
+ secret_destination?: boolean;
250
250
  };
251
251
  }
252
252
  export interface AgentVisibleRequestRecord {
253
- requestId: string;
254
- createdAt: string;
253
+ request_id: string;
254
+ created_at: string;
255
255
  reason: string;
256
- targetUrl: string;
257
- executionStatus: DispatchStatus;
258
- responseStatus?: number;
256
+ target_url: string;
257
+ execution_status: DispatchStatus;
258
+ response_status?: number;
259
259
  error?: string;
260
- hasResponseBody: boolean;
260
+ has_response_body: boolean;
261
261
  }
262
262
  export interface OwnerVisibleRequestRecord {
263
- requestId: string;
264
- createdAt: string;
265
- rootAgentId: string;
263
+ request_id: string;
264
+ created_at: string;
265
+ root_agent_id: string;
266
266
  reason: string;
267
- targetUrl: string;
268
- executionStatus: DispatchStatus;
269
- responseStatus?: number;
267
+ target_url: string;
268
+ execution_status: DispatchStatus;
269
+ response_status?: number;
270
270
  error?: string;
271
- hasResponseBody: boolean;
272
- missingGrants?: {
273
- agentSecret?: boolean;
274
- secretDestination?: boolean;
271
+ has_response_body: boolean;
272
+ missing_grants?: {
273
+ agent_secret?: boolean;
274
+ secret_destination?: boolean;
275
275
  };
276
276
  }
277
277
  export interface OwnerRequestRecord {
278
- requestId: string;
279
- createdAt: string;
280
- rootAgentId: string;
278
+ request_id: string;
279
+ created_at: string;
280
+ root_agent_id: string;
281
281
  reason: string;
282
282
  request: {
283
- targetUrl: string;
283
+ target_url: string;
284
284
  method: string;
285
285
  headers?: Record<string, string>;
286
286
  body?: string;
287
- secretAlias?: string;
287
+ secret_alias?: string;
288
288
  };
289
289
  response?: {
290
290
  status?: number;
@@ -292,10 +292,10 @@ export interface OwnerRequestRecord {
292
292
  body?: string;
293
293
  error?: string;
294
294
  };
295
- executionStatus: DispatchStatus;
296
- missingGrants?: {
297
- agentSecret?: boolean;
298
- secretDestination?: boolean;
295
+ execution_status: DispatchStatus;
296
+ missing_grants?: {
297
+ agent_secret?: boolean;
298
+ secret_destination?: boolean;
299
299
  };
300
300
  }
301
301
  export interface VaultToolDefinition {
@@ -304,80 +304,80 @@ export interface VaultToolDefinition {
304
304
  parameters: Record<string, any>;
305
305
  }
306
306
  export interface AgentListGrantsRequest {
307
- vaultId: VaultId;
308
- requestId: string;
309
- requestedAt: string;
307
+ vault_id: VaultId;
308
+ request_id: string;
309
+ requested_at: string;
310
310
  agent: VaultPrincipal & {
311
311
  kind: "agent";
312
312
  };
313
313
  proof: AgentProof;
314
314
  }
315
315
  export interface AgentListSecretsRequest {
316
- vaultId: VaultId;
317
- requestId: string;
318
- requestedAt: string;
316
+ vault_id: VaultId;
317
+ request_id: string;
318
+ requested_at: string;
319
319
  agent: VaultPrincipal & {
320
320
  kind: "agent";
321
321
  };
322
322
  proof: AgentProof;
323
323
  }
324
324
  export interface AgentListRequestsRequest {
325
- vaultId: VaultId;
326
- requestId: string;
327
- requestedAt: string;
325
+ vault_id: VaultId;
326
+ request_id: string;
327
+ requested_at: string;
328
328
  agent: VaultPrincipal & {
329
329
  kind: "agent";
330
330
  };
331
331
  proof: AgentProof;
332
332
  }
333
333
  export interface AgentGetRequestRequest {
334
- vaultId: VaultId;
335
- requestId: string;
336
- requestedAt: string;
334
+ vault_id: VaultId;
335
+ request_id: string;
336
+ requested_at: string;
337
337
  agent: VaultPrincipal & {
338
338
  kind: "agent";
339
339
  };
340
340
  proof: AgentProof;
341
- targetRequestId: string;
341
+ target_request_id: string;
342
342
  }
343
343
  export interface OwnerListRequestsRequest {
344
- vaultId: VaultId;
345
- requestId: string;
344
+ vault_id: VaultId;
345
+ request_id: string;
346
346
  actor: VaultPrincipal & {
347
347
  kind: "owner";
348
348
  };
349
- rootAgentId?: string;
350
- requestedAt: string;
349
+ root_agent_id?: string;
350
+ requested_at: string;
351
351
  }
352
352
  export interface OwnerGetRequestRequest {
353
- vaultId: VaultId;
354
- requestId: string;
353
+ vault_id: VaultId;
354
+ request_id: string;
355
355
  actor: VaultPrincipal & {
356
356
  kind: "owner";
357
357
  };
358
- targetRequestId: string;
359
- requestedAt: string;
358
+ target_request_id: string;
359
+ requested_at: string;
360
360
  }
361
361
  export interface OwnerApproveDispatchCommand {
362
- vaultId: VaultId;
363
- requestId: string;
362
+ vault_id: VaultId;
363
+ request_id: string;
364
364
  actor: VaultPrincipal & {
365
365
  kind: "owner";
366
366
  };
367
367
  decision: DispatchApprovalDecision;
368
- requestedAt: string;
368
+ requested_at: string;
369
369
  }
370
370
  export interface DispatchRequest {
371
- vaultId: VaultId;
372
- requestId: string;
373
- requestedAt: string;
371
+ vault_id: VaultId;
372
+ request_id: string;
373
+ requested_at: string;
374
374
  agent: VaultPrincipal & {
375
375
  kind: "agent";
376
376
  };
377
377
  proof: AgentProof;
378
- secretAlias?: string;
378
+ secret_alias?: string;
379
379
  reason: string;
380
- targetUrl: string;
380
+ target_url: string;
381
381
  method: string;
382
382
  headers?: Record<string, string>;
383
383
  body?: string;
@@ -385,20 +385,20 @@ export interface DispatchRequest {
385
385
  }
386
386
  export type DispatchDecision = "allow" | "deny" | "pending";
387
387
  export interface DispatchAuthorization {
388
- vaultId: VaultId;
388
+ vault_id: VaultId;
389
389
  decision: DispatchDecision;
390
390
  reason: string | null;
391
- secretId: SecretId | null;
392
- missingGrants?: {
393
- agentSecret?: boolean;
394
- secretDestination?: boolean;
391
+ secret_id: SecretId | null;
392
+ missing_grants?: {
393
+ agent_secret?: boolean;
394
+ secret_destination?: boolean;
395
395
  };
396
396
  }
397
397
  export interface DispatchInstruction {
398
- vaultId: VaultId;
399
- requestId: string;
400
- secretId: SecretId;
401
- targetUrl: string;
398
+ vault_id: VaultId;
399
+ request_id: string;
400
+ secret_id: SecretId;
401
+ target_url: string;
402
402
  method: string;
403
403
  headers?: Record<string, string>;
404
404
  body?: string;
@@ -411,146 +411,143 @@ export declare enum DispatchStatus {
411
411
  STALLED = "STALLED"
412
412
  }
413
413
  export interface DispatchResult {
414
- vaultId: VaultId;
415
- requestId: string;
414
+ vault_id: VaultId;
415
+ request_id: string;
416
416
  status: DispatchStatus;
417
- targetUrl: string;
417
+ target_url: string;
418
418
  method: string;
419
- responseStatus?: number;
420
- responseBody?: string;
419
+ response_status?: number;
420
+ response_body?: string;
421
421
  error?: string;
422
422
  }
423
423
  export interface AgentRequestResult {
424
- requestId: string;
425
- executionStatus: DispatchStatus;
426
- responseStatus?: number;
427
- responseBody?: string;
424
+ request_id: string;
425
+ execution_status: DispatchStatus;
426
+ response_status?: number;
427
+ response_body?: string;
428
428
  error?: string;
429
429
  }
430
430
  export interface AuditQuery {
431
- vaultId: VaultId;
432
- actorId?: string;
433
- secretAlias?: string;
434
- requestId?: string;
431
+ vault_id: string;
432
+ actor_id?: string;
433
+ secret_alias?: string;
434
+ request_id?: string;
435
435
  since?: string;
436
436
  }
437
- export declare enum AuditAction {
438
- REGISTER_AGENT_IDENTITY = "REGISTER_AGENT_IDENTITY",
439
- UPDATE_AGENT_IDENTITY = "UPDATE_AGENT_IDENTITY",
440
- GRANT_AGENT_SECRET = "GRANT_AGENT_SECRET",
441
- GRANT_SECRET_DESTINATION = "GRANT_SECRET_DESTINATION",
442
- REVOKE_AGENT_SECRET = "REVOKE_AGENT_SECRET",
443
- REVOKE_SECRET_DESTINATION = "REVOKE_SECRET_DESTINATION",
444
- WRITE_SECRET = "WRITE_SECRET",
445
- EXPORT_SECRET = "EXPORT_SECRET",
446
- REASSIGN_ALIAS = "REASSIGN_ALIAS",
447
- DELETE_SECRET = "DELETE_SECRET",
448
- EVALUATE_DISPATCH_POLICY = "EVALUATE_DISPATCH_POLICY",
449
- DISPATCH_SECRET = "DISPATCH_SECRET",
450
- LIST_AGENTS = "LIST_AGENTS",
451
- LIST_GRANTS = "LIST_GRANTS",
452
- LIST_REQUESTS = "LIST_REQUESTS",
453
- READ_REQUEST = "READ_REQUEST",
454
- READ_AUDIT = "READ_AUDIT",
455
- LIST_SECRETS = "LIST_SECRETS",
456
- ISSUE_SESSION_TOKEN = "ISSUE_SESSION_TOKEN",
457
- REVOKE_SESSION_TOKEN = "REVOKE_SESSION_TOKEN",
458
- APPROVE_DISPATCH = "APPROVE_DISPATCH",
459
- REJECT_DISPATCH = "REJECT_DISPATCH",
460
- PENDING_DISPATCH_APPROVAL = "PENDING_DISPATCH_APPROVAL"
461
- }
462
- export declare enum AuditOutcome {
463
- ALLOWED = "ALLOWED",
464
- DENIED = "DENIED",
465
- SUCCEEDED = "SUCCEEDED",
466
- FAILED = "FAILED",
467
- PENDING = "PENDING"
437
+ export declare enum AuditOperation {
438
+ IDENTITY_REGISTER = "identity.register",
439
+ IDENTITY_UPDATE = "identity.update",
440
+ IDENTITY_ISSUE_TOKEN = "identity.issue_token",
441
+ IDENTITY_REVOKE_TOKEN = "identity.revoke_token",
442
+ GRANT_SECRET = "grant.grant_secret",
443
+ GRANT_DESTINATION = "grant.grant_destination",
444
+ REVOKE_SECRET = "grant.revoke_secret",
445
+ REVOKE_DESTINATION = "grant.revoke_destination",
446
+ SECRET_WRITE = "secret.write",
447
+ SECRET_EXPORT = "secret.export",
448
+ SECRET_DELETE = "secret.delete",
449
+ POLICY_EVALUATE = "policy.evaluate_dispatch",
450
+ SECRET_DISPATCH = "secret.dispatch",
451
+ DISPATCH_APPROVE = "dispatch.approve",
452
+ DISPATCH_REJECT = "dispatch.reject",
453
+ DISPATCH_HOLD = "dispatch.pending_approval",
454
+ MANAGEMENT_LIST_AGENTS = "management.list_agents",
455
+ MANAGEMENT_LIST_GRANTS = "management.list_grants",
456
+ MANAGEMENT_LIST_REQUESTS = "management.list_requests",
457
+ MANAGEMENT_READ_REQUEST = "management.read_request",
458
+ MANAGEMENT_READ_AUDIT = "management.read_audit",
459
+ MANAGEMENT_LIST_SECRETS = "management.list_secrets"
468
460
  }
469
461
  export interface AuditEntry {
470
- entryId: string;
471
- occurredAt: string;
472
- vaultId: VaultId;
462
+ event_id: string;
463
+ ts: string;
464
+ vault_id: string;
473
465
  actor: VaultPrincipal;
474
- action: AuditAction;
475
- requestId?: string;
476
- targetUrl?: string;
477
- secretAlias?: string;
478
- secretId?: string;
479
- rootAgentId?: string;
480
- siteId?: string;
481
- outcome: AuditOutcome;
466
+ operation: AuditOperation;
467
+ decision: "allowed" | "denied";
468
+ execution_status: "not_executed" | "succeeded" | "failed";
469
+ request_id?: string;
470
+ secret_alias?: string;
471
+ secret_id?: string;
472
+ root_agent_id?: string;
473
+ site_id?: string;
474
+ target?: {
475
+ kind: "http" | "other";
476
+ url: string;
477
+ };
482
478
  detail: string;
479
+ error_code?: string | null;
483
480
  }
484
481
  export interface AgentIdentityRecord {
485
- vaultId: VaultId;
486
- rootAgentId: string;
487
- publicKey: string;
488
- privateKey?: string;
482
+ vault_id: VaultId;
483
+ root_agent_id: string;
484
+ public_key: string;
485
+ private_key?: string;
489
486
  metadata?: Record<string, any>;
490
487
  nickname?: string;
491
- sessionTokens?: readonly StoredSessionToken[];
488
+ session_tokens?: readonly StoredSessionToken[];
492
489
  }
493
490
  export interface StoredSessionToken {
494
491
  token: string;
495
- rootAgentId: string;
496
- issuedAt: string;
497
- expiresAt?: string;
492
+ root_agent_id: string;
493
+ issued_at: string;
494
+ expires_at?: string;
498
495
  }
499
496
  export interface OwnerAuditRequest {
500
- vaultId: VaultId;
497
+ vault_id: VaultId;
501
498
  actor: VaultPrincipal & {
502
499
  kind: "owner";
503
500
  };
504
501
  query: AuditQuery;
505
- requestId: string;
506
- requestedAt: string;
502
+ request_id: string;
503
+ requested_at: string;
507
504
  }
508
505
  export interface OwnerExportSecretRequest {
509
- vaultId: VaultId;
506
+ vault_id: VaultId;
510
507
  actor: VaultPrincipal & {
511
508
  kind: "owner";
512
509
  };
513
510
  alias: string;
514
- requestId: string;
515
- requestedAt: string;
511
+ request_id: string;
512
+ requested_at: string;
516
513
  }
517
514
  export interface OwnerSecretExport {
518
- vaultId: VaultId;
519
- secretId: SecretId;
515
+ vault_id: VaultId;
516
+ secret_id: SecretId;
520
517
  alias: SecretAlias;
521
518
  plaintext: string;
522
- exportedAt: string;
519
+ exported_at: string;
523
520
  }
524
521
  export interface OwnerListAgentsRequest {
525
- vaultId: VaultId;
526
- requestId: string;
522
+ vault_id: VaultId;
523
+ request_id: string;
527
524
  actor: VaultPrincipal & {
528
525
  kind: "owner";
529
526
  };
530
- requestedAt: string;
527
+ requested_at: string;
531
528
  }
532
529
  export interface OwnerListGrantsRequest {
533
- vaultId: VaultId;
534
- requestId: string;
530
+ vault_id: VaultId;
531
+ request_id: string;
535
532
  actor: VaultPrincipal & {
536
533
  kind: "owner";
537
534
  };
538
- rootAgentId?: string;
539
- secretAlias?: string;
540
- siteId?: string;
541
- requestedAt: string;
535
+ root_agent_id?: string;
536
+ secret_alias?: string;
537
+ site_id?: string;
538
+ requested_at: string;
542
539
  }
543
540
  export interface OwnerIssueSessionTokenRequest {
544
- vaultId: VaultId;
545
- requestId: string;
541
+ vault_id: VaultId;
542
+ request_id: string;
546
543
  actor: VaultPrincipal & {
547
544
  kind: "owner";
548
545
  };
549
- rootAgentId: string;
550
- requestedAt: string;
546
+ root_agent_id: string;
547
+ requested_at: string;
551
548
  }
552
549
  export interface OwnerSessionToken {
553
550
  token: string;
554
- rootAgentId: string;
555
- issuedAt: string;
551
+ root_agent_id: string;
552
+ issued_at: string;
556
553
  }