Table of Contents

How to generate a document with PDFMonkey by Zapier

Alexander Gao Updated by Alexander Gao

Prepare Landbot
  1. First we have to build a bot flow in your bot to collect the information you need to send to Zapier, like name, email, age, etc.

The information that we collect, will be stored in variables, that we will sent to Zapier.

As in the example below, we are storing the name input in the variable @name, that we will use later.

  1. Then let's set a Trigger automations block.

Create Zap trigger
  1. After set a trigger automation block, let's open Zapier:

  1. We need to do is click on the button Make A Zap:

  1. Search the option Webhook (webhooks by Zapier) and select it:

  1. On the dropdown Trigger Event, choose the option Catch Hook and press continue:

  1. Copy the Webhook URL, so that we can use it in the next steps, and press CONTINUE.
  1. On the following screen, don't press the Test trigger button yet (we will do it after a few more steps).
Prepare Landbot request to Zapier
  1. Go back to Landbot, and paste in the Trigger automation block the URL that you have copied from the Zap.
    Please add it to the URL field in the Trigger automation block.
  1. Scroll down and go to the Set data (variables) to be sent section of the Trigger automation, where you can set test values:
  1. And click on Test webhook trigger button:
  1. If you scroll down, you will see the response from Zapier:

  1. If you see the Status code as 200, and the status as "success", this means that our request was successfully sent.

Check the data of the request (test) in Zapier
  1. Go back to Zapier.
  2. Click on the button Test trigger, to check the information that we have sent from the Webhook Test:

  1. Once we press Test trigger you will see the page below, with the variables and values we used in the test:
As you can see, the @name, @email, and @age are the same as we sent to Zapier:This is how the trigger works, we send variables to Zapier, they receive, and when we try to test it as we did in step 15, it will be shown.

After we turn on Zap, the whole progress will be doing automatically.
  1. So far the part of trigger is done.
    However, after the trigger we have to set up the actions we want to trigger on Zapier. Please keep in mind that this set up is done in your Zapier account, not in Landbot.

Now let's press continue

Make a PDF file
  1. we choose an app to integrate, here we will use PDF monkey.

  1. Then in the Action Event we choose generate document, press continue.

  1. Sign in PDFMonkey.
When you sign in PDFMonkey, it requires an API Secret Key, just click on My account page, then copy the key, paste it in the sign in page. Then it's done.

  1. After sign in, let's continue. Below Action Event we choose Generate Document
  1. Let's open PDFMonkey to do some following issues.

  1. Click on add an application.

  1. Let's give it a name! Then click on the green button ADD
  1. After we add it, appears this page, of adding a template. Click on add a template below.
  1. Then we arrive here, choose a template that you need, for example the bill template.
  1. Let's give this PDF a name!
  1. Then click on the green button Create down there of the page
  1. And appears a page like this, maybe the code is making you dizzy, but don't worry, we don't have to edit the code in HTML section, click on Sample data above the code board instead.
  2. What we are going to do now is copy the code.

  1. Then we click on the green button Publish at upper right corner:

  1. Let's turn back to Zapier, the part of customize document:
  2. Let's put the application that we have created below App, and the template we have created below Template:
  3. Then we have come to the part of Dynamic Data: let's paste the code we have copied before.

  1. Also, normally it's very necessary to replace some information with our own variable, or our own data.

Like here we delete the string Company name, and replace it with our variable @name.

  1. Now we don't need to do anything else, just scroll down the page and press continue:

  1. Now it's time to send data, as always, after we confirm there's nothing wrong, we click on test and continue:

  1. Now we are successfully created a document.
  1. After created a document, we have to check it. Let's copy the download_url:
  2. Then create a new tab in the browser, paste it to the search bar, and press enter:
  1. Then it will be downloaded:
  1. Press it and open the pdf:

Yes, it's correct, the action 2 is done!

Also we have to add that it's just a test, so we can download this way. Normally every time you create a document, the document will be generated in the document section of PDFMonkey. Check the photo below.

How did we do?

How to insert a row to Google Spreadsheet by Zapier

Send WhatsApp Message Templates from Zapier