feat(dashboard): add client editing with PUT endpoint and edit modal
Add PUT /api/clients/{id} with dynamic UPDATE for name, description,
is_active, and rate_limit_per_minute. Expose description and
rate_limit_per_minute in client list/detail responses. Replace the
frontend editClient stub with a modal that fetches, edits, and saves
client data.
This commit is contained in:
@@ -82,7 +82,9 @@ pub fn router(state: AppState) -> Router {
|
||||
)
|
||||
.route(
|
||||
"/api/clients/{id}",
|
||||
get(clients::handle_get_client).delete(clients::handle_delete_client),
|
||||
get(clients::handle_get_client)
|
||||
.put(clients::handle_update_client)
|
||||
.delete(clients::handle_delete_client),
|
||||
)
|
||||
.route("/api/clients/{id}/usage", get(clients::handle_client_usage))
|
||||
.route("/api/providers", get(providers::handle_get_providers))
|
||||
|
||||
Reference in New Issue
Block a user