Versions in this module Expand all Collapse all v1 v1.1.0 May 22, 2026 Changes in this version + type AgentFunc func(ctx context.Context, input json.RawMessage, jc *JobContext) (any, error) + type Job struct + func (j *Job) Agent() string + func (j *Job) ID() string + func (j *Job) Lease() arcp.Lease + func (j *Job) Principal() string + type JobContext struct + func (jc *JobContext) ArtifactRef(uri, contentType string, byteSize uint64, sha256 string) + func (jc *JobContext) Budget() map[arcp.Currency]float64 + func (jc *JobContext) Context() context.Context + func (jc *JobContext) JobID() string + func (jc *JobContext) Lease() arcp.Lease + func (jc *JobContext) Log(level slog.Level, msg string, attrs ...slog.Attr) + func (jc *JobContext) Metric(name string, value float64, unit string, dims map[string]string) + func (jc *JobContext) Progress(current uint64, total uint64, units, message string) + func (jc *JobContext) RotateCredential(id, newValue string) error + func (jc *JobContext) SessionID() string + func (jc *JobContext) Status(phase, message string) + func (jc *JobContext) StreamResult(encoding string) (io.WriteCloser, error) + func (jc *JobContext) Thought(text string) + func (jc *JobContext) ToolCall(tool string, args any) string + func (jc *JobContext) ToolError(callID string, err error) + func (jc *JobContext) ToolResult(callID string, result any) + func (jc *JobContext) TraceID() string + func (jc *JobContext) ValidateLeaseOp(cap arcp.Capability, target string) error + type Options struct + AckLagThreshold uint64 + ChunkSize int64 + Clock clock.Clock + Features []string + HeartbeatInterval time.Duration + Logger *slog.Logger + MaxResultBytes int64 + Name string + Provisioner credentials.Provisioner + ResumeWindow time.Duration + Verifier auth.Verifier + Version string + type Server struct + func New(opts Options) *Server + func (s *Server) Accept(ctx context.Context, t transport.Transport) error + func (s *Server) Close() error + func (s *Server) RegisterAgent(name string, fn AgentFunc) + func (s *Server) RegisterAgentVersion(name, version string, fn AgentFunc) + func (s *Server) SetDefaultAgentVersion(name, version string) error