Documentation
¶
Index ¶
- type Client
- func (c *Client) AddProvider(ctx context.Context, req *pb.AddProviderReq) (*pb.Provider, error)
- func (c *Client) ApprovePlan(ctx context.Context, sessionID, planID string, skipSteps []string) (<-chan *pb.ChatEvent, error)
- func (c *Client) AttachSession(ctx context.Context, sessionID string) (<-chan *pb.ChatEvent, error)
- func (c *Client) Close() error
- func (c *Client) CompactSession(ctx context.Context, sessionID string) (<-chan *pb.ChatEvent, error)
- func (c *Client) CreateCron(ctx context.Context, sessionID, schedule, command string) (*pb.CronJob, error)
- func (c *Client) CreateSession(ctx context.Context, req *pb.CreateSessionReq) (*pb.Session, error)
- func (c *Client) EnsureCompatible() (*pb.VersionCheckResp, error)
- func (c *Client) GetAgentStatus(ctx context.Context, agentID string) (*pb.Agent, error)
- func (c *Client) GetFleetStatus(ctx context.Context, fleetID string) (*pb.FleetStatus, error)
- func (c *Client) GetTeamStatus(ctx context.Context, teamID string) (*pb.TeamStatus, error)
- func (c *Client) Health(ctx context.Context) (*pb.HealthResponse, error)
- func (c *Client) KillAgent(ctx context.Context, agentID string) error
- func (c *Client) KillFleetWorker(ctx context.Context, fleetID, workerID string) error
- func (c *Client) KillJob(ctx context.Context, jobID string) error
- func (c *Client) KillSession(ctx context.Context, id string) error
- func (c *Client) ListAgents(ctx context.Context) (*pb.AgentList, error)
- func (c *Client) ListCrons(ctx context.Context) (*pb.CronJobList, error)
- func (c *Client) ListJobs(ctx context.Context) (*pb.JobList, error)
- func (c *Client) ListProviders(ctx context.Context) (*pb.ProviderList, error)
- func (c *Client) ListSessions(ctx context.Context) (*pb.SessionList, error)
- func (c *Client) ListTeams(ctx context.Context, projectID string) (*pb.TeamList, error)
- func (c *Client) PauseCron(ctx context.Context, jobID string) error
- func (c *Client) PauseJob(ctx context.Context, jobID string) error
- func (c *Client) RejectPlan(ctx context.Context, sessionID, planID, feedback string) error
- func (c *Client) RemoveProvider(ctx context.Context, alias string) error
- func (c *Client) RequestReload(ctx context.Context) (<-chan *pb.ReloadStatus, error)
- func (c *Client) RespondToPermission(ctx context.Context, requestID string, allowed bool, scope string) error
- func (c *Client) ResumeCron(ctx context.Context, jobID string) error
- func (c *Client) ResumeJob(ctx context.Context, jobID string) error
- func (c *Client) SendMessage(ctx context.Context, sessionID, content string) (<-chan *pb.ChatEvent, error)
- func (c *Client) SetDefaultProvider(ctx context.Context, alias string) error
- func (c *Client) Shutdown(ctx context.Context) error
- func (c *Client) StartFleet(ctx context.Context, req *pb.StartFleetReq) (<-chan *pb.ChatEvent, error)
- func (c *Client) StartTeam(ctx context.Context, req *pb.StartTeamReq) (<-chan *pb.TeamEvent, error)
- func (c *Client) StopCron(ctx context.Context, jobID string) error
- func (c *Client) TestProvider(ctx context.Context, alias string) (*pb.TestProviderResult, error)
- func (c *Client) UpdateProviderModel(ctx context.Context, alias, model string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func EnsureDaemon ¶
EnsureDaemon starts the daemon if not running, then connects.
func (*Client) AddProvider ¶
func (*Client) ApprovePlan ¶
func (c *Client) ApprovePlan(ctx context.Context, sessionID, planID string, skipSteps []string) (<-chan *pb.ChatEvent, error)
ApprovePlan approves a proposed plan and returns a channel of ChatEvents.
func (*Client) AttachSession ¶
AttachSession streams events from an existing session.
func (*Client) CompactSession ¶
func (c *Client) CompactSession(ctx context.Context, sessionID string) (<-chan *pb.ChatEvent, error)
CompactSession requests immediate context compression for the given session. It sends a special sentinel message that handleChat recognises as a compression request rather than a user turn — the daemon compresses history and responds with a ContextCompressed event.
func (*Client) CreateCron ¶
func (*Client) CreateSession ¶
func (*Client) EnsureCompatible ¶
func (c *Client) EnsureCompatible() (*pb.VersionCheckResp, error)
EnsureCompatible sends a version check to the daemon and returns the result. Callers should inspect Compatible and ReloadRecommended to decide what to do.
func (*Client) GetAgentStatus ¶
func (*Client) GetFleetStatus ¶
GetFleetStatus returns the current status of a fleet.
func (*Client) GetTeamStatus ¶
GetTeamStatus returns the status of the active team.
func (*Client) KillFleetWorker ¶
KillFleetWorker cancels a specific worker within a fleet.
func (*Client) ListProviders ¶
func (*Client) ListSessions ¶
func (*Client) RejectPlan ¶
RejectPlan rejects a proposed plan with optional feedback.
func (*Client) RemoveProvider ¶
func (*Client) RequestReload ¶
RequestReload asks the daemon to checkpoint and restart, streaming status events until the stream closes. The daemon stops after sending "restarting".
func (*Client) RespondToPermission ¶
func (*Client) SendMessage ¶
func (c *Client) SendMessage(ctx context.Context, sessionID, content string) (<-chan *pb.ChatEvent, error)
SendMessage sends a chat message and returns a channel of ChatEvents.
func (*Client) SetDefaultProvider ¶
func (*Client) StartFleet ¶
func (c *Client) StartFleet(ctx context.Context, req *pb.StartFleetReq) (<-chan *pb.ChatEvent, error)
StartFleet starts a fleet execution and returns a channel of ChatEvents containing FleetStatus updates.