def set_custom(sld, tld, nameservers):
 opts = salt.utils.namecheap.get_opts('namecheap.domains.dns.setCustom')
 opts['SLD'] = sld
 opts['TLD'] = tld
 opts['Nameservers'] = ','.join(nameservers)
 response_xml = salt.utils.namecheap.post_request(opts)
 if (response_xml is None):
  return False
 dnsresult = response_xml.getElementsByTagName('DomainDNSSetCustomResult')[0]
 return salt.utils.namecheap.string_to_value(dnsresult.getAttribute('Update'))

def set_custom ( sld , tld , nameservers ) : opts = salt . utils . namecheap . get_opts ( 'namecheap.domains.dns.setCustom' ) opts [ 'SLD' ] = sld opts [ 'TLD' ] = tld opts [ 'Nameservers' ] = ',' . join ( nameservers ) response_xml = salt . utils . namecheap . post_request ( opts ) if ( response_xml is None ) : return False dnsresult = response_xml . getElementsByTagName ( 'DomainDNSSetCustomResult' ) [ 0 ] return salt . utils . namecheap . string_to_value ( dnsresult . getAttribute ( 'Update' ) )
sets domain to use custom dns servers .