These fields were unused in practice. Removed from frontend types, issue detail UI, backend handlers, daemon prompt/context, protocol messages, SQL queries, and tests. DB columns retained with defaults. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
53 lines
1.6 KiB
Go
53 lines
1.6 KiB
Go
package protocol
|
|
|
|
import "encoding/json"
|
|
|
|
// Message is the envelope for all WebSocket messages.
|
|
type Message struct {
|
|
Type string `json:"type"`
|
|
Payload json.RawMessage `json:"payload"`
|
|
}
|
|
|
|
// TaskDispatchPayload is sent from server to daemon when a task is assigned.
|
|
type TaskDispatchPayload struct {
|
|
TaskID string `json:"task_id"`
|
|
IssueID string `json:"issue_id"`
|
|
Title string `json:"title"`
|
|
Description string `json:"description"`
|
|
}
|
|
|
|
// TaskProgressPayload is sent from daemon to server during task execution.
|
|
type TaskProgressPayload struct {
|
|
TaskID string `json:"task_id"`
|
|
Summary string `json:"summary"`
|
|
Step int `json:"step,omitempty"`
|
|
Total int `json:"total,omitempty"`
|
|
}
|
|
|
|
// TaskCompletedPayload is sent from daemon to server when a task finishes.
|
|
type TaskCompletedPayload struct {
|
|
TaskID string `json:"task_id"`
|
|
PRURL string `json:"pr_url,omitempty"`
|
|
Output string `json:"output,omitempty"`
|
|
}
|
|
|
|
// DaemonRegisterPayload is sent from daemon to server on connection.
|
|
type DaemonRegisterPayload struct {
|
|
DaemonID string `json:"daemon_id"`
|
|
AgentID string `json:"agent_id"`
|
|
Runtimes []RuntimeInfo `json:"runtimes"`
|
|
}
|
|
|
|
// RuntimeInfo describes an available agent runtime on the daemon's machine.
|
|
type RuntimeInfo struct {
|
|
Type string `json:"type"`
|
|
Version string `json:"version"`
|
|
Status string `json:"status"`
|
|
}
|
|
|
|
// HeartbeatPayload is sent periodically from daemon to server.
|
|
type HeartbeatPayload struct {
|
|
DaemonID string `json:"daemon_id"`
|
|
AgentID string `json:"agent_id"`
|
|
CurrentTasks int `json:"current_tasks"`
|
|
}
|