Files
bookhoard/bruno/media-items/List Media Items.yml
T
john-okeefe 58a30b6561 chore(bruno): add multi-library dev setup with scan-all and folder requests
Update NewDevDBSetup collection to create Ebook, Comic, and Manga
libraries with separate IDs (ebook_library_id, comic_library_id,
manga_library_id) instead of a single library_id.

- Fix CreateComicLibrary and CreateMangaLibrary to use correct
  names, descriptions, and types instead of duplicating Ebook values
- Update NewDB.sh to run the full setup sequence: register user,
  create all three libraries, add folders, then scan all
- Add AddEbookLibraryFolder, AddComicLibraryFolder, and
  AddMangaLibraryFolder requests with per-type subfolder paths
- Add ScanAllLibraries request using bru.sendRequest() to scan
  each library sequentially via the /api/scanner/scan endpoint
- Update Get Libraries (Admin) to save all three library IDs
- Update List Media Items requests to use ebook_library_id
- Rename library_id to ebook_library_id in Create Library and
  Add Library Folder requests
- Add comic_library_id and manga_library_id to environment
2026-04-19 18:08:39 -04:00

62 lines
1.6 KiB
YAML

info:
name: List Media Items
type: http
seq: 1
http:
method: GET
url: "{{base_url}}/api/media-items?library_id={{ebook_library_id}}&limit=20&offset=0"
headers:
- name: ""
value: application/json
params:
- name: library_id
value: "{{ebook_library_id}}"
type: query
- name: limit
value: "20"
type: query
- name: offset
value: "0"
type: query
auth: inherit
settings:
encodeUrl: true
timeout: 0
followRedirects: true
maxRedirects: 5
docs: |-
## List Media Items
Retrieves a paginated list of media items from a specific library.
**Method:** GET
**Endpoint:** /api/media-items
**Authentication:** Required (Bearer token)
**Query Parameters:**
- `library_id` (string, required): Library UUID to filter items
- `limit` (number, optional): Number of results per page (default: 20, max: 100)
- `offset` (number, optional): Pagination offset (default: 0)
**Response:** Array of media item objects
- `id` (string): Media item UUID
- `title` (string): Media item title
- `library_id` (string): Library UUID
- `media_type` (string): Type of media (e.g., "ebook", "audiobook")
- `file_path` (string): Path to media file
- `created_at` (string): Creation timestamp
- `updated_at` (string): Last update timestamp
**Status Codes:**
- 200: Success
- 400: Invalid query parameters
- 401: Unauthorized
- 403: Forbidden (library access denied)
- 404: Library not found
- 500: Internal server error