In this tutorial, we will show you how to generate PDF from HTML Template in Integromat using PDF.co and Make an API Call Module. Here’s the HTML Template that we use.

  1. PDF.co App and Make an API Call
  2. PDF.co Connection
  3. Test Result
  4. Output
  5. Generate PDF from HTML Template – Video Guide
Sample HTML Template
Sample HTML Template

Step 1: PDF.co App and Make an API Call

First, select the PDF.co app for the App Event and choose the Make an API Call module for the Trigger Event.

PDF.co App and Make an API Call Module

Step 2: PDF.co Connection

Now, let’s set up the PDF.co configuration.

  • In the API Endpoint Path field, set the endpoint to /v1/pdf/convert/from/html to convert HTML to PDF.
  • Now in the Body section click on Add Item. Then, set the Key to templateId and set the Value to your HTML templateId. You can find your HTML template id at https://app.pdf.co/template/html

PDF.co Configuration
PDF.co Configuration

  • Click add another item with Key as templateData
    and set Value to the JSON string with input JSON data.

PDF.co Configuration

  • Make sure to enable these switches; Forcely enable async mode and Auto-run job/check for async jobs.
  • Set the Export Type to JSON output.

PDF.co Configuration

After setting up the configuration, let’s run the module to generate output PDF.

Step 3: Test Result

Great! We successfully converted the HTML template to PDF. You can copy and paste the URL to view the output.

Test Result

Step 4: Output

Here’s the converted output from the HTML template to PDF.

HTML to PDF Output
HTML to PDF Output

In this tutorial, you learned how to generate PDF from HTML template in Integromat using PDF.co and Make an API Call Module. You learned how to convert HTML to PDF using the /v1/pdf/convert/from/html endpoint. You also learned how to use the Make an API Call Module.

Generate PDF from HTML Template – Video Guide


 

Related Pages:

Related Samples: