X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Faccesstoken.php;h=4f683ba24f65ab0491783c3c0040d115e3d1005a;hb=1ef5cf964ef65b248dc150660124e95dcd933106;hp=e28a9334542f83e214191c2c36a6840d4ec32c6d;hpb=2fe978e1bb044a2ba8920156184dee7bb57c728b;p=quix0rs-gnu-social.git diff --git a/actions/accesstoken.php b/actions/accesstoken.php index e28a933454..4f683ba24f 100644 --- a/actions/accesstoken.php +++ b/actions/accesstoken.php @@ -22,6 +22,13 @@ if (!defined('LACONICA')) { exit(1); } class AccesstokenAction extends Action { function handle($args) { parent::handle($args); - common_server_error(_t('Not yet implemented.')); + try { + $req = OAuthRequest::from_request(); + $server = omb_oauth_server(); + $token = $server->fetch_access_token($req); + print $token; + } catch (OAuthException $e) { + common_server_error($e->getMessage()); + } } }