@treeseed/sdk 0.13.0-rc.114 → 0.13.0-rc.116
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/capacity-provider/client.d.ts +42 -0
- package/dist/capacity-provider/client.js +22 -1
- package/dist/capacity-provider/sandbox.d.ts +1 -0
- package/dist/capacity-provider/sandbox.js +1 -0
- package/dist/capacity-provider/source/candidate.d.ts +1275 -0
- package/dist/capacity-provider/source/candidate.js +72 -0
- package/dist/capacity-provider/source-workspace.d.ts +41 -0
- package/dist/capacity-provider/source-workspace.js +10 -0
- package/dist/content/validation/content-model-schemas.d.ts +5 -5
- package/dist/content/validation/portable-content-data.d.ts +1 -1
- package/dist/operator-contracts/canonical-command-tree.js +3 -1
- package/dist/operator-contracts/catalog/workdays/profile-commands.d.ts +4 -0
- package/dist/operator-contracts/catalog/workdays/profile-commands.js +20 -0
- package/dist/operator-contracts/catalog/workdays/profile-operations.d.ts +16 -0
- package/dist/operator-contracts/catalog/workdays/profile-operations.js +48 -0
- package/dist/operator-contracts/control-plane-operations.d.ts +17 -0
- package/dist/operator-contracts/control-plane-operations.js +4 -1
- package/package.json +1 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { sourceWorkspaceKeySchema } from "../source-workspace.js";
|
|
3
|
+
const sourceCandidateChunkBytes = 524288;
|
|
4
|
+
const digest = z.string().regex(/^sha256:[a-f0-9]{64}$/u);
|
|
5
|
+
const commit = z.string().regex(/^(?:[a-f0-9]{40}|[a-f0-9]{64})$/u);
|
|
6
|
+
const id = z.string().min(1).max(256);
|
|
7
|
+
const sourceCandidateAttestationSchema = z.object({
|
|
8
|
+
schemaVersion: z.literal("treeseed.source-candidate-attestation/v1"),
|
|
9
|
+
providerId: id,
|
|
10
|
+
assignmentId: id,
|
|
11
|
+
attempt: z.number().int().positive(),
|
|
12
|
+
leaseId: id,
|
|
13
|
+
source: sourceWorkspaceKeySchema,
|
|
14
|
+
commit,
|
|
15
|
+
parentCandidateId: id.nullable(),
|
|
16
|
+
bundle: z.object({
|
|
17
|
+
digest,
|
|
18
|
+
bytes: z.number().int().positive().max(sourceCandidateChunkBytes * 1024),
|
|
19
|
+
chunks: z.array(digest).min(1).max(1024)
|
|
20
|
+
}).strict(),
|
|
21
|
+
verification: z.object({
|
|
22
|
+
clean: z.literal(true),
|
|
23
|
+
objectClosure: z.literal(true),
|
|
24
|
+
ancestry: z.literal(true),
|
|
25
|
+
isolatedVerifier: z.literal(true),
|
|
26
|
+
executionStopped: z.literal(true),
|
|
27
|
+
verifierStopped: z.literal(true)
|
|
28
|
+
}).strict(),
|
|
29
|
+
verifiedAt: z.string().datetime()
|
|
30
|
+
}).strict().superRefine((value, context) => {
|
|
31
|
+
if (value.bundle.chunks.length !== Math.ceil(value.bundle.bytes / sourceCandidateChunkBytes)) {
|
|
32
|
+
context.addIssue({ code: z.ZodIssueCode.custom, path: ["bundle", "chunks"], message: "Candidate chunk count must match its bounded size." });
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
const signedSourceCandidateSchema = z.object({
|
|
36
|
+
attestation: sourceCandidateAttestationSchema,
|
|
37
|
+
signature: z.object({
|
|
38
|
+
algorithm: z.literal("Ed25519"),
|
|
39
|
+
keyId: id,
|
|
40
|
+
value: z.string().regex(/^[A-Za-z0-9_-]{86}$/u)
|
|
41
|
+
}).strict()
|
|
42
|
+
}).strict();
|
|
43
|
+
const authority = { runnerId: id, leaseToken: z.string().min(1).max(4096), candidate: signedSourceCandidateSchema };
|
|
44
|
+
const sourceCandidateRequestSchema = z.discriminatedUnion("action", [
|
|
45
|
+
z.object({
|
|
46
|
+
...authority,
|
|
47
|
+
action: z.literal("chunk"),
|
|
48
|
+
index: z.number().int().min(0).max(1023),
|
|
49
|
+
content: z.string().min(4).max(Math.ceil(sourceCandidateChunkBytes / 3) * 4).regex(/^[A-Za-z0-9+/]+={0,2}$/u)
|
|
50
|
+
}).strict(),
|
|
51
|
+
z.object({ ...authority, action: z.literal("commit") }).strict()
|
|
52
|
+
]);
|
|
53
|
+
const sourceChunkRequestSchema = z.object({
|
|
54
|
+
runnerId: id,
|
|
55
|
+
leaseToken: z.string().min(1).max(4096),
|
|
56
|
+
artifactId: id,
|
|
57
|
+
index: z.number().int().min(0).max(1023)
|
|
58
|
+
}).strict();
|
|
59
|
+
const sourceChunkResponseSchema = z.object({
|
|
60
|
+
artifactId: id,
|
|
61
|
+
index: z.number().int().min(0).max(1023),
|
|
62
|
+
digest,
|
|
63
|
+
content: z.string().min(4).max(Math.ceil(sourceCandidateChunkBytes / 3) * 4).regex(/^[A-Za-z0-9+/]+={0,2}$/u)
|
|
64
|
+
}).strict();
|
|
65
|
+
export {
|
|
66
|
+
signedSourceCandidateSchema,
|
|
67
|
+
sourceCandidateAttestationSchema,
|
|
68
|
+
sourceCandidateChunkBytes,
|
|
69
|
+
sourceCandidateRequestSchema,
|
|
70
|
+
sourceChunkRequestSchema,
|
|
71
|
+
sourceChunkResponseSchema
|
|
72
|
+
};
|
|
@@ -505,6 +505,23 @@ export declare const sourceWorkspaceResponseSchema: z.ZodEffects<z.ZodObject<{
|
|
|
505
505
|
publication: "denied" | "candidate-only";
|
|
506
506
|
credentialBindingId: string;
|
|
507
507
|
}>;
|
|
508
|
+
/** Present only for an accepted predecessor candidate selected by the control plane. */
|
|
509
|
+
sourceBundle: z.ZodOptional<z.ZodObject<{
|
|
510
|
+
artifactId: z.ZodString;
|
|
511
|
+
digest: z.ZodString;
|
|
512
|
+
bytes: z.ZodNumber;
|
|
513
|
+
chunks: z.ZodArray<z.ZodString, "many">;
|
|
514
|
+
}, "strict", z.ZodTypeAny, {
|
|
515
|
+
digest: string;
|
|
516
|
+
bytes: number;
|
|
517
|
+
artifactId: string;
|
|
518
|
+
chunks: string[];
|
|
519
|
+
}, {
|
|
520
|
+
digest: string;
|
|
521
|
+
bytes: number;
|
|
522
|
+
artifactId: string;
|
|
523
|
+
chunks: string[];
|
|
524
|
+
}>>;
|
|
508
525
|
repository: z.ZodObject<{
|
|
509
526
|
provider: z.ZodLiteral<"github">;
|
|
510
527
|
owner: z.ZodString;
|
|
@@ -595,6 +612,12 @@ export declare const sourceWorkspaceResponseSchema: z.ZodEffects<z.ZodObject<{
|
|
|
595
612
|
authorizationId: string;
|
|
596
613
|
ephemeralPublicKey: string;
|
|
597
614
|
};
|
|
615
|
+
sourceBundle?: {
|
|
616
|
+
digest: string;
|
|
617
|
+
bytes: number;
|
|
618
|
+
artifactId: string;
|
|
619
|
+
chunks: string[];
|
|
620
|
+
} | undefined;
|
|
598
621
|
}, {
|
|
599
622
|
repository: {
|
|
600
623
|
provider: "github";
|
|
@@ -635,6 +658,12 @@ export declare const sourceWorkspaceResponseSchema: z.ZodEffects<z.ZodObject<{
|
|
|
635
658
|
authorizationId: string;
|
|
636
659
|
ephemeralPublicKey: string;
|
|
637
660
|
};
|
|
661
|
+
sourceBundle?: {
|
|
662
|
+
digest: string;
|
|
663
|
+
bytes: number;
|
|
664
|
+
artifactId: string;
|
|
665
|
+
chunks: string[];
|
|
666
|
+
} | undefined;
|
|
638
667
|
}>, {
|
|
639
668
|
repository: {
|
|
640
669
|
provider: "github";
|
|
@@ -675,6 +704,12 @@ export declare const sourceWorkspaceResponseSchema: z.ZodEffects<z.ZodObject<{
|
|
|
675
704
|
authorizationId: string;
|
|
676
705
|
ephemeralPublicKey: string;
|
|
677
706
|
};
|
|
707
|
+
sourceBundle?: {
|
|
708
|
+
digest: string;
|
|
709
|
+
bytes: number;
|
|
710
|
+
artifactId: string;
|
|
711
|
+
chunks: string[];
|
|
712
|
+
} | undefined;
|
|
678
713
|
}, {
|
|
679
714
|
repository: {
|
|
680
715
|
provider: "github";
|
|
@@ -715,6 +750,12 @@ export declare const sourceWorkspaceResponseSchema: z.ZodEffects<z.ZodObject<{
|
|
|
715
750
|
authorizationId: string;
|
|
716
751
|
ephemeralPublicKey: string;
|
|
717
752
|
};
|
|
753
|
+
sourceBundle?: {
|
|
754
|
+
digest: string;
|
|
755
|
+
bytes: number;
|
|
756
|
+
artifactId: string;
|
|
757
|
+
chunks: string[];
|
|
758
|
+
} | undefined;
|
|
718
759
|
}>;
|
|
719
760
|
export type SourceCredentialDelivery = z.infer<typeof sourceCredentialDeliverySchema>;
|
|
720
761
|
export type SourceWorkspaceRequest = z.infer<typeof sourceWorkspaceRequestSchema>;
|
|
@@ -75,6 +75,13 @@ const sourceCredentialDeliverySchema = z.object({
|
|
|
75
75
|
}).strict();
|
|
76
76
|
const sourceWorkspaceResponseSchema = z.object({
|
|
77
77
|
authorization: sourceWorkspaceAuthorizationSchema,
|
|
78
|
+
/** Present only for an accepted predecessor candidate selected by the control plane. */
|
|
79
|
+
sourceBundle: z.object({
|
|
80
|
+
artifactId: id,
|
|
81
|
+
digest,
|
|
82
|
+
bytes: z.number().int().positive().max(536870912),
|
|
83
|
+
chunks: z.array(digest).min(1).max(1024)
|
|
84
|
+
}).strict().optional(),
|
|
78
85
|
repository: z.object({
|
|
79
86
|
provider: z.literal("github"),
|
|
80
87
|
owner: z.string().regex(/^[a-zA-Z0-9][a-zA-Z0-9-]{0,99}$/u),
|
|
@@ -84,6 +91,9 @@ const sourceWorkspaceResponseSchema = z.object({
|
|
|
84
91
|
}).strict(),
|
|
85
92
|
credential: sourceCredentialDeliverySchema
|
|
86
93
|
}).strict().superRefine((value, context) => {
|
|
94
|
+
if (value.sourceBundle && value.sourceBundle.chunks.length !== Math.ceil(value.sourceBundle.bytes / 524288)) {
|
|
95
|
+
context.addIssue({ code: z.ZodIssueCode.custom, path: ["sourceBundle"], message: "Source bundle chunks must match its bounded size." });
|
|
96
|
+
}
|
|
87
97
|
if (value.repository.cloneUrl !== `https://github.com/${value.repository.owner}/${value.repository.name}.git`) {
|
|
88
98
|
context.addIssue({ code: z.ZodIssueCode.custom, path: ["repository", "cloneUrl"], message: "Source transport must match its provider repository." });
|
|
89
99
|
}
|
|
@@ -2090,7 +2090,7 @@ declare const schemas: {
|
|
|
2090
2090
|
related_books?: string[] | undefined;
|
|
2091
2091
|
primary_contributor?: string | undefined;
|
|
2092
2092
|
related_notes?: string[] | undefined;
|
|
2093
|
-
decision_type?: "approved" | "rejected" | "
|
|
2093
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
2094
2094
|
rationale?: string | undefined;
|
|
2095
2095
|
}, {
|
|
2096
2096
|
title: string;
|
|
@@ -2108,7 +2108,7 @@ declare const schemas: {
|
|
|
2108
2108
|
related_books?: string[] | undefined;
|
|
2109
2109
|
primary_contributor?: string | undefined;
|
|
2110
2110
|
related_notes?: string[] | undefined;
|
|
2111
|
-
decision_type?: "approved" | "rejected" | "
|
|
2111
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
2112
2112
|
rationale?: string | undefined;
|
|
2113
2113
|
}>;
|
|
2114
2114
|
book: z.ZodObject<{
|
|
@@ -11915,7 +11915,7 @@ export declare function validateContentFrontmatter(model: PortableContentModel,
|
|
|
11915
11915
|
related_books?: string[] | undefined;
|
|
11916
11916
|
primary_contributor?: string | undefined;
|
|
11917
11917
|
related_notes?: string[] | undefined;
|
|
11918
|
-
decision_type?: "approved" | "rejected" | "
|
|
11918
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
11919
11919
|
rationale?: string | undefined;
|
|
11920
11920
|
} | {
|
|
11921
11921
|
status: "review" | "archived" | "draft" | "published";
|
|
@@ -21630,7 +21630,7 @@ export declare function describeContentFrontmatterSchema(model: PortableContentM
|
|
|
21630
21630
|
related_books?: string[] | undefined;
|
|
21631
21631
|
primary_contributor?: string | undefined;
|
|
21632
21632
|
related_notes?: string[] | undefined;
|
|
21633
|
-
decision_type?: "approved" | "rejected" | "
|
|
21633
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
21634
21634
|
rationale?: string | undefined;
|
|
21635
21635
|
}, {
|
|
21636
21636
|
title: string;
|
|
@@ -21648,7 +21648,7 @@ export declare function describeContentFrontmatterSchema(model: PortableContentM
|
|
|
21648
21648
|
related_books?: string[] | undefined;
|
|
21649
21649
|
primary_contributor?: string | undefined;
|
|
21650
21650
|
related_notes?: string[] | undefined;
|
|
21651
|
-
decision_type?: "approved" | "rejected" | "
|
|
21651
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
21652
21652
|
rationale?: string | undefined;
|
|
21653
21653
|
}> | z.ZodObject<{
|
|
21654
21654
|
schemaVersion: z.ZodLiteral<"treeseed.book/v2">;
|
|
@@ -2001,7 +2001,7 @@ export declare function validatePortableContentData(model: string, value: unknow
|
|
|
2001
2001
|
related_books?: string[] | undefined;
|
|
2002
2002
|
primary_contributor?: string | undefined;
|
|
2003
2003
|
related_notes?: string[] | undefined;
|
|
2004
|
-
decision_type?: "approved" | "rejected" | "
|
|
2004
|
+
decision_type?: "approved" | "rejected" | "superseded" | "deferred" | "request_changes" | undefined;
|
|
2005
2005
|
rationale?: string | undefined;
|
|
2006
2006
|
} | {
|
|
2007
2007
|
status: "review" | "archived" | "draft" | "published";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { commandPaths } from "./catalog/infrastructure/command-tree-paths.js";
|
|
2
2
|
import { managedSecretCommands } from "./catalog/services/secret-commands.js";
|
|
3
3
|
import { identityLoginCommand } from "./catalog/services/identity-commands.js";
|
|
4
|
+
import { WORKDAY_PROFILE_COMMAND_BINDINGS } from "./catalog/workdays/profile-commands.js";
|
|
4
5
|
import { hostProviderEnvironmentBranch, PROVIDER_ENVIRONMENT_COMMAND_BINDINGS, providerEnvironmentBranches } from "./catalog/provider-environment-commands.js";
|
|
5
6
|
const unavailable = (reason = "This capability is not enabled until its control-plane operation is accepted.") => ({
|
|
6
7
|
kind: "unavailable",
|
|
@@ -132,6 +133,7 @@ const operationBindings = {
|
|
|
132
133
|
"plans list": operation("plans.list", [field("path", "decisionId", "option", "decision", true), ...page()]),
|
|
133
134
|
"plans show": operation("plans.show", [field("path", "capacityPlanId", "argument", "plan", true)]),
|
|
134
135
|
"workdays plan": operation("workdays.plan", [field("path", "teamId", "context", "team", true), field("body", "profileId", "option", "profile"), field("body", "projects", "option", "projects", false, "csv"), field("body", "startsAt", "option", "start"), field("body", "endsAt", "option", "end"), field("body", "durationSeconds", "option", "duration", false, "integer"), field("body", "objectiveFilters", "option", "objective", false, "csv")]),
|
|
136
|
+
...WORKDAY_PROFILE_COMMAND_BINDINGS,
|
|
135
137
|
"workdays start": operation("workdays.start", [field("path", "teamId", "context", "team", true), field("body", "preflightId", "option", "preflight", true), field("body", "preflightDigest", "option", "digest", true)]),
|
|
136
138
|
"workdays list": operation("workdays.list", [field("path", "teamId", "context", "team", true), ...page()]),
|
|
137
139
|
"workdays show": operation("workdays.show", [field("path", "teamId", "context", "team", true), field("path", "runId", "argument", "workday", true)]),
|
|
@@ -454,7 +456,7 @@ const commandTree = {
|
|
|
454
456
|
branch("capacity", [leaf("status"), leaf("explain"), leaf("usage"), leaf("ledger"), leaf("audit")]),
|
|
455
457
|
branch("plans", [leaf("list"), leaf("show", "read", "plan"), leaf("explain", "read", "plan"), { nodeType: "leaf", segment: "diff", description: "Compare two API-derived plans.", kind: "read", arguments: [{ name: "left", description: "Left plan identity.", required: true }, { name: "right", description: "Right plan identity.", required: true }], resultSchemaId: "treeseed.command.plans.diff/v1", execution: unavailable() }]),
|
|
456
458
|
branch("workdays", [
|
|
457
|
-
branch("profiles", [leaf("list"), leaf("show", "read", "profile"), leaf("validate", "read", "file")]),
|
|
459
|
+
branch("profiles", [leaf("list"), leaf("show", "read", "profile"), leaf("reconcile", "mutation", "project", "authority"), leaf("validate", "read", "file")]),
|
|
458
460
|
leaf("plan", "mutation"),
|
|
459
461
|
leaf("start", "mutation", void 0, "authority"),
|
|
460
462
|
leaf("list"),
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
const team = { target: "path", field: "teamId", source: "context", name: "team", required: true, transform: "identity" };
|
|
2
|
+
const WORKDAY_PROFILE_COMMAND_BINDINGS = {
|
|
3
|
+
"workdays profiles list": { kind: "operation", operationId: "workdays.profiles.list", input: [
|
|
4
|
+
team,
|
|
5
|
+
{ target: "query", field: "limit", source: "option", name: "limit", transform: "integer" },
|
|
6
|
+
{ target: "query", field: "cursor", source: "option", name: "cursor", transform: "identity" },
|
|
7
|
+
{ target: "query", field: "status", source: "option", name: "status", transform: "identity" }
|
|
8
|
+
] },
|
|
9
|
+
"workdays profiles show": { kind: "operation", operationId: "workdays.profiles.show", input: [
|
|
10
|
+
team,
|
|
11
|
+
{ target: "path", field: "profileId", source: "argument", name: "profile", required: true, transform: "identity" }
|
|
12
|
+
] },
|
|
13
|
+
"workdays profiles reconcile": { kind: "operation", operationId: "workdays.profiles.reconcile", input: [
|
|
14
|
+
team,
|
|
15
|
+
{ target: "path", field: "projectId", source: "argument", name: "project", required: true, transform: "identity" }
|
|
16
|
+
] }
|
|
17
|
+
};
|
|
18
|
+
export {
|
|
19
|
+
WORKDAY_PROFILE_COMMAND_BINDINGS
|
|
20
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export declare const WORKDAY_PROFILE_OPERATIONS: {
|
|
2
|
+
profilesList: import("../../control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
3
|
+
[x: string]: any;
|
|
4
|
+
}, {
|
|
5
|
+
[x: string]: any;
|
|
6
|
+
}, undefined, Record<string, unknown>>;
|
|
7
|
+
profilesShow: import("../../control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
8
|
+
[x: string]: any;
|
|
9
|
+
}, {
|
|
10
|
+
[x: string]: any;
|
|
11
|
+
}, undefined, Record<string, unknown>>;
|
|
12
|
+
profilesReconcile: import("../../control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
13
|
+
projectId: string;
|
|
14
|
+
teamId: string;
|
|
15
|
+
}, {}, {}, Record<string, unknown>>;
|
|
16
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { defineOperation } from "../../operation-builder.js";
|
|
3
|
+
const team = z.object({ teamId: z.string().min(1) }).strict();
|
|
4
|
+
const empty = z.object({}).strict();
|
|
5
|
+
const output = z.record(z.unknown());
|
|
6
|
+
const read = (operationId, path, parameters, query, pagination) => defineOperation({
|
|
7
|
+
operationId,
|
|
8
|
+
description: "Read accepted repository workday profile generations.",
|
|
9
|
+
rest: { method: "GET", path },
|
|
10
|
+
parameters: `treeseed.${operationId}.parameters/v1`,
|
|
11
|
+
capability: "workdays.read",
|
|
12
|
+
authentication: "oauth",
|
|
13
|
+
oauthScopes: ["treeseed:read"],
|
|
14
|
+
kind: "read",
|
|
15
|
+
riskClass: "ordinary",
|
|
16
|
+
confirmation: "never",
|
|
17
|
+
surfaces: ["rest", "cli"],
|
|
18
|
+
cacheScope: "principal",
|
|
19
|
+
pagination
|
|
20
|
+
}, { path: parameters, query, body: z.undefined(), output });
|
|
21
|
+
const WORKDAY_PROFILE_OPERATIONS = {
|
|
22
|
+
profilesList: read(
|
|
23
|
+
"workdays.profiles.list",
|
|
24
|
+
"/v1/teams/{teamId}/workday-profiles",
|
|
25
|
+
team,
|
|
26
|
+
z.object({ limit: z.coerce.number().int().min(1).max(100).optional(), cursor: z.string().optional(), status: z.enum(["active", "archived", "superseded"]).optional() }).strict(),
|
|
27
|
+
"cursor"
|
|
28
|
+
),
|
|
29
|
+
profilesShow: read("workdays.profiles.show", "/v1/teams/{teamId}/workday-profiles/{profileId}", team.extend({ profileId: z.string().min(1) }), empty, "none"),
|
|
30
|
+
profilesReconcile: defineOperation({
|
|
31
|
+
operationId: "workdays.profiles.reconcile",
|
|
32
|
+
description: "Reconcile a bound repository profile after exact successful source verification.",
|
|
33
|
+
rest: { method: "POST", path: "/v1/teams/{teamId}/projects/{projectId}/workday-profiles/reconcile" },
|
|
34
|
+
parameters: "treeseed.workdays.profiles.reconcile.parameters/v1",
|
|
35
|
+
capability: "workdays.execute",
|
|
36
|
+
authentication: "oauth",
|
|
37
|
+
oauthScopes: ["treeseed:execution"],
|
|
38
|
+
kind: "mutation",
|
|
39
|
+
riskClass: "authority",
|
|
40
|
+
confirmation: "input_required",
|
|
41
|
+
surfaces: ["rest", "cli"],
|
|
42
|
+
cacheScope: "none",
|
|
43
|
+
pagination: "none"
|
|
44
|
+
}, { path: team.extend({ projectId: z.string().min(1) }), query: empty, body: empty, output })
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
WORKDAY_PROFILE_OPERATIONS
|
|
48
|
+
};
|
|
@@ -2004,6 +2004,20 @@ export declare const CONTROL_PLANE_OPERATIONS: {
|
|
|
2004
2004
|
teamId: string;
|
|
2005
2005
|
scheduleId: string;
|
|
2006
2006
|
}, {}, Record<string, unknown> | undefined, Record<string, unknown>>;
|
|
2007
|
+
readonly profilesList: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2008
|
+
[x: string]: any;
|
|
2009
|
+
}, {
|
|
2010
|
+
[x: string]: any;
|
|
2011
|
+
}, undefined, Record<string, unknown>>;
|
|
2012
|
+
readonly profilesShow: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2013
|
+
[x: string]: any;
|
|
2014
|
+
}, {
|
|
2015
|
+
[x: string]: any;
|
|
2016
|
+
}, undefined, Record<string, unknown>>;
|
|
2017
|
+
readonly profilesReconcile: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2018
|
+
projectId: string;
|
|
2019
|
+
teamId: string;
|
|
2020
|
+
}, {}, {}, Record<string, unknown>>;
|
|
2007
2021
|
};
|
|
2008
2022
|
readonly assignments: {
|
|
2009
2023
|
readonly list: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
@@ -2573,6 +2587,9 @@ export declare const CONTROL_PLANE_OPERATIONS: {
|
|
|
2573
2587
|
readonly sourceCandidate: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2574
2588
|
assignmentId: string;
|
|
2575
2589
|
}, {}, Record<string, unknown> | undefined, Record<string, unknown>>;
|
|
2590
|
+
readonly sourceChunk: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2591
|
+
assignmentId: string;
|
|
2592
|
+
}, {}, Record<string, unknown> | undefined, Record<string, unknown>>;
|
|
2576
2593
|
readonly renewAssignment: import("./control-plane-operation.js").ControlPlaneOperationBinding<{
|
|
2577
2594
|
assignmentId: string;
|
|
2578
2595
|
}, {}, Record<string, unknown> | undefined, Record<string, unknown>>;
|
|
@@ -2,6 +2,7 @@ import { z } from "zod";
|
|
|
2
2
|
import { defineOperation as define, defineTreeDxProxyOperation as treedxProxy, defineReadOperation as read } from "./operation-builder.js";
|
|
3
3
|
import { communicationOperations, providerCommunicationLifecycleOperations, providerDiscussionResponseOperation } from "./catalog/communication-operations.js";
|
|
4
4
|
import { inboxOperations } from "./catalog/inbox-operations.js";
|
|
5
|
+
import { WORKDAY_PROFILE_OPERATIONS } from "./catalog/workdays/profile-operations.js";
|
|
5
6
|
import { adminAccountOperations, adminTeamOperations } from "./catalog/admin-account-team-operations.js";
|
|
6
7
|
import { TREEAI_CONTROL_PLANE_OPERATIONS } from "./catalog/treeai-operations.js";
|
|
7
8
|
import { capabilityOntologyOperations } from "./catalog/capability-ontology-operations.js";
|
|
@@ -305,6 +306,7 @@ const CONTROL_PLANE_OPERATIONS = {
|
|
|
305
306
|
show: resource("plans.show", "GET", "/v1/capacity-plans/{capacityPlanId}", { capacityPlanId: z.string().min(1) }, { capability: "plans.read", surfaces: ["rest", "cli", "mcp_resource"] })
|
|
306
307
|
},
|
|
307
308
|
workdays: {
|
|
309
|
+
...WORKDAY_PROFILE_OPERATIONS,
|
|
308
310
|
list: resource("workdays.list", "GET", "/v1/teams/{teamId}/workday-runs", { teamId: z.string().min(1) }, { capability: "workdays.read", surfaces: ["rest", "cli", "mcp_tool"], pagination: "cursor" }),
|
|
309
311
|
preflight: resource("workdays.plan", "POST", "/v1/teams/{teamId}/workday-runs/preflight", { teamId: z.string().min(1) }, { capability: "workdays.execute", scopes: ["treeseed:execution"], surfaces: ["rest", "cli", "mcp_tool"] }),
|
|
310
312
|
start: resource("workdays.start", "POST", "/v1/teams/{teamId}/workday-runs", { teamId: z.string().min(1) }, { capability: "workdays.execute", scopes: ["treeseed:execution"], surfaces: ["rest", "cli", "mcp_tool"], risk: "authority" }),
|
|
@@ -482,7 +484,8 @@ const CONTROL_PLANE_OPERATIONS = {
|
|
|
482
484
|
assignment: providerPath("providers.assignments.show", "GET", "/v1/provider/assignments/{assignmentId}", { assignmentId: z.string().min(1) }, { read: true }),
|
|
483
485
|
assignmentExplanation: providerPath("providers.assignments.explain", "GET", "/v1/provider/assignments/{assignmentId}/explanation", { assignmentId: z.string().min(1) }, { read: true }),
|
|
484
486
|
sourceWorkspace: providerPath("providers.assignments.source.authorize", "POST", "/v1/provider/assignments/{assignmentId}/source-workspace", { assignmentId: z.string().min(1) }, { redactedPaths: ["body.leaseToken", "output.credential.ciphertext"] }),
|
|
485
|
-
sourceCandidate: providerPath("providers.assignments.source.candidate", "POST", "/v1/provider/assignments/{assignmentId}/source-candidates", { assignmentId: z.string().min(1) }, { redactedPaths: ["body.leaseToken"] }),
|
|
487
|
+
sourceCandidate: providerPath("providers.assignments.source.candidate", "POST", "/v1/provider/assignments/{assignmentId}/source-candidates", { assignmentId: z.string().min(1) }, { redactedPaths: ["body.leaseToken", "body.content"] }),
|
|
488
|
+
sourceChunk: providerPath("providers.assignments.source.chunk", "POST", "/v1/provider/assignments/{assignmentId}/source-workspace/chunks", { assignmentId: z.string().min(1) }, { redactedPaths: ["body.leaseToken", "output.content"] }),
|
|
486
489
|
renewAssignment: providerPath("providers.assignments.renew", "POST", "/v1/provider/assignments/{assignmentId}/renew", { assignmentId: z.string().min(1) }),
|
|
487
490
|
startExecution: providerPath("providers.assignments.execution.start", "POST", "/v1/provider/assignments/{assignmentId}/execution-start", { assignmentId: z.string().min(1) }),
|
|
488
491
|
startCloseout: providerPath("providers.assignments.closeout.start", "POST", "/v1/provider/assignments/{assignmentId}/closeout-start", { assignmentId: z.string().min(1) }),
|