---
title: "Count contacts"
method: GET
path: "/v1/contacts/count"
tags: ["contacts"]
---

# Count contacts

`GET /v1/contacts/count`

Return the total number of contacts for the authenticated user. Useful for displaying counts in dashboards without fetching full contact records.

## Query parameters

- `where` object
  - `in` union — Match contacts whose id is in this set (single id or array).
    - string, uuid
    - string[]
  - `not_in` union — Exclude contacts whose id is in this set (single id or array).
    - string, uuid
    - string[]
  - `ignore_merge` boolean — Filter by the `ignore_merge` flag (excluded from merge suggestions).
  - `is_starred` boolean — Match starred (true) or non-starred (false) contacts.
  - `is_archived` boolean — Match archived (true) or active (false) contacts. Defaults to false when omitted.
  - `has_priority_tier` union — Relationship priority tier: a tier number, an array of tiers (OR), or a boolean (true = any tier set, false = none).
    - integer
    - integer[]
    - boolean
  - `has_linkedin` union — LinkedIn slug: an exact slug string, or a boolean for presence/absence of a LinkedIn handle.
    - string
    - boolean
  - `has_instagram` union — Instagram slug: an exact slug string, or a boolean for presence/absence of an Instagram handle.
    - string
    - boolean
  - `has_twitter` union — Twitter/X slug: an exact slug string, or a boolean for presence/absence of a Twitter handle.
    - string
    - boolean
  - `has_source` union — Contact source: a single source string or an array of sources (OR).
    - string
    - string[]
  - `has_name` union — Full name: a bare string (fuzzy contains), an array of exact names, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
    - string
    - string[]
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_groups` union — Group membership: a group id, an array of group ids (OR), a boolean for any/no group, or `{ not }` to exclude group id(s).
    - object
      - `not` union, required
        - string
        - string[]
    - boolean
    - string, uuid
    - string[]
  - `has_groups_all` array[] — Array of group-id rows: AND across rows, OR within each row (contact must be in at least one group from every row).
    - string[]
  - `has_frequency` union — Keep-in-touch cadence: a frequency string, or a boolean for presence/absence of a cadence.
    - string
    - boolean
  - `has_location` union — Location: a string (fuzzy, accent-insensitive match), or a boolean for presence/absence of a location.
    - string
    - boolean
  - `has_location_exact` string — Location: exact string match (not fuzzy).
  - `has_job_title` union — Job title: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_never_keep_in_touch` boolean — Filter by the `never_keep_in_touch` flag.
  - `has_created_at` object — Creation-date range: `{ gte?, lte? }` ISO 8601 datetimes (at least one bound required).
    - `gte` string, date-time
    - `lte` string, date-time
  - `has_updated_at` object — Last-updated-date range: `{ gte?, lte? }` ISO 8601 datetimes (at least one bound required).
    - `gte` string, date-time
    - `lte` string, date-time
  - `has_birthday` union — Birthday: a specific date (matches on day + month), or true for any birthday set.
    - string, date-time
    - unknown
    - boolean
  - `has_tag` string, uuid — Match contacts carrying this single tag id.
  - `has_tags` union — Tags: an array of tag ids (OR), or `{ not }` to exclude tag id(s).
    - string[]
    - object
      - `not` union, required
        - string, uuid
        - string[]
  - `has_tags_all` array[] — Array of tag-id rows: AND across rows, OR within each row (contact must carry at least one tag from every row).
    - string[]
  - `has_company` union — Company: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_education` union — Education: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_description` union — Description/notes: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_linkedin_companies` union — LinkedIn companies text: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_linkedin_education` union — LinkedIn education text: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
    - string
    - boolean
    - object
      - `contains` string, required
    - object
      - `eq` string, required
  - `has_email` boolean — Match contacts that have (true) or lack (false) at least one email.
  - `has_phone_number` boolean — Match contacts that have (true) or lack (false) at least one phone number.
  - `not_has_name` union — Exclude contacts whose full name fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_company` union — Exclude contacts whose company fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_job_title` union — Exclude contacts whose job title fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_education` union — Exclude contacts whose education fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_description` union — Exclude contacts whose description fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_linkedin_companies` union — Exclude contacts whose LinkedIn companies text fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `not_has_linkedin_education` union — Exclude contacts whose LinkedIn education text fuzzily matches this string / any of these strings.
    - string
    - string[]
  - `has_linkedin_last_message_at` union — LinkedIn last-message time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
    - boolean
    - object
      - `gte` string, date-time
      - `lte` string, date-time
  - `has_last_seen_at` union — Last-seen (last interaction) time — alias for has_interaction: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
    - boolean
    - object
      - `gte` string, date-time
      - `lte` string, date-time
  - `has_distance` object — Geo radius filter: contacts within `meters` of `{ lat, lon }` (PostGIS ST_DWithin on geocoded coordinates). `label` is an optional display name for the point.
    - `lat` number, required
    - `lon` number, required
    - `meters` number, required
    - `label` string
  - `has_interaction` union — Interaction (last-seen) time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
    - boolean
    - object
      - `gte` string, date-time
      - `lte` string, date-time
  - `has_next_reminder` union — Next-reminder time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
    - boolean
    - object
      - `gte` string, date-time
      - `lte` string, date-time
  - `custom_fields` object[] — User-defined custom-field filters. Each clause is `{ field_id, operator, value? }`; multiple clauses AND together. Operators: contains, eq, in, not_in, present, absent, gte, lte.
    - `field_id` string, uuid, required
    - `operator` 'contains' | 'eq' | 'in' | 'not_in' | 'present' | 'absent' | 'gte' | 'lte', required
    - `value` union
      - string
      - string[]
  - `_or` object[] — Compound-OR escape hatch: an array of filter branches combined with OR, each ANDed with the top-level keys. One level deep — branches cannot themselves contain `_or`.
    - `in` union — Match contacts whose id is in this set (single id or array).
      - string, uuid
      - string[]
    - `not_in` union — Exclude contacts whose id is in this set (single id or array).
      - string, uuid
      - string[]
    - `ignore_merge` boolean — Filter by the `ignore_merge` flag (excluded from merge suggestions).
    - `is_starred` boolean — Match starred (true) or non-starred (false) contacts.
    - `is_archived` boolean — Match archived (true) or active (false) contacts. Defaults to false when omitted.
    - `has_priority_tier` union — Relationship priority tier: a tier number, an array of tiers (OR), or a boolean (true = any tier set, false = none).
      - integer
      - integer[]
      - boolean
    - `has_linkedin` union — LinkedIn slug: an exact slug string, or a boolean for presence/absence of a LinkedIn handle.
      - string
      - boolean
    - `has_instagram` union — Instagram slug: an exact slug string, or a boolean for presence/absence of an Instagram handle.
      - string
      - boolean
    - `has_twitter` union — Twitter/X slug: an exact slug string, or a boolean for presence/absence of a Twitter handle.
      - string
      - boolean
    - `has_source` union — Contact source: a single source string or an array of sources (OR).
      - string
      - string[]
    - `has_name` union — Full name: a bare string (fuzzy contains), an array of exact names, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
      - string
      - string[]
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_groups` union — Group membership: a group id, an array of group ids (OR), a boolean for any/no group, or `{ not }` to exclude group id(s).
      - object
        - `not` union, required
          - string
          - string[]
      - boolean
      - string, uuid
      - string[]
    - `has_groups_all` array[] — Array of group-id rows: AND across rows, OR within each row (contact must be in at least one group from every row).
      - string[]
    - `has_frequency` union — Keep-in-touch cadence: a frequency string, or a boolean for presence/absence of a cadence.
      - string
      - boolean
    - `has_location` union — Location: a string (fuzzy, accent-insensitive match), or a boolean for presence/absence of a location.
      - string
      - boolean
    - `has_location_exact` string — Location: exact string match (not fuzzy).
    - `has_job_title` union — Job title: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_never_keep_in_touch` boolean — Filter by the `never_keep_in_touch` flag.
    - `has_created_at` object — Creation-date range: `{ gte?, lte? }` ISO 8601 datetimes (at least one bound required).
      - `gte` string, date-time
      - `lte` string, date-time
    - `has_updated_at` object — Last-updated-date range: `{ gte?, lte? }` ISO 8601 datetimes (at least one bound required).
      - `gte` string, date-time
      - `lte` string, date-time
    - `has_birthday` union — Birthday: a specific date (matches on day + month), or true for any birthday set.
      - string, date-time
      - unknown
      - boolean
    - `has_tag` string, uuid — Match contacts carrying this single tag id.
    - `has_tags` union — Tags: an array of tag ids (OR), or `{ not }` to exclude tag id(s).
      - string[]
      - object
        - `not` union, required
          - string, uuid
          - string[]
    - `has_tags_all` array[] — Array of tag-id rows: AND across rows, OR within each row (contact must carry at least one tag from every row).
      - string[]
    - `has_company` union — Company: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }` for explicit fuzzy vs exact match.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_education` union — Education: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_description` union — Description/notes: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_linkedin_companies` union — LinkedIn companies text: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_linkedin_education` union — LinkedIn education text: a bare string (fuzzy contains), a boolean for presence/absence, or `{ contains }` / `{ eq }`.
      - string
      - boolean
      - object
        - `contains` string, required
      - object
        - `eq` string, required
    - `has_email` boolean — Match contacts that have (true) or lack (false) at least one email.
    - `has_phone_number` boolean — Match contacts that have (true) or lack (false) at least one phone number.
    - `not_has_name` union — Exclude contacts whose full name fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_company` union — Exclude contacts whose company fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_job_title` union — Exclude contacts whose job title fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_education` union — Exclude contacts whose education fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_description` union — Exclude contacts whose description fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_linkedin_companies` union — Exclude contacts whose LinkedIn companies text fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `not_has_linkedin_education` union — Exclude contacts whose LinkedIn education text fuzzily matches this string / any of these strings.
      - string
      - string[]
    - `has_linkedin_last_message_at` union — LinkedIn last-message time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
      - boolean
      - object
        - `gte` string, date-time
        - `lte` string, date-time
    - `has_last_seen_at` union — Last-seen (last interaction) time — alias for has_interaction: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
      - boolean
      - object
        - `gte` string, date-time
        - `lte` string, date-time
    - `has_distance` object — Geo radius filter: contacts within `meters` of `{ lat, lon }` (PostGIS ST_DWithin on geocoded coordinates). `label` is an optional display name for the point.
      - `lat` number, required
      - `lon` number, required
      - `meters` number, required
      - `label` string
    - `has_interaction` union — Interaction (last-seen) time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
      - boolean
      - object
        - `gte` string, date-time
        - `lte` string, date-time
    - `has_next_reminder` union — Next-reminder time: a boolean for presence/absence, or a `{ gte?, lte? }` ISO 8601 range.
      - boolean
      - object
        - `gte` string, date-time
        - `lte` string, date-time
    - `custom_fields` object[] — User-defined custom-field filters. Each clause is `{ field_id, operator, value? }`; multiple clauses AND together. Operators: contains, eq, in, not_in, present, absent, gte, lte.
      - `field_id` string, uuid, required
      - `operator` 'contains' | 'eq' | 'in' | 'not_in' | 'present' | 'absent' | 'gte' | 'lte', required
      - `value` union
        - string
        - string[]

## Response `200`

Successful response

- object
  - `error` boolean, required
  - `data` object, required
    - `count` integer, required

## Other responses

- `400` — Request body failed validation.
- `401` — Missing or invalid API key.
- `403` — Valid key, insufficient permission.
- `404` — Resource does not exist.
- `429` — Rate limit exceeded.
- `500` — Unexpected server error.

---

[API](https://skmtc.net/getdex/apis/dex-public-api.md) · [All operations](https://skmtc.net/getdex/apis/dex-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/getdex/dex-public-api/versions/6f01cd52ac12/schema)
