From 2171ba4651d82419574de925e4d8e29c895a939b Mon Sep 17 00:00:00 2001 From: Chris Caron Date: Sat, 9 Sep 2023 14:12:14 -0400 Subject: [PATCH] Updated Notify_Custom_JSON (markdown) --- Notify_Custom_JSON.md | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/Notify_Custom_JSON.md b/Notify_Custom_JSON.md index 088313f..f645c3d 100644 --- a/Notify_Custom_JSON.md +++ b/Notify_Custom_JSON.md @@ -76,6 +76,44 @@ The above would post a message such as: } ``` +You can also clear entries from showing by setting their values to being empty: +```bash +# Clear version and type from the payload: +# Assuming our {hostname} is localhost +# Assuming we want to clear both version and type from the output: +apprise -vv -t "Test Message Title" -b "Test Message Body" \ + "json://localhost/?:version&:type" +``` + +The above would post a message such as: +```json +{ + "title": "Test Message Title", + "message": "Test Message Body" +} +``` + +Finally, you can re-map values such as having the message go into a `body` tag instead: +```bash +# Add to the payload delivered to the remote server as if it was part +# the prepared message Apprise would have otherwise put together +# +# Assuming our {hostname} is localhost +# Assuming we want to remap the message section to body: +apprise -vv -t "Test Message Title" -b "Test Message Body" \ + "json://localhost/?:message=body" +``` + +The above would post a message such as: +```json +{ + "version": "1.0", + "title": "Test Message Title", + "body": "Test Message Body", + "type": "info" +} +``` + ### Header Manipulation Some users may require special HTTP headers to be present when they post their data to their server. This can be accomplished by just sticking a plus symbol (**+**) in front of any parameter you specify on your URL string. ```bash