aurelbichop/recherche-entreprises-bundle
Bundle Symfony pour l'API Recherche d'entreprises du gouvernement français.
composer require aurelbichop/recherche-entreprises-bundle
# config/packages/aurelbichop_recherche_entreprises.yaml
aurel_bichop_recherche_entreprises:
timeout: 10 # Timeout en secondes (défaut: 10)
use AurelBichop\RechercheEntreprisesBundle\Client\EntrepriseSearchClientInterface;
public function __construct(
private EntrepriseSearchClientInterface $entrepriseClient
) {}
public function search(): Response
{
$result = $this->entrepriseClient->search('carrefour');
foreach ($result->results as $entreprise) {
echo $entreprise->nomComplet . ' - ' . $entreprise->siren;
}
}
$entreprise = $this->entrepriseClient->findBySiren('652014051');
if ($entreprise) {
echo $entreprise->nomComplet;
}
# Recherche simple
php bin/console recherche-entreprise:search carrefour
# Par SIREN (détails complets)
php bin/console recherche-entreprise:search 652014051 --siren
SearchResult : Résultat paginéEntreprise : Données d'entrepriseSiege : Établissement siègevendor/bin/phpunit --testdox
How can I help you explore Laravel packages today?