selectInstance($URL); $response = $api->get_access_token($api->clientWebsite.'/auth?&host='.$domain, htmlspecialchars((string)filter_input(INPUT_GET, 'code'), ENT_QUOTES)); if(isset($response) && is_array($response) && isset($response['html']) && is_array($response['html']) && isset($response['html']["access_token"])) { $access_token = $response['html']["access_token"]; $profile = $api->accounts_verify_credentials()['html']; $account_id = $profile['id']; echo " "; } else echo "

An error occured

There was an error and Halcyon couldn't fetch or validate a access token for this instance

"; } ?>