Skip to main content

Python wrapper for the API Alerts service

Project description

API Alerts - Python

APIAlerts require the use of API Keys to integrate with your projects.

Copy your API Key from the projects page in the mobile app.

Get the App

Links

Installation

pip install apialerts==1.0.3

Sample usage

from apialerts import ApiAlerts, AlertRequest

def alerts_basic():
    # Create the ApiAlerts instance
    alerts = ApiAlerts()
    # Construct your message
    data = AlertRequest(
        message='Payment Received $10'
    )
    # Send alert to you project via your API Key
    alerts.send(data, 'PROJECT_API_KEY')

Advanced usage

from apialerts import ApiAlerts, AlertRequest

def alerts_advanced():
    alerts = ApiAlerts()
    # Set a default project API Key and enable logging
    alerts.configure('DEFAULT_API_KEY', True)
    # Construct your alert with additional tags and a link
    data = AlertRequest(
        message='Payment Received $10',
        tags=['Growth', 'Promotion'],
        link='https://apialerts.com'
    )
    # Send alert to default project specified in configure()
    alerts.send(data)
    # Or, send alert to an alternate project
    alerts.send(data, 'ALTERNATE_API_KEY')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

apialerts-1.0.3.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

apialerts-1.0.3-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

Details for the file apialerts-1.0.3.tar.gz.

File metadata

  • Download URL: apialerts-1.0.3.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for apialerts-1.0.3.tar.gz
Algorithm Hash digest
SHA256 1b098b9c7a18a0e698edef44164311dcd77d5d020d769aa0326794c1eb0d6afe
MD5 8aa8b75be7d6739f1e03502945481dd5
BLAKE2b-256 936c4248f804e92f25b04468e5578712cbec887a2e7f34904e0e6aa6cf7a8a5a

See more details on using hashes here.

File details

Details for the file apialerts-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: apialerts-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 4.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for apialerts-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 33f0c2b7ca5b55a872f0701596a787b1997128737f6b7f06c5b5efdedac29654
MD5 0057ed951a21578fb9f0d2038be38860
BLAKE2b-256 61592db1a5bbb180c9668ef7f70e01dca27424370f2c81fab3e0dcade1763b4c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page