1. Go to this page and download the library: Download floopfloop/sdk 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/ */
floopfloop / sdk example snippets
loopFloop\Client;
$client = new Client(apiKey: getenv('FLOOP_API_KEY'));
$created = $client->projects()->create([
'prompt' => 'A landing page for a cat cafe',
'subdomain' => 'cat-cafe',
'botType' => 'site',
]);
$live = $client->projects()->waitForLive($created['project']['id']);
echo "Live at: {$live['url']}\n";
use FloopFloop\HttpClient;
use FloopFloop\Client;
final class CurlHttpClient implements HttpClient { /* ... */ }
$client = new Client(apiKey: '...', httpClient: new CurlHttpClient());
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.