1. Go to this page and download the library: Download cjrasmussen/bluesky-api library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cjrasmussen / bluesky-api example snippets
use cjrasmussen\BlueskyApi\BlueskyApi;
$bluesky = new BlueskyApi();
try {
$bluesky->auth($handle, $app_password);
} catch (Exception $e) {
// TODO: Handle the exception however you want
}
$refresh_token = $bluesky->getRefreshToken();
try {
$bluesky->auth($refresh_token);
} catch (Exception $e) {
// TODO: Handle the exception however you want
}