Hi, I have ISPConfig 3.1.6 on debian Jessie multiserver setup. I am trying to create a script that adds a new domain for a client using remoting api : domains_domain_add.php, but was wondering how I prevent a new domain from being added if it has not been registered yet. For example add domain domainnotregistered.com, if the domain doesn't exist yet, show some kind of error message, and if it does exist then add the new domain in ispconfig. Any advice is greatly appreciated, thanks.
Check if the domain exists already with: $domain_record = $client->sites_web_domain_get($session_id, array('domain' => 'yourdomain.tld'));