Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.docinject.com/llms.txt

Use this file to discover all available pages before exploring further.

Exporting lets you take your DocInject documents outside the platform. Use the Word export when you need a branded, formatted .docx file ready to send or archive. Use Markdown when you need plain text that works anywhere — wikis, code repositories, or downstream tools.

Export formats

FormatFile typeTemplate required
Word.docxYes
Markdown.mdNo

Export a document from the UI

1

Open a document

Navigate to the document you want to export.
2

Click Export

Click Export in the document toolbar. The Export modal opens.
3

Choose a format

Select Markdown (.md) or Word (.docx).
4

Select a template (Word only)

If you chose Word, pick a template from the dropdown. The first available template is selected by default. If no templates appear, upload one first — see Managing templates below.
5

Click Export

Click Export. The file downloads immediately.

Export via API

GET /api/v1/documents/{doc_id}/export?template_id={template_id}
The Word export endpoint requires template_id as a query parameter and returns the .docx file with Content-Type: application/vnd.openxmlformats-officedocument.wordprocessingml.document. The Markdown export endpoint requires no additional parameters and returns the .md content with Content-Type: text/markdown. Both endpoints require authentication.
The template_id query parameter is required for Word export. Omitting it returns a 400 error.

Managing templates

Templates are .docx files that control the layout and styling of your Word exports. DocInject fills in document sections, steps, and content during export.

Upload a template

1

Go to Settings

Navigate to Settings → Templates.
2

Upload a file

Click the upload button and select a .docx file. Give the template a name.
You can also upload via the API:
POST /api/v1/templates
Content-Type: multipart/form-data

name=My Template
file=<your .docx file>
tab_width=0.5
The tab_width field controls indentation in the exported document (defaults to 0.5).

List templates

GET /api/v1/templates
Returns an array of templates available to your organization.

Delete a template

In Settings → Templates, click the delete button next to the template you want to remove. Via the API:
DELETE /api/v1/templates/{template_id}
Returns 204 No Content on success.
Deleting a template is permanent. Any export workflow that references it will fail until a replacement template is selected.