1.0.1 • Published 3 years ago

@njam-data/slack-data-pipeline-monitor v1.0.1

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

slack-data-pipeline-monitor

A slack app for sending messages about our data pipeline processes to a slack channel.

Install

Install with npm:

npm install @njam-data/slack-data-pipeline-monitor

Usage

import { DataPipelineMonitor } from '@njam-data/slack-data-pipeline-monitor'

const monitor = new DataPipelineMonitor({
  url: 'your slack incoming webhook url'
})

// Send a basic message
await monitor.info({
  text: 'test',
  url: 'https://example.com'
})

// Announce a successful data download
await monitor.dataDownloaded({
  text: 'test',
  dataUrl: 'http://example.com',
  sourceUrl: 'http://example.com'
})

// Send a warning message
await monitor.warning({
  text: 'test',
  url: 'http://example.com'
})

// Send an error message, which notifies @here in the channel
await monitor.error({
  text: 'test',
  url: 'http://example.com'
})
1.0.1

3 years ago

1.0.0

3 years ago