Gitea Admin API

The admin API from Gitea — 22 operation(s) for admin.

Operations 32

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /admin/actions/jobs List all Actions jobs on the instance · Lists all jobs #
Ask an LLM
“As a site admin, which Actions jobs are queued or running across the whole instance?”
“Can I filter instance-wide workflow jobs by status?”
Tell an agent
List every Actions job on the instance with status {status}.
Show the first {limit} workflow jobs across the whole server.
GET /admin/actions/runners List all global Actions runners · Get all runners #
Ask an LLM
“Which instance-wide runners are registered on this Gitea server?”
“Can I see only the global runners that are disabled?”
Tell an agent
List all global Actions runners on the instance.
Show global runners where disabled is {disabled}.
POST /admin/actions/runners/registration-token Get a global runner registration token · Get a global actions runner registration token #
Ask an LLM
“How do I get a token to register a runner that serves the entire instance?”
“Where does an admin get the global act runner registration token?”
Tell an agent
Generate a global runner registration token for the instance.
Give me the instance-wide token to register a shared Actions runner.
GET /admin/actions/runners/{runner_id} Get a global Actions runner · Get a global runner #
Ask an LLM
“What's the status of a specific instance-wide runner?”
“Can an admin look up one global runner by ID?”
Tell an agent
Show the global runner {runner_id}.
Check whether instance runner {runner_id} is online.
DELETE /admin/actions/runners/{runner_id} Delete a global Actions runner · Delete a global runner #
Ask an LLM
“How do I unregister a shared runner from the whole instance?”
“Can an admin remove a global runner permanently?”
Tell an agent destructive · confirm first
Delete global runner {runner_id}.
Unregister instance-wide runner {runner_id}.
PATCH /admin/actions/runners/{runner_id} Enable or disable a global runner · Update a global runner #
Ask an LLM
“Can I take a shared instance runner out of rotation without deleting it?”
“How does an admin re-enable a disabled global runner?”
Tell an agent
Set disabled to {disabled} on global runner {runner_id}.
Disable instance runner {runner_id} so it stops taking jobs.
GET /admin/actions/runs List all workflow runs on the instance · Lists all runs #
Ask an LLM
“Which workflow runs have happened across every repo on the server?”
“Can an admin filter instance-wide runs by actor, branch or commit?”
Tell an agent
List all workflow runs on the instance for branch {branch} with status {status}.
Show instance-wide runs triggered by {event} from actor {actor}.
GET /admin/cron List scheduled cron tasks · List cron tasks #
Ask an LLM
“Which background cron tasks does this Gitea server run, and when did they last run?”
“Can I see the schedule of the instance's maintenance jobs?”
Tell an agent
List the server's cron tasks.
Show page {page} of scheduled cron tasks.
POST /admin/cron/{task} Run a cron task immediately · Run cron task #
Ask an LLM
“How do I trigger a maintenance cron job right now instead of waiting?”
“Can an admin manually kick off a specific cron task?”
Tell an agent
Run the cron task {task} now.
Trigger the {task} maintenance job immediately.
GET /admin/emails List all user emails on the instance · List all emails #
Ask an LLM
“What email addresses are registered across all users on the server?”
“Can an admin export every user email page by page?”
Tell an agent
List every email address registered on the instance.
Show page {page} of all user emails.
GET /admin/emails/search Search user emails across the instance · Search all emails #
Ask an LLM
“Which account owns a particular email address?”
“Can an admin search all emails by a keyword or domain?”
Tell an agent
Search all user emails for {q}.
Find which accounts have an email matching {q}.
GET /admin/hooks List system-wide webhooks · List system's webhooks #
Ask an LLM
“Which system and default webhooks are configured on this instance?”
“Can I list only the system hooks, or only the default ones?”
Tell an agent
List the instance's system webhooks.
Show system-level hooks of type {type}.
POST /admin/hooks Create a system-wide webhook · Create a hook #
Ask an LLM
“How does an admin add a webhook that applies to every repository?”
“Can a system hook be limited to particular events or branches?”
Tell an agent
Create a system {type} webhook with config {config}.
Add an instance-wide {type} hook with config {config} for events {events}.
GET /admin/hooks/{id} Get a system-wide webhook · Get a hook #
Ask an LLM
“What URL and events does a given system hook use?”
“Can an admin look up one instance webhook by ID?”
Tell an agent
Show system webhook {id}.
Get the configuration of instance hook {id}.
DELETE /admin/hooks/{id} Delete a system-wide webhook · Delete a hook #
Ask an LLM
“How do I remove a webhook that applies across the whole instance?”
“Can an admin delete a system hook by ID?”
Tell an agent destructive · confirm first
Delete system webhook {id}.
Remove instance-wide hook {id}.
PATCH /admin/hooks/{id} Update a system-wide webhook · Update a hook #
Ask an LLM
“Can an admin deactivate a system hook without deleting it?”
“What's the way to change the events a system webhook fires on?”
Tell an agent
Set active to {active} on system webhook {id}.
Change instance hook {id} to fire on events {events}.
GET /admin/orgs List all organizations on the instance · List all organizations #
Ask an LLM
“Which organizations exist on this Gitea server?”
“Can an admin page through every org, including private ones?”
Tell an agent
List every organization on the instance.
Show page {page} of all organizations.
GET /admin/unadopted List unadopted repositories on disk · List unadopted repositories #
Ask an LLM
“Are there repository folders on disk that Gitea doesn't know about?”
“Can I filter unadopted repos by a name pattern?”
Tell an agent
List unadopted repositories on the server.
Find unadopted repositories matching {pattern}.
POST /admin/unadopted/{owner}/{repo} Adopt unadopted files as a repository · Adopt unadopted files as a repository #
Ask an LLM
“How do I turn a repository folder found on disk into a real Gitea repo?”
“Can an admin adopt orphaned repository files for a user?”
Tell an agent
Adopt the unadopted files at {owner}/{repo} as a repository.
Register the on-disk repo {repo} under {owner}.
DELETE /admin/unadopted/{owner}/{repo} Delete unadopted repository files · Delete unadopted files #
Ask an LLM
“How do I clean up orphaned repository files that were never adopted?”
“Can an admin delete an unadopted repo from disk?”
Tell an agent destructive · confirm first
Delete the unadopted files for {owner}/{repo}.
Remove orphaned repo {repo} under {owner} from disk.
GET /admin/users Search all users with admin filters · Search users according filter conditions #
Ask an LLM
“Which accounts on the server are admins or have 2FA turned off?”
“Can I find users that are inactive or prohibited from logging in?”
Tell an agent
Search all users for {q}.
List users where is_admin is {is_admin} and is_active is {is_active}.
POST /admin/users Create a user account · Create a user #
Ask an LLM
“How does an admin create a new user account directly?”
“Can I force a new user to change their password on first login?”
Tell an agent
Create user {username} with email {email}.
Create user {username} ({email}) with password {password} and must change password {must_change_password}.
DELETE /admin/users/{username} Delete a user account · Delete a user #
Ask an LLM
“How does an admin delete a user account?”
“Can I purge a user together with all their repositories and data?”
Tell an agent destructive · confirm first
Delete user {username}.
Delete user {username} and purge all their data: {purge}.
PATCH /admin/users/{username} Edit a user account as admin · Edit an existing user #
Ask an LLM
“How do I promote a user to site admin or prohibit their login?”
“Can an admin cap how many repos a user may create?”
Tell an agent
Set admin to {admin} for user {username} (login {login_name}, source {source_id}).
Prohibit login {prohibit_login} for {username} with login {login_name} and source {source_id}.
GET /admin/users/{username}/badges List a user's badges · List a user's badges #
Ask an LLM
“Which badges has a given user been awarded?”
“Can an admin see the badges on someone's profile?”
Tell an agent
List the badges for {username}.
Show which badges {username} holds.
POST /admin/users/{username}/badges Award badges to a user · Add a badge to a user #
Ask an LLM
“How do I give a user a badge?”
“Can an admin award several badges at once?”
Tell an agent
Add badges {badge_slugs} to {username}.
Award {username} the badges {badge_slugs}.
DELETE /admin/users/{username}/badges Remove badges from a user · Remove a badge from a user #
Ask an LLM
“How do I take a badge away from a user?”
“Can an admin strip multiple badges from someone at once?”
Tell an agent destructive · confirm first
Remove badges {badge_slugs} from {username}.
Revoke {username}'s badges {badge_slugs}.
POST /admin/users/{username}/keys Add an SSH key on behalf of a user · Add a public key on behalf of a user #
Ask an LLM
“Can an admin add an SSH key to someone else's account?”
“How do I install a read-only deploy-style key for a user as admin?”
Tell an agent
Add SSH key {key} titled {title} to user {username}.
On behalf of {username}, add key {key} named {title} with read only {read_only}.
DELETE /admin/users/{username}/keys/{id} Delete a user's SSH key as admin · Delete a user's public key #
Ask an LLM
“How does an admin remove a compromised SSH key from a user's account?”
“Can I delete another user's public key by ID?”
Tell an agent destructive · confirm first
Delete public key {id} from user {username}.
Remove {username}'s SSH key {id}.
POST /admin/users/{username}/orgs Create an organization owned by a user · Create an organization #
Ask an LLM
“Can an admin create an organization and make a specific user its owner?”
“How do I set a new org's visibility when creating it as admin?”
Tell an agent
Create organization {org_name} owned by {username}.
Create org {org_name} for {username} with visibility {visibility}.
POST /admin/users/{username}/rename Rename a user account · Rename a user #
Ask an LLM
“How does an admin change someone's username?”
“Can I rename a user account through the API?”
Tell an agent
Rename user {username} to {new_username}.
Change the username of {username} to {new_username}.
POST /admin/users/{username}/repos Create a repository on behalf of a user · Create a repository on behalf of a user #
Ask an LLM
“Can an admin create a repository inside another user's account?”
“How do I provision a private repo for a user as admin?”
Tell an agent
Create repository {name} for user {username}.
On behalf of {username}, create private repo {name} with private set to {private}.

Documentation

Specifications

Code Examples

💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repo-get-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repo-update-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issues-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issue-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pulls-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pull-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-branches-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-commits-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-release-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-webhook-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-org-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-org-repos-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-user-get-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-user-repo-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-admin-user-create-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-notifications-list-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-packages-list-owner-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-repository-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-issue-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-pullrequest-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-release-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-hook-example.json
💻
CodeExamples
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/examples/gitea-rest-api-package-example.json

Schemas & Data

📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-repository-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-issue-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-pullrequest-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-branch-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-commit-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-release-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-hook-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-organization-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-team-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-user-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-notificationthread-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-package-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-label-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-milestone-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-tag-schema.json
📊
JSONSchema
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-schema/gitea-rest-api-comment-schema.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-repository-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-issue-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-pullrequest-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-branch-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-commit-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-release-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-hook-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-organization-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-team-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-user-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-notificationthread-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-package-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-label-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-milestone-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-tag-structure.json
📊
JSONStructure
https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/json-structure/gitea-rest-api-comment-structure.json

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/gitea:gitea-admin-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

gitea-admin-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  description: This documentation describes the Gitea API.
  title: Gitea Admin API
  license:
    name: MIT
    url: http://opensource.org/licenses/MIT
  version: 1.27.0+dev-89-gf52b6f3315
servers:
- url: /api/v1
security:
- BasicAuth: []
- Token: []
- AccessToken: []
- AuthorizationHeaderToken: []
- SudoParam: []
- SudoHeader: []
- TOTPHeader: []
tags:


# --- truncated at 32 KB (64 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/gitea/refs/heads/main/openapi/gitea-admin-api-openapi.yml