Make Use of Our PDF Generation API to
Automate PDF Generation with HTML

with Zapier, Integromat, N8n #Nocode or a Simple REST API

Design beautiful content with HTML, CSS, Javascript and JSON

Our PDF Template Editor allows you to design reusable templates easily. It’s quick and easy to generate PDF documents with HTML, CSS, Javascript, JSON data and automate PDF generation with our simple API.

 

Generate Dynamic PDF documents with a simple REST API Request

With our PDF generation API, you can design a HTML template with our HTML template editor and create dynamic PDFs via a simple REST API. 

The following is an HTML template. To generate a new PDF, we just send a POST request with the properties to be overridden in JSON body.

HTML Template with Jinja2 Template Language

The dynamic data(JSON) will be passed in the {{ variable }} tag, it’s a special syntax of Jinja2 to render variables in the HTML template. You can learn more about the Jinja2 template language here

				
					<h1 class="text-3xl md:text-4xl font-medium mb-2 mt-2 text-center text-label">
  {{title}}
</h1>
<div class="text-center text-lg text-label2">
  {{url}}
</div>

<div class="container mx-auto mt-10">
  <div class="text-lg text-label2">
    There was once a little boy called <b>{{name}}</b>.
    I never knew his other name, and as he lived far off behind the {{place}}, we cannot go to inquire. He had fair hair and blue eyes, and there was something in his face that, when you had looked at him, made you feel quite happy and rested, and think of all the things you meant to do by-and-by when you were wiser and stronger.
  </div>

  <div class="text-lg text-label2 mt-10">
    He lived all alone with the tall aunt, who was very rich, in the big house at the end of the village. Every morning he went down the street with his little goat under his arm, and the village folk looked after him and said, "There goes Master <b>{{name}}</b>."
  </div>
</div>

				
			

Restful API To Generate a PDF

Method: POST
URL: https://api.apitemplate.io/v1/create?template_id=[template_id]
Header: X-API-KEY: [API_KEY]

JSON Data in the request body
				
					{
  "title": "VERY SHORT STORIES",
  "url": "http://www.gutenberg.org/files/30272/30272-h/30272-h.htm",
  "name": "Willie",
  "place": "mountain"
}
				
			
Response
				
					{
   "download_url":"https://pub-cdn.apitemplate.io/564121-23222232-6e2332375.pdf",
   "template_id":"cd23222b188c5c42",
   "transaction_ref":"564121-23222232-6e2332375",
   "status":"success"
}
				
			
Generated PDF

PDF Generation with Zapier, Integromat or Airtable

Besides API integration, we also integrate with No-code platforms for you to automate PDF creation. You can generate PDFs easily with Zapier, Integromat, N8n, and UiPath. Additionally, you can generate PDFs in bulk with our Airtable integration.

*Integration with other no-code platforms can be achieved with the platform’s HTTP/HTTPS component such as bubble.io – API Connector or Integromat – HTTP app

Sign up now for free!