meta { name: Add Books to Kobo Shelf type: http seq: 1 } post { url: {{baseURL}}/api/devices/{{deviceID}}/shelves body: json auth: inherit } headers { Authorization: Bearer {{userToken}} Content-Type: application/json } body:json { { "media_item_ids": [ "{{bookUUID1}}", "{{bookUUID2}}" ], "shelf_name": "Reading List", "shelf_position": 0 } } settings { encodeUrl: true timeout: 0 } docs { ## Add Books to Kobo Shelf Add one or more books to a Kobo device shelf. Manages which books should be synced to a specific Kobo device. Supports multiple shelves for organization. **Method:** POST **Endpoint:** /api/devices/{deviceID}/shelves **Authentication:** Bearer token **Path Parameters:** - `deviceID` (string): Device UUID **Request Body:** - `media_item_ids` (array): Array of book UUIDs to add - `shelf_name` (string): Name of the shelf (e.g., "Reading List", "Favorites") - `shelf_position` (number, optional): Position on the shelf (default: 0) **Response:** - `message` (string): Success message - `added_count` (number): Number of books added **Status Codes:** - 200: Success - books added to shelf - 400: Invalid request data - 401: Unauthorized - 404: Device or one or more books not found - 500: Internal server error **Note:** Adding a book that's already on the shelf updates its position if a new position is specified. Supports multiple shelves for organizing content on the Kobo device. }