MCPcopy Create free account
hub / github.com/Asana/java-asana / fetchToken

Method fetchToken

src/main/java/com/asana/OAuthApp.java:77–83  ·  view source on GitHub ↗
(String code, String userId)

Source from the content-addressed store, hash-verified

75 }
76
77 public String fetchToken(String code, String userId) throws IOException {
78 TokenResponse tokenResponse = this.flow.newTokenRequest(code)
79 .setRedirectUri(this.redirectUri)
80 .execute();
81 credential = this.flow.createAndStoreCredential(tokenResponse, userId);
82 return credential.getAccessToken();
83 }
84
85 public String fetchToken(String code) throws IOException {
86 return fetchToken(code, null);

Callers 2

mainMethod · 0.95
handleMethod · 0.80

Calls 1

executeMethod · 0.45

Tested by

no test coverage detected