[REST] Service desk customer search by email returns multiple results or none

Hi everyone.

I’m in a bit of a pickle here and I don’t understand how the search query term works really. It’s rather confusing.

For example doing something like this:

req, err = client.NewRequest("GET", "/rest/servicedeskapi/servicedesk/13/customer?query=email=\"email.address@gmail.com\"", nil)

Will return all users with the email domain gmail which is NOT what I would have expected / wanted. I can’t seem to turn off fuzzy searching basically.

And this field isn’t even working if I remove the ", it simply returns empty. Even though there is definitely a match.

Anyone has any ideas how to do this properly?