How can I generate a PDF file with n8n?

I have a JSON Object getting as HTTP Response.

{  
    "employee": {  
        "name":       "Rocky",   
        "salary":     "5000",   
        "active":     "true"
    }  
} 

I want to generate a PDF file with this JSON.

Is it possible?

Hi @mcnaveen,

Quick answer is yes you can create a PDF using the APITemplate.io Node

3 Likes

Hello @mcnaveen ,
with carboneio/carbone: Fast and simple report generator, from JSON to pdf, xslx, docx, odt… (github.com)
it could be a good option no ?

1 Like

Wow, This looks super cool. I’ll try and let you know.

1 Like

Hi @mcnaveen

I’m using Google Docs to generate a document from a template and get the pdf of that document

In my use case I start with Google Sheet, but it could be with HTTP Request

Here’s code for this workflow that you can adapt to your use case

8 Likes

Hey @Claudio_Balbino

This is Perfect. :slight_smile: 100% No Code Solution

Thank you for sharing.

2 Likes

Looks like google has updated their format. I use this https://www.googleapis.com/drive/v2/files/[FILE ID]/export?mimeType=application%2Fpdf&key=[API KEY] and it works great.

2 Likes

Hey ,
Can we make repetitive section to generate table for an invoice with Google docs ?

Thanks

It worked for me like a charm! Thank you!

1 Like