Skip to content

pH-T/telelog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telelog - Log via Telegram

Sends your log to your Telegram account. Uses the Telegram Bot API.

Setup

  • Create a Bot (and get its token), see https://core.telegram.org/bots
  • Start chatting with the bot (and actually send something - needed for the next step)
  • To get the CHAT_ID send the following request: curl https://api.telegram.org/bot<TOKEN>/getUpdates

Usage

logger := telelog.NewTelelog("TOKEN", "CHAT_ID") // os.Getenv("TOKEN")
logger.LogError("Here is some text")
logger.LogAlert("Here is some text")
logger.LogInfo("Here is some text")
logger.LogSuccess("Here is some text")

About

Telelog - Log via Telegram

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages