3
WebServices: svcDomainAdmin GetDomainDefaults returns undefined
Problem reported by Michael Stopnick - 8/25/2016 at 10:18 AM
Submitted
Trying to use the WebServices provided by SmarterMail.
When we retrieve information from svcDomainAdmin.GetDomainDefaults method, the ServerIp is reporting back as undefined. Is there a setting somewhere in SmarterMail that I'm missing to populate this setting?

3 Replies

Reply to Thread
0
Employee Replied
Employee Post
Hi Michael.  I just tested the GetDomainDefaults API using Storm, and it was successful for me.  I only needed to pass the Sys Admin username/password, and it returned the domain defaults found at Settings >> Defaults >> Domain Defaults.
 
0
Michael Stopnick Replied
Hey Rod,

The API itself works fine and I get a response. If you look at the value of ServerIp in the DomainSettingsResult returned object, it will be "undefined" or blank when it should be an ip address.

BTW, I just tried this with Storm (thanks for the link) to make sure it wasn't something in my program and got the same results.
0
Michael Stopnick Replied
Found a workaround.
 
The whole reason I needed the server ip address was so that I could setup the domain through the API which doesn't allow you to set the IP of the domain to an empty string. Reason I wanted to set it to an empty string is so the domain would use the server's primary IP without actually assigning it in SmarterMail (it makes moving the server when upgrading easier).
 
So to get around this, I initially set the domain assigning it an IP and then immediately call SetRequestedDomainSettings() passing in `["serverip=","serveripv6="]` to make both IPs unassigned.
 
Not the most elegant solution, but it works.

Reply to Thread