A sample application that demonstrates how the Google OAuth2 library can be used to authenticate
against a locally running Keycloak server with a registered public client where using PKCE is required.
Please note that before running this sample application, a local Keycloak server must be
running and a PKCE enabled client must have been defined. Please see
samples/keycloak-pkce-cmdline-sample/scripts/initialize-keycloak.sh for further
information.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[],null,["# Package com.google.api.services.samples.keycloak.cmdline (1.39.0)\n\nVersion latestkeyboard_arrow_down\n\n- [1.39.0 (latest)](/java/docs/reference/google-oauth-client/latest/com.google.api.services.samples.keycloak.cmdline)\n- [1.38.2](/java/docs/reference/google-oauth-client/1.38.2/com.google.api.services.samples.keycloak.cmdline)\n- [1.37.0](/java/docs/reference/google-oauth-client/1.37.0/com.google.api.services.samples.keycloak.cmdline)\n- [1.36.0](/java/docs/reference/google-oauth-client/1.36.0/com.google.api.services.samples.keycloak.cmdline)\n- [1.34.1](/java/docs/reference/google-oauth-client/1.34.1/com.google.api.services.samples.keycloak.cmdline)\n- [1.33.3](/java/docs/reference/google-oauth-client/1.33.3/com.google.api.services.samples.keycloak.cmdline)\n- [1.32.1](/java/docs/reference/google-oauth-client/1.32.1/com.google.api.services.samples.keycloak.cmdline) \n\nClasses\n-------\n\n### [PKCESample](/java/docs/reference/google-oauth-client/latest/com.google.api.services.samples.keycloak.cmdline.PKCESample)\n\nA sample application that demonstrates how the Google OAuth2 library can be used to authenticate\nagainst a locally running Keycloak server with a registered public client where using [PKCE](https://tools.ietf.org/html/rfc7636) is required.\n\nPlease note that before running this sample application, a local Keycloak server must be\nrunning and a PKCE enabled client must have been defined. Please see `\nsamples/keycloak-pkce-cmdline-sample/scripts/initialize-keycloak.sh` for further\ninformation."]]