Sub2API 0.2.7-custom.3
Pre-release
Pre-release
·
386 commits
to main
since this release
AI API Gateway Platform - 将 AI 订阅配额分发和管理
Extend PUT /api/v1/admin/api-keys/:id with an optional status field
(active|inactive) so automation (e.g. a mesh-VPN online watcher using
the Admin API Key) can toggle a user's gateway key without touching
the user-scoped endpoint.
- service: AdminSetAPIKeyStatus writes the status column via the
column-masked repo update and invalidates the auth cache (incl.
cross-instance broadcast) so the change applies on the next request - handler: status branch runs after the group update so the response
snapshot carries all mutations; expired/quota_exhausted stay
system-managed and are rejected at binding and service level - contract matches the user-side PUT /api/keys/:id (inactive is the
stored value for manual disable); add the StatusAPIKeyInactive
constant that was previously a magic string - tests: 6 service unit tests + 5 handler tests; stub now emulates
persistence across calls like the real repo
📥 Installation
Docker:
# GitHub Container Registry
docker pull ghcr.io/redcath/sub2api:0.2.7-custom.3One-line install (Linux):
curl -sSL https://raw.githubusercontent.com/redcatH/sub2api/main/deploy/install.sh | sudo bashManual download:
Download the appropriate archive for your platform from the assets below.