Antigravity OpenAI-Compatible Proxy
A small FastAPI reverse proxy that passes OpenAI-compatible /v1/* requests directly to the local Antigravity listener at http://127.0.0.1:8901/v1. It preserves the requested model name and request body, and streams Server-Sent Events. Antigravity CLI/service owns sign-in and OAuth; this proxy does not obtain credentials or alter model names. If Antigravity is signed in, its listener handles the authenticated request.
Run on Termux (Android)
Install Python and unzip in Termux if needed:
pkg update
pkg install python unzip
Unzip the project, enter its folder, install the package and dependencies, then start it:
unzip antigravity-proxy.zip
cd antigravity-proxy
cp .env.example .env
python -m pip install .
antigravity-proxy
Keep the Antigravity CLI/service running and listening at the configured local URL. The defaults are ANTIGRAVITY_LOCAL_URL=http://127.0.0.1:8901/v1 and PROXY_PORT=8000. To change them, edit .env before starting the proxy. For a local development run instead of installing, use python main.py.
Test the proxy:
curl http://127.0.0.1:8000/health
curl http://127.0.0.1:8000/v1/models
curl -N http://127.0.0.1:8000/v1/chat/completions \
-H 'Content-Type: application/json' \
-d '{"model":"YOUR_MODEL","messages":[{"role":"user","content":"Hello"}],"stream":true}'
/health checks the upstream /v1/models endpoint and returns HTTP 200 on success or 503 if the listener is unavailable or returns an error. The proxy deliberately removes incoming Authorization headers; use Antigravity's own signed-in listener.
Build and upload to PyPI from Termux
PyPI does not accept a project-source ZIP as a Twine upload. Twine uploads the source distribution and wheel built from this project. From the unzipped project directory:
python -m pip install --upgrade build twine
python -m build
python -m twine upload dist/*
Twine will prompt for credentials. For a PyPI API token, enter __token__ as the username and the complete token (including the pypi- prefix) as the password. Create the project/token on PyPI first. The name antigravity-proxy must be available on PyPI; if it is already taken, change project.name in pyproject.toml to an available name and rebuild before uploading.
Metadata
Release files for antigravity-proxy 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| antigravity_proxy-0.1.0.tar.gz | 4.0 kB | Without provenance | Details for antigravity_proxy-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| antigravity_proxy-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for antigravity_proxy-0.1.0-py3-none-any.whl |
Total release size: 8.3 kB
Release files / antigravity_proxy-0.1.0.tar.gz
| Download URL | antigravity_proxy-0.1.0.tar.gz |
|---|---|
| Size | 4.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
80bb025c27f5d4cb80f9efe882a9cc2043dadf071cf36fd0dc889578643d6b4c
|
|
BLAKE2b-256 checksum How to use checksums |
71cd8ad6f0f3e2c94610be5079648e88d4b955d9c149ccc40adc7fd6512ad88e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.8
|
Release files / antigravity_proxy-0.1.0-py3-none-any.whl
| Download URL | antigravity_proxy-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e3d1ab559492f1bb05f328ff6d05359ec07a4b33fb9e7f12a1ecef1ce2705d41
|
|
BLAKE2b-256 checksum How to use checksums |
07da0d14075544d10b32e58d938f3c2c447b2d223c1c4c6e39226e8beac80830
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.8
|
Security for antigravity-proxy 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.