format: "pdf" and the look in style. You get a laid-out PDF (headings, tables, page numbers) with the font
embedded, so it looks the same everywhere.
Steps
- Ask your model to answer in Markdown (headings with
#, lists, tables). - Store your API key in
DOCONDA_API_KEYand install the SDK (pip install docondaornpm install @doconda/sdk). - Send that Markdown with
format: "pdf"and the style, and download the PDF.
content for prompt (“Quarterly summary for the board, with
blue headings”): the style asked for in the sentence is applied too.
What you get back
- A PDF with the font embedded. With
format: "pdf"you get only the PDF; withdocxyou also get the editable Word file. style_applied: how the style was understood, andstyle_unsupported: what couldn’t be applied.status:ready,ready_with_warnings,needs_revieworfailed(not charged).- A report with what’s worth checking (
documents.report(id)).
Limits
- With
quality: "fast"you get the basic style: font, size, colors, alignment, margins, cover page, table of contents, header and footer. - The links in
outputsexpire after 5 minutes;documents.outputs(id)gives you new ones. - Fonts: any Google Fonts family plus Calibri, Cambria, Arial, Times New Roman and Courier New. A font that doesn’t
exist comes back in
style_unsupported.
FAQ
Do I have to maintain templates or print CSS?
Do I have to maintain templates or print CSS?
No. You describe the look in a sentence and the layout adapts to the kind of document (a contract, with numbered
clauses; a letter, without page numbers).
Can I add images?
Can I add images?
Yes. Upload them with
files.upload, pass them in sources and place them in the Markdown with .What if I also need the Word file?
What if I also need the Word file?
Use
format: "docx": you get the Word file and its PDF.Keep reading
- Create and Style.
- Quickstart.