Whydah Home

compared with
Current by Thor Henning Hetland
on Nov 30, 2021 09:58.

Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (2)

View Page History
{code}
// Execute a POST to authenticate my application
String appToken = Request.Post("https://sso.whydah.net/sso/logon") Request.Post("https://sso.whydah.net/tokenservice/logon")
.bodyForm(Form.form().add("applicationcredential", myAppCredential).build())
.execute().returnContent().asBytes();

// Execute a POST to SecurityTokenService with userticket to get usertoken
String usertoken = Request.Post("https://sso.whydah.net/sso/user/"+appTokenID+"/get_usertoken_by_userticket/") Request.Post("https://sso.whydah.net/tokenservice/user/"+appTokenID+"/get_usertoken_by_userticket/")
.bodyForm(Form.form().add("apptoken", appToken)
.add("userticket", userTicket).build())