Filter by two fields

I’m looking for a way to filter contacts by two fields, in this case Email and Phone.

If I try this, there are not results.

/contacts?filters[email]=some_email&filters[phone]=some_phone

Must return two contacts.

If I try this, then only finds by the second search.

/contacts?search=some_email&search=some_phone

This return one contact instead of two.

Some of our contacts have only email, other have only email.

What’s the correct way to find contacts using two fields?

Don’t know why this editor removes all line breaks btw.

1 Like

HI there,

For /contacts?filters[email]=some_email &filters[phone]=some_phone, I don’t beleive phone nor email are a type of filter. That wouldn’t work imo.

For /contacts?search=some_email &search=some_phone, you are negating the first ‘search’ parameter by setting the second. That woudl yield result sby seocnd search as you experienced.

Maybe try this:
contacts?email=some_email &search=some_phone