# Search API empty response

**URL:** <https://community.hubspot.com/t/search-api-empty-response/78672>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [April 4, 2023, 1:33pm UTC](https://community.hubspot.com/t/search-api-empty-response/78672 "2023-04-04T13:33:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ACarr3](https://avatars.discourse-cdn.com/v4/letter/a/76d3ee/32.png) [@ACarr3](https://community.hubspot.com/u/ACarr3)\
**Post date:** [April 4, 2023, 1:33pm UTC](https://community.hubspot.com/t/search-api-empty-response/78672/1 "2023-04-04T13:33:03Z")

</div>

Hi guys, I’m using the search api to retrieve some info. The thing here is that I need to send an array of values and I want to get the ones that exist in my hubspot account. For some reason, the API search is not working with the property I’m trying to retrieve.

This is my filter:

{

“filterGroups”: [

```
{

  "filters": \[

    {

      "values": \["7Y087XErdLsi8hsb3", "76f3gdtsXErdLsi8hsb3"],

      "propertyName": "customproperty",

      "operator": "IN"

    }

  ]

}

```

],

“properties”: [“customproperty”]

}

Endpoint: [https://api.hubapi.com/crm/v3/objects/id/search](https://api.hubapi.com/crm/v3/objects/id/search)

Also, I have another custom property that contains emails, if I search those the API search works, but it doesn’t when search for especific values like this: 7Y087XErdLsi8hsb3 or 76f3gdtsXErdLsi8hsb3

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [April 5, 2023, 6:10pm UTC](https://community.hubspot.com/t/search-api-empty-response/78672/2 "2023-04-05T18:10:45Z")

</div>

Hey, @ACarr3 👋 Thanks for the great question. I set up a test like yours and got the same result, a 200 response and an empty array. Challenging and not a lot to work with.

Here’s the issue — the IN search operator only accepts values in lowercase (even if the value is mixed-case on the object record, like your examples). It’s mentioned in the documentation, but should be **bolded** or flagged explicitly. From the documentation — “This operator is case-sensitive, so inputted values must be in lowercase”.

Here’s what I did using your example and my test portal:

Request

`POST https://api.hubapi.com/crm/v3/objects/contacts/search`

Body

```lia-code-sample
{
 "properties": [
 "customproperty"
 ],
 "filterGroups": [
 {
 "filters": [
 {
 "propertyName": "customproperty",
 "operator": "IN",
 "values": ["7y087xerdlsi8hsb3","76f3gdtsxerdlsi8hsb3"]
 }
 ]
 }
 ]
}

```

Response

```lia-code-sample
{
 "total": 4,
 "results": [
 {
 "id": "801",
 "properties": {
 "createdate": "2022-11-03T21:42:31.255Z",
 "customproperty": "7Y087XErdLsi8hsb3",
 "hs_object_id": "801",
 "lastmodifieddate": "2023-04-05T17:40:19.990Z"
 },
 "createdAt": "2022-11-03T21:42:31.255Z",
 "updatedAt": "2023-04-05T17:40:19.990Z",
 "archived": false
 },
 {
 "id": "901",
 "properties": {
 "createdate": "2022-11-03T21:42:31.255Z",
 "customproperty": "7Y087XErdLsi8hsb3",
 "hs_object_id": "901",
 "lastmodifieddate": "2023-04-05T17:39:40.188Z"
 },
 "createdAt": "2022-11-03T21:42:31.255Z",
 "updatedAt": "2023-04-05T17:39:40.188Z",
 "archived": false
 },
 {
 "id": "951",
 "properties": {
 "createdate": "2022-11-03T21:42:31.255Z",
 "customproperty": "76f3gdtsXErdLsi8hsb3",
 "hs_object_id": "951",
 "lastmodifieddate": "2023-04-05T17:41:04.990Z"
 },
 "createdAt": "2022-11-03T21:42:31.255Z",
 "updatedAt": "2023-04-05T17:41:04.990Z",
 "archived": false
 },
 {
 "id": "1001",
 "properties": {
 "createdate": "2022-11-03T21:42:31.255Z",
 "customproperty": "76f3gdtsXErdLsi8hsb3",
 "hs_object_id": "1001",
 "lastmodifieddate": "2023-04-05T17:41:31.949Z"
 },
 "createdAt": "2022-11-03T21:42:31.255Z",
 "updatedAt": "2023-04-05T17:41:31.949Z",
 "archived": false
 }
 ]
}

```

Which matches what I see in-app:

 ![CleanShot 2023-04-05 at 12.07.17.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/0/7/07865a5e5d65f2b37585eeffa2b19bc3b00cdca1.png)

I hope this helps get you moving forward. Have fun building! — Jaycee

---

<div class="post-metadata">

**Author:** ![ACarr3](https://avatars.discourse-cdn.com/v4/letter/a/76d3ee/32.png) [@ACarr3](https://community.hubspot.com/u/ACarr3)\
**Post date:** [April 7, 2023, 1:43am UTC](https://community.hubspot.com/t/search-api-empty-response/78672/3 "2023-04-07T01:43:33Z")

</div>

Thanks so much for your help, thanks to you I’ll be able to find good sleep today 😉
