@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
@@ -74,8 +74,8 @@ async function runAgentDemo(port: number, agentRecord: any, token: string) {
74
74
 
75
75
  try {
76
76
  const result = await agentClient.agentDispatch({
77
- secretAlias: "api-token",
78
- targetUrl: "https://httpbin.org/post",
77
+ secret_alias: "api-token",
78
+ target_url: "https://httpbin.org/post",
79
79
  method: "POST",
80
80
  reason: "LLM agent needs to perform isolated dispatch",
81
81
  body: JSON.stringify({ message: "Hello from isolated Process A" }),
@@ -101,48 +101,48 @@ async function main() {
101
101
 
102
102
  // Owner registers the agent and a grant (simulated local call for setup)
103
103
  await vault.ownerRegisterAgentIdentity({
104
- vaultId: vault.vaultId,
105
- requestId: `setup:${Date.now()}:register_agent`,
106
- owner: { kind: "owner", id: ownerIdentity.rootAgentId },
104
+ vault_id: vault.vault_id,
105
+ request_id: `setup:${Date.now()}:register_agent`,
106
+ owner: { kind: "owner", id: ownerIdentity.root_agent_id },
107
107
  agentRecord: {
108
- vaultId: vault.vaultId,
109
- rootAgentId: agentRecord.rootAgentId,
110
- publicKey: agentRecord.publicKey,
108
+ vault_id: vault.vault_id,
109
+ root_agent_id: agentRecord.root_agent_id,
110
+ public_key: agentRecord.public_key,
111
111
  },
112
- requestedAt: new Date().toISOString(),
112
+ requested_at: new Date().toISOString(),
113
113
  });
114
114
 
115
115
  // Owner writes a secret (simulated local call for setup)
116
116
  const secret = await vault.ownerCreateSecret({
117
117
  kind: "owner.create_secret",
118
- vaultId: vault.vaultId,
119
- requestId: `setup:${Date.now()}:write_secret`,
120
- owner: { kind: "owner", id: ownerIdentity.rootAgentId },
118
+ vault_id: vault.vault_id,
119
+ request_id: `setup:${Date.now()}:write_secret`,
120
+ owner: { kind: "owner", id: ownerIdentity.root_agent_id },
121
121
  alias: "api-token",
122
122
  plaintext: "SK-PROD-12345",
123
123
  source: { kind: "manual" },
124
- requestedAt: new Date().toISOString(),
124
+ requested_at: new Date().toISOString(),
125
125
  });
126
126
 
127
127
  // Owner grants permissions (New Grant-based API)
128
128
  await vault.ownerGrantAgentSecret(
129
- { kind: "owner", id: ownerIdentity.rootAgentId },
130
- agentRecord.rootAgentId,
129
+ { kind: "owner", id: ownerIdentity.root_agent_id },
130
+ agentRecord.root_agent_id,
131
131
  "api-token"
132
132
  );
133
133
 
134
134
  await vault.ownerGrantSecretDestination(
135
- { kind: "owner", id: ownerIdentity.rootAgentId },
135
+ { kind: "owner", id: ownerIdentity.root_agent_id },
136
136
  "api-token",
137
137
  "httpbin.org"
138
138
  );
139
139
 
140
140
  const session = await vault.ownerIssueSessionToken({
141
- vaultId: vault.vaultId,
142
- requestId: `setup:${Date.now()}:issue_session_token`,
143
- actor: { kind: "owner", id: ownerIdentity.rootAgentId },
144
- rootAgentId: agentRecord.rootAgentId,
145
- requestedAt: new Date().toISOString(),
141
+ vault_id: vault.vault_id,
142
+ request_id: `setup:${Date.now()}:issue_session_token`,
143
+ actor: { kind: "owner", id: ownerIdentity.root_agent_id },
144
+ root_agent_id: agentRecord.root_agent_id,
145
+ requested_at: new Date().toISOString(),
146
146
  });
147
147
 
148
148
  // 3. Run the "LLM Agent" (Process A)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@the-ai-company/cbio-node-runtime",
3
- "version": "1.63.6",
3
+ "version": "1.63.8",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -28,7 +28,7 @@
28
28
  "scripts": {
29
29
  "build": "tsc",
30
30
  "build:docs": "npx typedoc --options typedoc.json",
31
- "release": "npx standard-version && npm publish",
31
+ "release": "npm test && npx standard-version && npm publish",
32
32
  "prepare": "npm run build && npm run build:docs",
33
33
  "test": "npm run build && npm run test:types && npm run test:acceptance",
34
34
  "test:types": "tsc -p tsconfig.type-tests.json --noEmit",
@@ -1,143 +0,0 @@
1
- [**CBIO Node Runtime Agent API v1.63.6**](../README.md)
2
-
3
- ***
4
-
5
- # Enumeration: AuditAction
6
-
7
- ## Enumeration Members
8
-
9
- ### APPROVE\_DISPATCH
10
-
11
- > **APPROVE\_DISPATCH**: `"APPROVE_DISPATCH"`
12
-
13
- ***
14
-
15
- ### DELETE\_SECRET
16
-
17
- > **DELETE\_SECRET**: `"DELETE_SECRET"`
18
-
19
- ***
20
-
21
- ### DISPATCH\_SECRET
22
-
23
- > **DISPATCH\_SECRET**: `"DISPATCH_SECRET"`
24
-
25
- ***
26
-
27
- ### EVALUATE\_DISPATCH\_POLICY
28
-
29
- > **EVALUATE\_DISPATCH\_POLICY**: `"EVALUATE_DISPATCH_POLICY"`
30
-
31
- ***
32
-
33
- ### EXPORT\_SECRET
34
-
35
- > **EXPORT\_SECRET**: `"EXPORT_SECRET"`
36
-
37
- ***
38
-
39
- ### GRANT\_AGENT\_SECRET
40
-
41
- > **GRANT\_AGENT\_SECRET**: `"GRANT_AGENT_SECRET"`
42
-
43
- ***
44
-
45
- ### GRANT\_SECRET\_DESTINATION
46
-
47
- > **GRANT\_SECRET\_DESTINATION**: `"GRANT_SECRET_DESTINATION"`
48
-
49
- ***
50
-
51
- ### ISSUE\_SESSION\_TOKEN
52
-
53
- > **ISSUE\_SESSION\_TOKEN**: `"ISSUE_SESSION_TOKEN"`
54
-
55
- ***
56
-
57
- ### LIST\_AGENTS
58
-
59
- > **LIST\_AGENTS**: `"LIST_AGENTS"`
60
-
61
- ***
62
-
63
- ### LIST\_GRANTS
64
-
65
- > **LIST\_GRANTS**: `"LIST_GRANTS"`
66
-
67
- ***
68
-
69
- ### LIST\_REQUESTS
70
-
71
- > **LIST\_REQUESTS**: `"LIST_REQUESTS"`
72
-
73
- ***
74
-
75
- ### LIST\_SECRETS
76
-
77
- > **LIST\_SECRETS**: `"LIST_SECRETS"`
78
-
79
- ***
80
-
81
- ### PENDING\_DISPATCH\_APPROVAL
82
-
83
- > **PENDING\_DISPATCH\_APPROVAL**: `"PENDING_DISPATCH_APPROVAL"`
84
-
85
- ***
86
-
87
- ### READ\_AUDIT
88
-
89
- > **READ\_AUDIT**: `"READ_AUDIT"`
90
-
91
- ***
92
-
93
- ### READ\_REQUEST
94
-
95
- > **READ\_REQUEST**: `"READ_REQUEST"`
96
-
97
- ***
98
-
99
- ### REASSIGN\_ALIAS
100
-
101
- > **REASSIGN\_ALIAS**: `"REASSIGN_ALIAS"`
102
-
103
- ***
104
-
105
- ### REGISTER\_AGENT\_IDENTITY
106
-
107
- > **REGISTER\_AGENT\_IDENTITY**: `"REGISTER_AGENT_IDENTITY"`
108
-
109
- ***
110
-
111
- ### REJECT\_DISPATCH
112
-
113
- > **REJECT\_DISPATCH**: `"REJECT_DISPATCH"`
114
-
115
- ***
116
-
117
- ### REVOKE\_AGENT\_SECRET
118
-
119
- > **REVOKE\_AGENT\_SECRET**: `"REVOKE_AGENT_SECRET"`
120
-
121
- ***
122
-
123
- ### REVOKE\_SECRET\_DESTINATION
124
-
125
- > **REVOKE\_SECRET\_DESTINATION**: `"REVOKE_SECRET_DESTINATION"`
126
-
127
- ***
128
-
129
- ### REVOKE\_SESSION\_TOKEN
130
-
131
- > **REVOKE\_SESSION\_TOKEN**: `"REVOKE_SESSION_TOKEN"`
132
-
133
- ***
134
-
135
- ### UPDATE\_AGENT\_IDENTITY
136
-
137
- > **UPDATE\_AGENT\_IDENTITY**: `"UPDATE_AGENT_IDENTITY"`
138
-
139
- ***
140
-
141
- ### WRITE\_SECRET
142
-
143
- > **WRITE\_SECRET**: `"WRITE_SECRET"`
@@ -1,35 +0,0 @@
1
- [**CBIO Node Runtime Agent API v1.63.6**](../README.md)
2
-
3
- ***
4
-
5
- # Enumeration: AuditOutcome
6
-
7
- ## Enumeration Members
8
-
9
- ### ALLOWED
10
-
11
- > **ALLOWED**: `"ALLOWED"`
12
-
13
- ***
14
-
15
- ### DENIED
16
-
17
- > **DENIED**: `"DENIED"`
18
-
19
- ***
20
-
21
- ### FAILED
22
-
23
- > **FAILED**: `"FAILED"`
24
-
25
- ***
26
-
27
- ### PENDING
28
-
29
- > **PENDING**: `"PENDING"`
30
-
31
- ***
32
-
33
- ### SUCCEEDED
34
-
35
- > **SUCCEEDED**: `"SUCCEEDED"`