Compare commits

...

2 Commits

2 changed files with 19 additions and 2 deletions

4
bot.sh
View File

@@ -121,8 +121,8 @@ $current_weather
################################################################################# #################################################################################
echo Uploading to Telegram echo Uploading to Telegram
curl -X POST https://api.telegram.org/bot$TG_BOT_API_KEY/sendPhoto \ curl -X POST https://api.telegram.org/bot$TG_BOT_TOKEN/sendPhoto \
-F chat_id=$TG_CHANNEL_ID \ -F chat_id=$TG_CHATID \
-F photo=@$image \ -F photo=@$image \
-F caption="$caption" \ -F caption="$caption" \
-F parse_mode=Markdown >> /dev/null -F parse_mode=Markdown >> /dev/null

17
env.example Normal file
View File

@@ -0,0 +1,17 @@
# Your Telegram Bot API Token, Contact @BotFather on Telegram to obtain token
TG_BOT_TOKEN=''
# Your Telegram chat ID, This could be your user, group, supergroup or channel ID
# add "-100" first if supergroup or channel
TG_CHATID=''
# accepted units: s (seconds), m (minutes), h (hours), d (days), ms (milliseconds)
# Example: DELAY=10m
DELAY=30m
# Exmaple: RTSP_URL=rtsp://usernams:password@ipaddress:port/streampath
RTSP_URL=rtsp://
# Use some maps service to fetch this, this is used to fetch weather from API. (Default is Male', Maldives)
LATITUDE="4.1752"
LONGITUDE="73.5092"