Creates a new nameserver. Returns ``True`` if the nameserver was created
    successfully.

    sld
        SLD of the domain name

    tld
        TLD of the domain name

    nameserver
        Nameserver to create

    ip
        Nameserver IP address

    CLI Example:

    .. code-block:: bash

        salt '*' namecheap_domains_ns.create sld tld nameserver ip

def create(sld, tld, nameserver, ip):
    '''
    Creates a new nameserver. Returns ``True`` if the nameserver was created
    successfully.

    sld
        SLD of the domain name

    tld
        TLD of the domain name

    nameserver
        Nameserver to create

    ip
        Nameserver IP address

    CLI Example:

    .. code-block:: bash

        salt '*' namecheap_domains_ns.create sld tld nameserver ip
    '''

    opts = salt.utils.namecheap.get_opts('namecheap.domains.ns.create')
    opts['SLD'] = sld
    opts['TLD'] = tld
    opts['Nameserver'] = nameserver
    opts['IP'] = ip

    response_xml = salt.utils.namecheap.post_request(opts)
    if response_xml is None:
        return False

    domainnscreateresult = response_xml.getElementsByTagName('DomainNSCreateResult')[0]
    return salt.utils.namecheap.string_to_value(domainnscreateresult.getAttribute('IsSuccess'))