{"repo":"salmanzafar949/MQTT-Laravel","free":true,"listed":false,"github":"https://github.com/salmanzafar949/MQTT-Laravel","clone":"git clone https://github.com/salmanzafar949/MQTT-Laravel.git","description":"Laravel package to connect, publish, and subscribe to an MQTT broker","language":"PHP","stars":102,"topics":["laravel","mqtt","php","iot","laravel-package","mqtt-client","pubsub"],"license":"MIT","category":"api-integrations-sdks","readme_excerpt":"Laravel MQTT A simple Laravel library to connect, publish and subscribe to an MQTT broker. Based on bluerhinos/phpMQTT. A working example application is available in the Laravel-Mqtt-Example repo. Table of contents - Compatibility - Installation - Configuration - Usage - Publishing - Subscribing - Multiple topics - Helper functions - Artisan commands - Multiple connections - Events - Notifications - TLS / SSL - Error handling - Testing your app - Available methods - Testing & quality - Roadmap - Releasing - Changelog - Contributing - License Compatibility PHP Laravel ----------- ------------- 7.2 – 8.4 5.5 – 12.x The package uses Laravel's package auto-discovery, so it works out of the box across all of the above versions. Installation The service provider and Mqtt facade are registered automatically on Laravel 5.5+. Only if you are on Laravel $client id and $retain are optional: ConnectAndPublish($topic, $message) works too. When no client id is given, a unique one is generated for you. Subscribing Or via the facade: Subscribing blocks the process while it listens, so run it from an Artisan command / queue worker rather than an HTTP request. Subscribing to multiple topics Pass an array of topics to listen to several at once: Helper functions Two convenience helpers are also available: Artisan commands Publish or subscribe straight from the CLI — no need to hand-write a console command: Multiple connections Talk to more than one broker by defining extra connections in config/","default_branch":null,"files":null,"tree":[],"storefront":"/r/salmanzafar949","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/salmanzafar949/MQTT-Laravel/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}