}
private OAuthToken getAccessToken(String refreshToken) throws IOException {
final String tokenUrl = String.format(ACCESS_TOKEN_URL, refreshToken,
oAuthParams.getRedirectUri(), oAuthParams.getClientId(), oAuthParams.getClientSecret());
final WebRequest webRequest = new WebRequest(new URL(tokenUrl), HttpMethod.POST);
final WebResponse webResponse = webClient.loadWebResponse(webRequest);
if (webResponse.getStatusCode() != HttpStatus.SC_OK) {
throw new IOException(String.format("Error getting access token: [%s: %s]",
webResponse.getStatusCode(), webResponse.getStatusMessage()));