Child pages
  • WHM API 1 Functions - cluster_member_has_trust_with
Skip to end of metadata
Go to start of metadata

Description

This function queries whether nameservers in a DNS cluster can share records with one another. Servers in a DNS cluster must exist in a Reverse Trust relationship to share information. This relationship requires each server to have an API token.

Note:

DNS servers in a Write-Only role do not need to exist in a Reverse Trust relationship.

For more information, read our Guide to DNS Cluster Configurations documentation.

Examples 


 JSON API
https://hostname.example.com:2087/cpsess##########/json-api/cluster_member_has_trust_with?api.version=1&host=192.0.2.0
 Command Line
whmapi1 cluster_member_has_trust_with host=192.0.2.0


Notes:

  • Unless otherwise noted, you must URI-encode values.
  • For more information and additional output options, read our Guide to WHM API 1 documentation or run the whmapi1 --help command.
  • If you run CloudLinux™, you must use the full path of the whmapi1 command:

    /usr/local/cpanel/bin/whmapi1

 Output (JSON)
{
  "data": {
    "has_trust": "1"
  },
  "metadata": {
    "version": 1,
    "reason": "OK",
    "result": 1,
    "command": "cluster_member_has_trust_with"
  }
}


Note:

Use WHM's API Shell interface (WHM >> Home >> Development >> API Shell) to directly test WHM API calls.

Parameters

ParameterTypeDescriptionPossible valuesExample
hoststring

Required

The nameserver's IP address.

A valid IP address.192.0.2.0
althost string

The nameserver's alternate IP address. This is useful, for example, if your DNS cluster exists in a NAT-configured network.

This parameter defaults to an empty string.

A valid IP address.192.0.3.0 

Returns

ReturnTypeDescriptionPossible valuesExample
has_trust BooleanWhether the nameserver can send information to other cluster members.
  • 1 — Can send information.
  • 0 — Can't send information.
1