API Reference
Create Document
Create a DOCX document from markdown with track changes support. Supports <ins>, <del>, and <comment> tags.
Authorizations
X-API-KeystringheaderrequiredYour API key for authentication
Body Parameters
markdownstringbodyrequiredThe markdown content to convert to a document. Supports track changes markup (<ins>, <del>, <comment> tags).
output_formatstringbodyThe output format for the document. Currently only 'docx' is supported.
webhook_urlstringbodyOptional webhook URL to call when the request is complete.
Cookies
wos-sessionstringcookieSession cookie
access_tokenstringcookieAccess token cookie
datalab_active_teamstringcookieActive team cookie
Response
Successful Response
Create Document
import requests
url = "https://www.datalab.to/api/v1/create-document"
headers = {"X-API-Key": "<api-key>"}
payload = {"markdown": "<string>", "output_format": "docx", "webhook_url": "<string>"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)200Success
{
"request_id": "<string>",
"request_check_url": "<string>",
"success": true,
"error": "<string>",
"versions": {}
}