Get a book
const url = 'https://digize.com/api/v1/books/example';const options = {method: 'GET', headers: {'x-api-key': '<x-api-key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://digize.com/api/v1/books/example \ --header 'x-api-key: <x-api-key>'One book with its brief and stage.
Needs the books:read permission.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Responses
Section titled “Responses”Done
object
object
object
Made from the title and unique, for the book’s page on a site.
Its stage: brief while the brief isn’t finished, then briefing, interviewing, generating, editing, ready once a build exists, and published once a listing is live.
The author’s photo, from Books › Settings when the book began.
Why reading the sources for the interview failed, when it did; the book is back at brief until it’s started again.
How many runs of the writer it has had; 0 before the first.
Words in its chapters.
The model the author picked to write it, preselected for the next run (books.writers.list).
What writing it with a GPT model has cost on the workspace’s own OpenAI account, in US dollars.
How many things the interview learned, which the writer writes from.
Whether it has something to write from: an outline or an insight (books.generate.start).
B5: the cover front picked, in Images (books.cover.get has the rest).
The cover front picked, as the shelf shows it; unless it’s coverDesigned, the title and author are set over it at build.
Whether the cover front picked is a whole design with the title, subtitle and author in it (GPT Image’s), printed as it is.
Example
{ "chapterLength": "short", "trim": "5x8", "theme": "classic", "sources": { "services": [ "stripe" ] }, "status": "brief"}What was sent isn’t valid (invalid).
object
object
object
Example
{ "error": { "code": "invalid" }}No key, or one that’s unknown, off or expired.
object
object
object
Example
{ "error": { "code": "invalid" }}The key doesn’t have the permission this needs.
object
object
object
Example
{ "error": { "code": "invalid" }}Nothing has that id (not_found).
object
object
object
Example
{ "error": { "code": "invalid" }}Over the rate limit; see retry-after.
object
object
object
Example
{ "error": { "code": "invalid" }}