Skip to content

Instantly share code, notes, and snippets.

@yzdann
Created August 21, 2019 15:16
Show Gist options
  • Save yzdann/6f93e691f261864f173be8de2d0b20fe to your computer and use it in GitHub Desktop.
Save yzdann/6f93e691f261864f173be8de2d0b20fe to your computer and use it in GitHub Desktop.
#!/bin/bash
ADDRESS='localhost'
PORT='5555'
STATE='SUCCESS'
LIMIT='1'
status=$(curl -s "$ADDRESS:$PORT/api/tasks?state=$STATE&limit=$LIMIT" | jq ".[].uuid")
if [ ! -z "$status" ];
then
echo 'send telegram message'
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment