Good evening everyone,
is there any query or call I can make to retrieve user address information to the home page, for example? Without going through the orderForm
Good evening everyone,
is there any query or call I can make to retrieve user address information to the home page, for example? Without going through the orderForm
Hi Guilherme,
If the customer doesnāt have an account in the store yet, the best approach would be through the orderForm itself, especially using the Shopper Location app.
However, if the customer already has an account, itās possible to retrieve the registered address using the Search documents API from Master Data. Just search the address Data Entity (by default the acronym would be AD) and define an easy search term like the email address, as shown in the example below:
https://{{accountName}}.vtexcommercestable.com.br/api/dataentities/AD/search?_fields=_all&_where=(userId={{userEmail}})
Eduardo Luciano
Field Software Engineer | VTEX
Hello @eduardo.luciano, this is exactly what I needed. Thank you so much!