Key–value pairs for Merge Tags defined in the Sign template. Keys must match tag names. Values replace the corresponding tags and are rendered as plain text in the generated document.
Key–value pairs for Form Fields defined in the template. Keys must match field names. Values prefill the corresponding fields in the generated document.
Key–value pairs for Variables defined in the AgreementGen template. Keys must match variable names. Values prefill the corresponding variables and are rendered as plain text in the generated document.
Map of collection name → array of record objects used to expand table-scoped row-loop markers in the template.
Each key must match a collection name returned by Get Template Details under collections[].name.
Each value is an ordered array of flat record objects; each record is a key–value map where keys match the collection's variable names and values are strings.
Records are rendered in array order.
Maximum 100 items per collection, and up to 50 collections per request.
Applies to AgreementGen templates only. Ignored silently when the template type is not lumin.
Unix epoch timestamp (in seconds) indicating when signed_url will no longer work.
{"docsConfig":{"theme":"aspen","$schema":"https://mintlify.com/docs.json","name":"Lumin Developer Docs","colors":{"primary":"#171717","light":"#FFFFFF","dark":"#D4D4D4"},"logo":{"light":"https://mintcdn.com/luminpdf-82c12c3f/S8lnm3z-VpB7-Jo7/logo/logo-light.svg?fit=max\u0026auto=format\u0026n=S8lnm3z-VpB7-Jo7\u0026q=85\u0026s=7efd61a54cbb6df606831ac070f96525","dark":"https://mintcdn.com/luminpdf-82c12c3f/S8lnm3z-VpB7-Jo7/logo/logo-dark.svg?fit=max\u0026auto=format\u0026n=S8lnm3z-VpB7-Jo7\u0026q=85\u0026s=a85445ea50bdbdd58bb06a604a7b81d6","href":"/"},"favicon":"https://mintcdn.com/luminpdf-82c12c3f/S8lnm3z-VpB7-Jo7/favicon.png?fit=max\u0026auto=format\u0026n=S8lnm3z-VpB7-Jo7\u0026q=85\u0026s=a8770eb57248f1a494c24b10227b64f7","api":{"openapi":"tabs/api-reference/lumin-openapi.yaml","params":{"expanded":"all"},"examples":{"defaults":"all","prefill":true}},"appearance":{"default":"light"},"navbar":{"links":[{"href":"mailto:[email protected]","label":"Contact developer support"}]},"footer":{"socials":{"website":"https://www.luminpdf.com","github":"https://github.com/luminpdf","linkedin":"https://www.linkedin.com/company/luminpdf"}},"seo":{"metatags":{"canonical":"https://developers.luminpdf.com"}},"styling":{"codeblocks":{"theme":{"light":"github-light","dark":"github-dark"}},"latex":false},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"navigation":{"global":{"anchors":[{"anchor":"Terms of Use","icon":"newspaper","href":"https://www.luminpdf.com/terms-of-use"},{"anchor":"Help Center","icon":"circle-question","href":"https://help.luminpdf.com/"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"luminpdf-82c12c3f","hasAudioNarration":false,"actualSubdomain":"luminpdf-82c12c3f","customDomains":["developers.luminpdf.com"],"gitSource":{"type":"github","owner":"luminpdf","repo":"lumin-dev-docs","deployBranch":"production","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ab35b45d139634430d6ee1a","collectionId":"9ba3beff-c026-4ba1-93db-5a1cdbb8ac62","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ab35b45d139634430d6ee1a"},"entitlements":{},"buildId":"6ab35b45d139634430d6ee1a","clientVersion":"0.0.4044","searchFilterCounts":[{"language":"default","tag":"API Reference","count":34},{"language":"default","tag":"Lumin API reference","count":33},{"language":"default","tag":"Guides","count":13},{"language":"default","tag":"Signature requests","count":10},{"language":"default","tag":"Documents","count":9},{"language":"default","tag":"Workspaces","count":5},{"language":"default","tag":"Templates","count":4},{"language":"default","tag":"Walkthroughs","count":4},{"language":"default","tag":"Webhooks","count":4},{"language":"default","tag":"Agreements","count":3}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"tabs/api-reference/api/templates/generate-document-from-template","slug":"/tabs/api-reference/api/templates/generate-document-from-template","pageMetadata":{"title":"Generate Document from Template","description":"Creates a downloadable document from an existing Lumin template.","openapi":"POST /templates/{template_id}/generate-document","href":"/tabs/api-reference/api/templates/generate-document-from-template"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Creates a downloadable document from an existing Lumin template.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,p:`p`,..._provideComponents(),...props.components},{Accordion}=_components;if(!Accordion)_missingMdxReference(`Accordion`,true);return _jsxs(Accordion,{title:`Required scopes (OAuth 2.0)`,icon:`key`,id:`required-scopes-oauth-2-0`,children:[_jsx(_components.p,{children:`This endpoint requires the following scope:`}),_jsx(_components.p,{children:_jsx(_components.code,{children:`templates`})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":{"theme":{"light":"github-light","dark":"github-dark"}},"config":{},"pageMetadata":{"title":"Generate Document from Template","description":"Creates a downloadable document from an existing Lumin template.","openapi":"POST /templates/{template_id}/generate-document","href":"/tabs/api-reference/api/templates/generate-document-from-template"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"summary":"Generate Document from Template","description":"Creates a downloadable document from an existing Lumin template.","security":["7ea39b87-3193-4c41-8d80-fc23c24ef309","62e85e7e-fb23-494f-a8f9-392d4d5e8811"],"tags":["Templates"],"parameters":["67a1ca51-a462-4b9f-81f5-56ffc02d09c7"],"requestBody":"6c197f3d-d461-438e-a472-edf2545d252f","responses":{"200":"9b81ccfc-52b4-4c64-83d5-f686f48cea45","4XX":"59513daf-203c-4bc7-950f-81e913e808ea"},"method":"post","type":"path","servers":["5d5d29d0-7468-455e-aa18-a9b021396aa8"],"path":"/templates/{template_id}/generate-document","baseUrlOptions":["https://api.luminpdf.com/v1"],"title":"Generate Document from Template","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated","prefillPlaygroundWithExample":true,"prefillPlaygroundExamples":[{"body.tags":{"Client.Name":"Acme Corp","Effective.Date":"2025-08-01"},"body.fields":{"CustomerName":"John Doe","AgreeToTerms":true},"body.variables":{"Company.Name":"ACME Corp","Document.Name":"NDA Document"},"body.collections.Opportunity\\.LineItems.items.0.Product\\.Name":"Annual enterprise license","body.collections.Opportunity\\.LineItems.items.0.Product\\.Quantity":"1","body.collections.Opportunity\\.LineItems.items.0.Product\\.UnitPrice":"$1,000.00","body.collections.Opportunity\\.LineItems.items.0.Product\\.Total":"$1,000.00","body.collections.Opportunity\\.LineItems.items.1.Product\\.Name":"Premium support package","body.collections.Opportunity\\.LineItems.items.1.Product\\.Quantity":"1","body.collections.Opportunity\\.LineItems.items.1.Product\\.UnitPrice":"$500.00","body.collections.Opportunity\\.LineItems.items.1.Product\\.Total":"$500.00","body.document_name":"My Contract"}]},"dependencies":{"parameters":{"67a1ca51-a462-4b9f-81f5-56ffc02d09c7":{"in":"path","name":"template_id","schema":{"type":"string","isRequired":true,"description":"ID of the template to generate document from.","uniqueKey":"","typeLabel":"string"},"required":true,"description":"ID of the template to generate document from."}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"tags":{"type":"object","description":"Key–value pairs for **Merge Tags** defined in the Sign template. Keys must match tag names. Values replace the corresponding tags and are rendered as plain text in the generated document.\n","uniqueKey":"tags","typeLabel":"object"},"fields":{"type":"object","description":"Key–value pairs for **Form Fields** defined in the template. Keys must match field names. Values prefill the corresponding fields in the generated document.\n","uniqueKey":"fields","typeLabel":"object"},"variables":{"type":"object","description":"Key–value pairs for **Variables** defined in the AgreementGen template. Keys must match variable names. Values prefill the corresponding variables and are rendered as plain text in the generated document.\n","uniqueKey":"variables","typeLabel":"object"},"collections":{"type":"object","description":"Map of **collection name → array of record objects** used to expand table-scoped row-loop markers in the template.\n\n- Each key must match a collection name returned by [Get Template Details](/tabs/api-reference/api/templates/get-template-details) under `collections[].name`.\n- Each value is an ordered array of flat record objects; each record is a key–value map where keys match the collection's variable names and values are strings.\n- Records are rendered in array order.\n- Maximum 100 items per collection, and up to 50 collections per request.\n\nApplies to AgreementGen templates only. Ignored silently when the template `type` is not `lumin`.\n","additionalProperties":{"type":"array","items":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"collections.additionalProperties.items.[INDEX].additionalProperties","typeLabel":"string"},"uniqueKey":"collections.additionalProperties.items.[INDEX]","typeLabel":"object"},"uniqueKey":"collections.additionalProperties","typeLabel":"object[]"},"uniqueKey":"collections","typeLabel":"object"},"document_name":{"type":"string","description":"Optional name for the generated document. If omitted, the document name defaults to the template's name.","uniqueKey":"document_name","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"tags":{"Client.Name":"Acme Corp","Effective.Date":"2025-08-01"},"fields":{"CustomerName":"John Doe","AgreeToTerms":true},"variables":{"Company.Name":"ACME Corp","Document.Name":"NDA Document"},"collections":{"Opportunity.LineItems":[{"Product.Name":"Annual enterprise license","Product.Quantity":"1","Product.UnitPrice":"$1,000.00","Product.Total":"$1,000.00"},{"Product.Name":"Premium support package","Product.Quantity":"1","Product.UnitPrice":"$500.00","Product.Total":"$500.00"}]},"document_name":"My Contract"},"examples":{"Example":{"title":"Example","value":{"tags":{"Client.Name":"Acme Corp","Effective.Date":"2025-08-01"},"fields":{"CustomerName":"John Doe","AgreeToTerms":true},"variables":{"Company.Name":"ACME Corp","Document.Name":"NDA Document"},"collections":{"Opportunity.LineItems":[{"Product.Name":"Annual enterprise license","Product.Quantity":"1","Product.UnitPrice":"$1,000.00","Product.Total":"$1,000.00"},{"Product.Name":"Premium support package","Product.Quantity":"1","Product.UnitPrice":"$500.00","Product.Total":"$500.00"}]},"document_name":"My Contract"}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"9b81ccfc-52b4-4c64-83d5-f686f48cea45":{"description":"Returns the generated document.","content":{"application/json":{"schema":{"type":"object","required":["document_name","signed_url","expires_at"],"properties":{"document_name":{"type":"string","description":"Name of the generated document (from input or default).","isRequired":true,"uniqueKey":"document_name","typeLabel":"string"},"signed_url":{"type":"string","format":"uri","description":"Signed HTTPS URL to download the generated document. Expires in 30 minutes.","isRequired":true,"uniqueKey":"signed_url","typeLabel":"string\u003curi>"},"expires_at":{"type":"integer","format":"unix-epoch","description":"Unix epoch timestamp (in seconds) indicating when signed_url will no longer work.","isRequired":true,"uniqueKey":"expires_at","typeLabel":"integer\u003cunix-epoch>"}},"uniqueKey":"","typeLabel":"object"},"example":{"document_name":"NDA_AcmeCorp","signed_url":"https://files.luminpdf.com/download/nda-acmecorp-abc123.pdf?expires=2025-08-24T10:45:00Z","expires_at":1766726700},"examples":{"Example":{"title":"Example","value":{"document_name":"NDA_AcmeCorp","signed_url":"https://files.luminpdf.com/download/nda-acmecorp-abc123.pdf?expires=2025-08-24T10:45:00Z","expires_at":1766726700}}},"exampleType":"examples"},"application/pdf":{"schema":{"type":"string","format":"binary","uniqueKey":"","typeLabel":"file"},"examples":{"Example":{"title":"Example","value":"\u003cstring>"}},"exampleType":"generated"}},"exampleType":"examples"},"59513daf-203c-4bc7-950f-81e913e808ea":{"description":"Unexpected error","content":{"application/json":{"schema":{"type":"object","required":["error_code","error_message"],"properties":{"error_code":{"type":"string","description":"The system error code.","isRequired":true,"uniqueKey":"error_code","typeLabel":"string"},"error_message":{"type":"string","description":"The human-readable error message.","isRequired":true,"uniqueKey":"error_message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error_code":"\u003cstring>","error_message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"7ea39b87-3193-4c41-8d80-fc23c24ef309":{"ApiKey":{"type":"apiKey","in":"header","name":"X-API-Key","description":"Provide your API key in the `X-API-Key` header, e.g., `X-API-Key: YOUR_API_KEY`.\n","scopes":[]}},"62e85e7e-fb23-494f-a8f9-392d4d5e8811":{"BearerAuth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"https://auth.luminpdf.com/oauth2/auth","tokenUrl":"https://auth.luminpdf.com/oauth2/token","scopes":{"openid":"Retrieve basic identity details (username, email, profile picture).","offline_access":"Request a refresh token for long-lived access. Private apps only.","profile.read":"View basic user profile information.","workspaces":"View and manage Workspaces and Spaces.","workspaces.read":"View information about the authenticated user's Workspace.","templates":"View and manage templates in a Workspace.","pdf:files":"Create, edit, and delete PDF files in a Workspace.","pdf:files.read":"Retrieve PDF documents stored in a Workspace.","sign:requests":"Create, update, or view signature requests.","sign:requests.read":"Retrieve signature requests.","agreements":"Create, update, or delete AgreementGen documents."}}},"description":"OAuth 2.0 authorization code flow. Provide your access token in the `Authorization` header, e.g., `Authorization: Bearer \u003ctoken>`. See the [OAuth 2.0 guide](/tabs/guides/authentication/oauth2) for details.\n","scopes":["templates"]}}},"servers":{"5d5d29d0-7468-455e-aa18-a9b021396aa8":{"url":"https://api.luminpdf.com/v1","description":"Production server"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"X-API-Key","description":"Provide your API key in the `X-API-Key` header, e.g., `X-API-Key: YOUR_API_KEY`.\n","scopes":[]},"schema":{"title":"X-API-Key","type":"string","description":"Provide your API key in the `X-API-Key` header, e.g., `X-API-Key: YOUR_API_KEY`.\n","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKey","name":"X-API-Key"}],"title":"ApiKey"},{"schemes":[{"scheme":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"https://auth.luminpdf.com/oauth2/auth","tokenUrl":"https://auth.luminpdf.com/oauth2/token","scopes":{"openid":"Retrieve basic identity details (username, email, profile picture).","offline_access":"Request a refresh token for long-lived access. Private apps only.","profile.read":"View basic user profile information.","workspaces":"View and manage Workspaces and Spaces.","workspaces.read":"View information about the authenticated user's Workspace.","templates":"View and manage templates in a Workspace.","pdf:files":"Create, edit, and delete PDF files in a Workspace.","pdf:files.read":"Retrieve PDF documents stored in a Workspace.","sign:requests":"Create, update, or view signature requests.","sign:requests.read":"Retrieve signature requests.","agreements":"Create, update, or delete AgreementGen documents."}}},"description":"OAuth 2.0 authorization code flow. Provide your access token in the `Authorization` header, e.g., `Authorization: Bearer \u003ctoken>`. See the [OAuth 2.0 guide](/tabs/guides/authentication/oauth2) for details.\n","scopes":["templates"]},"schema":{"title":"OAuth2 Auth","type":"string","isRequired":true,"description":"OAuth 2.0 authorization code flow. Provide your access token in the `Authorization` header, e.g., `Authorization: Bearer \u003ctoken>`. See the [OAuth 2.0 guide](/tabs/guides/authentication/oauth2) for details.\n","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"BearerAuth","name":"Authorization"}],"title":"BearerAuth"}]},"originalFileLocation":"tabs/api-reference/lumin-openapi.yaml"},"subdomain":"luminpdf-82c12c3f","siteName":"Lumin Developer Docs","title":"Generate Document from Template - Lumin Developer Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-05-27T13:10:51.733Z","originalFileLocation":"tabs/api-reference/api/templates/generate-document-from-template.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"light\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Creates a downloadable document from an existing Lumin template.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Lumin Developer Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Generate Document from Template - Lumin Developer Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Creates a downloadable document from an existing Lumin template.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Lumin Developer Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://luminpdf-82c12c3f.mintlify.app/_mintlify/api/og/v2?division=Templates\u0026amp;title=Generate+Document+from+Template\u0026amp;description=Creates+a+downloadable+document+from+an+existing+Lumin+template.\u0026amp;theme=4aee959671d2808ae59aaacd\u0026amp;signature=0982409561073d2afa87df7c99f9f8f3a7b82296f72acdb2a83216483d7e3e34\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Generate Document from Template - Lumin Developer Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Creates a downloadable document from an existing Lumin template.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://luminpdf-82c12c3f.mintlify.app/_mintlify/api/og/v2?division=Templates\u0026amp;title=Generate+Document+from+Template\u0026amp;description=Creates+a+downloadable+document+from+an+existing+Lumin+template.\u0026amp;theme=4aee959671d2808ae59aaacd\u0026amp;signature=0982409561073d2afa87df7c99f9f8f3a7b82296f72acdb2a83216483d7e3e34\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/luminpdf-82c12c3f/pSGZfwsnYnu5RQbc/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Lumin Developer Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#171717\">\u003clink data-mint-head rel=\"canonical\" href=\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/tabs/api-reference/api/templates/generate-document-from-template.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://developers.luminpdf.com/#organization\",\"name\":\"Lumin Developer Docs\",\"url\":\"https://developers.luminpdf.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/luminpdf-82c12c3f/S8lnm3z-VpB7-Jo7/logo/logo-light.svg?fit=max\u0026auto=format\u0026n=S8lnm3z-VpB7-Jo7\u0026q=85\u0026s=7efd61a54cbb6df606831ac070f96525\"}},{\"@type\":\"WebSite\",\"@id\":\"https://developers.luminpdf.com#website\",\"name\":\"Lumin Developer Docs\",\"url\":\"https://developers.luminpdf.com\",\"publisher\":{\"@id\":\"https://developers.luminpdf.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template#webpage\",\"url\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template\",\"name\":\"Generate Document from Template\",\"description\":\"Creates a downloadable document from an existing Lumin template.\",\"dateModified\":\"2026-05-27T13:10:51.733Z\",\"isPartOf\":{\"@id\":\"https://developers.luminpdf.com#website\"},\"breadcrumb\":{\"@id\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Lumin API reference\",\"item\":\"https://developers.luminpdf.com/tabs/api-reference/api/agreements/agreements\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Templates\",\"item\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/templates\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Generate Document from Template\",\"item\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template#apireference\",\"headline\":\"Generate Document from Template\",\"name\":\"Generate Document from Template\",\"description\":\"Creates a downloadable document from an existing Lumin template.\",\"url\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template\",\"mainEntityOfPage\":{\"@id\":\"https://developers.luminpdf.com/tabs/api-reference/api/templates/generate-document-from-template#webpage\"},\"dateModified\":\"2026-05-27T13:10:51.733Z\",\"publisher\":{\"@id\":\"https://developers.luminpdf.com/#organization\"},\"isPartOf\":{\"@id\":\"https://developers.luminpdf.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Lumin Developer Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Lumin Developer Docs","nav":{"global":{"anchors":[{"anchor":"Terms of Use","icon":"newspaper","href":"https://www.luminpdf.com/terms-of-use"},{"anchor":"Help Center","icon":"circle-question","href":"https://help.luminpdf.com/"}]},"tabs":[{"tab":"Home","pages":[{"title":"Home","href":""}]},{"tab":"Guides","pages":[{"title":"Guides","href":"/tabs/guides/getting-started"}]},{"tab":"API Reference","groups":[{"group":"API Documentation","pages":[{"title":"Lumin API Reference","sidebarTitle":"Introduction","href":"/tabs/api-reference/api/lumin-api-reference"}]},{"group":"Lumin API reference","pages":[{"group":"Agreements","expanded":false,"pages":[{"title":"Agreements","sidebarTitle":"Overview","href":"/tabs/api-reference/api/agreements/agreements"},{"title":"Create Agreement","openapi":"POST /agreements","href":"/tabs/api-reference/api/agreements/create-agreement"},{"title":"Get Agreement File","openapi":"GET /agreements/{agreement_id}/file","href":"/tabs/api-reference/api/agreements/get-agreement-file"}]},{"group":"Signature requests","expanded":false,"pages":[{"title":"Signature Requests","sidebarTitle":"Overview","href":"/tabs/api-reference/api/signature-requests/signature-requests"},{"title":"Get Signature Request","openapi":"GET /signature_request/{signature_request_id}","href":"/tabs/api-reference/api/signature-requests/get-signature-request"},{"title":"Update Signature Request","openapi":"PATCH /signature_request/{signature_request_id}","href":"/tabs/api-reference/api/signature-requests/update-signature-request"},{"title":"Send Signature Request","openapi":"POST /signature_request/send","href":"/tabs/api-reference/api/signature-requests/send-signature-request"},{"title":"Send Signature Request from Template","openapi":"POST /signature_request/send-from-template","href":"/tabs/api-reference/api/signature-requests/send-signature-request-from-template"},{"title":"Get Signing Link","openapi":"POST /signature_request/{signature_request_id}/signing-link","href":"/tabs/api-reference/api/signature-requests/get-signing-link"},{"title":"Create Signing Session","openapi":"POST /signature_request/{signature_request_id}/signing-session","href":"/tabs/api-reference/api/signature-requests/create-signing-session"},{"title":"Send Reminder Emails","openapi":"POST /signature_request/remind/{signature_request_id}","href":"/tabs/api-reference/api/signature-requests/send-reminder-emails"},{"title":"Cancel Signature Request","openapi":"PUT /signature_request/cancel/{signature_request_id}","href":"/tabs/api-reference/api/signature-requests/cancel-signature-request"},{"title":"Get Signature Request File","openapi":"GET /signature_request/{signature_request_id}/file","href":"/tabs/api-reference/api/signature-requests/get-signature-request-file"}]},{"group":"Templates","expanded":false,"pages":[{"title":"Templates","sidebarTitle":"Overview","href":"/tabs/api-reference/api/templates/templates"},{"title":"List Templates","openapi":"GET /templates","href":"/tabs/api-reference/api/templates/list-templates"},{"title":"Get Template Details","description":"Returns essential template details for a specific template.","openapi":"GET /templates/{template_id}","href":"/tabs/api-reference/api/templates/get-template-details"},{"title":"Generate Document from Template","openapi":"POST /templates/{template_id}/generate-document","href":"/tabs/api-reference/api/templates/generate-document-from-template"}]},{"group":"Documents","expanded":false,"pages":[{"title":"Documents","sidebarTitle":"Overview","description":"Create, upload, and process PDF documents in the Workspace.","href":"/tabs/api-reference/api/documents/documents"},{"title":"Upload Document","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents","href":"/tabs/api-reference/api/documents/create-document"},{"title":"Merge Documents","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/merge","href":"/tabs/api-reference/api/documents/merge-documents"},{"title":"Compress Document","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/compress","href":"/tabs/api-reference/api/documents/compress-document"},{"title":"Split Document","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/split","href":"/tabs/api-reference/api/documents/split-document"},{"title":"Add Password","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/add-password","href":"/tabs/api-reference/api/documents/add-password"},{"title":"Remove Password","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/remove-password","href":"/tabs/api-reference/api/documents/remove-password"},{"title":"Summarize Document","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/summarize","href":"/tabs/api-reference/api/documents/summarize-document"},{"title":"Translate Document","openapi":"tabs/api-reference/lumin-openapi.yaml POST /documents/translate","href":"/tabs/api-reference/api/documents/translate-document"}]},{"group":"Workspaces","expanded":false,"pages":[{"title":"Workspaces","sidebarTitle":"Overview","href":"/tabs/api-reference/api/workspaces/workspaces"},{"title":"Get Workspace Information","openapi":"GET /workspaces/info","href":"/tabs/api-reference/api/workspaces/get-workspace-information"},{"title":"Get Workspace Members","openapi":"GET /workspaces/members","href":"/tabs/api-reference/api/workspaces/get-workspace-members"},{"title":"List Spaces","openapi":"GET /workspaces/spaces","href":"/tabs/api-reference/api/workspaces/list-spaces"},{"title":"Create Space","openapi":"POST /workspaces/spaces","href":"/tabs/api-reference/api/workspaces/create-space"}]},{"group":"Users","expanded":false,"pages":[{"title":"Users","sidebarTitle":"Overview","href":"/tabs/api-reference/api/users/users"},{"title":"Get User Information","openapi":"GET /user/info","href":"/tabs/api-reference/api/users/get-user-information"}]}]}]},{"tab":"Lumin MCP","pages":[{"title":"Lumin MCP","href":"/tabs/mcp/client"}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/tabs/changelog"}]}]},"basePath":"","title":"Generate Document from Template - Lumin Developer Docs","buildId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","deploymentId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CS552b7R.js","utils-DDTCYAF2.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-De8ttokP.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-DrwRDvAh.js","snippetPresets-DtAN0nWx.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-D5rWArI6.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-O2i12wsz.js","shallow-DV8xABTt.js","getApiPlaygroundDisplay-DBZ0B5Jx.js","CodeSnippet-BVi0tPUX.js","CodeSnippets-CqASbIwY.js","Page-m07pfKpT.js","getPastedJson-DG9vsMS8.js","icon-CXzRSCr8.js","MethodPill-BdKVtEuX.js","DuplicateIcon-CZlmBrJI.js","createIcon-biFEUKPL.js","DynamicMarkdown-B54_zNBF.js","SectionHeading-DwwHK3Pt.js","axios-vUo_bRtp.js","Markdown-DfhCTwyA.js","clsx-xpJZXxdP.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-BTZUMDnx.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-DqdKa2R4.js"]}