Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions src/lib/validation/schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,18 @@ export const AgentCreateSchema = z.object({
projectId: z.string().optional(),
avatarSeed: z.string().optional(),
avatarUrl: z.string().nullable().optional().default(null),
/** Per-agent working directory. Used as the cwd for execute tool calls and
* as the root for workspace-scoped file operations. */
workspace: z.string().nullable().optional().default(null),
/** When 'workspace', the structured file tool's reads/writes are confined to
* the agent's workspace directory; 'machine' allows the whole host. */
filesystemScope: z.enum(['workspace', 'machine']).nullable().optional().default(null),
/** Per-agent filesystem allow/block lists enforced by the file tool. Globs
* are matched against fully-resolved absolute paths. */
fileAccessPolicy: z.object({
allowedPaths: z.array(z.string()).optional(),
blockedPaths: z.array(z.string()).optional(),
}).nullable().optional().default(null),
sandboxConfig: AgentSandboxConfigSchema,
executeConfig: AgentExecuteConfigSchema,
autoRecovery: z.boolean().optional().default(false),
Expand Down
Loading