2025-06-20 19:49:15 +01:00
|
|
|
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs).
|
|
|
|
|
// Do not edit this file manually.
|
2025-06-14 17:36:54 -04:00
|
|
|
// Auto-generated from Rust backend types using ts-rs
|
|
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type ApiResponse<T> = { success: boolean, data: T | null, message: string | null, };
|
2025-06-14 17:36:54 -04:00
|
|
|
|
2025-06-24 10:50:20 +01:00
|
|
|
export type Config = { theme: ThemeMode, executor: ExecutorConfig, disclaimer_acknowledged: boolean, onboarding_acknowledged: boolean, sound_alerts: boolean, sound_file: SoundFile, push_notifications: boolean, editor: EditorConfig, };
|
2025-06-19 12:53:41 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type ThemeMode = "light" | "dark" | "system";
|
2025-06-19 12:53:41 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type EditorConfig = { editor_type: EditorType, custom_command: string | null, };
|
2025-06-20 19:25:18 +01:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type EditorType = "vscode" | "cursor" | "windsurf" | "intellij" | "zed" | "custom";
|
2025-06-20 19:25:18 +01:00
|
|
|
|
2025-06-24 01:05:55 +01:00
|
|
|
export type EditorConstants = { editor_types: Array<EditorType>, editor_labels: Array<string>, };
|
|
|
|
|
|
2025-06-24 10:50:20 +01:00
|
|
|
export type SoundFile = "abstract-sound1" | "abstract-sound2" | "abstract-sound3" | "abstract-sound4" | "cow-mooing" | "phone-vibration" | "rooster";
|
|
|
|
|
|
|
|
|
|
export type SoundConstants = { sound_files: Array<SoundFile>, sound_labels: Array<string>, };
|
|
|
|
|
|
|
|
|
|
export type ConfigConstants = { editor: EditorConstants, sound: SoundConstants, };
|
|
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type ExecutorConfig = { "type": "echo" } | { "type": "claude" } | { "type": "amp" };
|
2025-06-16 18:37:19 -04:00
|
|
|
|
2025-06-24 01:05:55 +01:00
|
|
|
export type ExecutorConstants = { executor_types: Array<ExecutorConfig>, executor_labels: Array<string>, };
|
2025-06-22 22:58:01 +01:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type CreateProject = { name: string, git_repo_path: string, use_existing_repo: boolean, setup_script: string | null, };
|
2025-06-14 17:36:54 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type Project = { id: string, name: string, git_repo_path: string, setup_script: string | null, created_at: Date, updated_at: Date, };
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type UpdateProject = { name: string | null, git_repo_path: string | null, setup_script: string | null, };
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type SearchResult = { path: string, is_file: boolean, match_type: SearchMatchType, };
|
2025-06-17 23:41:24 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type SearchMatchType = "FileName" | "DirectoryName" | "FullPath";
|
2025-06-17 23:41:24 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type CreateTask = { project_id: string, title: string, description: string | null, };
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-21 23:14:00 +01:00
|
|
|
export type CreateTaskAndStart = { project_id: string, title: string, description: string | null, executor: ExecutorConfig | null, };
|
|
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type TaskStatus = "todo" | "inprogress" | "inreview" | "done" | "cancelled";
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type Task = { id: string, project_id: string, title: string, description: string | null, status: TaskStatus, created_at: string, updated_at: string, };
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type TaskWithAttemptStatus = { id: string, project_id: string, title: string, description: string | null, status: TaskStatus, created_at: string, updated_at: string, has_in_progress_attempt: boolean, has_merged_attempt: boolean, };
|
2025-06-16 21:25:19 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type UpdateTask = { title: string | null, description: string | null, status: TaskStatus | null, };
|
2025-06-14 18:44:34 -04:00
|
|
|
|
2025-06-21 19:45:47 +01:00
|
|
|
export type TaskAttemptStatus = "setuprunning" | "setupcomplete" | "setupfailed" | "executorrunning" | "executorcomplete" | "executorfailed";
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-20 22:55:30 +01:00
|
|
|
export type TaskAttempt = { id: string, task_id: string, worktree_path: string, merge_commit: string | null, executor: string | null, created_at: string, updated_at: string, };
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-21 19:45:47 +01:00
|
|
|
export type CreateTaskAttempt = { executor: string | null, };
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-20 22:39:06 +01:00
|
|
|
export type UpdateTaskAttempt = Record<string, never>;
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-24 01:05:55 +01:00
|
|
|
export type CreateFollowUpAttempt = { prompt: string, };
|
|
|
|
|
|
2025-06-21 19:45:47 +01:00
|
|
|
export type TaskAttemptActivity = { id: string, execution_process_id: string, status: TaskAttemptStatus, note: string | null, created_at: string, };
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-21 19:45:47 +01:00
|
|
|
export type CreateTaskAttemptActivity = { execution_process_id: string, status: TaskAttemptStatus | null, note: string | null, };
|
2025-06-16 16:16:42 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type DirectoryEntry = { name: string, path: string, is_directory: boolean, is_git_repo: boolean, };
|
2025-06-17 11:09:50 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type DiffChunkType = "Equal" | "Insert" | "Delete";
|
2025-06-17 11:09:50 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type DiffChunk = { chunk_type: DiffChunkType, content: string, };
|
2025-06-17 11:09:50 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type FileDiff = { path: string, chunks: Array<DiffChunk>, };
|
2025-06-17 11:09:50 -04:00
|
|
|
|
2025-06-20 19:57:38 +01:00
|
|
|
export type WorktreeDiff = { files: Array<FileDiff>, };
|
2025-06-19 18:59:47 -04:00
|
|
|
|
2025-06-21 10:29:16 +01:00
|
|
|
export type BranchStatus = { is_behind: boolean, commits_behind: number, commits_ahead: number, up_to_date: boolean, merged: boolean, };
|
|
|
|
|
|
2025-06-24 01:05:55 +01:00
|
|
|
export type ExecutionProcess = { id: string, task_attempt_id: string, process_type: ExecutionProcessType, executor_type: string | null, status: ExecutionProcessStatus, command: string, args: string | null, working_directory: string, stdout: string | null, stderr: string | null, exit_code: bigint | null, started_at: string, completed_at: string | null, created_at: string, updated_at: string, };
|
2025-06-21 10:29:16 +01:00
|
|
|
|
|
|
|
|
export type ExecutionProcessStatus = "running" | "completed" | "failed" | "killed";
|
|
|
|
|
|
|
|
|
|
export type ExecutionProcessType = "setupscript" | "codingagent" | "devserver";
|
|
|
|
|
|
2025-06-24 01:05:55 +01:00
|
|
|
export type CreateExecutionProcess = { task_attempt_id: string, process_type: ExecutionProcessType, executor_type: string | null, command: string, args: string | null, working_directory: string, };
|
|
|
|
|
|
|
|
|
|
export type UpdateExecutionProcess = { status: ExecutionProcessStatus | null, exit_code: bigint | null, completed_at: string | null, };
|
|
|
|
|
|
|
|
|
|
export type ExecutorSession = { id: string, task_attempt_id: string, execution_process_id: string, session_id: string | null, prompt: string | null, created_at: string, updated_at: string, };
|
|
|
|
|
|
|
|
|
|
export type CreateExecutorSession = { task_attempt_id: string, execution_process_id: string, prompt: string | null, };
|
|
|
|
|
|
|
|
|
|
export type UpdateExecutorSession = { session_id: string | null, prompt: string | null, };
|
|
|
|
|
|
|
|
|
|
// Generated constants
|
|
|
|
|
export const EXECUTOR_TYPES: string[] = [
|
|
|
|
|
"echo",
|
|
|
|
|
"claude",
|
|
|
|
|
"amp"
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export const EDITOR_TYPES: EditorType[] = [
|
|
|
|
|
"vscode",
|
|
|
|
|
"cursor",
|
|
|
|
|
"windsurf",
|
|
|
|
|
"intellij",
|
|
|
|
|
"zed",
|
|
|
|
|
"custom"
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export const EXECUTOR_LABELS: Record<string, string> = {
|
|
|
|
|
"echo": "Echo (Test Mode)",
|
|
|
|
|
"claude": "Claude",
|
|
|
|
|
"amp": "Amp"
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
export const EDITOR_LABELS: Record<string, string> = {
|
|
|
|
|
"vscode": "VS Code",
|
|
|
|
|
"cursor": "Cursor",
|
|
|
|
|
"windsurf": "Windsurf",
|
|
|
|
|
"intellij": "IntelliJ IDEA",
|
|
|
|
|
"zed": "Zed",
|
|
|
|
|
"custom": "Custom"
|
2025-06-24 10:50:20 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
export const SOUND_FILES: SoundFile[] = [
|
|
|
|
|
"abstract-sound1",
|
|
|
|
|
"abstract-sound2",
|
|
|
|
|
"abstract-sound3",
|
|
|
|
|
"abstract-sound4",
|
|
|
|
|
"cow-mooing",
|
|
|
|
|
"phone-vibration",
|
|
|
|
|
"rooster"
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export const SOUND_LABELS: Record<string, string> = {
|
|
|
|
|
"abstract-sound1": "Gentle Chime",
|
|
|
|
|
"abstract-sound2": "Soft Bell",
|
|
|
|
|
"abstract-sound3": "Digital Tone",
|
|
|
|
|
"abstract-sound4": "Subtle Alert",
|
|
|
|
|
"cow-mooing": "Cow Mooing",
|
|
|
|
|
"phone-vibration": "Phone Vibration",
|
|
|
|
|
"rooster": "Rooster Call"
|
2025-06-24 01:05:55 +01:00
|
|
|
};
|