Endpoints
Repository browsing endpoints, all under /api/gg. Swap
:owner and :repo for the account slug and repository name.
-
GET
/api/gg/repos/:owner/:repo/tree?path=Lists the contents of a directory inside the repository.
-
GET
/api/gg/repos/:owner/:repo/raw?path=README.mdReturns file content as
text/plain. -
GET
/api/gg/repos/:owner/:repo/infoBasic repository metadata.
-
GET
/api/gg/repos/:owner/:repo/branchesList of branch names.
-
GET
/api/gg/repos/:owner/:repo/tagsList of tag names.
-
GET
/api/gg/repos/:owner/:repo/topicsDiscovery categories/tags (currently empty until topic storage is added).
-
GET
/api/gg/repos/:owner/:repo/commitsList of commit SHAs.
Authentication
Management endpoints and authenticated browsing require a session token. Anonymous browsing works when no API key is configured on the server.
Session token โ send X-ZKP-Token: <token> on management
endpoints and authenticated browsing. Generate one from the dashboard account menu.
Anonymous browsing โ works without a token in trusted-network mode (no API key configured on the server).
Git smart-HTTP
Clone, fetch and push over HTTPS. Add X-ZKP-Token to Git HTTP requests.
-
GET
/:owner/:repo.git/info/refs?service=git-upload-packAdvertises refs for
git clone/git fetch. -
POST
/:owner/:repo.git/git-upload-packUploads a pack for fetch, clone and push operations.