Create PDF

I know there’s a Node to Read a PDF and to extract it’s contents.

I would love a node to create a PDF File to let’s say attach to an email

yes, this would be nice to have. It Will be cool to allow the user to provide a template and the data to fill the template as a JSON.

1 Like

Yes exactly :slight_smile:

I did research that a while ago but I think the issue was finding an npm library to use. Think they were normally all just wrappers around an external program that had to be installed additionally and had also some other issues.

Not sure about bugs, but this doesnt seem to be a wrapper

Not sure if I did also look into that one in August last year. Quite possible that I missed it as it is quite “new” and at that time had like 200 stars.
On the first look it looks promising. The only downside I can see right now (but did just skim the first page) is the huge size, as it is larger than the all of the n8n code combined.

Maybe an idea to give users the ability to add/download certain nodes as “Addons” ?
If people dont need it there’s no point of them downloading it
I dont know how modular n8n is

Is already possible since the beginning of n8n to add own modules with own nodes. It is however not possible yet to do that conveniently via the UI. Sadly no idea when we will get to it.
For that reason is it currently still quite complicated esp. with docker and so not a good option yet.

Hmm allright, But yeah it would be an amazing feature :smiley: (Especially since i need it haha)

:wink: Yes totally agree. Would be both very cool. Loading modules more easily and creating/editing/filling PDFs!

Oh i only just now noticed i placed this post in the wrong category

Yeah I did some search last night and all solutions as @jan mentioned need a library that weights more than n8n itself which is crazy.

I wanted to create a tiny version of this https://www.useanvil.com/pdf-filling-api/

I guess PDF’s are really complicated that they need such a huge library?

It seems like it. This is a quote from the anvil guys.

When we started Anvil, we thought programmatically completing PDFs would be pretty easy. We assumed there would be a popular open-source module or easy-to-integrate API we could pull in to immediately read and fill PDFs.

We quickly learned PDFs are unbelievably complicated, and even though they are ubiquitous, the tooling out there for processing PDFs programmatically was pretty thin.

You would think it would be different since it’s such a widely used file format

Maybe an idea to create a Word file, Fill that and then convert it?

I looked into this for a different project. There are indeed a couple of options to generate PDFs without external tools that not so bad. Just the idea of using a PDF as a base template - forget that :slight_smile: They need to be created from scratch.

Both are libs that seems to do the job just fine.
It’s just the question what kind of input interface one would provide for the n8n node.

2 Likes

This here is the right approach. My team generates many PDFs using python, C# and javascript libraries, and the ones that work within the PDF format are very difficult to use and usually expensive. However generating an html page and then converting it to PDF is much easier and free.

For one of our websites we use rasterizeHTML + jspdf.

I’m following this project https://carbone.io/ .

It uses libreoffice to render a work/libreoffice document as a template into a PDF getting a json with the data you need. It’s open source and some functionality is closed source. One of the closed source functionality is to add imaged to a file, which is what I need and it makes me doubt about adopting it.

1 Like

oh, I would absolutely love being able to make reports this way!

i have no votes left :frowning:

1 Like