# \[API\] /api/users/lookup

**URL:** <https://community.grafana.com/t/api-api-users-lookup/306>\
**Category:** Developers & API\
**Tags:** api\
**Created:** [March 28, 2017, 10:39am UTC](https://community.grafana.com/t/api-api-users-lookup/306 "2017-03-28T10:39:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![aime](https://avatars.discourse-cdn.com/v4/letter/a/258eb7/32.png) [@aime](https://community.grafana.com/u/aime)\
**Post date:** [March 28, 2017, 10:39am UTC](https://community.grafana.com/t/api-api-users-lookup/306/1 "2017-03-28T10:39:02Z")

</div>

Hello Dear grafana community,

I am trying to get a specific user using curl and I’m always getting the following answer from grafana server {“message”:“Failed to get user”}.  
Is it normal ?  
For the reference, I am using grafana version 4.1.2 and the request I make is as shown bellow:  
curl [http://admin:mypassword@mygrafanaserver.com/api/users/lookup?loginOrEmail=admin](http://admin:mypassword@mygrafanaserver.com/api/users/lookup?loginOrEmail=admin).

Thanks in advance for you help

---

<div class="post-metadata">

**Author:** ![nopzor1200](https://avatars.discourse-cdn.com/v4/letter/n/a4c791/32.png) [@nopzor1200](https://community.grafana.com/u/nopzor1200)\
**Post date:** [March 28, 2017, 10:20pm UTC](https://community.grafana.com/t/api-api-users-lookup/306/2 "2017-03-28T22:20:13Z")

</div>

Hi aime,  
Try upgrading your Grafana to the latest version. There have been some recent changes to the users API including lookup/search. If you still have problems, let us know.

---

<div class="post-metadata">

**Author:** ![daniellee](https://sea2.discourse-cdn.com/grafana/user_avatar/community.grafana.com/daniellee/32/41_2.png) [@daniellee](https://community.grafana.com/u/daniellee)\
**Post date:** [March 29, 2017, 10:41am UTC](https://community.grafana.com/t/api-api-users-lookup/306/3 "2017-03-29T10:41:22Z")

</div>

That works for me on the latest master. There have been some changes to the API but no breaking changes. Does it work in the browser if you login in as admin and then try: `http://mygrafanaserver.com/api/users/lookup?loginOrEmail=admin`?

Just a sanity check, I had to quote the curl argument to get it to work:

`curl "http://admin:admin@community.grafana.com/api/users/lookup?loginOrEmail=admin"`

---

<div class="post-metadata">

**Author:** ![anon80964540](https://avatars.discourse-cdn.com/v4/letter/a/bbe5ce/32.png) [@anon80964540](https://community.grafana.com/u/anon80964540)\
**Post date:** [January 13, 2021, 4:02pm UTC](https://community.grafana.com/t/api-api-users-lookup/306/4 "2021-01-13T16:02:13Z")

</div>

Closed on January 13, 2021, 4:02pm UTC


