Using external Identity stores for OAuth2 password grant type

Hi,

For OAuth2 password grant type users should be stored in gateway, how could I integrate already existing users in my database as resource owners.

Thank You,
Shiva.

So, when you are using oAuth2 with password grant, it will try to lookup for a keys which created with “Basic Authentification” turned on:

So you need to write a script to pre-create keys for all your users or create them manually.

If the following approach does not work for you, you need to check our auth middleware //tyk.io/docs/plugins/supported-languages/rich-plugins/python/custom-auth-python-tutorial/, and write some custom logic which query your database.