PHP code example of survos / sais-bundle
1. Go to this page and download the library: Download survos/sais-bundle 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/ */
survos / sais-bundle example snippets
@todo: command that sends batches of images
#[Route('/featured', name: 'app_list_featured_projects')]
public function listFeatured(SaisClientService $saisService): Response
{
$payload = new \Survos\SaisBundle\Model\ProcessPayload(
$images,
['small'],
$this->urlGenerator->generate('app_webhook')
);
$saisService->dispatchProcess($payload);
}
#[Route('/webhook', name: 'app_webhook')]
public function webHook(): Response
{
$data = ...
}