Scheduling a message from within PHP script

Hello.

I’m trying to build and send a campaign directly from a PHP script - an automatic weekly newsletter.

I already build a script that will fetch the content from a Wordpress site and build a template ready for sending. The processqueue cron is also working.
Now I think I have to build another script that will fetch that template and schedule a campaign to the date I want, directly on the database. Then, another cron job will run this script once a week, and the processqueue cron job will take care of sending.
I can’t seem to find any documentation for the database, so I’m not sure if the tables message and listmessage are enough to do what I want. Besides that, is there a better way to do this?

I’m using phpList 3.0.5, hosted on a VPN.
Thank you for your help.