Return a list of contacts

Endpoint: /contacts
HTTP method: GET
URL: https://e1.envoke.com/v1/contacts

Get a list of full contact objects. This list can be filtered by a number of conditions see API Filtering. The result set can be returned sorted, limited to a total number of results and paged by skipping a number of records.

NOTE: All examples below are formatted for readability, actual GET requests require URI encoding. Each example below also includes a cURL request. Make sure to change the API_ID and API_KEY with your values.

Return all contacts

https://e1.envoke.com/v1/contacts
curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts"


Find 5 contacts sorted by email address ascending

https://e1.envoke.com/v1/contacts?sort[email]=ASC&limit=5
curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts?sort%5Bemail%5D=ASC&limit=5"

  

Find a contact by email address

https://e1.envoke.com/v1/contacts?filter[email]=jon@doe.com
curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts?filter%5Bemail%5D=jon%40doe.com"

  

Find a contact by custom field (regular expressions)

Setup filter object:
{
filter: {
"custom_fields.barcode": {
$regex: "abc"
}
}
}

Serialize object for use in query string (using jQuery.param()):
jQuery.param({filter: {"custom_fields.barcode":{$regex: "abc"}}});
Result:
filter%5Bcustom_fields.barcode%5D%5B%24regex%5D=abc

https://e1.envoke.com/v1/contacts?filter[custom_fields.barcode][$regex]=abc

curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts?filter%5Bcustom_fields.barcode%5D%5B%24regex%5D=abc"

Find a contact by custom field (exact match)

https://e1.envoke.com/v1/contacts?filter[custom_fields.barcode]=abc

curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts?filter%5Bcustom_fields.barcode%5D=abc"

Find a single contact with the id "1234"

https://e1.envoke.com/v1/contacts/1234
curl -X GET -u API_ID:API_KEY "https://e1.envoke.com/v1/contacts/1234"

  

Did this answer your question?