
Gitea Has a Free API: Self-Host Your Own GitHub with Full REST and GraphQL APIs
What is Gitea? Gitea is a lightweight, self-hosted Git service — your own GitHub/GitLab in a single binary. It runs on a Raspberry Pi, a $5 VPS, or enterprise hardware. Gitea includes repositories, issues, pull requests, CI/CD (Gitea Actions), packages, and a full REST API — all in a ~100MB binary. Install # Docker (recommended) docker run -d --name gitea -p 3000:3000 -p 2222:22 \ -v gitea-data:/data gitea/gitea:latest # Or single binary wget https://dl.gitea.com/gitea/latest/gitea-linux-amd64 chmod +x gitea-linux-amd64 ./gitea-linux-amd64 The REST API Gitea has a Swagger-documented REST API at https://your-gitea/api/swagger . export GITEA_URL = "https://git.myserver.com/api/v1" export GITEA_TOKEN = "your-token" Repositories # Create repo curl -X POST " $GITEA_URL /user/repos" \ -H "Authorization: token $GITEA_TOKEN " \ -H "Content-Type: application/json" \ -d '{"name": "my-project", "private": false, "auto_init": true}' # List repos curl -s " $GITEA_URL /user/repos" \ -H "Authorizatio
Continue reading on Dev.to DevOps
Opens in a new tab


