MCPcopy Index your code
hub / github.com/coder/coder / NewAPI

Function NewAPI

agent/agentproc/api.go:39–45  ·  view source on GitHub ↗

NewAPI creates a new process API handler.

(logger slog.Logger, execer agentexec.Execer, updateEnv func(current []string) (updated []string, err error), pathStore *agentgit.PathStore, workingDir func() string)

Source from the content-addressed store, hash-verified

37
38// NewAPI creates a new process API handler.
39func NewAPI(logger slog.Logger, execer agentexec.Execer, updateEnv func(current []string) (updated []string, err error), pathStore *agentgit.PathStore, workingDir func() string) *API {
40 return &API{
41 logger: logger,
42 manager: newManager(logger, execer, updateEnv, workingDir),
43 pathStore: pathStore,
44 }
45}
46
47// Close shuts down the process manager, killing all running
48// processes.

Calls 1

newManagerFunction · 0.85