Skip to content

Notify v0.1.0

Choose a tag to compare

@seakee seakee released this 13 Aug 02:55
· 5 commits to main since this release

Release Highlights

  • Initial release of the Notify package
  • Unified interface for managing multiple notification channels
  • Support for Lark, DingTalk, WeChat, Email, Telegram, and Bark notifications
  • Configurable default channel and notification level
  • Message ID generation for tracking
  • Asynchronous message processing with graceful shutdown

Features

  • Multiple notification channels:
    • Lark
    • DingTalk
    • WeChat
    • Email
    • Telegram
    • Bark
  • Four notification levels: Info, Success, Error, and Warning
  • Flexible configuration options for each channel
  • Easy-to-use methods for sending notifications
  • Concurrent processing of notifications

Installation

go get github.com/sk-pkg/notify@v0.1.0

Quick Start

import "github.com/sk-pkg/notify"

manager, err := notify.New(
    notify.OptLarkConfig(lark.Config{Enabled: true}),
    notify.OptDefaultChannel(notify.LarkChan),
    notify.OptDefaultLevel(notify.InfoLevel),
)
if err != nil {
    // Handle error
}

msgID, err := manager.Info("recipient", "Hello", "World")
if err != nil {
    // Handle error
}

// Don't forget to close when done
defer manager.Close()

Documentation

For detailed usage and configuration options, please refer to the main README.

For Lark-specific documentation, see the Lark README.

License

This package is governed by a MIT style license. See the LICENSE file for details.

Feedback and Contributions

We welcome your feedback and contributions. Please open an issue or submit a pull request on our GitHub repository.