Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
indigo_2025.1_documentation:api [2026/02/01 19:37] – [Schedule Messaging] davel17indigo_2025.1_documentation:api [2026/03/23 12:52] (current) – [refresh folder server message] davel17
Line 97: Line 97:
 The WebSocket and HTTP APIs are designed to be familiar to those that have been using the legacy RESTful API. However, anyone with knowledge of Python, JavaScript or similar languages should be able to pick up the structure of the new APIs very quickly. To help those making the transition as well as those learning to use API calls for the first time, we've laid out several examples to show how API calls are made, as well as all the current API hooks available. The WebSocket and HTTP APIs are designed to be familiar to those that have been using the legacy RESTful API. However, anyone with knowledge of Python, JavaScript or similar languages should be able to pick up the structure of the new APIs very quickly. To help those making the transition as well as those learning to use API calls for the first time, we've laid out several examples to show how API calls are made, as well as all the current API hooks available.
  
-Here's a simple Python script to open the device-feed and print out any messages it receives (you'll need to ''**pip3 install websockets**'' before running it).+Here's a simple Python script to open the device-feed and print out any messages it receives (you'll need to ''**pip3 install websockets**'' before running it if it isn't already installed - Indigo installs it on the Indigo Server Mac so you won't need to install there).
  
 === Python Receiver Example === === Python Receiver Example ===
Line 784: Line 784:
 </code> </code>
  
-As of this release, this is the only way to get the current state of folders (there are not add/update/delete messages). If you think you need to refresh your folder list, then send the refresh message. Since folders are generally static, there really isn't much need to continually get the folder list.+As of this release, this is the only way to get the current state of folders (there are no add/update/delete messages). If you think you need to refresh your folder list, then send the refresh message. Since folders are generally static, there really isn't much need to continually get the folder list.
  
 ==== Log Feed ==== ==== Log Feed ====
Line 2303: Line 2303:
 ==== Schedule Messaging ==== ==== Schedule Messaging ====
  
-=== Action Group Objects ===+=== Schedule Objects ===
  
-You’ll receive full variable JSON objects which represent an Indigo triggerp instance. See the [[object_model_reference|Indigo Object Model]] docs for trigger details.+You’ll receive full variable JSON objects which represent an Indigo schedule instance. See the [[object_model_reference|Indigo Object Model]] docs for schedule details.
  
 <code json>{ <code json>{
-    "class": "indigo.Trigger", +  "class": "indigo.Schedule", 
-    "configured": true+  "absoluteDate": null
-    "description": "A trigger description."+  "absoluteDateTime": null
-    "enabled": true+  "absoluteTime": null
-    "folderId": 12345678+  "autoDelete": false
-    "globalProps": { +  "configured": true, 
-        "com.indigodomo.indigoserver": {}+  "dateType": 0
-        "com.indigodomo.webserver": +  "description": "", 
-            "httpMethod": "GET", +  "enabled": false
-            "postProcessing": "JSON"+  "folderId": 0
-            "webhookId": "8aa4b5140c5c473ea170465239143839" +  "globalProps": {}, 
-        }+  "id": 12345678, 
-        "emptyDict": {+  "name": "My Schedule Name", 
-    }, +  "nextExecution": null, 
-    "id": 12345678, +  "pluginProps": {}, 
-    "name": "My Trigger Name", +  "randomizeBy": 0, 
-    "pluginProps": {}, +  "remoteDisplay": true, 
-    "remoteDisplay": true, +  "sharedProps": {}, 
-    "sharedProps": {}, +  "sunDelta": 0, 
-    "suppressLogging": false+  "suppressLogging": false
 +  "timeType": 3
 } }
 </code> </code>
Line 2347: Line 2348:
 ''objectId'' is the id of the schedule. ''objectId'' is the id of the schedule.
  
-** enable **+** enable ** ''[[schedule_class#enable|indigo.schedule.enable(123456789)]]''
 <code json> <code json>
 { {
Line 2357: Line 2358:
 </code> </code>
  
 +
 +==== Trigger Messaging ====
 +
 +=== Trigger Objects ===
 +
 +You’ll receive full variable JSON objects which represent an Indigo trigger instance. See the [[object_model_reference|Indigo Object Model]] docs for trigger details.
 +
 +<code json>{
 +  "class": "indigo.Trigger",
 +  "configured": true,
 +  "description": "A trigger description.",
 +  "enabled": true,
 +  "folderId": 12345678,
 +  "globalProps": {
 +    "com.indigodomo.indigoserver": {},
 +    "com.indigodomo.webserver": {
 +      "httpMethod": "GET",
 +      "postProcessing": "JSON",
 +      "webhookId": "8aa4b5140c5c473ea170465239143839"
 +    },
 +    "emptyDict": {}
 +  },
 +  "id": 12345678,
 +  "name": "My Trigger Name",
 +  "pluginProps": {},
 +  "remoteDisplay": true,
 +  "sharedProps": {},
 +  "suppressLogging": false
 +}
 +</code>
  
 === Trigger Command Messages === === Trigger Command Messages ===
Line 2362: Line 2393:
 These are the available trigger commands. The ''id'' key is optional, but may contain a user generated ID that will be logged and returned to help match up with message requests. Custom ''id'' values should be strings. These are the available trigger commands. The ''id'' key is optional, but may contain a user generated ID that will be logged and returned to help match up with message requests. Custom ''id'' values should be strings.
  
-** execute **  ''[[schedule_class#execute|indigo.schedule.execute(123456789)]]''+** execute **  ''[[trigger_class#execute|indigo.trigger.execute(123456789)]]''
  
 <code json> <code json>
Line 2374: Line 2405:
 ''objectId'' is the id of the trigger. ''objectId'' is the id of the trigger.
  
-** enable **+** enable **   ''[[trigger_class#enable|indigo.trigger.enable(123456789)]]''
 <code json> <code json>
 { {
  • /www/perceptive/wiki/data/attic/indigo_2025.1_documentation/api.1769974631.txt.gz
  • Last modified: 2026/02/01 19:37
  • by davel17