Refactored the web panel's user link generation to resolve a major performance bottleneck. Previously, fetching links for N users would trigger N separate script executions, causing significant delays from process startup overhead.
- Introduced a new bulk API endpoint (`/api/v1/users/uri/bulk`) that accepts a list of usernames and calls the backend script only once.
- Updated the frontend JavaScript in `users.html` to use this new endpoint, replacing N parallel API calls with a single one.
- Cleaned up the `wrapper_uri.py` script for better readability and maintainability.
Integrates WARP (install, uninstall, configure, status) functionality
into the web panel's settings page. Users can now manage WARP
directly from the UI.
- Created `GetSubPathResponse` Pydantic schema for the API response.
- Added a new GET endpoint `/api/v1/config/normalsub/subpath` to fetch
the current NormalSub subpath using `cli_api.get_normalsub_subpath()`.
- Returns the subpath or null if not found/set.
This commit introduces a new PUT endpoint `/api/v1/config/normalsub/edit_subpath`
to allow modification of the NormalSub service's subpath.
- Added `EditSubPathInputBody` Pydantic model for request validation.
- Implemented the API endpoint in `normalsub.py` router, calling the
corresponding `cli_api.edit_normalsub_subpath` function.
- Includes error handling for validation and general exceptions.
- Add POST `/api/v1/config/hysteria/webpanel/decoy/setup` endpoint to configure the decoy site.
- Add POST `/api/v1/config/hysteria/webpanel/decoy/stop` endpoint to remove the decoy site configuration.
- Implement `BackgroundTasks` for both endpoints to prevent Caddy service restarts from interrupting the API response.
- Add `SetupDecoyRequest` Pydantic schema for the setup endpoint payload.
- Added user existence check before attempting removal
- Return 404 status code when user is not found
- Leveraged existing get_user functionality for consistency
- Separated HTTPException handling to preserve status codes
- Enhanced error handling to provide clearer feedback to API consumers