buzz.bookhive.uploadPersonalBook
Upload an ebook file to the authenticated user's personal library. Accepts EPUB, MOBI/AZW/AZW3, FB2 (including .fb2.zip) and CBZ. The declared Content-Type is advisory only: the format is determined from the file's magic bytes checked against the `filename` extension, and a file that matches neither is rejected. `application/octet-stream` is accepted because mobile document pickers and plain curl uploads routinely send it.
Details · procedure
| Kind | procedure |
|---|---|
| Authority | bookhive.buzz |
| Commit rev | 3n2mntpdbjk2e |
| Indexed |
Procedure
procedure · POSTParameters
query stringOriginal file name including extension. Required: the extension is the only thing distinguishing the zip-container formats (.epub / .cbz / .fb2.zip) from each other, and it is the key used to match e-reader sync documents to this file.
minLength: 1maxLength: 512
Input
application/epub+zip,application/x-mobipocket-ebook,application/vnd.amazon.ebook,application/vnd.amazon.mobi8-ebook,application/x-fictionbook+xml,application/vnd.comicbook+zip,application/x-cbz,application/zip,application/octet-streamOutput
application/jsonTotal bytes this user is allowed to store
minimum: 0
Total bytes stored for this user after the upload
minimum: 0
Errors
UnsupportedFormat
The bytes are not a recognised ebook, or do not match the filename's extension
AlreadyExists
A book with this content hash is already in the library
TooLarge
The file exceeds the per-file size limit
QuotaExceeded
The upload would take the library over its total storage quota
Busy
Too many uploads are being processed; retry shortly