Send log messages to sendinblue's transactional email service.
Project description
Description
This is a logging handler for Python's logging module to send log messages over sendinblue's transactional email service.
Installation
$ pip install sendinblue-logger
Usage
import sblue
import logging
import os
handler = sblue.LoggingHandler(
level=logging.ERROR,
api_key=os.getenv('SENDINBLUE_API_KEY'),
from_email='sender-email@domain.com',
to_email='recipient-email@domain.com',
)
logging.basicConfig(
filename='/home/user/project/project.log',
encoding='utf-8',
level=logging.DEBUG,
format='%(asctime)s - %(levelname)s: %(message)s',
handlers=(handler,)
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sendinblue-logger-1.0.0.tar.gz.
File metadata
- Download URL: sendinblue-logger-1.0.0.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.14 CPython/3.9.13 Darwin/19.6.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
de9a64a5a7ff4f6bdbebb4a1644f1f80551e44bcc51c39281371c866f3bfd2b7
|
|
| MD5 |
7ffceeac976429dee317e037b26efa3a
|
|
| BLAKE2b-256 |
5fbe16a706984ce27aeefe798914b700b726f134adf2b9a58d0a9ef646fc8804
|
File details
Details for the file sendinblue_logger-1.0.0-py3-none-any.whl.
File metadata
- Download URL: sendinblue_logger-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.14 CPython/3.9.13 Darwin/19.6.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6f6d0f6c122c4a01c483945935e0aebe5ca8b55cdad502c94cbc09f6d0757c87
|
|
| MD5 |
2f78ae02b02c64385452a94e6e3d13ba
|
|
| BLAKE2b-256 |
ba1a6b2c3a2b2e765f2875e07386cf7f942c99b27714997afc184e64b32c9d8c
|