httpapi

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 23, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterRoutes

func RegisterRoutes(mux *http.ServeMux, svc Service)

RegisterRoutes exposes project-scoped workflow chain REST routes.

Historically only the governed-intake POST was exposed over REST; Get/List/ Cancel/Retry lived on MCP only (RC-1). The chain-run read/cancel routes and the aggregate tree/summary routes are now wired here so operators and stats scripts can answer "what is the status of run X?" in one call instead of an N-call MCP fan-out. See .ai/tasks/RUN_OBSERVABILITY_GAP.md TIER 1+2.

Types

type Service

type Service interface {
	StartGovernedIntake(ctx context.Context, req projectdurable.DurableIntakeRequest, input projectworkflowchain.StartInput) (projectworkflowchain.StartResult, error)
	Get(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.ChainRun, error)
	List(ctx context.Context, filter projectworkflowchain.ChainFilter) (projectworkflowchain.ListResult, error)
	CancelChain(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.ChainRun, error)
	RetryGitOps(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.ChainRun, error)
	RetryChain(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.RetryChainResult, error)
	DeleteChainRun(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.DeleteChainRunResult, error)
	GetRunTree(ctx context.Context, projectID, chainRunID string) (projectworkflowchain.RunTree, error)
	GetProjectRunSummary(ctx context.Context, projectID string) (projectworkflowchain.ProjectRunSummary, error)
}

Service abstracts the workflow chain surface used by these REST routes. Declared as an interface so handlers can be tested with a fake and so the metadata-only contract stays explicit.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL