Schema - SmartThingsCommunity/smartthings-core-sdk GitHub Wiki

The SmartThings Schema is a specification for use in a cloud-connected device integration. It does not require using the SmartThings API.

SmartThings Schema recognizes three interaction types.

  • Discovery: Return a list of devices.
  • State Refresh: Return the state of the devices.
  • Command: Issue commands to the device.

Functions

Note: The list of functions can be found here.

  • list - Returns a list of all ST Schema C2C connectors belonging to the user.

  • get - Returns a specific ST schema connector. Requires the id of the "endpointApp" UUID of the connector, e.g. "viper_799ff3a0-8249-11e9-9bf1-b5c7d651c2c3"

  • create - Create an ST Schema connector. Requires a data definition of the connector.

  • update - Update an ST Schema conector. Requires the id of the "endpointApp" UUID of the connector, e.g. "viper_799ff3a0-8249-11e9-9bf1-b5c7d651c2c3" and the data definition of the connector.

  • delete - Delete an ST Schema connector. Requires the id of the "endpointApp" UUID of the connector, e.g. "viper_799ff3a0-8249-11e9-9bf1-b5c7d651c2c3"

  • installedApps - Returns a list of the installed ST Schema connector instances in the specified location. Requires the locationId UUD of the location.

  • getInstalledApps - Returns a specific installed instance of an ST Schema connector. The returned object includes a list of the devices created by the instance. Requires the UUID of the installed app instance.

  • deleteInstalledApp - Deletes a specific installed instance of an ST Schema connector. This operation will also delete all devices created by the instance. Requires id of the connector to be deleted.