I would use the remote api for that. Create clients, sites, mail domains etc. with the api and then check the resulting websites, maildirs etc. Some example scripts for the remote api are in the remote_client folder of the ispconfig tar.gz file.