Download & Installation
Der Pushsafer Adapter wird direkt über die ioBroker Administration (Reiter Adapter) heruntergeladen und installiert.
npm install iobroker.pushsafer
oder https://github.com/ioBroker/ioBroker.pushsafer
Benutzung
Anlegen und Einrichten von einer oder mehreren Pushsafer Instanzen
um eine Push-Nachricht über den ScriptEngine zu senden:
<?php // send notification to all instances of pushsafer adapter sendTo("pushsafer", "message body"); // send notification to specific instance of pushsafer adapter sendTo("pushsafer.1", "message body"); // To specify subject or other options sendTo("pushsafer", { message: 'Test text', // mandatory - your text message title: 'SweetHome', // optional - your message's title, otherwise your app's name is used device: '12', // optional - a device id or device group id (empty or a = all devices) sound: '2', // optional - a number betwenn 0-28 (see pushsafers API description) icon: '2', // optional - a number betwenn 1-98 (see pushsafers API description) vibration: '0', // optional - a number betwenn 0-3 (see pushsafers API description) picture: 'absolutePathToPicture' // optional - absolute path to picture or base64 coded image URL picture2: 'absolutePathToPicture2' // optional - absolute path to picture or base64 coded image URL picture3: 'absolutePathToPicture3' // optional - absolute path to picture or base64 coded image URL url: 'http://blabla', // optional - URL or URL scheme, https://www.pushsafer.com/en/url_schemes urlTitle: 'Link to BLA', // optional - title of URL time2live '60', // optional - Integer number 0-43200: Time in minutes, after which message automatically gets purged. }); ?>
Weitere Informationen zum Ersetzten von Werten (Titel, Nachricht, Sound, Icon, Vibration) in deiner Push-Benachrichtigung, findest du in unserer API Beschreibung!