Now that we have installed a simple script we can proceed further and see how we can use a more complex one. Our use case here is simple and very common in a company: using data stored in a database to fill your document.
For example, at the beginning of this book we have created a business card. However, we would like all of the employees of our fictive GraphCo company to have their own business card. If the company has very few people involved, creating the cards manually might be fast enough. But if your company has more than 50 or 100 people, it could take very long to do them one by one. You certainly have the employees list somewhere. In our case, we have created the Scribus template, without the employee frame. We have created a MySQL table for the employees, but, Python might be able to read other kinds of database systems too.
When writing Python script for Scribus the important place to go to is the Scribus Python API reference...