{"openapi":"3.1.0","info":{"title":"SmartThings (BYOK) API","version":"0.1.0","description":"SmartThings (BYOK) lets an AI assistant read your own SmartThings devices and, with your approval of each change, change their state through the SmartThings API with a key you supply (SmartThings personal access token (a new token is valid for 24 hours; scopes: list devices, see devices, control devices)). Read tools plus 4 device-changing tools (switch_power, set_level, set_color,...\n\nMost operations are read-only. These change the state of a device and run only with confirm = \"yes\" after the user approved that change: switch_power, set_level, set_color, set_color_temperature. The same tools are available over MCP (streamable HTTP) at https://byok-smartthings-device-control.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-smartthings-device-control/docs"},"termsOfService":"https://connectorbay.com/byok-smartthings-device-control/terms"},"servers":[{"url":"https://byok-smartthings-device-control.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-smartthings-device-control/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_devices":{"post":{"operationId":"list_devices","summary":"List the devices you can access with name, label, maker, location, room, type and health state. Pairing keys and cipher ","description":"List the devices you can access with name, label, maker, location, room, type and health state. Pairing keys and cipher data are not returned. Use for \"Which SmartThings devices do I have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"location_id":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"description":"Only items in this location id.","title":"Location Id"},"capability":{"anyOf":[{"maxLength":80,"type":"string"},{"type":"null"}],"default":null,"description":"Only devices with this capability, for example switch or switchLevel.","title":"Capability"}},"title":"list_devicesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_device":{"post":{"operationId":"get_device","summary":"Get one device: name, label, maker, location, room, type and health state. Use for \"Show SmartThings device 6f1b3a5c\".","description":"Get one device: name, label, maker, location, room, type and health state. Use for \"Show SmartThings device 6f1b3a5c\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"}},"required":["device_id"],"title":"get_deviceArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_device_status":{"post":{"operationId":"get_device_status","summary":"Get the full current status of a device: the value of every capability attribute in each component, plus its health stat","description":"Get the full current status of a device: the value of every capability attribute in each component, plus its health state. Use for \"Is SmartThings device 6f1b3a5c on, and at what level\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"}},"required":["device_id"],"title":"get_device_statusArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_device_health":{"post":{"operationId":"get_device_health","summary":"Get whether a device is online or offline and when that last changed. Use for \"Is SmartThings device 6f1b3a5c online\".","description":"Get whether a device is online or offline and when that last changed. Use for \"Is SmartThings device 6f1b3a5c online\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"}},"required":["device_id"],"title":"get_device_healthArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_locations":{"post":{"operationId":"list_locations","summary":"List your locations (homes) with id and name. Use for \"Which SmartThings locations do I have\".","description":"List your locations (homes) with id and name. Use for \"Which SmartThings locations do I have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"limit":{"anyOf":[{"maximum":200,"minimum":1,"type":"integer"},{"type":"null"}],"default":50,"description":"How many locations to return.","title":"Limit"}},"title":"list_locationsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_rooms":{"post":{"operationId":"list_rooms","summary":"List the rooms of a location with id and name. Use for \"Which rooms are in my SmartThings home\".","description":"List the rooms of a location with id and name. Use for \"Which rooms are in my SmartThings home\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"location_id":{"description":"SmartThings location id (a UUID) from list_locations.","maxLength":64,"title":"Location Id","type":"string"}},"required":["location_id"],"title":"list_roomsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/switch_power":{"post":{"operationId":"switch_power","summary":"Turn a switch, plug or light on or off (the switch capability). Use only on lights, plugs and similar switchable devices","description":"Turn a switch, plug or light on or off (the switch capability). Use only on lights, plugs and similar switchable devices; never send it to a door, lock, garage opener, alarm or camera device. This changes the physical device. Use for \"Turn off the SmartThings desk lamp 6f1b3a5c\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"},"state":{"description":"on or off.","enum":["on","off"],"title":"State","type":"string"},"confirm":{"const":"yes","description":"Must be exactly yes, only after the user approved this change in chat.","title":"Confirm","type":"string"},"component":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":"main","description":"Device component to command; almost every device uses main.","title":"Component"}},"required":["device_id","state","confirm"],"title":"switch_powerArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":false,"x-changes-device-state":true,"x-requires-confirmation":"confirm"}},"/v1/tools/set_level":{"post":{"operationId":"set_level","summary":"Set the dimming level of a dimmable light or switch from 0 to 100 percent (the switchLevel capability). Use only on ligh","description":"Set the dimming level of a dimmable light or switch from 0 to 100 percent (the switchLevel capability). Use only on lights, plugs and similar switchable devices; never send it to a door, lock, garage opener, alarm or camera device. This changes the physical device. Use for \"Dim SmartThings light 6f1b3a5c to 40 percent\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"},"level":{"description":"Dimming level in percent, 0 to 100.","maximum":100,"minimum":0,"title":"Level","type":"integer"},"confirm":{"const":"yes","description":"Must be exactly yes, only after the user approved this change in chat.","title":"Confirm","type":"string"},"component":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":"main","description":"Device component to command; almost every device uses main.","title":"Component"}},"required":["device_id","level","confirm"],"title":"set_levelArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":false,"x-changes-device-state":true,"x-requires-confirmation":"confirm"}},"/v1/tools/set_color":{"post":{"operationId":"set_color","summary":"Set the color of a color light with hue and saturation, both 0 to 100 (the colorControl capability). Use only on lights,","description":"Set the color of a color light with hue and saturation, both 0 to 100 (the colorControl capability). Use only on lights, plugs and similar switchable devices; never send it to a door, lock, garage opener, alarm or camera device. This changes the physical device. Use for \"Make SmartThings light 6f1b3a5c blue\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"},"hue":{"description":"Hue in percent of the color wheel, 0 to 100 (about 66 is blue).","maximum":100,"minimum":0,"title":"Hue","type":"integer"},"saturation":{"description":"Saturation in percent, 0 to 100.","maximum":100,"minimum":0,"title":"Saturation","type":"integer"},"confirm":{"const":"yes","description":"Must be exactly yes, only after the user approved this change in chat.","title":"Confirm","type":"string"},"component":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":"main","description":"Device component to command; almost every device uses main.","title":"Component"}},"required":["device_id","hue","saturation","confirm"],"title":"set_colorArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":false,"x-changes-device-state":true,"x-requires-confirmation":"confirm"}},"/v1/tools/set_color_temperature":{"post":{"operationId":"set_color_temperature","summary":"Set the white color temperature of a tunable light in kelvin (the colorTemperature capability). Use only on lights, plug","description":"Set the white color temperature of a tunable light in kelvin (the colorTemperature capability). Use only on lights, plugs and similar switchable devices; never send it to a door, lock, garage opener, alarm or camera device. This changes the physical device. Use for \"Set SmartThings light 6f1b3a5c to warm white 2700 K\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"device_id":{"description":"SmartThings device id (a UUID) from list_devices.","maxLength":64,"title":"Device Id","type":"string"},"kelvin":{"description":"Color temperature in kelvin; the device accepts only its own supported range, typically 2200 to 6500.","maximum":30000,"minimum":1000,"title":"Kelvin","type":"integer"},"confirm":{"const":"yes","description":"Must be exactly yes, only after the user approved this change in chat.","title":"Confirm","type":"string"},"component":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":"main","description":"Device component to command; almost every device uses main.","title":"Component"}},"required":["device_id","kelvin","confirm"],"title":"set_color_temperatureArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":false,"x-changes-device-state":true,"x-requires-confirmation":"confirm"}}}}