| title | API Reference |
|---|---|
| section | api |
| sidebar | true |
| description | Endpoint reference for the Gitpay Git Worker. |
Base URL (local default): http://localhost:3001
All repository endpoints require [authentication]({{ '/api/authentication/' | relative_url }}) and enforce creator ownership.
Prefer the product narrative in [How it works]({{ '/guides/how-it-works/' | relative_url }}) if you are new to the worker.
| Method | Path | Description |
|---|---|---|
| GET | [/health]({{ '/api/health/' |
relative_url }}) |
| POST | [/repositories/init]({{ '/api/init/' |
relative_url }}) |
| PUT | [/repositories/file]({{ '/api/save-file/' |
relative_url }}) |
| POST | [/repositories/files]({{ '/api/list-files/' |
relative_url }}) |
| POST | [/repositories/read-file]({{ '/api/read-file/' |
relative_url }}) |
| DELETE | [/repositories/file]({{ '/api/delete-file/' |
relative_url }}) |
| POST | [/repositories/versions]({{ '/api/versions/' |
relative_url }}) |
| POST | [/repositories/zip]({{ '/api/zip/' |
relative_url }}) |
| POST | [/repositories/download-file]({{ '/api/download-file/' |
relative_url }}) |
FastAPI publishes:
| URL | Purpose |
|---|---|
/docs |
Swagger UI |
/redoc |
ReDoc |
/openapi.json |
OpenAPI 3 schema |
See [OpenAPI]({{ '/api/openapi/' | relative_url }}) for how this docs site relates to the live schema.
- JSON request bodies (
Content-Type: application/json) - UTF-8 file content as strings on JSON endpoints (
read-file,save-file) - Mutating responses include
commit_shaandversion_tag - Download endpoints (
zip,download-file) return binary bodies withContent-Disposition: attachmentand metadata inX-Commit-Sha/X-Version-Tagheaders - Errors:
{ "detail": "..." }with HTTP 400 / 401 / 403