Thanks alot Till.
Now, I have realized some inconsistencies with database creation (sites_database_add). My understanding is that you can NOT have the same database name on the same server.
However, the API allows me to create same DB name on the same server_id several times without it complaining. It actually creates it in the database though on the real server it does not ...(I think you need this check in API)