@treeseed/sdk 0.13.0-rc.90 → 0.13.0-rc.92
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/.treeseed-build-complete.json +1 -1
- package/dist/agent-capacity/contracts/capacity/assignments/assignment-context-pack.d.ts +6 -6
- package/dist/agent-capacity/validation/agent-definition-schema.d.ts +144 -144
- package/dist/capacity-provider/environment-catalog.d.ts +12 -12
- package/dist/capacity-provider/index.d.ts +1 -0
- package/dist/capacity-provider/index.js +1 -0
- package/dist/capacity-provider/install-configuration.d.ts +39 -0
- package/dist/capacity-provider/install-configuration.js +18 -0
- package/dist/configuration/secrets-capability.d.ts +3 -0
- package/dist/configuration/secrets-capability.js +3 -0
- package/dist/content/validation/agent-operational-content-schemas.d.ts +16 -16
- package/dist/content/validation/auxiliary-content-schemas.d.ts +20 -20
- package/dist/content/validation/content-model-schemas.d.ts +304 -304
- package/dist/content/validation/portable-content-data.d.ts +28 -28
- package/dist/deployment/ai-hosting.d.ts +297 -0
- package/dist/deployment/ai-hosting.js +63 -0
- package/dist/deployment/ai-instance.d.ts +48 -0
- package/dist/deployment/ai-instance.js +23 -0
- package/dist/deployment/hosted-topology-template.d.ts +24 -24
- package/dist/deployment/hosted-topology.d.ts +114 -114
- package/dist/deployment/index.d.ts +2 -0
- package/dist/deployment/index.js +2 -0
- package/dist/deployment/schemas.d.ts +38 -38
- package/dist/development/schemas.d.ts +76 -76
- package/dist/operator-contracts/canonical-command-tree.js +3 -10
- package/dist/operator-contracts/catalog/communication-operations.d.ts +5 -5
- package/dist/operator-contracts/catalog/hosted-topology-operations.d.ts +21 -21
- package/dist/operator-contracts/catalog/inbox-operations.d.ts +8 -8
- package/dist/operator-contracts/catalog/infrastructure/ai-instance-operations.d.ts +29 -0
- package/dist/operator-contracts/catalog/infrastructure/ai-instance-operations.js +18 -0
- package/dist/operator-contracts/catalog/infrastructure/command-tree-paths.d.ts +3 -0
- package/dist/operator-contracts/catalog/infrastructure/command-tree-paths.js +15 -0
- package/dist/operator-contracts/communication/contracts.d.ts +34 -34
- package/dist/operator-contracts/control-plane-operations.d.ts +63 -34
- package/dist/operator-contracts/control-plane-operations.js +3 -17
- package/dist/operator-contracts/inbox/contracts.d.ts +30 -30
- package/dist/operator-contracts/operation-builder.d.ts +1 -0
- package/dist/operator-contracts/operation-builder.js +17 -0
- package/dist/platform/schemas.d.ts +220 -40
- package/dist/platform/schemas.js +7 -2
- package/dist/platform/workset.js +5 -1
- package/dist/secrets-capability/github-actions-encryption.js +1 -1
- package/dist/secrets-capability/provider-operation-contracts.d.ts +14 -0
- package/dist/secrets-capability/service-provider-contracts.d.ts +4 -2
- package/dist/secrets-capability/service-provider-contracts.js +41 -27
- package/dist/secrets-capability/shared-access.d.ts +51 -0
- package/dist/secrets-capability/shared-access.js +36 -0
- package/dist/secrets-capability/shared-resources.d.ts +376 -0
- package/dist/secrets-capability/shared-resources.js +91 -0
- package/dist/secrets-capability/vault-contracts.d.ts +132 -0
- package/dist/secrets-capability/vault-contracts.js +56 -0
- package/package.json +1 -1
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
const id = z.string().regex(/^[A-Za-z0-9][A-Za-z0-9_-]{0,127}$/u);
|
|
3
|
+
const path = z.string().min(1).max(512).refine((value) => value.split("/").every((segment) => /^[A-Za-z0-9][A-Za-z0-9_.-]*$/u.test(segment)), "Canonical relative vault path required.");
|
|
4
|
+
const endpoint = z.string().url().refine((value) => {
|
|
5
|
+
const url = new URL(value);
|
|
6
|
+
return url.protocol === "https:" && !url.username && !url.password && !url.search && !url.hash && url.pathname === "/";
|
|
7
|
+
}, "HTTPS origin without credentials, query or fragment required.");
|
|
8
|
+
const vaultDescriptorSchema = z.object({
|
|
9
|
+
id,
|
|
10
|
+
ownerTeamId: id.nullable(),
|
|
11
|
+
displayName: z.string().trim().min(1).max(160),
|
|
12
|
+
backend: z.enum(["managed-openbao", "external-openbao", "hashicorp-vault"]),
|
|
13
|
+
endpoint,
|
|
14
|
+
secretsMount: path,
|
|
15
|
+
namespace: path.nullable(),
|
|
16
|
+
networkRouteId: id,
|
|
17
|
+
tlsTrustId: id,
|
|
18
|
+
authentication: z.object({
|
|
19
|
+
method: z.literal("approle"),
|
|
20
|
+
mount: path,
|
|
21
|
+
roleId: z.string().min(1).max(256),
|
|
22
|
+
bootstrapCredentialRef: id
|
|
23
|
+
}).strict(),
|
|
24
|
+
status: z.enum(["unverified", "ready", "unavailable", "revoked"]),
|
|
25
|
+
version: z.number().int().nonnegative().safe()
|
|
26
|
+
}).strict();
|
|
27
|
+
const vaultAllocationSchema = z.object({
|
|
28
|
+
id,
|
|
29
|
+
vaultId: id,
|
|
30
|
+
teamId: id,
|
|
31
|
+
grantId: id.nullable(),
|
|
32
|
+
pathPrefix: path,
|
|
33
|
+
permissions: z.array(z.enum(["read", "write", "delete"])).min(1),
|
|
34
|
+
version: z.number().int().nonnegative().safe()
|
|
35
|
+
}).strict();
|
|
36
|
+
const vaultCredentialReferenceSchema = z.discriminatedUnion("mode", [
|
|
37
|
+
z.object({ mode: z.literal("managed"), vaultId: id, allocationId: id, recordPath: path }).strict(),
|
|
38
|
+
z.object({
|
|
39
|
+
mode: z.literal("existing"),
|
|
40
|
+
vaultId: id,
|
|
41
|
+
allocationId: id,
|
|
42
|
+
recordPath: path,
|
|
43
|
+
fieldMapping: z.record(id, id).refine((value) => Object.keys(value).length > 0, "At least one field mapping is required."),
|
|
44
|
+
pinnedVersion: z.number().int().positive().safe().nullable()
|
|
45
|
+
}).strict()
|
|
46
|
+
]);
|
|
47
|
+
function assertCredentialRecordMutation(reference) {
|
|
48
|
+
vaultCredentialReferenceSchema.parse(reference);
|
|
49
|
+
if (reference.mode === "existing") throw new Error("existing_secret_read_only");
|
|
50
|
+
}
|
|
51
|
+
export {
|
|
52
|
+
assertCredentialRecordMutation,
|
|
53
|
+
vaultAllocationSchema,
|
|
54
|
+
vaultCredentialReferenceSchema,
|
|
55
|
+
vaultDescriptorSchema
|
|
56
|
+
};
|