&client_id= // ( is url of this script). // 3. Store the refresh token use Nikapps\BazaarApi\Bazaar; use Nikapps\BazaarApi\Config; require_once __DIR__ . '/../vendor/autoload.php'; $bazaar = new Bazaar(new Config([ 'client-secret' => 'your-client-secret', 'client-id' => 'your-client-id' ])); $redirectUrl = 'http://example.com/callback'; $token = $bazaar->token($redirectUrl); if ($token->failed()) { echo $token->errorDescription(); } else { echo "Refresh Token: " . $token->refreshToken(); }