[keycloak-user] Is there any public Keycloak endpoint to get a code?

Bernardo Pacheco bernardo at zwift.com
Thu Mar 9 12:11:19 EST 2017


Hi everybody,

I'm trying to find out if Keycloak has an endpoint where I can submit my
username and password to get a code. Later with this code I could exchange
it for an access token.

According to the Keycloak's documentation and taking a looking into the
Keycloak source code, the only endpoint I found out is the following:

auth/realms/{realm-name}/protocol/openid-connect/auth?response_type=code&client_id={client_id}&redirect_uri={redirect_uri}&state={state}&login=true

However, this endpoint returns a HTML page with a form where an user could
enter with username and password. The form action is:

auth/realms/zwift/login-actions/request/login?code={code}

The code parameter is generated by Keycloak when the HTML was processed and
served, so I cannot call this endpoint directly because I need this code
parameter.

My question is: in any Keycloak version, is there a public Keycloak
endpoint where I can submit username and password to get a code that will
be used to get a access token later via /token endpoint?

Just a note, I'm using an old Keycloak version: v1.2.0-Final.

Regards,


More information about the keycloak-user mailing list