Supply a YAML file as configuration, as in this example. Via the document ID and SQL query, point at data in a Grist document.
Optionally, it inserts or update records in the database based on the data processed.
pip install grist-template
or
pipx install grist-template
grist-template config.yml
See the this example and the command line help.