routes

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: May 27, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RouteArtifact = route.Route[ArtifactParams, ArtifactQuery, ArtifactExtraction]{
	Method:      "GET",
	Path:        "/artifact/package/{ecosystem}/{name}",
	OperationID: "getArtifactFiles",
	Summary:     "Get manifest files from a package artifact",
	Description: "Downloads a package artifact and extracts manifest/text files (e.g., package.json for npm, setup.py for pypi) without full disk extraction.",
	Tags:        []string{"artifact"},
}
View Source
var RouteDepsOutdatedSource = route.Route[DepsOutdatedSourceParams, DepsOutdatedSourceQuery, DepsOutdatedSourceResponse]{
	Method:      "POST",
	Path:        "/v2/deps/outdated/source/{url}",
	OperationID: "depsOutdatedSource",
	Summary:     "Get outdated dependency counts for a source",
	Description: "Returns counts of total and outdated dependencies without the full edge graph. Valkey-only.",
	Tags:        []string{"deps"},
}
View Source
var RouteDepsTreeSource = route.Route[DepsTreeSourceParams, DepsTreeSourceQuery, DepsTreeSourceResponse]{
	Method:      "POST",
	Path:        "/v2/deps/tree/source/{url}",
	OperationID: "depsTreeSource",
	Summary:     "Get dependency tree for a source",
	Description: "Returns the dependency edge graph without timestamp population or outdated computation. Valkey-only.",
	Tags:        []string{"deps"},
}
View Source
var RouteHealth = route.Route[route.NoParams, route.NoQuery, HealthCheckResponse]{
	Method:      "GET",
	Path:        "/health/check",
	OperationID: "healthCheck",
	Summary:     "Health check",
	Description: "Verifies cache backend connectivity by performing write-then-read test. Returns 503 if backend is unavailable.",
	Tags:        []string{"health"},
}

Functions

This section is empty.

Types

type ArtifactExtraction

type ArtifactExtraction struct {
	Ecosystem       string            `json:"ecosystem"`
	PackageName     string            `json:"package_name"`
	TarballFilename string            `json:"tarball_filename,omitempty"`
	Files           map[string]string `json:"files"`
	ArtifactURL     string            `json:"artifact_url,omitempty"`
	Verified        bool              `json:"verified"`
	VerifyError     *string           `json:"verify_error,omitempty"`
	SkipReason      *string           `json:"skip_reason,omitempty"`
}

type ArtifactParams

type ArtifactParams struct {
	Ecosystem string
	Name      string
}

type ArtifactQuery

type ArtifactQuery struct {
	Version *string
}

type DepsOutdatedSourceParams

type DepsOutdatedSourceParams struct{}

type DepsOutdatedSourceQuery

type DepsOutdatedSourceQuery struct {
	Commit  *string
	Trusted *string
}

type DepsOutdatedSourceResponse

type DepsOutdatedSourceResponse struct {
	SourceKey      string   `json:"source_key"`
	TotalDepsCount int      `json:"total_deps_count"`
	OutdatedCount  int      `json:"outdated_count"`
	OutdatedKeys   []string `json:"outdated_keys"`
}

type DepsTreeSourceParams

type DepsTreeSourceParams struct{}

type DepsTreeSourceQuery

type DepsTreeSourceQuery struct {
	Commit  *string
	Trusted *string
}

type DepsTreeSourceResponse

type DepsTreeSourceResponse struct {
	SourceKey string                   `json:"source_key"`
	Edges     []depsgraph.DepsTreeEdge `json:"edges"`
}

type HealthCheckResponse

type HealthCheckResponse struct {
	Status string `json:"status"`
	Error  string `json:"error,omitempty"`
}

Jump to

Keyboard shortcuts

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