Searching or Query parameters?

in Development
does e-com API has some form of searching by querying fields? like retail API https://developers.lightspeedhq.com/retail/tutorials/searching/
this: https://developers.lightspeedhq.com/ecom/introduction/resources/ shows some filtering, but is very basic and general
my case:
i would like to find a customer id by email
i would like the customer to authenticate himself in my application by asking email and password. so i need to find the customer id of this email and check the password with "customerLogin"
or is there another way of authenticating a customer?
8 comments
Hi @thisconnect ,
We have tested it, but you need to query /[email protected] and you will get the record.
Like this:
I am getting following error message
Please advice
Hello @renjithmb,
Looking at the error message I believed you used a Retail API endpoint. You can do searches with the email address. I'm sending you the API request to do so.
Hi @Alex Lugo ,
I am trying following api call
But still error message. Could you give a correct example path as I am trying to get customer data by email id
Hey @renjithmb, I think the confusion is that this post has been placed in the eCom API section but you're asking about the Retail API.
To query for a customer via their email you can do this:
https://api.lightspeedapp.com/API/Account/{{accountID}}/Customer.json?load_relations=["Contact"]&Contact.email={{email}}
Hope this helps!
Adrian Samuel
Software Developer
Lightspeed HQ
Great catch Adrian, I'm moving this post to the Retail section.
Hello,
I'm looking to do the same thing but with the customer's phone number.
I've tried:
The only one that i've found that semi-works is Customer.pager, but I'd like to query all phone numbers.
Thanks,
--Paul
Hi Paul,
Try this