PublishDrive

Example: Update a book

Partial PATCH updates — retitle an ebook, manage audiobook chapters, or adjust print-on-demand metadata.

Reference: Update a book. Send only fields you want to change; omitted keys are left unchanged.

Replace YOUR_API_KEY and BOOK_PUBLIC_ID. Demo id below matches other examples.

See also


Ebook — change title

curl -sS -X PATCH "https://api.sandbox.dev.publishdrive.com/v2/distribution/books/b2c3d4e5-f6a7-8901-bcde-f12345678901" \
  -H "apikey: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"title":"Updated Ebook Title"}'

Audiobook — set chapters (after files exist)

curl -sS -X PATCH "https://api.sandbox.dev.publishdrive.com/v2/distribution/books/b2c3d4e5-f6a7-8901-bcde-f12345678901" \
  -H "apikey: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "format": "audio",
    "chapters": [
      {
        "fileId": "d4e5f6a7-b8c9-0123-def0-123456789abc",
        "sequence": 1,
        "title": "Chapter One",
        "titleAscii": null
      }
    ]
  }'
curl -sS -X PATCH "https://api.sandbox.dev.publishdrive.com/v2/distribution/books/b2c3d4e5-f6a7-8901-bcde-f12345678901" \
  -H "apikey: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "format": "print",
    "title": "Updated Print Title",
    "podDetails": {
      "pageCount": 320,
      "trimSizeId": 1,
      "bindingType": "PAPERBACK",
      "coverLaminateType": "GLOSS",
      "interiorColorType": "B&W",
      "paperColorType": "CREAM"
    }
  }'

On this page