curl --request POST \
--url https://api.dev.name.com/core/v1/accounts \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"account": {
"accountName": "reseller_subaccount",
"password": "SecureP4ss!",
"contacts": {
"registrant": {
"firstName": "Jane",
"lastName": "Doe",
"address1": "123 Main St.",
"city": "Denver",
"state": "CO",
"zip": "12345",
"country": "US",
"phone": "+13035551212",
"email": "[email protected]"
}
}
},
"apiTos": true,
"tos": true
}
'{
"accountName": "new_reseller_account",
"apiToken": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"apiTokenName": "my_reseller_token"
}Creates a new sub-account under your authenticated reseller account and returns API credentials for the new account. This endpoint is only available to approved reseller accounts. Contact name.com support to request access.
curl --request POST \
--url https://api.dev.name.com/core/v1/accounts \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"account": {
"accountName": "reseller_subaccount",
"password": "SecureP4ss!",
"contacts": {
"registrant": {
"firstName": "Jane",
"lastName": "Doe",
"address1": "123 Main St.",
"city": "Denver",
"state": "CO",
"zip": "12345",
"country": "US",
"phone": "+13035551212",
"email": "[email protected]"
}
}
},
"apiTos": true,
"tos": true
}
'{
"accountName": "new_reseller_account",
"apiToken": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"apiTokenName": "my_reseller_token"
}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.
CreateAccountRequest has the information that is needed to create an account with the CreateAccount function.
CreateAccountRequest has the information that is needed to create an account with the CreateAccount function.
The account details for the new account being created.
Show child attributes
AccountId is the unique id of account.
12345
AccountName is the unique name of the account. Minimum length is 6 characters, maximum length is 60.
6 - 60"namecom_reseller"
When set to true, domains in this account will be automatically renewed before expiration.
Contact information associated with this account. Contact information associated with this account.
Show child attributes
Contact contains all relevant contact data for a domain registrant. This schema is used for API responses and may contain null values for legacy data. For creating or updating contacts, use ContactRequest which enforces all validation requirements.
Contact contains all relevant contact data for a domain registrant. This schema is used for creating and updating contacts (POST/PUT requests) and includes all validation requirements. All fields listed in the required array must be provided and cannot be null or empty.
Show child attributes
First name of the contact. First name of the contact. First name of the contact.
1"John"
Last name of the contact. Last name of the contact. Last name of the contact.
1"Doe"
The first line of the contact's address. The first line of the contact's address. The first line of the contact's address.
1"123 Main Street"
City of the contact's address. City of the contact's address. City of the contact's address.
1"New York"
State or Province of the contact's address. State or Province of the contact's address. State or Province of the contact's address.
1"NY"
ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. This field is required and must be a non-empty string.
1"10001"
Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code.
"US"
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15551234567"
Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise. Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise.
"Example Inc."
The second line of the contact's address (optional). The second line of the contact's address (optional).
"Suite 400"
Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15557654321"
Contact contains all relevant contact data for a domain registrant. This schema is used for API responses and may contain null values for legacy data. For creating or updating contacts, use ContactRequest which enforces all validation requirements.
Contact contains all relevant contact data for a domain registrant. This schema is used for creating and updating contacts (POST/PUT requests) and includes all validation requirements. All fields listed in the required array must be provided and cannot be null or empty.
Show child attributes
First name of the contact. First name of the contact. First name of the contact.
1"John"
Last name of the contact. Last name of the contact. Last name of the contact.
1"Doe"
The first line of the contact's address. The first line of the contact's address. The first line of the contact's address.
1"123 Main Street"
City of the contact's address. City of the contact's address. City of the contact's address.
1"New York"
State or Province of the contact's address. State or Province of the contact's address. State or Province of the contact's address.
1"NY"
ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. This field is required and must be a non-empty string.
1"10001"
Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code.
"US"
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15551234567"
Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise. Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise.
"Example Inc."
The second line of the contact's address (optional). The second line of the contact's address (optional).
"Suite 400"
Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15557654321"
Contact contains all relevant contact data for a domain registrant. This schema is used for API responses and may contain null values for legacy data. For creating or updating contacts, use RegistrantContactRequest which enforces all validation requirements.
Contact contains all relevant contact data for a domain registrant. This schema is used for creating and updating contacts (POST/PUT requests) and includes all validation requirements. All fields listed in the required array must be provided and cannot be null or empty.
Show child attributes
First name of the contact. First name of the contact. First name of the contact.
1"John"
Last name of the contact. Last name of the contact. Last name of the contact.
1"Doe"
The first line of the contact's address. The first line of the contact's address. The first line of the contact's address.
1"123 Main Street"
City of the contact's address. City of the contact's address. City of the contact's address.
1"New York"
State or Province of the contact's address. State or Province of the contact's address. State or Province of the contact's address.
1"NY"
ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. This field is required and must be a non-empty string.
1"10001"
Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code.
"US"
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15551234567"
Company name of the contact. Leave blank if the contact is an individual. Please be advised that ICANN policy links the "Company Name" field (Organization) in your domain's contact details to its legal ownership. If this field contains information, the listed organization is considered the legal "Registered Name Holder" (domain owner). Company name of the contact. Leave blank if the contact is an individual. Please be advised that ICANN policy links the "Company Name" field (Organization) in your domain's contact details to its legal ownership. If this field contains information, the listed organization is considered the legal "Registered Name Holder" (domain owner).
"Example Inc."
The second line of the contact's address (optional). The second line of the contact's address (optional).
"Suite 400"
Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15557654321"
Contact contains all relevant contact data for a domain registrant. This schema is used for API responses and may contain null values for legacy data. For creating or updating contacts, use ContactRequest which enforces all validation requirements.
Contact contains all relevant contact data for a domain registrant. This schema is used for creating and updating contacts (POST/PUT requests) and includes all validation requirements. All fields listed in the required array must be provided and cannot be null or empty.
Show child attributes
First name of the contact. First name of the contact. First name of the contact.
1"John"
Last name of the contact. Last name of the contact. Last name of the contact.
1"Doe"
The first line of the contact's address. The first line of the contact's address. The first line of the contact's address.
1"123 Main Street"
City of the contact's address. City of the contact's address. City of the contact's address.
1"New York"
State or Province of the contact's address. State or Province of the contact's address. State or Province of the contact's address.
1"NY"
ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. ZIP or Postal Code of the contact's address. This field is required and must be a non-empty string.
1"10001"
Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code. Country code for the contact's address. Must be an ISO 3166-1 alpha-2 country code.
"US"
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Email address of the contact. Must be a valid email format. The validation is performed against the addr-spec syntax in RFC 822
Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]". Phone number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15551234567"
Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise. Company name of the contact. Leave blank if the contact is an individual, as some registries may assume it is a corporate entity otherwise.
"Example Inc."
The second line of the contact's address (optional). The second line of the contact's address (optional).
"Suite 400"
Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]". Fax number of the contact. Should follow the E.164 international format: "+[country code][number]".
"+15557654321"
CreateDate is the date the account was created.
"2023-04-01T12:00:00Z"
Password has minimum length of 7 characters. It must contain at least 1 letter and at least 1 number/symbol.
7Must be set to true to indicate acceptance of the API Terms of Service.
true
Must be set to true to indicate acceptance of the general Terms of Service.
true
A successful response containing the newly created account details and credentials.
CreateAccountResponse contains information about the newly created account and the API credentials generated for it.
AccountName is the unique user-assigned name of newly created account.
"new_reseller_account"
The authentication token that should be used to access the API. This value is only returned once upon account creation.
"a1b2c3d4-e5f6-7890-abcd-ef1234567890"
ApiTokenName user assigned name of api token.
"my_reseller_token"
Was this page helpful?