Skip to main content

Client setup with an adapter

--- Learn how to set up your OpenID connection if you are using an adapter/library.

Using a client with an adapter

After having your Installation JSON, you can setup your application quickly using the Keycloak adapters/libaries. Keycloak has adapters for a number of languages, including java, javascript and C#. For a list of adapters and instructions on how to connect see here.

There are example applications available to demonstrate integrating with Keycloak here In most cases, it does not require any additional information than the Installation JSON you can download.

More on understanding the json file

Our guidance on libraries/adapters

Evaluation of existing OIDC client libraries to select which example apps we should create for our client teams.

We are evaluating on the following criteria:

  • Being maintained? - Is the library being currently maintained? Recent commits/publish?
  • Meets feature set - Does the library allow teams to perform auth flows? Will it allow for custom KC params? (kc_idp_hint)
  • Popularity - How popular is it?
  • Open source - Is it Open Source?
  • Support for PKCE - Does it support PKCE?
  • Works for SPAs - Does the library work for single page applications?
  • Comments - Relevant comments

JavaScript

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
passport-keycloak-bearer1889 DL/Week
oidc-client-ts38550 DL/Week
sso-express127 DL/WeekBeing used by some community teams.
openid-client940475 DL/WeekFor Node.js only.
keycloak-js222218 DL/WeekKeycloak supported in their documentation.

TypeScript

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
oidc-client-ts38550 DL/Week
sso-express127 DL/WeekBeing used by some community teams. Works for TypeScript.
keycloak-js222218 DL/WeekKeycloak supported in their documentation. Works for TypeScript.

C#/.Net

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
IdentityModel.OidcClientN/A

Python

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
JWTConnect-Python-OidcRP400 DL/Week
pyoidcN/A

Java

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
Spring SecurityN/A (Very popular)N/A
SpringBoot N/A (Very popular)N/A

AngularJS

LibraryBeing Maintained?Meets feature setPopularityOpen sourceSupport for PKCEWorks for SPAsComments
angular-auth-oidc-client28000 DL/week

Additional Notes

  • Libraries being considered which were not maintained are not included in this list.