Fetching the PDF
On this page
The published manual as an A4 document, drawn from the published page itself: the same template, colors, fonts and sections, with nothing around them.
Request
GET https://stylehub.cloud/api/v1/manuals/{slug}.pdfThe slug, the token and the refusals are the same as for the manual. See Reading a manual.
Example
curl -sS https://stylehub.cloud/api/v1/manuals/acme.pdf -o acme.pdfResponse
application/pdf, with a Content-Length.slug field, such as acme.pdf.If-None-Match and an unchanged manual answers 304 with no body and draws nothing.public, max-age=60 for a public or unlisted manual read with no token, private, no-store otherwise. See Caching.A drawn document is kept in memory on the server for ten minutes. A second caller in that time gets the same bytes rather than a second drawing.
Its own allowance
A render draws the whole page, so it is counted twice: once against the request allowance, like every call, and once against a smaller render allowance of its own. Reading JSON all minute never uses up the renders; reading PDFs all minute does use up the requests.
| Plan of the brand | PDF renders a minute |
|---|---|
| Free | 3 |
| Pro | 10 |
| Business | 30 |
Only a call that draws is a render. A 304 and a document served from the ten minute cache are not. Past the number the answer is 429 with Retry-After in seconds, X-RateLimit-Limit set to the render allowance, and the error Too many PDF renders. Up to N a minute. See Rate limits.
Refusals of its own
What is in the document
- The published sections, in order, in the manual's template and design settings, the same version the page shows.
- No internal blocks and no empty ones, the same rule as the page and the JSON.
- The Stylehub footer, when the manual shows branding or the brand's plan has no white label.
The same document as the button
Download PDF button on a public or unlisted manual links to this address. The button in the dashboard does not: it draws the team's own draft fresh, published or not. What a reader can do with the document is in The manual as a PDF.Something the API does that this page does not say? Write to hello@stylehub.cloud with the request and the answer you got.