SHARE
TWEET

Untitled

a guest Aug 12th, 2016 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. WSRequest request = ws.url("http://abababa .com");
  2. WSRequest complexRequest = request.setHeader("X-API-Key", "xxxxxx")
  3.             .setHeader("Content-Type", "application/x-www-form-urlencoded")
  4. CompletionStage<WSResponse> responsePromise = complexRequest.post("grant_type=password"
  5.             + "&username=xxxxx&password=yyyyy");
  6. CompletionStage<JsonNode> jsonPromise = responsePromise.thenApply(WSResponse::asJson);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top