Shipreleases
POST/repositories/{repo_id}/releases
Create a release for a tag, creating the tag from a target ref when absent
create_release
release:create
A token needs therelease:createscope: Create releases and upload release assetsGranted bywrite_api,write_repository.Every operation this scope unlocksAudited · mutation
x-gitmoap-audit: {"kind":"audited","arg":"mutation"}
Quota · releases per repo
x-gitmoap-quota: {"kind":"enforced","arg":"releases_per_repo"}
Creates a release on a tag. When the tag does not exist yet, name a target — a branch, a tag or a commit — and the tag is created there in the same request.
Parameters
Path
- repo_idRepositoryId (string · uuid)Repository ID
Request body
application/json- tag_nameTagName (string)
- bodyReleaseBody (string) or nulloptional
- draftbooleanoptional
- nameReleaseName (string) or nulloptionalRelease title; defaults to
tag_namewhen omitted. - prereleasebooleanoptional
- targetGitRef (string) or nulloptionalA commit SHA or branch to create the tag from when it does not yet exist.
Request body exampleSynthesized example
{
"tag_name": "payments-api"
}
Responses
201Release createdapplication/json
authorActorSummaryWho created the release.
- The ActorSummary schema
- emailstring
- idstring
- usernamestring
- avatar_urlstring or nulloptional
- commit_shaCommitHash (string)The commit the tag pointed to when the release was created.
- created_atstring
- nameReleaseName (string)
- repository_idRepositoryId (string · uuid)
- tag_nameTagName (string)
- updated_atstring
assetsarray of ReleaseAssetoptionalThe release's files. Included when a single release is fetched.
- The ReleaseAsset schema
- asset_idReleaseAssetId (string · uuid)
- content_typestring
- created_atstring
- nameAssetName (string)
- repository_idRepositoryId (string · uuid)
- sizeinteger · int640–∞
- stateAssetStateuploadingavailableWhether a release file has been uploaded:
uploading(an upload URL was issued, but the upload has not been confirmed yet) oravailable. - tag_nameTagName (string)
- updated_atstring
uploaderActorSummaryWho uploaded the file.
- The ActorSummary schema
- emailstring
- idstring
- usernamestring
- avatar_urlstring or nulloptional
- download_urlstring or nulloptionalWhere to download the file.
- bodyReleaseBody (string) or nulloptional
- draftbooleanoptionalWhether the release is an unpublished draft, visible only to people with Developer access or above.
- prereleasebooleanoptionalWhether the release is marked as a pre-release. A pre-release is never returned as the latest release.
- published_atstring or nulloptionalSet when the release leaves draft.
- tarball_urlstring or nulloptionalWhere to download the tagged source as a
.tar.gzarchive. - versioninteger · int64optional0–∞Increases with every change. Send it with an update so that a change made since you read the release is not overwritten.
- zipball_urlstring or nulloptionalWhere to download the tagged source as a
.ziparchive.
201 exampleSynthesized example
{
"author": {
"email": "lin@acme.example",
"id": "id-2790",
"username": "mara",
"avatar_url": "https://gitmoap.example/acme/90f4e4cd"
},
"commit_sha": "95c176a8ade2e520bfd85b492cafe65db9a5e3d6",
"created_at": "2026-10-15T20:48:24Z",
"name": "payments-api",
"repository_id": "5b0e7c2a-9d14-4e8b-a6f1-2c3d4e5f6a70",
"tag_name": "payments-api",
"updated_at": "2026-10-15T13:39:46Z",
"assets": [
{
"asset_id": "425022fb-73a8-4c56-951c-b297566a6955",
"content_type": "content-type-a58f",
"created_at": "2026-10-14T11:18:58Z",
"name": "payments-api",
"repository_id": "5b0e7c2a-9d14-4e8b-a6f1-2c3d4e5f6a70",
"size": 0,
"state": "uploading",
"tag_name": "payments-api",
"updated_at": "2026-10-09T11:20:37Z",
"uploader": {
"email": "mara@acme.example",
"id": "id-42ab",
"username": "lin"
}
},
{
"asset_id": "ba7543c6-dc39-4677-8283-f1660b3b325e",
"content_type": "content-type-0c5d",
"created_at": "2026-10-14T01:27:12Z",
"name": "payments-api",
"repository_id": "5b0e7c2a-9d14-4e8b-a6f1-2c3d4e5f6a70",
"size": 1,
"state": "uploading",
"tag_name": "payments-api",
"updated_at": "2026-10-14T06:13:02Z",
"uploader": {
"email": "lin@acme.example",
"id": "id-7b61",
"username": "mara"
}
}
],
"body": "Renders each region as density contours of its operations.",
"draft": false,
"prerelease": false,
"published_at": "2026-10-11T13:36:44Z",
"tarball_url": "https://gitmoap.example/acme/2d678b5d",
"version": 74,
"zipball_url": "https://gitmoap.example/acme/ae02b121"
}
400Invalid requestapplication/json
Error codes
- BAD_REQUESTThe request is malformed: a parameter or a body field is not a well-formed value of its type
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
400 exampleSynthesized example
{
"error": {
"code": "code-0a1b",
"message": "Inline scalar newtypes but keep their brand"
}
}
401Unauthenticated — no credential, or an invalid oneapplication/json
Error codes
- UNAUTHORIZEDNo credential was sent, or the one sent is invalid, expired or revoked
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
401 exampleSynthesized example
{
"error": {
"code": "code-da22",
"message": "Label every synthesized example"
}
}
403Forbidden — the caller's access level or token scope is insufficientapplication/json
Error codes
- FORBIDDENYou are signed in but may not do this here;
reasonnames the permission or the rule that refused it - INSUFFICIENT_SCOPEThe access token lacks the scope this operation needs;
required_scopenames it - PERMISSION_REQUIREDYou need a permission you do not hold here; the message names it
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
403 exampleSynthesized example
{
"error": {
"code": "code-31da",
"message": "Pin a page's payload to the build that rendered it"
}
}
404Repository or target not foundapplication/json
Error codes
- NOT_FOUNDThe resource does not exist — or exists and you cannot see it: a private resource you have no access to answers exactly as an absent one does
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
404 exampleSynthesized example
{
"error": {
"code": "code-5ca3",
"message": "Draw the region map from operation density"
}
}
409Release already existsapplication/json
Error codes
- CONFLICTThe request conflicts with the resource's current state;
reasonsays how - LEGAL_ACCEPTANCE_REQUIREDAccept the current Terms of Service before changing anything; reading stays open
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
409 exampleSynthesized example
{
"error": {
"code": "code-86c4",
"message": "Inline scalar newtypes but keep their brand"
}
}
429The repository's release limit is reachedapplication/json
Error codes
- TOO_MANY_REQUESTSRetryableA quota, a rate limit or a transfer budget is spent. When the response carries
Retry-After, retry after that many seconds
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
429 exampleSynthesized example
{
"error": {
"code": "code-05bd",
"message": "Pin a page's payload to the build that rendered it"
}
}
CLI
gitmoap releases create
- --repo-ididRepository ID (id or owner/repo path)
- --bodystringoptional
- --draftflagoptional
- --namestringoptional
- --prereleaseflagoptional
- --tag-namestring
- --targetstringoptional