Coelevate Documentation
API ReferenceContext Repository

List releases

Returns the project's release history, newest first.

GET /context/v1/releases

Returns the project's release history, newest first. A release is one published state of the whole context repository; each published change creates the next. Pass release to read one release by number, or tag to read the release currently holding that tag; the two cannot be combined, and a tag no release holds is a 404. The response also reports which release is the latest.

Requires the context:read scope.

Parameters

ParameterLocationRequiredDescription
limitquerynoReturn at most this many releases, from 1 to 200. Defaults to 50.
offsetquerynoSkip this many releases before returning. Defaults to 0.
tagquerynoReturn the release currently holding this tag. A tag no release holds is a 404. Cannot be combined with release.
releasequerynoReturn this one release, by number or canonical name (projects/{project}/releases/{n}). Cannot be combined with tag.

Responses

StatusMeaning
200The request succeeded.
401The token is missing, expired or invalid.
403The token does not carry the scope this operation requires.
404No such project, or the token belongs to a different project.
422The request was not valid: a parameter or the body failed validation.

The 200 response body:

FieldTypeRequiredDescription
latestinteger or nullnoThe number of the latest release, or null before the first one.
releasesarray of ReleaseRecordyesThe releases asked for.

Shapes

The named shapes used above.

ReleaseRecord

One published state of the whole repository.

FieldTypeRequiredDescription
changeset_idstringyesThe changeset whose publication made this release.
changeset_revisioninteger or nullnoThe revision the changeset was at when it was published.
created_atstringyesWhen the release was made.
created_byobjectyesWho published it and why.
deletedarray of stringyesThe ids of the objects this release retired.
namestring or nullnoThe release's canonical name, projects/{project}/releases/{release}. A request that takes a release in a query accepts this name in its place; a URL path takes the bare number. It is null when the id cannot be written in a canonical name.
object_versionsmap of integeryesThe version of every object as this release published it.
project_idstringyesThe project the release belongs to.
releaseintegeryesThe release number. Each published change makes the next.
tag_historyarray of objectyesEvery time a tag was added to or removed from this release, oldest first.
tagsarray of stringyesThe tags this release carries.

Example

curl -sS "$API_URL/context/v1/releases" \
  -H "Authorization: Bearer $TOKEN"