Skip to content

adig/mailgun-events-slack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mailgun-events-slack

Simple nodejs app that polls for Events (Logs) from Mailgun API and sends them as messages to Slack channel using the Incoming Webhooks API

Running

Define following NODE_ENV parameters and run app by calling yarn run.

  • MAILGUN_DOMAIN Mailgun domain name to use for polling for events
  • MAILGUN_API_KEY Mailgun private API key
  • SLACK_WEBHOOK_URL Webhook url created for your slack domain and channel, see Documentation

Config

Allows you to configure Mailgun query options and customize slack message colors. Change the values from config.json:

  • filter Query to pass to Mailgun events request. begin and end values will be ignored and created at rutime. See Mailgun API reference
  • colors Color to use for slack attachments based on Mailgun Event Type
  • polling_time Value in seconds to wait between polling calls. Each call will ask for events between timestamp of last fetched result or polling_time ago, and the next one will happen after polling_time has passed once the results are processed (sent to Slack).

Dependencies

About

Simple nodejs app that reads events(logs) from mailgun and sends them to Slack

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors