refactor: Reorganize Bruno requests by role permissions

- Create separate admin folder for admin-only operations
- Move admin endpoints (Create/Update/Delete Ebook, Scanner, Folder Management) to /bruno/admin/
- Add admin dashboard, profile, and library page requests
- Add Register Admin User request with explicit admin role
- Update Register User request to include role field
- Remove empty scanner folder structure

API organization:
- Admin requests: /bruno/admin/ (require admin role)
- User requests: /bruno/user/ (available to all authenticated users)
- Environment: Single {{token}} variable works for both roles
This commit is contained in:
2026-01-26 21:19:19 -05:00
parent 997a7318f8
commit f2994f9147
14 changed files with 105 additions and 441 deletions
-40
View File
@@ -1,40 +0,0 @@
meta {
name: Delete Ebook
type: http
seq: 5
}
delete {
url: http://localhost:8765/api/ebooks/{{ebookid}}
body: none
auth: inherit
}
script:post-response {
function onResponse(res) {
let token = bru.setEnvVar("ebookid", "", { persist: true });
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## Delete Ebook
Removes an ebook from the library.
**Authentication:** Required (Bearer token)
**Path Parameters:**
- `id` (string): Ebook UUID
**Response:** 204 No Content
**Error Responses:**
- 401: Invalid authentication
- 404: Ebook not found
}