opsdocsConsole

Ops platform / HTTP API

Packages and registries

The npm and cargo registries your packages are published to and installed from, and the reads behind the Packages pages.

Updated 13 Oct 2026View as Markdown

The npm and cargo registries your packages are published to and installed from, and the reads behind the Packages pages.

GET /api/v1/packages

Every claimed name in the projects the caller belongs to.

StatusMeansBody
200DoneEstatePackagesResponse

GET /api/v1/projects/{slug}/modules

The modules the project publishes, with the projects that use them.

ParameterInTypeAbout
slugpathstring
StatusMeansBody
200DoneProjectModulesResponse
403Your role does not allow this
404No such project

GET /api/v1/projects/{slug}/modules/{name}/notes

Every recorded release's notes for one module, newest first. A module with no notes answers an empty list; a name the project never recorded is a 404.

ParameterInTypeAbout
slugpathstring
namepathstring
StatusMeansBody
200Donearray of ModuleNotes
403Your role does not allow this
404No such project or module

GET /api/v1/projects/{slug}/packages

One project's Packages page: its images, its npm names, its crates, and the three urls the "How to publish" text prints.

ParameterInTypeAbout
slugpathstring
StatusMeansBody
200DoneProjectPackagesResponse
403Your role does not allow this
404No such project

GET /api/v1/projects/{slug}/packages/{registry}

One registry's names in one project.

ParameterInTypeAbout
slugpathstring
registrypathstring
StatusMeansBody
200Donearray of PackageSummary
403Your role does not allow this
404No such project or registry

GET /api/v1/projects/{slug}/packages/{registry}/{name}

One name and every version published under it.

ParameterInTypeAbout
slugpathstring
registrypathstring
namepathstring
StatusMeansBody
200DonePackageDetailResponse
403Your role does not allow this
404No such project, registry or package

GET /cargo/1/{name}

The index entry of a crate with a one letter name: one line for each version.

ParameterInTypeAbout
namepathstringA one character crate name
StatusMeansBody
200The index file, one JSON object per line
304The client already holds this file
401No live ops token in the bare Authorization header
403Not allowed to read this project's packages
404No such crate

GET /cargo/2/{name}

The index entry of a crate with a two letter name: one line for each version.

ParameterInTypeAbout
namepathstringA two character crate name
StatusMeansBody
200The index file, one JSON object per line
304The client already holds this file
401No live ops token in the bare Authorization header
403Not allowed to read this project's packages
404No such crate

GET /cargo/3/{first}/{name}

The index entry of a crate with a three letter name: one line for each version.

ParameterInTypeAbout
firstpathstringThe first character of the name
namepathstringA three character crate name
StatusMeansBody
200The index file, one JSON object per line
304The client already holds this file
401No live ops token in the bare Authorization header
403Not allowed to read this project's packages
404No such crate

PUT /cargo/api/v1/crates/new

Publish one version of a crate. cargo publish --registry ops sends it.

StatusMeansBody
200Published
400The length prefixed body or its metadata is malformed
401No live ops token in the bare Authorization header
403Unclaimed, or not allowed to publish
409That version is already published
413Larger than the body limit

GET /cargo/api/v1/crates/{name}/{version}/download

Download one crate version.

ParameterInTypeAbout
namepathstringThe crate name
versionpathstringThe version, as published
StatusMeansBody
200The .crate archive
401No live ops token in the bare Authorization header
403Not allowed to read this project's packages
404No such crate or version

PUT /cargo/api/v1/crates/{name}/{version}/unyank

Undo a yank.

ParameterInTypeAbout
namepathstringThe crate name
versionpathstringThe version, as published
StatusMeansBody
200Unyanked
401No live ops token in the bare Authorization header
403Not allowed to publish in this project
404No such version

DELETE /cargo/api/v1/crates/{name}/{version}/yank

Yank one crate version, so new lockfiles stop choosing it. Lockfiles that already name it keep working.

ParameterInTypeAbout
namepathstringThe crate name
versionpathstringThe version, as published
StatusMeansBody
200Yanked
401No live ops token in the bare Authorization header
403Not allowed to publish in this project
404No such version

GET /cargo/config.json

Where cargo downloads crates from and publishes to. Cargo reads it first.

StatusMeansBody
200The sparse registry's discovery document

GET /cargo/{prefix}/{infix}/{name}

The index entry of a crate with a name of four letters or more: one line for each version.

ParameterInTypeAbout
prefixpathstringThe first two characters of the name
infixpathstringThe next two characters of the name
namepathstringA crate name of four characters or more
StatusMeansBody
200The index file, one JSON object per line
304The client already holds this file
401No live ops token in the bare Authorization header
403Not allowed to read this project's packages
404No such crate

GET /npm/{pkg}

The npm package document: every version of the package and where to download it. npm and pnpm read it on install.

ParameterInTypeAbout
pkgpathstringThe scoped name, one percent encoded segment
StatusMeansBody
200The packument
401No live ops token in the Bearer header
403Not allowed to read this project's packages
404No such package

PUT /npm/{pkg}

Publish one version of an npm package. npm publish and pnpm publish send it.

ParameterInTypeAbout
pkgpathstringThe scoped name, one percent encoded segment
StatusMeansBody
201Published
401No live ops token in the Bearer header
403Out of scope, unclaimed, or not allowed to publish
409That version is already published
413Larger than the body limit
422The publish body is not one version with one tarball

GET /npm/{pkg}/-/{file}

Download the tarball of one npm package version.

ParameterInTypeAbout
pkgpathstringThe scoped name, one percent encoded segment
filepathstringThe filename the packument advertised
StatusMeansBody
200The archive bytes
401No live ops token in the Bearer header
403Not allowed to read this project's packages
404No such package or version

GET /v2/token

A short lived token for the image registry, in exchange for an ops token sent as the password. docker login and docker push ask for it.

ParameterInTypeAbout
servicequerystring
scope (optional)querystring
StatusMeansBody
200DoneRegistryTokenResponse
400Unknown registry service
401The basic credential is not a live ops token
503No issuer key is configured

Types

EstatePackagesResponse

It carries no images, because an image belongs to a service and a service belongs to one project.

FieldTypeAbout
cargoarray of PackageSummary
npmarray of PackageSummary

ProjectModulesResponse

FieldTypeAbout
modulesarray of ModuleSummary
version (optional)string or nullThe tag version the list was recorded at; null until a modules/ tree has published, which is also what a project that publishes no modules answers.

ModuleNotes

One release's patch notes, Markdown as the CHANGELOG.md section holds it.

FieldTypeAbout
notesstring
versionstring

ProjectPackagesResponse

One project's Packages page: the two claimed name lists, the images derived from its builds, and the three urls the "How to publish" text prints.

FieldTypeAbout
cargoarray of PackageSummary
cargo_index_urlstring
imagesarray of ImageRepoSummary
npmarray of PackageSummary
npm_registry_urlstringThe absolute npm and cargo base urls the "How to publish" text prints.
registry_hoststringThe registry host, "" when OPS_REGISTRY is unset.

PackageSummary

FieldTypeAbout
bytesinteger
latest (optional)string or nullThe newest version by published_at; null when the name is claimed and empty.
namestring
projectstring
published_at (optional)string or null
publisher (optional)string or null
registrystring"npm" or "cargo".
versionsinteger
yankedinteger

PackageDetailResponse

One name and everything published under it. blob_key, shasum and the stored manifest stay out: the first is an object key nothing outside ops may address, and the other two are wire fields the packument rebuilds.

FieldTypeAbout
dist_tagsmap of stringnpm only; empty for a crate.
namestring
projectstring
registrystring
shared_witharray of stringEmpty on almost every claim, and the page prints "null" for it.
versionsarray of PackageVersionSummary

RegistryTokenResponse

What a docker client reads. access_token duplicates token: older clients read one field, newer ones the other, and Distribution's own realm sends both.

FieldTypeAbout
access_tokenstring
expires_ininteger
issued_atstring
tokenstring

ModuleSummary

One module: the folder's name, the two published names it groups, its place in the framework's graph and who uses it.

FieldTypeAbout
consumersarray of ModuleConsumer
crate_name (optional)string or nullsyncronet-<name> on the cargo registry, when the module has a crate.
descriptionstring
layer_name (optional)string or nullThe npm name, when the module has a layer.
namestring
requiresarray of stringThe other modules its crate depends on.

ImageRepoSummary

FieldTypeAbout
commitstring
digeststringThe newest digest ops pushed, "sha256:…".
environmentsarray of stringEnvironments currently running this digest, in environment order.
pushed_at (optional)string or null
repositorystring"{project}/{service}", the repository name in the registry.
servicestring
size_bytes (optional)integer or null

PackageVersionSummary

FieldTypeAbout
digeststringThe archive's SHA-256, lowercase hex, no "sha256:" prefix.
integrity (optional)string or nullnpm only.
published_atstring
publisherstring
size_bytesinteger
versionstring
yankedboolean

ModuleConsumer

A project whose newest default branch build resolved one of the module's halves.

FieldTypeAbout
packagestringThe published name it resolved, syncronet-auth or @syncronet/nuxt-auth.
projectstring
versionstring