Database to document

Document Automation API

Document Automation API

Businesses create a variety of documents from their enterprise systems such as CRM, ERP, SCM etc. The most common approach for the development of document automation functionality is by coding for each document template inside the system. It makes the code less modular and inflexible. Moreover, every time a template changes, the associated code require modifications.

Document automation API allows the document creation to happen outside of application's core functionality and it can be ported across other applications thus allowing you to create complex workflows. For mobile apps, document creation outside the device reduce performance overheads, saves battery life and improves scalability.

Integration with API empowers business users to create/edit templates without seeking IT support. If your end users create documents from their own templates, then using external API that addresses various special scenarios of templates saves a lot of time and effort.

EDocGen Document Automation API

EDocGen offer REST API to generate and distribute documents from XML-JSON-XLSX data, databases, and third-party applications. EDocGen is API first product and you can do pretty much everything that you can do with the online app. This includes the dynamic population of

  1. Text
  2. Tables
  3. Hyperlinks
  4. Images
  5. Content Blocks

Apart from this, API also supports multi-lingual document templates, Arithmetic calculations, conditional statements (if-else) that allow you to generate proposals, invoices, contracts etc. without any manual intervention. Generate the documents either in Word or PDF format and distribute them through email or sync to Google Drive apart from download.

EDocGen document generation API is built for high performance and generate thousands of complex documents in few seconds. Since the API calls are asynchronous, you can initiate high volume requests to generate millions of documents.

Using EDocGen, you can also create one document at a time. This is useful if you want to have a form on your website and filling it by users creates a document.

Frequently Asked Questions

Does my account give access to API?

If you have an active EDocGen account then you may use the API.

Does your API support my programming language?

If your language is able to send HTTP requests and receive HTTP response, then yes. This isn't a problem for modern languages.

What Dynamic field types EDocGen supports

EDocGen supports the dynamic population of Text, Tables, Hyperlinks, content blocks and Images. Apart from this, it also supports conditions (if-else) and calculations using basic arithmetic operations

Can I generate PDF documents

Yes. You can use both Word templates and fillable pdf templates for pdf document generation.

What are the delivery options available for assembled documents

1. Download generated documents in zip/docx formats

2. Email generated file

3. Sync generated files to Google drive

Document Generation API Endpoint


EDocgen uses token based authentication. Register with EDocGen portal and call /login to authenticate your credentials and obtain the token.



"username": "string",

"password": "string"


Once you obtain token, you can use to make other API call by passing it in the header.

API Elements

Please refer to for API documentation. EDocGen API elements include

  1. Uploading template
  2. Get templates details
  3. Get markers/dynamic fields in a template
  4. Image upload
  5. Content Block upload
  6. Bulk document generation from XML/JSON/XLSX
  7. Generated Files Details
  8. Download generated files
  9. Email generated files


Below is sample template

Document Generation API template

Marker Format

{"markers":{"entry":[{"key":"university","value":"Put value for university here."}, {"key":"photoimg","value":"Put value for photoimg here."}, {"key":"name","value":"Put value for name here."}, {"key":"marksdata","value":"Put value for marksdata here."}, {"key":"exam","value":"Put value for exam here."}]}, "templateId":"54a24c6fe4b048a7e255b590"}

JSON Data Population

{"markers":{"entry":[{"key":"university","value":"University of California"}, {"key":"photoimg","value":"54a24cdfe4b048a7e255b592"}, {"key":"name ","value":"Anushka Sharma"}, {"key":"marksdata","value":"[['Maths','45'],['Science','65'],['Biology','75']] "}, {"key":"exam","value":"Diploma in Sciences"}]},"templateId":"54a24c6fe4b048a7e255b590"}

Popular Posts