Skip to main content

Python agent for TRIGGERcmd cloud service.

Project description

TRIGGERcmd Python Package

For the full TRIGGERcmd agent, visit https://triggercmd.com.

Use this package to listen for triggers sent to a computer in your TRIGGERcmd account.

Send triggers with Amazon Alexa, Google Assistant, IFTTT, Zapier, Smart Things, etc. See this page for more ways.

Usage:

import json
from triggercmd import agent

computer_id = (your triggercmd computer id)
token = (your triggercmd token)

def my_function(msg):
    print(msg)
    message = json.loads(msg)
    print("Received this trigger:", message['trigger'])

agent.connect(computer_id, token, my_function)

Example output:

Connected
{"trigger":"Calculator","id":"13123391234567891acbf123"}
Received this trigger: Calculator
{"trigger":"Notepad","id":"13123391234567891acbf124"}
Received this trigger: Notepad

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

triggercmd-0.0.17.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

triggercmd-0.0.17-py3-none-any.whl (4.4 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