api

package
v0.0.0-...-19d8ef3 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2026 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Health

func Health(c *echo.Context) error

Health is used to determine if Caesium is healthy.

func RegisterUI

func RegisterUI(e *echo.Echo)

func Shutdown

func Shutdown(ctx context.Context) error

func Start

func Start(ctx context.Context, bus event.Bus, authSvc *auth.Service, auditor *auth.AuditLogger, limiter *auth.RateLimiter, sessions *auth.SessionStore, sso *auth.SSOService, providers SSOProviders, wakeupHandler InternalWakeupHandler) error

Start launches Caesium's API.

The run-owner coordination endpoints (/internal/dispatch, /internal/complete) are deliberately NOT served here — they live on a dedicated mutually authenticated TLS listener (see dispatch.InternalServer) so the public API can remain plain HTTP behind the operator's proxy.

Types

type CheckResult

type CheckResult struct {
	Status    Status `json:"status,omitempty"`
	LatencyMs int64  `json:"latency_ms,omitempty"`
	Count     int64  `json:"count,omitempty"`
}

CheckResult describes the outcome of an individual health check.

type HealthChecks

type HealthChecks struct {
	Database   *CheckResult `json:"database"`
	ActiveRuns *CheckResult `json:"active_runs"`
	Triggers   *CheckResult `json:"triggers"`
	Nodes      *CheckResult `json:"nodes"`
}

HealthChecks holds all dependency check results.

type HealthResponse

type HealthResponse struct {
	Status Status        `json:"status"`
	Uptime time.Duration `json:"uptime"`
	Checks *HealthChecks `json:"checks,omitempty"`
}

HealthResponse defines the data the Health REST endpoint returns.

type InternalWakeupHandler

type InternalWakeupHandler func(ctx context.Context, id string, ttl int)

type SSOProviders

SSOProviders holds SSO providers that are mounted by the API.

type Status

type Status string

Status enumerates the health statuses of Caesium.

const (
	Healthy  Status = "healthy"
	Degraded Status = "degraded"
)

Directories

Path Synopsis
gql
rest
controller/agent
Package agent implements the scoped /v1/agent/* tool surface controllers: the triage bundle, read-only context passthroughs, typed-action proposals, and timeline notes.
Package agent implements the scoped /v1/agent/* tool surface controllers: the triage bundle, read-only context passthroughs, typed-action proposals, and timeline notes.
controller/agentprofile
Package agentprofile is the REST surface for the AgentProfile resource (docs/design-agent-in-the-loop.md, agent-in-the-loop-remediation Stream E2).
Package agentprofile is the REST surface for the AgentProfile resource (docs/design-agent-in-the-loop.md, agent-in-the-loop-remediation Stream E2).
controller/blame
Package blame implements the DAG blame endpoint:
Package blame implements the DAG blame endpoint:
controller/dataset
Package dataset implements the freshness dataset REST surface.
Package dataset implements the freshness dataset REST surface.
controller/incident
Package incident implements the operator-facing incident REST surface (agent-in-the-loop D1/D2): the read API (GET /v1/incidents, GET /:id) and the tier-3 approval decisions (POST /:id/approvals/:approval_id/{approve,reject}).
Package incident implements the operator-facing incident REST surface (agent-in-the-loop D1/D2): the read API (GET /v1/incidents, GET /:id) and the tier-3 approval decisions (POST /:id/approvals/:approval_id/{approve,reject}).
controller/receipt
Package receipt exposes the reproducibility-receipt REST endpoints: emit a content-addressed receipt for a run, and verify a committed receipt against a run's current persisted state (drift detection).
Package receipt exposes the reproducibility-receipt REST endpoints: emit a content-addressed receipt for a run, and verify a committed receipt against a run's current persisted state (drift detection).
controller/replay
Package replay implements the quarantined replay REST endpoint.
Package replay implements the quarantined replay REST endpoint.
controller/reproduce
Package reproduce exposes the read-only task execution descriptor endpoint.
Package reproduce exposes the read-only task execution descriptor endpoint.
controller/rundiff
Package rundiff implements the run-diff endpoint:
Package rundiff implements the run-diff endpoint:
controller/topology
Package topology implements the historical DAG topology endpoints (data-plane-memory B2).
Package topology implements the historical DAG topology endpoints (data-plane-memory B2).
controller/why
Package why implements the causal-explainer endpoint (data-plane-memory A3):
Package why implements the causal-explainer endpoint (data-plane-memory A3):
service/agent
Package agent implements the service layer behind the scoped /v1/agent/* tool surface: the triage bundle, the read-only context passthroughs, timeline notes, and the typed-action proposal path that delegates to Stream B's action executor.
Package agent implements the service layer behind the scoped /v1/agent/* tool surface: the triage bundle, the read-only context passthroughs, timeline notes, and the typed-action proposal path that delegates to Stream B's action executor.
service/agentprofile
Package agentprofile implements the AgentProfile server-side resource: the declarative image/engine/limits, secret:// model-credential references, session budgets, and default playbook a job's metadata.remediation.profile field references (docs/design-agent-in-the-loop.md "Declarative policy", Stream E2).
Package agentprofile implements the AgentProfile server-side resource: the declarative image/engine/limits, secret:// model-credential references, session budgets, and default playbook a job's metadata.remediation.profile field references (docs/design-agent-in-the-loop.md "Declarative policy", Stream E2).
service/blame
Package blame wraps the internal blame query for REST controllers.
Package blame wraps the internal blame query for REST controllers.
service/dataset
Package dataset exposes the freshness dataset read model and manual advance operation used by the REST controller and operator CLI.
Package dataset exposes the freshness dataset read model and manual advance operation used by the REST controller and operator CLI.
service/incident
Package incident wraps read-side incident queries and the tier-3 approval decision flow for REST controllers (agent-in-the-loop D1/D2).
Package incident wraps read-side incident queries and the tier-3 approval decision flow for REST controllers (agent-in-the-loop D1/D2).
service/receipt
Package receipt is the REST service wrapper around internal/receipt: it builds a reproducibility receipt for a run and verifies a committed receipt against a run's current persisted state.
Package receipt is the REST service wrapper around internal/receipt: it builds a reproducibility receipt for a run and verifies a committed receipt against a run's current persisted state.
service/replay
Package replay implements the REST replay service around the internal replay constructor, including B4's scoped idempotency reservation.
Package replay implements the REST replay service around the internal replay constructor, including B4's scoped idempotency reservation.
service/reproduce
Package reproduce exposes the read-only execution descriptor surface used by the reproduce client feature.
Package reproduce exposes the read-only execution descriptor surface used by the reproduce client feature.
service/rundiff
Package rundiff wraps the internal run-diff query for REST controllers.
Package rundiff wraps the internal run-diff query for REST controllers.
service/topology
Package topology provides the service layer for the historical DAG topology API (data-plane-memory B2).
Package topology provides the service layer for the historical DAG topology API (data-plane-memory B2).
service/why
Package why wraps the internal run-level causal explainer (data-plane-memory A3) for use by the REST controller.
Package why wraps the internal run-level causal explainer (data-plane-memory A3) for use by the REST controller.

Jump to

Keyboard shortcuts

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