-
-
Notifications
You must be signed in to change notification settings - Fork 406
Notify_lametric
Chris Caron edited this page Aug 7, 2020
·
12 revisions
- Source: https://lametric.com
- Icon Support: Yes
- Message Format: Text
- Message Limit: 32768 Characters per message
You now have to methods of notifying your LaMetric Device:
- Device Mode: Directly query your LaMetric Device on your local network to send it a notification.
- Cloud Mode: A secure query to LaMetric's API server in the cloud to send a message to your clock. You will have limited options with this method.
With Device Mode, your Apprise query will directly interface with the LaMetric Time Device on your local network.
- Sign Up and login to the Developer Webpage.
- Locate your Device API Key; you can find it here:
- You now need to know the IP address your device resides on. Your devices IP Address can be found in LaMetric Time app at: Settings -> Wi-Fi -> IP Address
Using Cloud Mode, you will interface with your LaMetric Time device through the internet.
- Sign Up and login to the Developer Webpage.
- Create a Notification App if you haven't already done so from here.
- Provide it an app name, a description and privacy URL (which can point to anywhere; I set mine to
http://localhost
). No permissions are required. - Access your newly created app so that you can acquire both the Client ID and the Client Secret here
Device Mode Syntaxes are as follows:
lametric://{apikey}@{hostname}
lametric://{apikey}@{hostname}:{port}
lametric://{userid}:{apikey}@{hostname}
lametric://{userid}:{apikey}@{hostname}:{port}
Cloud Mode Syntax is as follows:
lametric://{client_id}@{client_secret}
The breakdown of parameters depend on whether you are using the Cloud Mode or Device Mode.
Variable | Required | Description |
---|---|---|
apikey | Yes | Your Device API Key can be found on LaMetric's website here |
hostname | Yes | This is the IP address or hostname of your Lametric device on your local network. |
port | No | The port your LaMetric device is listening on. By default the port is 8080. |
userid | No | The account login to your Lametric device on your local network. By default the user is set to dev . |
mode | No | Define the Apprise/Lametric mode to use. This can be either set to cloud or device . It's worth pointing out that Apprise is smart enough to detect the mode you're using based on the URL you provide it. But for those who want to explicitly provide it's value, they can do so. |
cycles | No | The number of times message should be displayed. If cycles is set to 0 , notification will stay on the screen until user dismisses it manually. By default it is set to 1 . |
sounds | No | An audible alarm that can be sent with the notification. The following keywords are supported: bicycle , car , cash , cat , dog , dog2 , energy , knock-knock , letter_email , lose1 , lose2 , negative1 , negative2 , negative3 , negative4 , negative5 , notification , notification2 , notification3 , notification4 , open_door , positive1 , positive2 , positive3 , positive4 , positive5 , positive6 , statistic , thunder , water1 , water2 , win , win2 , wind , wind_short , alarm1 , alarm2 , alarm3 , alarm4 , alarm5 , alarm6 , alarm7 , alarm8 , alarm9 , alarm10 , alarm11 , alarm12 , and alarm13 . |
priority | No | The priority of the message; the possible values are info , warning , and critical . By default info is used if nothing is specified. |
icon_type | No | Represents the nature of notification; the possible values are info , alert , and none . By default none is used if nothing is specified. |
Variable | Required | Description |
---|---|---|
client_id | Yes | Your Device Client ID can be found on LaMetric's website here after you create a Notification App. |
client_secret | Yes | Your Device Client Secret can be found on LaMetric's website here after you create a Notification App. |
mode | No | Define the Apprise/Lametric mode to use. This can be either set to cloud or device . It's worth pointing out that Apprise is smart enough to detect the mode you're using based on the URL you provide it. But for those who want to explicitly provide it's value, they can do so. |
Send a LaMetric Time notification using Device Mode (local to our network):
# Assuming our {apikey} is abc123
# Assuming our {hostname} is 192.168.1.3
apprise -vv -t -b "Test Message Body" lametric://[email protected]
Send a LaMetric Time notification using Cloud Mode (using LaMetrics Developer API):
# Assuming our {client_id} is 12:23:45:64
# Assuming our {client_secret} is abcdefg==
apprise -vv -t -b "Test Message Body" lametric://12:23:45:64@abcdefg==