Group

Query contacts in a group

Queries contacts that are members of the given group.

get/v1/projects/{project_id}/groups/{id}/contacts

Request

  • Base URL: https://api.telerivet.com
  • URL: https://api.telerivet.com/v1/projects/{project_id}/groups/{id}/contacts
  • Auth: one of:
    • HTTP basic
    • OAuth 2 (authorization code, authorization URL https://telerivet.com/oauth/authorize, token URL https://api.telerivet.com/oauth/token)

Path parameters

project_idstring required

ID of the Project

idstring required

ID of the Group

Query parameters

namestring

Filter contacts by name

phone_numberstring

Filter contacts by phone number

time_createdinteger

Unix timestamp in seconds

Filter contacts by time created

last_message_timeinteger

Unix timestamp in seconds

Filter contacts by last time a message was sent or received

last_incoming_message_timeinteger

Unix timestamp in seconds

Filter contacts by last time a message was received

last_outgoing_message_timeinteger

Unix timestamp in seconds

Filter contacts by last time a message was sent

incoming_message_countinteger

Filter contacts by number of messages received from the contact

outgoing_message_countinteger

Filter contacts by number of messages sent to the contact

send_blockedboolean

Filter contacts by blocked status

varsobject

Filter contacts by value of a custom variable (e.g. vars[email], vars[foo], etc.)

sort'default' | 'name' | 'phone_number' | 'last_message_time'

Sort the results based on a field

sort_dir'asc' | 'desc'

Sort the results in ascending or descending order

page_sizeinteger

Number of results returned per page (max 500)

offsetinteger

Number of items to skip from beginning of result set

markerstring

'next_marker' property returned by a previous call to this API method, indicating where the next page of results should start.

countboolean

If true, the API will return the count of items matching the filter, instead of the items themselves

Response

Successful response. When count=1 parameter is provided, returns {"count": N} instead.

truncatedboolean

True if there are more results

next_markerstring

Marker for pagination

page_sizeinteger

Number of results per page

sort_dir'asc' | 'desc'

Sort direction

countinteger

Total count of matching items (only when count=1 parameter is provided)

Example response

{
  "data": [
    {
      "id": "CTa1299c3d0e371023",
      "name": "John Smith",
      "phone_number": "+16505550123",
      "time_created": 1390348075,
      "time_updated": 1390348099,
      "conversation_status": "active",
      "last_message_time": 1395881121,
      "last_incoming_message_time": 1395881121,
      "last_outgoing_message_time": 1395881032,
      "message_count": 13,
      "incoming_message_count": 2,
      "outgoing_message_count": 11,
      "last_message_id": "SM97f47ac232df154d",
      "project_id": "PJ2ad0100821a98bea",
      "url": "https://telerivet.com/p/asdf/contact/CTa1299c3d0e371023"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.