Skip to main content
POST
/
core
/
v1
/
domains
/
{domainName}
:setContacts
Set Contacts
curl --request POST \
  --url https://api.dev.name.com/core/v1/domains/{domainName}:setContacts \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "contacts": {
    "admin": {
      "firstName": "John",
      "lastName": "Doe",
      "address1": "123 Main Street",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "companyName": "Example Inc.",
      "address2": "Suite 400",
      "fax": "+15557654321"
    },
    "billing": {
      "firstName": "John",
      "lastName": "Doe",
      "address1": "123 Main Street",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "companyName": "Example Inc.",
      "address2": "Suite 400",
      "fax": "+15557654321"
    },
    "registrant": {
      "firstName": "John",
      "lastName": "Doe",
      "address1": "123 Main Street",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "companyName": "Example Inc.",
      "address2": "Suite 400",
      "fax": "+15557654321"
    },
    "tech": {
      "firstName": "John",
      "lastName": "Doe",
      "address1": "123 Main Street",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "companyName": "Example Inc.",
      "address2": "Suite 400",
      "fax": "+15557654321"
    }
  }
}
'
{
  "domainName": "example.com",
  "createDate": "2023-01-15T14:30:00Z",
  "expireDate": "2025-01-15T14:30:00Z",
  "autorenewEnabled": true,
  "locked": true,
  "privacyEnabled": true,
  "contacts": {
    "admin": {
      "firstName": "John",
      "lastName": "Doe",
      "companyName": "Example Inc.",
      "address1": "123 Main Street",
      "address2": "Suite 400",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "fax": "+15557654321",
      "isVerified": true
    },
    "billing": {
      "firstName": "John",
      "lastName": "Doe",
      "companyName": "Example Inc.",
      "address1": "123 Main Street",
      "address2": "Suite 400",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "fax": "+15557654321",
      "isVerified": true
    },
    "registrant": {
      "firstName": "John",
      "lastName": "Doe",
      "companyName": "Example Inc.",
      "address1": "123 Main Street",
      "address2": "Suite 400",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "fax": "+15557654321",
      "isVerified": true
    },
    "tech": {
      "firstName": "John",
      "lastName": "Doe",
      "companyName": "Example Inc.",
      "address1": "123 Main Street",
      "address2": "Suite 400",
      "city": "New York",
      "state": "NY",
      "zip": "10001",
      "country": "US",
      "email": "[email protected]",
      "phone": "+15551234567",
      "fax": "+15557654321",
      "isVerified": true
    }
  },
  "nameservers": [
    "ns1.example.com",
    "ns2.example.com"
  ],
  "renewalPrice": 12.99
}

Authorizations

Authorization
string
header
required

Authenticate via HTTP Basic with your account username and API token. Examples use an explicit 'Authorization: Basic <base64(username:token)>' header; 'curl -u username:token' is equivalent. For sandbox, append "-test" to your username and use your sandbox token on api.dev.name.com.

Path Parameters

domainName
string
required

DomainName is the domain name to set the contacts for.

Example:

"example.com"

Body

application/json

SetContactsRequest passes the contact info for each role to the SetContacts function.

contacts
object

Contacts stores the contact information for the roles related to domains. This schema is used for requests.

Response

A successful response with updated domain contact information.

The response format for a domain.

domainName
string
required

The punycode-encoded value of the domain name. The punycode-encoded value of the domain name.

Example:

"example.com"

createDate
string<date-time>
required

The date and time when the domain was created at the registry. The date and time when the domain was created at the registry.

Example:

"2023-01-15T14:30:00Z"

expireDate
string<date-time>
required

The date and time when the domain will expire. The date and time when the domain will expire.

Example:

"2025-01-15T14:30:00Z"

autorenewEnabled
boolean
required

Indicates whether the domain is set to renew automatically before expiration. Indicates whether the domain is set to renew automatically before expiration.

Example:

true

locked
boolean
required

Indicates if the domain is locked, preventing transfers to another registrar. Indicates if the domain is locked, preventing transfers to another registrar.

Example:

true

privacyEnabled
boolean
required

Indicates if Whois Privacy is enabled for this domain. Indicates if Whois Privacy is enabled for this domain.

Example:

true

contacts
object
required

Contacts stores the contact information for the roles related to domains. Contacts stores the contact information for the roles related to domains.

nameservers
string[]
required

The list of nameservers assigned to this domain. If unspecified, it defaults to the account's default nameservers. The list of nameservers assigned to this domain. If unspecified, it defaults to the account's default nameservers.

Example:
["ns1.example.com", "ns2.example.com"]
renewalPrice
number<double>

The cost to renew the domain. This may be required for the RenewDomain operation. The cost to renew the domain. This may be required for the RenewDomain operation.

Example:

12.99