Skip to content

Search contacts

Request

Search contacts using advanced filters with pagination and sorting. Use this to find contacts by any combination of fields — name, company, email status, pipeline stage, tags, and more.

Security
bearerAuth
Bodyapplication/jsonrequired
filterobject

Filter criteria. Supports scalar values (equals), arrays (IN), objects with operators (>=, <=, etc.), "is_null", "is_not_null".

Example:
{ "company_name": "Acme Inc", "email_status": "ok" }
limitinteger, >= 1

Number of results to return.

Default:20
Example:20
offsetinteger, >= 0

Number of results to skip.

Default:0
Example:0
order_fieldstring

Field to sort by.

Default:"created_at"
Example:"name"
order_typestring

Sort direction.

Default:"desc"
Enum:"asc""desc"
Example:"asc"
disable_aggregationboolean

Skip enrichment data aggregation.

Default:false
POST
/leads/api/leads/search
curl -i -X POST \
  https://leadgen.grinfi.io/leads/api/leads/search \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "filter": {
      "company_name": "Acme Inc",
      "email_status": "ok"
    },
    "limit": 20,
    "offset": 0,
    "order_field": "created_at",
    "order_type": "desc"
  }'

Responses

Paginated list of matching contacts.

Bodyapplication/json
dataArray of objects(lead)
limitinteger
Example:20
offsetinteger
Example:0
totalinteger
Example:142
Response
{ "data": [ {} ], "limit": 20, "offset": 0, "total": 142 }