Retrieving contact information in the API requires specific syntax depending on whether you are using REST or SOAP. Use this table to find the syntax for your command.
Understanding How The API Works »
REST Syntax
Click to view all REST Resources |
Contact/ GET — Returns contact information specific to the contact(s) requested.
HTTP Action — GET
URIs:
Get one Contact — https://api.dynect.net/REST/Contact/<nickname>/
Get all Contacts — https://api.dynect.net/REST/Contact/
|
Arguments:
No Arguments.
|
Response:
Get one Contact — Click for More Info
- string
address — The contact’s street address.
- string
address_2 — The contact’s street address, line 2.
- string
city — The contact’s city, part of the contact’s address.
- string
country — The contact’s country, part of the contact’s address.
- string
email — The contact’s email address.
- string
fax — The contact’s fax number.
- string
first_name — The contact’s first name.
- string
last_name — The contact’s last name.
- string
nickname — The contact’s nickname. Used to perform actions on a single contact.
- string
notify_email — Email address at which the contact should receive notifications.
- string
pager_email — Email address at which the contact should receive messages destined for a pager.
- string
organization — The contact’s organization.
- string
phone — The contact’s phone number.
A phone number can have the form: (0) (country-code) (local number) (ext extension)
Only the country-code (1 – 3 digits) and the local number (1 – 7 digits) are required.
The extension can be up to 4 digits. Any non-digits are ignored.
- string
post_code — The contact’s postal (zip) code, part of the contact’s address.
- string
state — The contact’s state.
- string
website — The URL of the contact’s website.
Get all Contacts — Array of individual contact resources.
|
SOAP Syntax
Click to view all SOAP Commands |
GetOneContact — Returns contact information specific to the contact requested.
GetContacts — Returns all existing contacts in your account.
|
Arguments:
GetOneContact:
string nickname — Required. The nickname of the desired contact.
string token — Required. The session identifier.
GetContacts:
string token — Required. The session identifier.
|
Response:
GetOneContact — Click for More Info
- hash data
- string
address — The contact’s street address.
- string
address_2 — The contact’s street address, line 2.
- string
city — The contact’s city, part of the contact’s address.
- string
country — The contact’s country, part of the contact’s address.
- string
email — The contact’s email address.
- string
fax — The contact’s fax number.
- string
first_name — The contact’s first name.
- string
last_name — The contact’s last name.
- string
nickname — The contact’s nickname. Used to perform actions on a single contact.
- string
notify_email — Email address at which the contact should receive notifications.
- string
pager_email — Email address at which the contact should receive messages destined for a pager.
- string
organization — The contact’s organization.
- string
phone — The contact’s phone number.
A phone number can have the form: (0) (country-code) (local number) (ext extension)
Only the country-code (1 – 3 digits) and the local number (1 – 7 digits) are required.
The extension can be up to 4 digits. Any non-digits are ignored.
- string
post_code — The contact’s postal (zip) code.
- string
state — The contact’s state.
- string
website — The URL of the contact’s website.
GetContacts — Click for More Info
- array data
- string
address — The contact’s street address.
- string
address_2 — The contact’s street address, line 2.
- string
city — The contact’s city, part of the contact’s address.
- string
country — The contact’s country, part of the contact’s address.
- string
email — The contact’s email address.
- string
fax — The contact’s fax number.
- string
first_name — The contact’s first name.
- string
last_name — The contact’s last name.
- string
nickname — The contact’s nickname. Used to perform actions on a single contact.
- string
notify_email — Email address at which the contact should receive notifications.
- string
pager_email — Email address at which the contact should receive messages destined for a pager.
- string
organization — The contact’s organization.
- string
phone — The contact’s phone number.
A phone number can have the form: (0) (country-code) (local number) (ext extension)
Only the country-code (1 – 3 digits) and the local number (1 – 7 digits) are required.
The extension can be up to 4 digits. Any non-digits are ignored.
- string
post_code — The contact’s postal (zip) code.
- string
state — The contact’s state.
- string
website — The URL of the contact’s website.
|
Example Request — Click for More Info
GetOneContact:
{
'nickname'=>'nick1',
'token'=> 'zaq12wsxcDe34rf89gt56nh',
}
GetContacts:
{
'token'=> 'zaq12wsxcDe34rf89gt56nh',
}
|
<< DNS API Knowledge Base