Get (domain)
Queries various types of data regarding the user's domain. For example, the all_info type allows you to retrieve all data for the domain. The list type queries the list of domains associated with the user's profile. The list type can also be used to return a list of domains that expire within a specified range. The nameservers type returns the nameservers currently acting as DNS servers for the domain.
Domain Status
This API data will return results if a domain is active or in the expiration grace period, but it will not return results once a domain is deleted during and after the redemption period.
Request parameters for get (domain)
Standard Parameters
- action = get
- object = domain
- registrant_ip = valid IP address of the registrant
Note:
The get (domain) command may be used without end-user credentials when type=admin, all_info, billing, expire_action, forwarding_email (.NAME only), list, tech, owner, nameservers, status, rsp_whois_info, ced_info, nexus_info, or whois_privacy_state. For more information, see "Submitting API commands without credentials".
Attributes
Parameters within the attributes associative array are described below.
Parameter name | Obligation | Definition / Value |
---|---|---|
active_contacts_only | Optional | Retrieves the currently active contact information for owner, admin, billing and tech, as they are currently set on the domain. This info will be returned regardless of whether there is a pending trade in progress. |
clean_ca_subset | Optional | Determines the type of contact_set values that are returned for .CA domains when type = admin or tech. If clean_ca_subset is not specified, the query returns the values addr_address_number, addr_corporative, addr_office, addr_orientation, addr_street_cat, and addr_street_name along with the standard address fields (address1, address2, and address3). |
domain | The relevant domain. | |
limit | Optional | The maximum number of domains to return per page. |
max_to_expiry | Required when | Defines the expiration range (in days): to fetch the list of domains that are between max_to_expiry and min_to_expiry before the expiration date. If min_to_expiry is not provided, it defaults to 0. If min_to_expiry > max_to_expiry, the list is empty. These parameters can have negative values, which means days past the expiration date. For example, -5 means 5 days past the expiration date. |
min_to_expiry | Required when | Defines the expiration range (in days): to fetch the list of domains that are between max_to_expiry and min_to_expiry before expiration date. If min_to_expiry is not provided, it defaults to 0. If min_to_expiry > max_to_expiry, the list is empty. These parameters can have negative values, which means days past the expiration date. For example, -5 means 5 days past the expiration date. |
page | Optional | Determines which page to retrieve, using the page number. The page index starts at 0 (zero). |
type | Required | Type of query. Allowed values are:
Note: If the TLD does not allow WHOIS Privacy, always returns Disabled. All completed/cancelled requests are deleted from the database two weeks after they move to final state. |
Response parameters for get (domain)
Standard parameters
- action = reply
- object = domain
- is_success = a Boolean is returned, indicating success or failure of the
request - response_code = response code indicating outcome of the request
- response_text = message describing the outcome of the request
Attributes
The response message returned varies depending on the value of the type field that was used to send the request.
Return details for type = admin, billing, owner, or tech
Parameter name | Obligation | Definition/Value |
---|---|---|
contact_set | Returned when type= owner, admin, billing, or tech and is_success = true | An associative array containing the contact information of the requested type. For details on contact fields, see "ContactSet". |
description | Returned when type= | The domain description. |
status | Always returned | The status of the contact. Possible values are:
Note: When a pending_current_registrant or pending_new_registrant value is displayed, the contact information included in the response is that which will be displayed in whois once the trade is complete. Both pending_current_registrant and pending_new_registrant will only ever be returned for gTLDs. |
Return details for type = all_info
The response message consists of a combination of the fields used for type = nameserver, and type = owner, admin, tech, or billing. The contact_set contains a type for each possible contact type.
Also returns the fields: auto_renew, expiredate, let_expire, sponsoring_rsp as per the Extended Results of type = list.
Parameter name | Obligation | Definition/Value |
---|---|---|
affiliate_id | Returned if applicable and  | The affiliate id associated with the domain. |
descr | Returned when type = all_info and is_success = true | The text of the domain description. |
 | Returned when type = all_info and is_success = true | The text of the DNS errors. |
nameserver_list | Returned when type = all_info and is_success = true | A list of nameservers. Each nameserver is represented as an anonymous associative array. For more information, see the Nameserver_List table below. |
registry_createdate | Returned when type = all_info and is_success = true | The date that the domain was created at the Registry. |
registry_expiredate | Returned when type = all_info only if the Registry provides this information. | The domain's expiry date as recorded at the Registry. |
registry_transferdate | Returned when type = all_info only if the Registry provides this information and the domain was transferred. | The Registry's record of when the domain was transferred. |
registry_updatedate | Returned when type = all_info only if the Registry provides this information. | The date the domain was last updated at the Registry. |
sponsoring_rsp | Returned when type = all_info and is_success = true | Indicates if the domain is under your reseller profile:
|
tld_data | Returned for .ASIA, | An associative array containing registrant information. |
Nameserver_List
Parameters within the nameserver_list associative array are described below.
Parameter name | Obligation | Definition/Value |
---|---|---|
ip_address | Returned if the nameserver has an IPv4 address. | The IPv4 address of the nameserver. |
ipv6 | Returned if the nameserver has an IPv6 address. | The IPv6 address of the nameserver. |
name | Returned when type = all_info | The name of the nameserver. |
sort_order | Returned when type = all_info | The nameserver sort order. |
Return details for type = ca_whois_display_setting
Parameters within the ca_whois_display_setting associative array are
described below.
Parameter name | Obligation | Definition/Value |
---|---|---|
display | Returned if | Indicates the current setting for the CIRA WHOIS Privacy setting.
|
individual | Returned if | Indicates whether the domain owner is an individual registrant. Only individual registrants (Canadian citizens, Permanent residents, Legal representatives, Aboriginal peoples) can change their CIRA Whois Privacy setting. |
Return details for type = domain_auth_info
Parameter name | Obligation | Definition/Value |
---|---|---|
domain_auth_info | Returned when type = domain_auth_info and is_success = true | Authentication password for the domain. This facilitates transfers to others registrars. |
Return details for type = expire_action
Parameter name | Obligation | Definition/Value |
---|---|---|
auto_renew | Returned when type = | Indicates whether the domain can auto renew or not:
|
expiredate | Returned when type = expire_action and is_success = true | The date that the domain is set to expire, in the format YYYY-MM-DD HH24:MM:SS. |
let_expire | Returned when type = expire_action and is_success = true | Indicates whether the domain is set to expire silently:
|
Return details for type = forwarding_email
Parameter name | Obligation | Definition/Value |
---|---|---|
forwarding_email | Returned when type = forwarding_email and is_success = true | The domain's e-mail address that is used for forwarding purposes. |
Return details for type = list
count | Returned when type = list and is_success = true | The count (total number) of domain names in the current user profile. |
---|---|---|
domain_list | Returned when type = list and is_success = true | An array of domain name hashes. For compatibility reasons, if you set with_encoding_types attribute in the request to 0 or don't set it at all, then you get an array of scalars, domain names. For more information, see the Domain_List table below. |
ext_results | Returned when type = list and is_success = true | An array of extended results that indicate the domains and their expiry dates. |
remainder | Returned when type = list and is_success = true | A boolean variable indicating whether there are more domains in the list:
|
Domain_List
Parameters within the domain_list associative array are described below
Parameter name | Obligation | Definition/Value |
---|---|---|
domain | Returned when type = list and is_success = true | Fully qualified domain name. |
encoding_type | Returned when type = list and is_success = true | The three-character tag that represents the language encoding type for the domain. For a list of languages and codes, see “AppendixC: |
Ext_Results
Parametername | Obligation | Definition/Value |
---|---|---|
auto_renew | Returned when type = list and is_success = true | Status of the auto-renew flag:
|
expiredate | Returned when type = list and is_success = true | Expiration date of the domain. |
has_whois_privacy | Returned when type = list and is_success = true | Indicates whether WHOIS Privacy is enabled:
|
let_expire | Returned when type = list and is_success = true | Status of the let-expire flag:
|
lock_state | Returned when type = list and is_success = true | Flag indicating if the domain is locked to prevent transfers:
|
sponsoring_rsp | Returned when type = list and is_success = true | Flag indicating if the domain is sponsored by the reseller making the call:
|
Return details for type = nameservers
Parameter name | Obligation | Definition/Value |
---|---|---|
nameserver_list | Returned when type = nameservers and *is_success = true | A list of nameservers. Each nameserver is represented as an anonymous associative array. For more information, see the Nameserver_List table below. |
Nameserver_List
Parameters within the nameserver_list associative array are described below.
Parameter name | Obligation | Definition/Value |
---|---|---|
ipaddress | Returned when type = nameservers | IP address of the nameserver |
name | Returned when type = nameservers | Fully qualified domain name of the nameserver. |
sortorder | Returned when type = nameservers | Sort order of this nameserver. The sortorder does not necessarily start at 0 and there may be gaps between nameserver entries. It does indicate the relative sorting order of the nameservers. The sort order value must be preserved for nameserver modification commands. |
Return details for type = rsp_whois_info
Parameter name | Obligation | Definition/Value |
---|---|---|
business | Returned when type = rsp_whois_info and is_success = true | The business name of the RSP. |
domain_enabled | Returned when type = rsp_whois_info and is_success = true | Indicates whether this feature enabled for given domain:
|
Returned when type = rsp_whois_info and is_success = true | Email address of the RSP. | |
phone | Returned when type = rsp_whois_info and is_success = true | Phone number of the RSP. |
rsp_enabled | Returned when type = rsp_whois_info and is_success = true | Indicates whether this feature is enabled or disabled by RSP:
|
url | Returned when type = rsp_whois_info and is_success = true | The URL of the RSP. |
Return details for type = status
Parameter name | Obligation | Definition/Value |
---|---|---|
auctionescrow | Returned when type = status and domain is in auction escrow | Indicates whether the domain has been placed in auction escrow. If in auction escrow, the domain cannot be renewed.
|
can_modify | Returned when type = status and is_success = true | Indicates whether the lock state can be modified during this session:
|
domain_supports | Returned when type = status and is_success = true | Indicates whether the TLD is one that supports domain locking:
|
lock_state | Returned when type = status and is_success = true | Indicates whether the domain is locked:
|
parkp_status | Optional | Indicates if the domain is enabled for the Parked Pages service. Values are Enabled, Activating, or blank. If returned but left blank, the domain is not enabled. |
transferaway_in progress | Optional | f returned, indicates that the domain is in the process of being transferred away. Value is 1. |
Note:
The domain_supports and can_modify attributes are different in that a TLD from a registry that supports domain locking always returns 1 for domain_supports, but the state of the current session as well as the internal state of the domain at OpenSRS affects can_modify. This is only true when all of the following conditions are met:
- Request is done through the sponsoring reseller for the domain.
- The TLD for the domain is one that supports locking at the registry level.
- The domain is not locked internally by OpenSRS.
Return details for type = tld_data
Parameter name | Obligation | Definition/Value |
---|---|---|
tld_data | Returned for | An associative array containing registrant information. For more information, see tld_data. |
Return details for type = whois_privacy_state
Parameter name | Obligation | Definition / Value |
---|---|---|
state | Returned when type = whois_privacy_state and is_success = true | WHOIS Privacy state: enabled, disabled, enabling (in process), or disabling (in process). |
Get domain examples
For type = admin or tech
Example 1
Including the clean_ca_subset parameter
Request
<?xml version='1.0' encoding="UTF-8" standalone="no"?>
<!DOCTYPE OPS_envelope SYSTEM "ops.dtd">
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="object">DOMAIN</item>
<item key="action">GET</item>
<item key="attributes">
<dt_assoc>
<item key="clean_ca_subset">1</item>
<item key="domain">example.com</item>
<item key="type">admin</item>
</dt_assoc>
</item>
<item key="registrant_ip">10.0.62.128</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Response
<?xml version='1.0' encoding="UTF-8" standalone="no"?>
<!DOCTYPE OPS_envelope SYSTEM "ops.dtd">
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="object">DOMAIN</item>
<item key="is_success">1</item>
<item key="response_code">200</item>
<item key="response_text">Query Successful</item>
<item key="action">REPLY</item>
<item key="attributes">
<dt_assoc>
<item key="contact_set">
<dt_assoc>
<item key="admin">
<dt_assoc>
<item key="address1">32 Oak Street</item>
<item key="address2"></item>
<item key="address3"></item>
<item key="status">active</item>
<item key="status">active</item>
<item key="city">Toronto</item>
<item key="state">ON</item>
<item key="postal_code">M1M1M1</item>
<item key="country">CA</item>
<item key="org_name">Example Company</item>
<item key="phone">+1.4165551212</item>
<item key="fax"></item>
<item key="first_name">Marlin</item>
<item key="last_name">Wilk</item>
<item key="email">[email protected]</item>
<item key="lang">EN</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Example 2
Without the clean_ca_subset parameter
Request
<?xml version='1.0' encoding="UTF-8" standalone="no"?>
<!DOCTYPE OPS_envelope SYSTEM "ops.dtd">
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="action">GET</item>
<item key="object">DOMAIN</item>
<item key="registrant_ip">10.0.62.128</item>
<item key="attributes">
<dt_assoc>
<item key="domain">example.com</item>
<item key="type">admin</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Response
<?xml version='1.0' encoding="UTF-8" standalone="no"?>
<!DOCTYPE OPS_envelope SYSTEM "ops.dtd">
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="object">DOMAIN</item>
<item key="response_text">Query Successful</item>
<item key="action">REPLY</item>
<item key="attributes">
<dt_assoc>
<item key="contact_set">
<dt_assoc>
<item key="admin">
<dt_assoc>
<item key="addr_address_number"></item>
<item key="addr_corporative"></item>
<item key="addr_office"></item>
<item key="addr_orientation"></item>
<item key="addr_street_cat"></item>
<item key="addr_street_name">32 Oak Street</item>
<item key="address1">32 Oak Street</item>
<item key="address2"></item>
<item key="address3"></item>
<item key="status">active</item>
<item key="city">Toronto</item>
<item key="state">ON</item>
<item key="postal_code">M1M1M1</item>
<item key="country">CA</item>
<item key="org_name">Example Company</item>
<item key="first_name">Marlin</item>
<item key="last_name">Wilk</item>
<item key="lang">EN</item>
<item key="email">[email protected]</item>
<item key="phone">+1.4165551212</item>
<item key="fax"></item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
<item key="response_code">200</item>
<item key="is_success">1</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Example 3
Without end-user credentials
Request
<?xml version="1.0" encoding="UTF-8" standalone='yes'?>
<!DOCTYPE OPS_envelope SYSTEM 'ops.dtd'>
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="action">GET</item>
<item key="object">DOMAIN</item>
<item key="attributes">
<dt_assoc>
<item key="domain">mydomain.com</item>
<item key="type">admin</item>
<item key="limit">10</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Response
<?xml version="1.0" encoding="UTF-8" standalone='yes'?>
<!DOCTYPE OPS_envelope SYSTEM 'ops.dtd'>
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="action">REPLY</item>
<item key="object">DOMAIN</item>
<item key="response_code">200</item>
<item key="response_text">Query Successful</item>
<item key="is_success">1</item>
<item key="attributes">
<dt_assoc>
<item key="contact_set">
<dt_assoc>
<item key="billing">
<dt_assoc>
<item key="org_name">Empire Limited Inc.</item>
<item key="first_name">George</item>
<item key="last_name">Walsh</item>
<item key="address1">44 Hemlock St.</item>
<item key="address2"></item>
<item key="address3"></item>
<item key="status">active</item>
<item key="city">Tampa</item><item key="state">Florida</item>
<item key="country">US</item>
<item key="postal_code">90211</item>
<item key="phone">+1.4165551122</item>
<item key="fax"></item>
<item key="email">[email protected]</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
For type = all_info
Example 1
Request
<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<!DOCTYPE OPS_envelope SYSTEM 'ops.dtd'>
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="action">get</item>
<item key="object">domain</item>
<item key="registrant_ip">111.121.121.121</item>
<item key="attributes">
<dt_assoc>
<item key="domain">mydomain.com</item>
<item key="type">all_info</item>
<item key="limit">10</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
</body>
</OPS_envelope>
Response
<?xml version='1.0' encoding="UTF-8" standalone="no" ?>
<!DOCTYPE OPS_envelope SYSTEM "ops.dtd">
<OPS_envelope>
<header>
<version>0.9</version>
</header>
<body>
<data_block>
<dt_assoc>
<item key="protocol">XCP</item>
<item key="action">REPLY</item>
<item key="object">DOMAIN</item>
<item key="is_success">1</item>
<item key="response_code">200</item>
<item key="response_text">Query Successful</item>
<item key="attributes">
<dt_assoc>
<item key="auto_renew">0</item>
<item key="registry_createdate">2006-12-12 21:27:25</item>
<item key="registry_expiredate">2007-12-12 21:27:25</item>
<item key="registry_updatedate">2006-12-12 21:27:25</item>
<item key='affiliate_id'>NUAffiliate123</item>
<item key="sponsoring_rsp">1</item>
<item key="expiredate">2007-12-12 21:27:25</item>
<item key="let_expire">0</item>
<item key="contact_set">
<item key="contact_set">
<dt_assoc>
<item key="admin">
<dt_assoc>
<item key="country">US</item>
<item key="address3">Admin</item>
<item key="org_name">Example Inc.</item>
<item key="phone">+1.4165550123x1812</item>
<item key="state">CA</item>
<item key="address2">Suite 100</item>
<item key="status">active</item>
<item key="last_name">Adams</item>
<item key="email">[email protected]</item>
<item key="city">Santa Clara</item>
<item key="postal_code">90210</item>
<item key="fax">+1.4165550125</item>
<item key="address1">32 Oak Street</item>
<item key="first_name">Adler</item>
</dt_assoc>
</item>
<item key="owner">
<dt_assoc>
<item key="country">US</item>
<item key="address3">Owner</item>
<item key="status">active</item>
<item key="org_name">Example Inc.</item>
<item key="phone">+1.4165550123x1902</item>
<item key="state">CA</item>
<item key="address2">Suite 500</item>
<item key="last_name">Ottway</item>
<item key="email">[email protected]</item>
<item key="city">SomeCity</item>
<item key="postal_code">90210</item>
<item key="fax">+1.4165550124</item>
<item key="address1">32 Oak Street</item>
<item key="first_name">Owen</item>
</dt_assoc>
</item>
<item key="billing">
<dt_assoc>
<item key="country">US</item>
<item key="address3">Billing</item>
<item key="org_name">Example Inc.</item>
<item key="phone">+1.4165550123x1248</item>
<item key="state">CA</item>
<item key="address2">Suite 200</item>
<item key="status">active</item>
<item key="last_name">Burton</item>
<item key="email">[email protected]</item>
<item key="city">Santa Clara</item>
<item key="postal_code">90210</item>
<item key="fax">+1.4165550136</item>
<item key="address1">32 Oak Street</item>
<item key="first_name">Bill</item>
<item key="first_name">Bill</item>
</dt_assoc>
</item>
</dt_assoc>
</item>
</item>
<item key="nameserver_list">
<dt_array>
<item key="0">
<dt_assoc>
<item key="ipaddress">21.40.33.21</item>
<item key="sortorder">1</item>
<item key="name">ns1.systemdns.com</item>
</dt_assoc>
</item>
<item key="1">
<dt_assoc>
<item key="ipaddress">207.136.100.142</item>
<item key="sortorder">2</item>
<item key="name">ns2.systemdns.com</item>
</dt_assoc>
</item>
<item key="2">
<dt_assoc>
<item key="ipaddress">24.22.23.28</item>
<item key="sortorder">3</item>
<item key="name">patrick.example.com</item>
</dt_assoc>
</item>
<item key="3">
<dt_assoc>
<item key="ipaddress">24.22.23.24</item>
<item key="sortorder">4</item>
<item key="name">qa1.example.com</item>
</dt_assoc>
</item>
<item key="4">
<dt_assoc>
<item key="ipaddress">24.22.23.25</item>
<item key="sortorder">5</item>
<item key="name">qa2.example.com</item>
</dt_assoc>
</item>
</dt_array>
</item>
</dt_assoc>
</item>
</dt_assoc>
</data_block>
Updated almost 4 years ago