---
title: "Search Contacts"
method: POST
path: "/contacts/search"
tags: ["contacts"]
---

# Search Contacts

`POST /contacts/search`

Use this endpoint to get a list of contacts matching the given search criteria. Contacts are returned if they include a given first name, last name, company name, and contact type. it will filter by range of dates, using the CreationDate of the contact. The size of the return is controlled with the pageSize query parameter which defaults to 25 and must be > 0 and <= 25. Set pageIndex > 0 to access contacts past the first page when more than pageSize contacts meet the search criteria. Sort criteria, startDate and endDate are required. The search returns includes like phone numbers, email addresses and location address.

## Query parameters

- `pageSize` integer
- `pageStartIndex` integer

## Request body

- ContactSearchPost
  - `contactTypes` string[]
  - `searchTerm` string — It could be the first name, last name, company name of the contact.
  - `startDate` string, date-time, required — An ISO 8601 string of the startDate to search. It will search by CreationDate. https://en.wikipedia.org/wiki/ISO_8601
  - `endDate` string, date-time, required — An ISO 8601 string of the endDate to search It will search by CreationDate. https://en.wikipedia.org/wiki/ISO_8601
  - `sort` ContactSort, required
    - `sortDirection` 'Ascending' | 'Descending', required — Sort direction of the search
    - `sortColumn` 'CreatedDate' | 'CompanyName' | 'ContactType' | 'firstName' | 'lastName' | 'LifeTimeValue', required — The columm to be sorted

## Response `200`

OK

- ContactCollection — Base structure for all paginated collection responses. This provides consistent pagination metadata across all collection endpoints.
  - `count` integer — The total number of items available across all pages. Use this to calculate the total number of pages available.
  - `pageSize` integer — The number of items per page in this response. This reflects either your requested page size or the default value.
  - `pageStartIndex` integer — The starting index of this page of results. Use with pageSize to track your position in the overall result set.
  - `items` Contact[]
    - `id` string, uuid
    - `_link` string, uri
    - `companyName` string — The company name of given contact.
    - `crossReference` string — The cross reference of given contact.
    - `firstName` string — The first name of given contact.
    - `lastName` string — The last name of given contact.
    - `salutation` string — The salutation of given contact.

## Other responses

- `400` — Bad Request - The server cannot process the request due to a client error. Common causes: - Invalid request format - Missing required fields - Validation errors in the request data
- `401` — Unauthorized - Authentication is required or has failed. Common causes: - Missing API key - Invalid API key - Expired or deactivated API key
- `416` — Range Not Satisfiable - The requested page of results is not available. Common causes: - pageStartIndex is beyond the available data range - Invalid pagination parameters

---

[API](https://skmtc.net/acculynx/apis/acculynx-api-v2.md) · [All operations](https://skmtc.net/acculynx/apis/acculynx-api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/acculynx/acculynx-api-v2/revisions/3a9e3886e400/schema)
