@jesseditson/dnsimple
Version:
A Node.JS client for the DNSimple API.
44 lines (43 loc) • 2.1 kB
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.VanityNameServers = void 0;
class VanityNameServers {
constructor(_client) {
this._client = _client;
/**
* Enables Vanity Name Servers for the domain.
*
* This method sets up the appropriate A and AAAA records for the domain to provide vanity name servers, but it does not change the delegation for the domain. To change the delegation for domains to vanity name servers use the endpoints to Delegate to Vanity Name Servers or Dedelegate from Vanity Name Servers.
*
* PUT /{account}/vanity/{domain}
*
* @see https://developer.dnsimple.com/v2/vanity/#enableVanityNameServers
*
* @param account The account id
* @param domain The domain name or id
* @param params Query parameters
*/
this.enableVanityNameServers = (() => {
const method = (account, domain, params = {}) => this._client.request("PUT", `/${account}/vanity/${domain}`, null, params);
return method;
})();
/**
* Disables Vanity Name Servers for the domain.
*
* This method removes the A and AAAA records required for the domain to provide vanity name servers, but it does not change the delegation for the domain. To change the delegation for domains to vanity name servers use the endpoints to Delegate to Vanity Name Servers or Dedelegate from Vanity Name Servers.
*
* DELETE /{account}/vanity/{domain}
*
* @see https://developer.dnsimple.com/v2/vanity/#disableVanityNameServers
*
* @param account The account id
* @param domain The domain name or id
* @param params Query parameters
*/
this.disableVanityNameServers = (() => {
const method = (account, domain, params = {}) => this._client.request("DELETE", `/${account}/vanity/${domain}`, null, params);
return method;
})();
}
}
exports.VanityNameServers = VanityNameServers;
;