# Obtaining Access Token for Keycloak User Using Admin Account

**URL:** <https://forum.keycloak.org/t/obtaining-access-token-for-keycloak-user-using-admin-account/26275>\
**Category:** Miscellanaeous\
**Created:** [May 29, 2024, 9:12am UTC](https://forum.keycloak.org/t/obtaining-access-token-for-keycloak-user-using-admin-account/26275 "2024-05-29T09:12:42Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mthri](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/mthri/32/9612_2.png) [@mthri](https://forum.keycloak.org/u/mthri)\
**Post date:** [May 29, 2024, 9:12am UTC](https://forum.keycloak.org/t/obtaining-access-token-for-keycloak-user-using-admin-account/26275/1 "2024-05-29T09:12:42Z")

</div>

I have a Keycloak server for SSO. In this server, there may be many users. I need a way to obtain an access token for a specific user (for example, John in the realm ‘test\_realm’) using an admin account from the master realm. I only have the user’s user ID or username and do not have the user’s password. I also use the python-keycloak Python library for communication with the Keycloak server(but it’s not important. If you have a solution for this using cURL, please let me know). How can I do that?

Version: 20.0.2  
Product: Default  
Admin UI version: 911eb6b83b301a990cbd0029c086150dfef279e9
