This commit updates all documentation files throughout the project: - Updated IMPLEMENTATION_PLAN.md with new implementation details - Updated PROJECT_GUIDELINES.md with coding standards and practices - Updated README.md with current project information - Updated SCREENSHOT_AUTOMATION.md with new automation details - Added TEST_DATA.md with test fixtures data - Updated cover_image_serving_plan.md with static URL patterns Documentation API updates: - Updated API reference documentation for all endpoints including: - Authentication (login, logout, register, refresh_token) - Book matching (auto_link, bulk_link, link_book, search) - Collections (CRUD operations, shelf mappings, auto-assign rules) - Conflicts (bulk operations, resolve/dismiss) - Devices (registration, approval, shelf management) - Highlights (create, update, delete, get) - Kobo sync (bookmark, markup, initialization, sync) - KOReader sync (library, metadata, bookmarks, progress) - Libraries (CRUD, folders, media items, stats) - Media items (bulk operations, CRUD) - Notes (CRUD operations) - OPDS (acquisition, feeds, publication) - Progress (reading progress tracking) - Queue (device queue management) - Ratings (star ratings) - Scanner (watch mode, scan operations) - Sync protocols (Kobo, KOReader) - Users (profile, password, admin operations) - WebSocket protocols - Updated user guides (admin, dashboard, settings, sync) - Updated device setup guides (Kobo, KOReader) - Updated developer guides (testing, contributing, operations) - Updated scripts/README.md
70 lines
1.6 KiB
Markdown
70 lines
1.6 KiB
Markdown
# OPDS Acquisition
|
|
|
|
Download books and list available formats.
|
|
|
|
## Download Book with Format Conversion
|
|
|
|
**Endpoint**: `GET /opds/devices/{deviceId}/download/{bookId}`
|
|
**Auth**: Device token required
|
|
|
|
### Query Parameters
|
|
|
|
| Parameter | Type | Required | Description |
|
|
| --------- | ------ | -------- | -------------------------------------- |
|
|
| format | string | No | Book format: `epub` (default), `kepub` |
|
|
|
|
### Example Request
|
|
|
|
```http
|
|
GET /opds/devices/kobo-id/download/uuid-123?format=kepub
|
|
```
|
|
|
|
### Response (200 OK)
|
|
|
|
**Headers:**
|
|
|
|
- `Content-Type`: `application/epub+zip` or `application/vnd.kobo+xml+zip`
|
|
- `Content-Disposition`: attachment; filename="The Hobbit.epub"
|
|
- `X-Bookhoard-UUID`: uuid-123
|
|
- `X-Bookhoard-SHA256`: abc123... (original hash)
|
|
- `X-Bookhoard-KEPUB-SHA256`: xyz789... (KEPUB hash if format=kepub)
|
|
|
|
**Body:** Book file binary data
|
|
|
|
## List Available Formats
|
|
|
|
**Endpoint**: `GET /opds/devices/{deviceId}/formats/{bookId}`
|
|
**Auth**: Device token required
|
|
|
|
### Example Request
|
|
|
|
```http
|
|
GET /opds/devices/kobo-id/formats/uuid-123
|
|
```
|
|
|
|
### Response (200 OK)
|
|
|
|
```json
|
|
{
|
|
"media_item_id": "uuid-123",
|
|
"formats": [
|
|
{
|
|
"format_type": "epub",
|
|
"file_path": "/path/to/book.epub",
|
|
"file_sha256": "abc123...",
|
|
"file_size_bytes": 2456789,
|
|
"mime_type": "application/epub+zip",
|
|
"available": true
|
|
},
|
|
{
|
|
"format_type": "kepub",
|
|
"file_path": "/cache/book.kepub.epub",
|
|
"file_sha256": "xyz789...",
|
|
"file_size_bytes": 2478932,
|
|
"mime_type": "application/vnd.kobo+xml+zip",
|
|
"available": true
|
|
}
|
|
]
|
|
}
|
|
```
|