API Method: StartActionByGet
This is the method that allows you to specify the action ID in the URL, and is probably the best to do quick integrations - QR Codes, streamdeck, etc. You cannot pass arguments using this method.
-
HTTP Method:
GET
-
Request Type: Action ID in the URL
-
Response Type: Execution Tracking ID
There are 4 main methods to start an action in OliveTin, which can be used in scripts or other applications. These methods allow you to trigger actions either immediately or wait for them to complete, and they can be accessed via HTTP requests.
Function | HTTP Method | Request Type (How to select an action) | Response Type |
---|---|---|---|
POST |
|||
GET |
|||
POST |
|||
GET |
Example API call; Start an action by ID in the URL
user@host: curl http://olivetin.example.com/api/StartActionByGet/pingGithub
The corresponding config.yaml would look like this;
actions:
- title: Ping GitHub.com
id: pingGithub
shell: ping github.com -c 1
IDs are used by these API calls, as you probably want the interface to display a human-readable title, whereas the API call doesn’t want to have spaces or punctuation.