Skip to main content

Webhook that runs scripts depending on the name

Project description

Webhook Actions

python Latest PyPI version Downloads Total alerts Language grade: Python

Webhook that runs scripts located in ~/webhook-actions/ directory.

How To Use

  1. Add scripts into webhook-actions. These can be in sub-directories
  2. Call the URL http://localhost:5000/your-script-name

Simple example

  • URL: http://localhost:5000/log-stat
  • Body: something
  • Command: ~/webhook-actions/log-stat something

Example with subdirectories

  • URL: https://YOUR_DOMAIM.com/git/your-project/deploy
  • Body: {"tag": "1.0.1"}
  • Command: ~/webhook-actions/git/your-project/deploy "{\"tag\": \"1.0.1\"}"

Example config file

The config file is located at ~/.webhook-actions.cgf. When you run the script the first time it will create a default configuration.

[General]
# Port to listen to
Port = 5000

Authors

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

webhook-actions-0.2.1.tar.gz (9.2 kB view hashes)

Uploaded Source

Built Distribution

webhook_actions-0.2.1-py3-none-any.whl (11.3 kB view hashes)

Uploaded Python 3

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