Report Markup Language from ReportLab is the simplest way to programatically produce great looking PDF documents with the minimum of fuss.
It's an XML dialect which, combined with a python module which converts the XML files into PDF. Because RML files are just plain text, and Python runs on a plethora of platforms, it's very easy to plug RML into your existing solution or build something new using your favourite language.
Using RML inside a web framework
How to produce dynamic PDF documents using RML and your favourite web framework. These examples show how to integrate a small "Hello, World"-type dynamic PDF solution into popular web frameworks.