RunningHub multi-webapp API gateway with sticky egress and Studio UI
https://image.linyiai.one/ ↗// momentum
// why it's here
- Active: last commit today
- Built almost entirely by one person
// how to help
// readme
runninghub2api
独立 Go 网关:号池 + 异步生视频任务,走 RunningHub 网页 WebApp 链路,最终返回 file_url。
账号可通过控制台添加,或由外部系统调用 /admin/sync/accounts(/api/accounts/push)同步进来。
快速启动
cd runninghub2api
cp .env.example .env
# 编辑 RH2API_ADMIN_USER / RH2API_ADMIN_PASSWORD / RH2API_API_KEY
# 后端
go mod tidy
go run ./cmd/runninghub2api
# 前端(另开终端;开发热更新)
cd web
npm install
npm run dev
# → http://127.0.0.1:5178 (vite 代理到 :8088)
# 或构建后由 Go 同端口托管
cd web && npm run build
# 打开 http://127.0.0.1:8088/ 用账号密码登录
健康检查:GET http://127.0.0.1:8088/health
管理台:账号密码登录后,工作室/号池直接可用。API Key 在「系统设置」可复制,给下游调用和账号推送。
导入账号
curl -X POST http://127.0.0.1:8088/admin/sync/accounts \
-H "Authorization: Bearer $RH2API_API_KEY" \
-H "Content-Type: application/json" \
-d '{"accounts":[{"email":"a@b.com","password":"plain","source":"sync","status":"active"}]}'