XSL-FO Transform API — XML + XSLT to PDF
Generate PDFs with PdfBroker.io by providing an XSL-FO document formatted as XSLT along with an XML data document. The service applies the transformation to produce the final PDF output. This approach separates data from presentation, making templates reusable.
Endpoint
POST https://api.pdfbroker.io/api/pdf/xslfowithtransform
How It Works
- You provide an XSLT stylesheet that produces XSL-FO output
- You provide an XML data document with the content to format
- The API applies the XSLT transformation to the XML data
- The resulting XSL-FO document is processed into a PDF
Advantage
By separating the XSLT template from the XML data, you can reuse the same template with different data sets. This is ideal for generating invoices, reports, certificates, and other documents with variable content.
Live Demo
See a practical example of invoice generation using XSL-FO transformation:
Additional Resources
- Swagger documentation for the complete API specification
- XSL-FO with XSLT tutorial for learning how to combine XSL-FO and XSLT
- PdfBroker Template Tool for developing and testing templates