Download the PHP package problematik/php-autoremote without Composer
On this page you can find all versions of the php package problematik/php-autoremote. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download problematik/php-autoremote
More information about problematik/php-autoremote
Files in problematik/php-autoremote
Package php-autoremote
Short Description PHP wrapper for AutoRemote
License MIT
Homepage https://github.com/problematik/php-autoremote
Informations about the package php-autoremote
PHP-AutoRemote
PHP-AutoRemote is a PHP wrapper for AutoRemote. It uses method chaning for easy setup and can set all attributes listed on the AutoRemoteWebInterface.
Installation
To include PHP-AutoRemote in your project edit your project's composer.json
file to require problematik/php-autoremote
Usage
PHP-AutoRemote is meant to be simple to use. To send an notification to your device all you need to do is the following:
Done, that's it! You should now see the notification on your device!
You've send the notification and something went wrong? Then the AutoRemoteException
will be thrown
Don't want to chain methods together, you would rater pass an array of properties to the constructor? Thats fine to...
But sometimes you just want to send an AutoRemote message
, that can be done like so
Want to add a button to your notification?
We just added a button to a notification using the AutoRemoteNotificationButton
class which takes in message, label, icon
respectively.
For the icon we used the AutoRemoteIcon
class, that has predefined constants with the icons you can use in your notifications, but you can use any string value as long it is listed in the AutoRemote Notification action in Tasker under the Button icon field, like so:
Please note that the
AutoRemoteIcon
class list only the icons which can be found in theAutoRemoteNotification
apk under theres/drawable-hdpi
, so some are missing (but that should still be enough, you have 350 icons predefined))
Properties
All the properties names can be found on the AutoRemoteWebInterface. The names are derived like so:
Message
=>message
// (all are lowercase)Target (optional)
=>target
(all are without parentheses)Act as Sender (Optional)
=>actAsSender
(all are camelCase)
with the exception of
Message validity time in seconds (Optional)
=>messageValidity
Picture URL
=>pictureUrl
Led On ms
=>ledOnMS
Led Off ms
=>ledOffMS
Icon URL
=>iconUrl
Some more examples
Send a notification with vibration pattern:
Send a notification with led color:
or use the shorthand method
Send a notification with progress bar