Skip to main content

This Airflow plugin creates a Zenduty Alert when it is run.

Project description

Airflow Plugin - Zenduty

This plugin creates a Zenduty Alert when plugin is run.

Operators

ZendutyIncidentOperator

This operator composes the logic for this plugin. It generates an Incident on Zenduty by sending an Alert to Zenduty. It accepts the following parameters:

  • api_key: API Key generated by Zenduty (Required).
  • integration_id: The Integration_id generated by the API Integration (Required).
  • title: Title of the incident that is to be created.
  • summary: Summary for the incident to be created.

Requirements

This plugin requires the zenduty-api python package.

Example Failure Callback Usage

from airflow.models import DAG, Variable
from airflow.operators.bash_operator import BashOperator
from zenduty_airflow_operator import ZendutyIncidentOperator

my_test_dag = DAG('example')

op = BashOperator(
    dag=my_test_dag,
    task_id='my_task',
    provide_context=True,
    python_callable=my_python_job,
    on_failure_callback=zenduty_incident
)
    
def zenduty_incident():

    operator = ZendutyIncidentOperator(
        api_key=Variable.get("api_key"),
        integration_id=Variable.get("integration_id"),
        title="Test Title",
        summary="Test Summary"
    )

    return operator.execute()

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

zenduty_airflow_operator-0.1.2.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

zenduty_airflow_operator-0.1.2-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file zenduty_airflow_operator-0.1.2.tar.gz.

File metadata

  • Download URL: zenduty_airflow_operator-0.1.2.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for zenduty_airflow_operator-0.1.2.tar.gz
Algorithm Hash digest
SHA256 5c311ab22770284eea2a0259a5911149174d142520d2fab4140b2a287e03f58f
MD5 2a9348da7197015c253b717705c5c794
BLAKE2b-256 a2c59a3f65973f8100c54833356c5732b2a6f13708c7896a1ac51d9045962652

See more details on using hashes here.

File details

Details for the file zenduty_airflow_operator-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: zenduty_airflow_operator-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9

File hashes

Hashes for zenduty_airflow_operator-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9bf007a4654fe12eadea00c206a16eded8a9645491c9a67aad0ab1e952bd557f
MD5 e753b6d6154f7b45ff9833bfb81dfd7b
BLAKE2b-256 fd782c406e08201612687a14da6aed13a0d71db942ddae256b7f6b650ae62e1e

See more details on using hashes here.

Supported by

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