Perform a search using a specific field from an item type
GET {{baseUrl}}/itemSearch/field?term=<string>&field_type=<string>&exact_match=false&field_key=<string>&return_item_ids=<boolean>&start=<integer>&limit=<integer>
Performs a search from the values of a specific field. Results can either be the distinct values of the field (useful for searching autocomplete field values), or the IDs of actual items (deals, leads, persons, organizations or products).
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
term | string | (Required) The search term to look for. Minimum 2 characters (or 1 if using exact_match ). Please note that the search term has to be URL encoded. | |
field_type | string | (Required) The type of the field to perform the search from | |
exact_match | boolean | When enabled, only full exact matches against the given term are returned. The search <b>is</b> case sensitive. | |
field_key | string | (Required) The key of the field to search from. The field key can be obtained by fetching the list of the fields using any of the fields' API GET methods (dealFields, personFields, etc.). Only the following custom field types are searchable: address , varchar , text , varchar_auto , double , monetary and phone . Read more about searching by custom fields <a href="https://support.pipedrive.com/en/article/search-finding-what-you-need#searching-by-custom-fields" target="_blank" rel="noopener noreferrer">here</a>. | |
return_item_ids | string | Whether to return the IDs of the matching items or not. When not set or set to 0 or false , only distinct values of the searched field are returned. When set to 1 or true , the ID of each found item is returned. | |
start | string | Pagination start | |
limit | string | Items shown per page |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Accept | string |
RESPONSES
status: OK
{"success":true,"data":[{"id":1,"name":"Jane Doe"},{"id":2,"name":"John Doe"}],"additional_data":{"pagination":{"start":0,"limit":100,"more_items_in_collection":false}}}