This endpoint returns all books belonging to the library identified byDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/marchena96/Paradigma-lab1/llms.txt
Use this file to discover all available pages before exploring further.
libraryId. Before returning results, the service validates that a library with the given ID exists in the database. If no matching library is found, the endpoint returns 404 Not Found. If the library exists but has no books, a 200 OK response with an empty array is returned.
Endpoint
GET /api/libraries/{libraryId}/books
The controller is registered under the route template api/libraries/{libraryId}/[controller], where [controller] resolves to books (the name of BooksController).
Authentication
No authentication is required for this endpoint. There is no[Authorize] attribute on the GetAll action.
Path Parameters
The unique identifier of the library whose books should be retrieved.
Status Codes
| Status | Meaning |
|---|---|
200 OK | The library exists; the response body contains the array of books (may be empty). |
404 Not Found | No library with the supplied libraryId exists. |
Response Fields
The auto-generated primary key of the book.
The title of the book.
The genre or category of the book. Empty string if none was provided at creation.
The ID of the library this book belongs to.