1

If i requested it is redirecting to KeyCloak login page but i want to use customized login page of my project and if i request for login then internally the KeyCloak should be logged in and then request go for backend, is it possible? If possible how, if anyone explained me it will be helpful for me

praveen jp
  • 197
  • 2
  • 14

1 Answers1

2

you could either create your own theme which is reflecting your project's style. Find the documentation here.

Or you could check for the REST API and obtain an access and refresh token using the username and password. See this stackoverflow here.

Tim
  • 353
  • 2
  • 8
  • As you said i had tried in the second approach but i am facing error like { "error": "invalid_request", "error_description": "Missing form parameter: grant_type" }, you can find my requested url also http://localhost:8080/auth/realms/master/protocol/openid-connect/token – praveen jp Jul 11 '17 at 10:21
  • It says: parameter missing. Did you provide the mentioned data { client_id : 'Id_of_your_client', username : 'your_username', password : '@#$%^&', grant_type : "password" }? – Tim Jul 13 '17 at 06:08
  • yes, i have provided all but still im facing same problem. – praveen jp Jul 13 '17 at 10:06
  • 3
    Try using body content-type: x-www-form-urlencoded, it helped me resolve the issue, and I can succesfully query keycloak via postman – fleczycki Aug 11 '17 at 10:07
  • try removing auth from your URL. for me this is working http://:8180/realms/frtest/protocol/openid-connect/token in postman – Abdul Aug 01 '22 at 14:08