pip install relatorio
python
from relatorio.templates.opendocument import Template
from relatorio import SxDocument
python
template_path = '/path/to/template.odt'
template = Template(template_path)
python
data = {
'name': 'John Doe',
'age': 25,
'email': 'john@example.com'
}
python
sx = SxDocument(template=template)
sx.insert(data)
python
output_path = '/path/to/output.pdf'
sx.save(output_path)