Covers releases and tags (list/get/create/delete) — all verified working with the current write:issue/write:repository token scope.
67 lines
2.6 KiB
Markdown
67 lines
2.6 KiB
Markdown
---
|
|
topic: call-signatures
|
|
source_keys:
|
|
- gitea-mcp-repo
|
|
- gitea-mcp-slim-go
|
|
---
|
|
|
|
# Release and tag call signatures
|
|
|
|
Verified against the live MCP tool schemas at authoring time (not copied from upstream API docs,
|
|
which can drift from the deployed gitea-mcp version). `owner` and `repo` are required strings on
|
|
every tool below and are omitted from the per-tool lists for brevity.
|
|
|
|
## Releases
|
|
|
|
**`list_releases`**
|
|
- Optional: `is_draft` (boolean), `is_pre_release` (boolean), `page` (number, default 1), `per_page` (number, default 20)
|
|
- Returns an array of release objects (shape below), one page at a time.
|
|
|
|
**`get_release`**
|
|
- Required: `id` (number) — the release's numeric id, not its tag name.
|
|
- Returns a single release object.
|
|
|
|
**`get_latest_release`**
|
|
- No parameters beyond `owner`/`repo`.
|
|
- Returns a single release object for the most recently published (non-draft, non-prerelease by Gitea's own "latest" definition) release.
|
|
|
|
**`create_release`**
|
|
- Required: `tag_name` (string), `target` (string — branch, tag, or commit SHA to cut the tag from), `title` (string)
|
|
- Optional: `body` (string — release notes), `is_draft` (boolean), `is_pre_release` (boolean)
|
|
- If `tag_name` doesn't already exist as a tag, Gitea creates it against `target` as part of this call.
|
|
|
|
**`delete_release`**
|
|
- Required: `id` (number) — same numeric id as `get_release`. Does not accept `tag_name`.
|
|
- Does not delete the underlying tag.
|
|
|
|
**Release object shape** (returned by list/get/create/latest):
|
|
```
|
|
id, tag_name, target, title, body, draft, prerelease, html_url, author, created_at, published_at
|
|
```
|
|
`author` is the creator's login. `body` holds the release notes.
|
|
|
|
## Tags
|
|
|
|
**`list_tags`**
|
|
- Optional: `page` (number, default 1), `per_page` (number, default 20)
|
|
- Returns an array of `{ name, commit_sha }` — no `message` field on list responses.
|
|
|
|
**`get_tag`**
|
|
- Required: `tag_name` (string)
|
|
- Returns `{ name, message, commit_sha }` — the only tag call that returns `message`.
|
|
|
|
**`create_tag`**
|
|
- Required: `tag_name` (string)
|
|
- Optional: `target` (string — commitish to tag; if omitted, Gitea tags the default branch tip), `message` (string — annotated tag message)
|
|
|
|
**`delete_tag`**
|
|
- Required: `tag_name` (string). Does not accept a numeric id.
|
|
- Does not delete any release wrapping the tag.
|
|
|
|
## Pagination
|
|
|
|
None of the list tools auto-paginate. To collect a full result set, call with `page: 1`, then
|
|
`page: 2`, etc., stopping when a page returns fewer items than `per_page`. `list_releases` and
|
|
`list_tags` default `per_page` to 20 — lower than the 30-default used by most other gitea-mcp list
|
|
tools, so a caller assuming 30 will under-count pages needed for a fixed total.
|