Plugin API
Everything is public JSON with CORS enabled. Tools written for Poggit work by changing the host.
Poggit-compatible endpoints
| Endpoint | What it returns |
|---|---|
GET /releases.json | Every public release, same fields as Poggit (name, version, artifact_url, api[{from,to}], deps, categories, state…) plus type, sha256, size, advisory. Filters: ?name=, ?id=, ?latest-only. |
GET /releases.min.json | Same data (kept for compatibility). |
GET /get/{name} | Redirects to the newest stable .phar. ?prerelease allows betas. |
GET /get/{name}/{version} | Redirects to that version. |
GET /r/{id}/{file}.phar | The file (header X-Checksum-Sha256). |
GET /v.dl/{virion}/{constraint} | Newest virion matching ^1.2.0, ~1.2, 1.2.3, *. |
v1
GET /api/v1/plugins | Projects with their newest release. Filters: q, category, type=plugin|library, sort=downloads|updated|new|rating|name, api=5.46.0. |
GET /api/v1/plugins/{name} | One project with all its public releases. |
POST /api/v1/releases | Publish (token needed). Multipart fields: phar or git_url + git_ref [+ git_path]; optional tagline, description, changelog, major_category, categories, keywords, license, repo_url, api_to, pre_release. Answers 201 with the state, or 422 with the failed checks. |
Publishing from CI
Create a token in your dashboard and save it as a masked CI variable (HUB_TOKEN).
Build the .phar in an earlier step of the job, then upload it:
GitLab CI
publish:
image: alpine:3.20
rules:
- if: $CI_COMMIT_TAG
script:
# ...the steps that build build/MyPlugin.phar...
- apk add --no-cache curl
- curl --fail-with-body -H "Authorization: Bearer $HUB_TOKEN"
-F phar=@build/MyPlugin.phar
-F changelog="$CI_COMMIT_TAG_MESSAGE"
https://plugins.vanillamine.com/api/v1/releases
GitHub Actions
on: { push: { tags: ["v*"] } }
jobs:
publish:
runs-on: ubuntu-latest
steps:
# ...the steps that build build/MyPlugin.phar...
- run: >
curl --fail-with-body -H "Authorization: Bearer ${{ secrets.HUB_TOKEN }}"
-F phar=@build/MyPlugin.phar
https://plugins.vanillamine.com/api/v1/releases