Download the PHP package besmartand-pro/bsap-sensor-bundle without Composer
On this page you can find all versions of the php package besmartand-pro/bsap-sensor-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download besmartand-pro/bsap-sensor-bundle
More information about besmartand-pro/bsap-sensor-bundle
Files in besmartand-pro/bsap-sensor-bundle
Package bsap-sensor-bundle
Short Description Symfony integration for the BeSmartAnd.Pro Sensor PHP client.
License MIT
Informations about the package bsap-sensor-bundle
BeSmartAnd.Pro Sensor Bundle
Integracja besmartand-pro/bsap-sensor-client z Symfony 7.4 i 8.x, dla PHP 8.4+. Bundle dodaje konfigurację, transport Symfony HttpClient i autowiring. Obsługa API i modele danych znajdują się w osobnej bibliotece klienta.
Instalacja
Zarejestruj bundle w config/bundles.php:
Dodaj config/packages/bsap_sensor.yaml:
Tylko api_token jest wymagany. Pozostałe wartości powyżej są domyślne. Token umieść w zmiennej środowiskowej lub Symfony Secrets; nie zapisuj go w repozytorium.
http_client pozwala wskazać istniejący scoped HTTP client aplikacji. Bundle tworzy własną pochodną tego serwisu, ustawia timeout i maksymalny czas żądania, a także wyłącza przekierowania. Aplikacja powinna mieć włączony HttpClient FrameworkBundle, np. framework: { http_client: ~ }.
Użycie przez autowiring
Można również wstrzyknąć konkretną klasę SensorClient. Interfejs i klasa wskazują ten sam serwis. Opis modeli, wyjątków i ograniczeń endpointu znajduje się w README biblioteki bsap-sensor-client.
Licencja MIT.
All versions of bsap-sensor-bundle with dependencies
besmartand-pro/bsap-sensor-client Version ~1.0.0
nyholm/psr7 Version ^1.8
symfony/config Version ^7.4 || ^8.0
symfony/dependency-injection Version ^7.4 || ^8.0
symfony/http-client Version ^7.4 || ^8.0
symfony/http-kernel Version ^7.4 || ^8.0