How to get access token from spring authorization server

45 views Asked by At

I am trying to setup spring authorization server by using the getting started guide.

server starts up fine but I am not able to fetch access token using rest API and getting following error:

org.springframework.security.oauth2.core.OAuth2AuthenticationException: Client authentication failed: client_id

I am using following Rest API:

http://localhost:9000/oauth2/token

and passing following payload in request:

grant_type:client_credential
client_id:oidc-client
client_secret:secret

and using basic authentication with following username and password:

username: user
password: password

I am not sure what the above error is pointing me to. Am I using wrong end point or am I using wrong client_id and client_secret.

Would appreciate any help.

0

There are 0 answers