https://developer.lametric.com/icons $message=" Die Waesche ist fertig !"; // MAX 6 char (with icon) for no scroll $priority="info"; // info, warning, critical $priority_icon="info"; // none, info, alert $sound = "notification"; // http://lametric-documentation.readthedocs.io/en/latest/reference-docs/device-notifications.html $sound_repeat=5; $url = "http://Lametric-IP:8080/api/v2/device/notifications"; $curl = curl_init(); $headers = array( "Accept: application/json", "Content-Type: application/json", "Authorization: Basic [dev:Lametric-API-Passwort]", "Cache-Control: no-cache", ); $frames = array( "priority" => $priority, 'icon_type' => $priority_icon, "model" => array( "cycles" => $nb_cycle, "frames" => array( array( "icon" => $icon_id, "text" => $message ) ), "sound" => array ( "category" => "notifications", "id" => $sound, "repeat" => $sound_repeat ) ) ); echo "CALL :
".json_encode($frames); echo "

"; curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); curl_setopt($curl, CURLOPT_URL, $url); curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); curl_setopt($curl, CURLOPT_POST, 1); curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($frames)); $response = curl_exec($curl); echo "RESPONSE :
".$response; curl_close($curl); ?>