whmcs_get_domain_nameservers
Retrieve nameserver information for a domain using its ID in WHMCS. This tool helps manage domain configurations by providing current nameserver details.
Instructions
Get nameservers for a domain
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| domainid | Yes | Domain ID |
Implementation Reference
- src/index.ts:658-671 (registration)Registers the MCP tool 'whmcs_get_domain_nameservers' with input schema requiring domainid and a thin wrapper handler that delegates to WhmcsApiClient.getDomainNameservers'whmcs_get_domain_nameservers', { title: 'Get Domain Nameservers', description: 'Get nameservers for a domain', inputSchema: { domainid: z.number().describe('Domain ID'), }, }, async (params) => { const result = await whmcsClient.getDomainNameservers(params); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }], }; }
- src/whmcs-client.ts:869-877 (handler)The core handler method in WhmcsApiClient that performs the actual API call to WHMCS using action 'DomainGetNameservers' to retrieve the five nameservers (ns1-ns5) for the specified domain ID.async getDomainNameservers(params: { domainid: number }) { return this.call<WhmcsApiResponse & { ns1: string; ns2: string; ns3: string; ns4: string; ns5: string; }>('DomainGetNameservers', params); }