vtcode_desktop_protocol/method.rs
1//! Known desktop JSON-RPC methods.
2/// Initialize and negotiate protocol support.
3pub const INITIALIZE: &str = "desktop/initialize";
4/// Capture a bounded read-only Git preview, including valid unborn branches.
5pub const WORKSPACE_REVIEW: &str = "workspace/review";
6/// List sessions in the selected workspace.
7pub const SESSION_LIST: &str = "session/list";
8/// Create a session.
9pub const SESSION_CREATE: &str = "session/create";
10/// Load a durable session.
11pub const SESSION_LOAD: &str = "session/load";
12/// Load one bounded earlier page from the selected durable session.
13pub const SESSION_HISTORY: &str = "session/history";
14/// Read one bounded page of archived tool output on demand.
15pub const SESSION_OUTPUT_READ: &str = "session/output/read";
16/// Read one bounded MCP app-resource body for static preview.
17pub const MCP_APP_READ: &str = "mcp/app/read";
18/// Close the selected session after cleanup.
19pub const SESSION_CLOSE: &str = "session/close";
20/// Delete one session archive by identifier.
21pub const SESSION_DELETE: &str = "session/delete";
22/// Read on-disk usage broken down by owning store.
23pub const STORAGE_SUMMARY: &str = "storage/summary";
24/// List managed loop-isolation worktrees.
25pub const WORKTREE_LIST: &str = "worktree/list";
26/// Remove one managed worktree by name.
27pub const WORKTREE_REMOVE: &str = "worktree/remove";
28/// Submit a user turn.
29pub const TURN_SUBMIT: &str = "turn/submit";
30/// Cancel a running turn.
31pub const TURN_CANCEL: &str = "turn/cancel";
32/// Pop the newest queued message back for editing.
33pub const TURN_QUEUE_TAKE_LATEST: &str = "turn/queue/take-latest";
34/// Respond to a pending interaction.
35pub const INTERACTION_RESPOND: &str = "interaction/respond";
36/// Discover active provider/model setup.
37pub const CONFIG_DISCOVER: &str = "config/discover";
38/// Change runtime session options while idle.
39pub const CONFIG_OPTIONS: &str = "config/options";
40/// Persist the selected built-in CLI theme.
41pub const CONFIG_THEME: &str = "config/theme";
42/// Read a bounded, credential-filtered CLI settings catalog.
43pub const CONFIG_SETTINGS_READ: &str = "config/settings/read";
44/// Persist one CLI setting through the shared configuration service.
45pub const CONFIG_SETTINGS_WRITE: &str = "config/settings/write";
46/// Open one layered config file in the platform default editor.
47pub const CONFIG_OPEN_FILE: &str = "config/openFile";
48/// Discover installed CLI skills and Agent Plugins.
49pub const COMPOSER_RESOURCES: &str = "composer/resources";
50/// List selectable models from the service's catalog.
51pub const CONFIG_MODELS: &str = "config/models";
52/// Select the provider/model used for the next session.
53pub const CONFIG_SELECT: &str = "config/select";
54/// Store a provider API key from the desktop client in secure storage.
55/// The secret travels the local channel only and is never echoed back.
56pub const CONFIG_SECRET_STORE: &str = "config/secret/store";
57/// Shut down the local service after owned tasks finish.
58pub const SHUTDOWN: &str = "desktop/shutdown";
59/// Stream an authoritative runtime event.
60pub const THREAD_EVENT: &str = "thread/event";
61/// Ask the client to resolve a runtime interaction.
62pub const INTERACTION_REQUESTED: &str = "interaction/requested";
63/// Publish the active primary agent for a live session.
64pub const PRIMARY_AGENT_CHANGED: &str = "session/primaryAgentChanged";
65/// Publish visible turn state.
66pub const TURN_STATUS: &str = "turn/status";
67/// Publish the authoritative queued-message snapshot.
68pub const TURN_QUEUE_STATUS: &str = "turn/queue-status";
69/// Read bridge state and the non-secret configured origin list.
70pub const WEBMCP_STATUS: &str = "webmcp/status";
71/// Start or reuse the WebMCP bridge and issue an origin-bound pairing code.
72pub const WEBMCP_PAIR: &str = "webmcp/pair";
73/// Revoke the bridge's pairings and stop its listener.
74pub const WEBMCP_STOP: &str = "webmcp/stop";
75/// Read the cached updater status (current/latest version, no network I/O).
76pub const UPDATE_STATUS: &str = "update/status";
77
78/// Transient UI progress for the active desktop session.
79pub const UI_PROGRESS: &str = "session/ui_progress";