SendLit logoSendLit Docs
API ReferenceContacts

List contacts

Returns a paginated list of contacts. Pass filter as serialized ContactFilterWithAggregator JSON for inline filtering, or segmentId to only return contacts currently matching that saved segment's filter (404 if the segment doesn't exist). SendLit supports fixed generic contact filters over first-class fields, tags, and custom fields; client-specific concepts should be synced into namespaced tags or customFields. q, filter, and segmentId combine with AND. The response's total reflects the combined filters.

GET
/contacts

Returns a paginated list of contacts. Pass filter as serialized ContactFilterWithAggregator JSON for inline filtering, or segmentId to only return contacts currently matching that saved segment's filter (404 if the segment doesn't exist). SendLit supports fixed generic contact filters over first-class fields, tags, and custom fields; client-specific concepts should be synced into namespaced tags or customFields. q, filter, and segmentId combine with AND. The response's total reflects the combined filters.

x-sendlit-apikey<token>

In: header

Query Parameters

q?string

Search term matched against email or name

segmentId?string

Only return contacts matching this saved segment's filter; combines with q using AND

filter?string

Serialized ContactFilterWithAggregator JSON; combines with q and segmentId using AND

offset?integer
Range1 <= value
rowsPerPage?integer
Range1 <= value

Response Body

application/json

application/json

application/json

curl -X GET "https://api.sendlit.dev/contacts"
{
  "items": [
    {
      "contactId": "string",
      "email": "string",
      "name": "string",
      "subscribed": true,
      "customFields": {},
      "tags": [
        "string"
      ],
      "unsubscribeToken": "string",
      "createdAt": "string",
      "updatedAt": "string"
    }
  ],
  "total": 0
}
{
  "error": "string"
}
{
  "error": "string"
}