NewAPI Sync Tool (Node.js + Express).
The access token can be obtained from Personal Settings - Security Settings - System Service Token.
- Node.js 18+
npm install
npm startOpen http://localhost:8083.
PORT: server port (default8083)SECRET_KEY: encryption key forconfig.json(defaultnewapi-sync-tool-2024)CONFIG_DIR: directory forconfig.jsonandmonitor-config.json(default project root)
docker build -t newapi-elegant .
docker run -d --name newapi-elegant \
-p 8083:8083 \
-e PORT=8083 \
-e SECRET_KEY=change-me \
-e CONFIG_DIR=/data \
-v ./data:/data \
newapi-elegantdocker compose up -d- Push this repo to GitHub.
- Create a Zeabur project from the GitHub repo (Dockerfile deploy is recommended).
- Set environment variables:
PORT,SECRET_KEY,CONFIG_DIR. - Add a persistent volume and mount it to
/data, then setCONFIG_DIR=/data. - Create a Zeabur template and copy the deploy button code into this README.
Button link format :
This app needs a long-running Node process and writes config files on disk. Serverless runtimes (Cloudflare Workers/Pages Functions, Vercel/Netlify Functions) are not a good fit without a rewrite.
Platforms that work well for this style:
- Render, Railway, Fly.io, Koyeb, Zeabur, or any VPS + Docker
General steps:
- Connect the GitHub repo.
- Build:
npm ci --omit=dev(ornpm install) - Start:
npm start - Set
PORT,SECRET_KEY,CONFIG_DIR(use a persistent disk path if supported)
Do not commit node_modules/, config.json, or monitor-config.json.
This project is licensed under the MIT License.