- edited description
Fetching Token form TokenEndPointURL
I am wondering is there any method available here to fetch the token from using grant type is credential using tokenEndpoint Url
I will have the following input
1)TokenEndPointurl -> https://login.microsoftonline.com/ed841e4cfd71414926c/oauth2/token
2) clientid/client scrent :-> xxxxxx/xxxxxx
3) grant_type---->client_credentials
4) resource=>http://dataservicespoc.onmicrosoft.com/PartyOData
This will return the token:
grant_type=client_credentials&client_id=ce705a3c-f80c-4447-9ebd-e1e061cd8eaf&client_secret=XXXXXXXXXX=&resource=http://dataservicespoc.onmicrosoft.com/PartyOData
Thanks
Comments (5)
-
reporter -
repo owner - edited description
-
repo owner That's really beyond the scope of this library, which is JOSE/JWT processing. You could use HttpURLConnection or Apache's HttpClient to make the HTTP request. There are likely OAuth client libraries too, which could help, but if all you need is a POST with the client credentials, one of those (or similar) is probably enough. JsonUtil in this library is a simple tool that can parse the response or and JSON processor that you like.
-
repo owner - changed status to invalid
making as invalid as it is beyond the scope of what jose4j does
-
reporter Thanks Really appreciate. I am doing the HttpURLConnection.
- Log in to comment