}
public static void authCallback() throws Exception {
String token = session.get(SessionKeys.TOKEN);
String secret = session.get(SessionKeys.SECRET);
ServiceInfo serviceInfo = Dropbox.OAUTH;
OAuth.Response oauthResponse = OAuth.service(serviceInfo).retrieveAccessToken(token, secret);
if (oauthResponse.error == null) {
Logger.info("Succesfully authenticated with Dropbox.");
User u = upsertUser(oauthResponse.token, oauthResponse.secret);
session.put(SessionKeys.TYPE, AccountType.DROPBOX.name());