Gateway: snooze finished threads, and name the files a file approval would change
This commit is contained in:
1 parent
d10df56cc9
commit
4dc4e57dac
8 files changed
+295
-10
No files matched your search
@@ -93,6 +93,11 @@ export interface PendingRequest {
|
||||
reason: string | null;
|
||||
/** Approval choices, in the server's order. Empty for questions. `warning` flags a risky choice. */
|
||||
options: Array<{ decision: ApprovalDecision; label: string; warning?: string }>;
|
||||
/**
|
||||
* On `file-change` approvals: the files the agent wants to change. Counts and preview are null
|
||||
* and empty when the server sends no diff before approval, which is the usual case.
|
||||
*/
|
||||
files: PendingFile[];
|
||||
/** Questions for the user. Empty for approvals. */
|
||||
questions: Array<{
|
||||
id: string;
|
||||
@@ -105,6 +110,15 @@ export interface PendingRequest {
|
||||
}>;
|
||||
}
|
||||
|
||||
export interface PendingFile {
|
||||
path: string;
|
||||
name: string;
|
||||
additions: number | null;
|
||||
deletions: number | null;
|
||||
/** The first few changed lines, each starting with `+` or `-`. */
|
||||
preview: string[];
|
||||
}
|
||||
|
||||
export interface FeedItem {
|
||||
hostId: string;
|
||||
hostLabel: string;
|
||||
@@ -120,6 +134,8 @@ export interface FeedItem {
|
||||
activity: Activity | null;
|
||||
/** What the latest run changed, in total. Null when it changed no files or is not read yet. */
|
||||
changes: ChangeTotals | null;
|
||||
/** When a snoozed thread comes back to Recent. Null when it is not snoozed. */
|
||||
snoozedUntil: string | null;
|
||||
request: PendingRequest | null;
|
||||
/**
|
||||
* Set when `request` comes from a subagent this thread delegated to, rather than the thread
|
||||
@@ -215,6 +231,8 @@ export interface Feed {
|
||||
recent: FeedItem[];
|
||||
/** How many threads Recent holds in all. More than `recent.length` means `GET /v1/recent` has the rest. */
|
||||
recentTotal: number;
|
||||
/** Finished threads snoozed for later, listed by `GET /v1/snoozed`. */
|
||||
snoozedTotal: number;
|
||||
hosts: HostSummary[];
|
||||
}
|
||||
|
||||
@@ -252,6 +270,11 @@ export interface ThreadDetail {
|
||||
changedFiles: ChangedFile[];
|
||||
}
|
||||
|
||||
export interface SnoozeRequest {
|
||||
/** When the thread comes back, in the future and at most 30 days away. */
|
||||
until: string;
|
||||
}
|
||||
|
||||
export interface ThreadModeRequest {
|
||||
askFirst: boolean;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user