Skip to main content
Glama
Buggy1111

shelly-mcp

by Buggy1111

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
SHELLY_CLOUD_AUTH_KEYNoAuth key for Shelly Cloud (optional, for cloud fallback)

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tasks
{
  "list": {},
  "cancel": {},
  "requests": {
    "tools": {
      "call": {}
    },
    "prompts": {
      "get": {}
    },
    "resources": {
      "read": {}
    }
  }
}
tools
{
  "listChanged": true
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
shelly_switch_setA

Turn a switch/relay channel on or off (optionally auto-revert after N seconds).

Returns the post-action ChannelState. Audit-logged.

shelly_switch_toggleB

Toggle a switch/relay channel. Returns the post-action ChannelState. Audit-logged.

shelly_light_setA

Set a light/dimmer/RGB(W)/CCT channel (Gen1 /color,/light ↔ Gen2 Light/RGB/RGBW/CCT.Set).

Only the provided fields are changed. brightness 0-100, rgb three 0-255 values, temp_k white colour temperature. Returns the post-action LightState. Audit-logged.

shelly_cover_moveA

Move a roller/cover: action is open|close|stop, or pass position (0-100) to go to it.

Returns the post-action CoverState. Audit-logged.

shelly_energy_liveA

Live power/energy per channel: power_w, voltage, current, pf, freq, totals.

None where a device can't report it (e.g. Gen1 plugs have no voltage/current). Pass channel to narrow to one. Safe, read-only.

shelly_energy_historyA

Best-effort energy history: lifetime totals plus any per-minute series the device exposes in its status; notes when richer history needs a local connection.

Detailed historical queries (Pro 3EM EMData/CSV, Gen1 em_data.csv) land with the local backends (M2) — over cloud only totals + recent by-minute are available.

shelly_rpcA

Call any read-only RPC method (*.Get*/*.List*/*.Check*) on a device.

Mutating methods are refused here — use shelly_rpc_write. The method name is classified server-side; unknown methods are treated as writes and rejected.

shelly_rpc_writeA

Call any mutating RPC method. Requires confirm:true; audit-logged.

Read methods are rejected (use shelly_rpc). Destructive methods (factory reset, wipe-all, reset-wifi) need a second gate: params.i_understand_data_loss = true.

shelly_list_methodsA

List the RPC methods a device supports (Gen2+ Shelly.ListMethods).

Returns an actionable error on Gen1/cloud where the device can't enumerate methods.

shelly_kvs_listA

List KVS keys (with their etags). match is a wildcard pattern (default all).

shelly_kvs_getB

Get one KVS value (with its etag) by key.

shelly_kvs_setA

Set a KVS key to a JSON value. Audit-logged.

shelly_kvs_deleteA

Delete a KVS key. Requires confirm:true. Audit-logged.

shelly_versionA

Return the shelly-mcp server version (health check).

shelly_discoverA

Discover Shelly devices on the LAN via mDNS, merged with the cloud account list.

timeout_s is the mDNS browse window. Set use_cloud=false to skip the cloud list (LAN-only). Safe, read-only; returns lightweight identities (probe for detail).

shelly_list_devicesA

List every Shelly device known to this server (configured + cloud account).

Safe, read-only. Returns each device's canonical identity (id, name, generation, model, online state) — the starting point before any status or control call.

shelly_get_infoA

Identify one device (generation, model, firmware, online state, capabilities).

device is a device id or a configured name. Safe, read-only.

shelly_get_statusA

Get a device's normalized live status (Gen1/Gen2/Cloud folded into one shape).

Returns canonical channels/lights/covers plus the raw per-generation payload. Pass component (e.g. "switch:0") to narrow to a single component. Safe, read-only.

shelly_list_componentsA

List the component keys present on a device (e.g. ['switch:0', 'input:0']).

Safe, read-only. Use this to discover what a specific device exposes before reading status or controlling it.

shelly_get_configB

Get a device's configuration, with credential fields masked as *** (Gen1 /settings returns Wi-Fi/MQTT secrets in the clear — they must not reach the model). Local-first — the Shelly Cloud API can't expose config, so this returns an actionable error for cloud-only devices.

shelly_scene_listA

List defined scenes (name, description, action count). Read-only.

shelly_scene_getB

Show a scene's full definition (its ordered actions). Read-only.

shelly_scene_createA

Define (save) a named scene from an ordered list of {device, method, params}.

Every method must be a non-destructive mutating method; every device must be known. Fails if the name already exists unless overwrite=true. Prefer absolute Set methods over Toggle so the scene is safe to run twice (you'll get a warning otherwise).

shelly_scene_runA

Run a named scene: attempt every action in order, report per-action results.

Best-effort and sequential — a failing action does not abort the rest. status is ok (all succeeded), partial (some failed), or failed (none succeeded). A partial run can simply be re-run later to finish it (scenes use absolute states, so re-running is safe). Every action is audit-logged.

shelly_scene_deleteA

Delete a named scene. Requires confirm:true.

shelly_schedule_listA

List the schedules configured on a device. Local-only (cloud can't manage schedules).

shelly_schedule_createA

Create a schedule: timespec 6-field cron, calls list of {method, params}.

Validates the timespec, the ≤20-per-device limit, and each call's method. Audit-logged.

shelly_schedule_updateC

Update fields of an existing schedule by id. Audit-logged.

shelly_schedule_deleteA

Delete a schedule by id. Requires confirm:true. Audit-logged.

shelly_script_listA

List scripts on a device (id, name, enable, running). Local-only.

shelly_script_get_codeA

Get a script's full source, reassembling the device's paginated GetCode.

shelly_script_createB

Create an empty script (optionally named). Returns its id. Audit-logged.

Use shelly_script_put_code to give it code (that step is confirm-gated).

shelly_script_put_codeA

Upload code into a script (chunked). Arbitrary code on the deviceconfirm:true.

append=false replaces the script body; true appends. Large code is split into ≤1 KB chunks automatically. Audit-logged.

shelly_script_startB

Start a script by id. Returns was_running. Audit-logged.

shelly_script_stopB

Stop a script by id. Returns was_running. Audit-logged.

shelly_script_evalA

Evaluate an expression inside a running script. Arbitrary codeconfirm:true.

Returns the stringified result. Audit-logged.

shelly_script_deleteA

Delete a script by id. Requires confirm:true. Audit-logged.

shelly_system_rebootB

Reboot a device. Requires confirm:true. Audit-logged.

shelly_system_updateA

Trigger a firmware update (channel = stable|beta). Requires confirm:true.

shelly_system_set_authA

Enable/rotate the device login password (≥12 chars). Requires confirm:true.

The password is write-only — never returned, and redacted in the audit log.

shelly_virtual_listB

List the device's virtual (dynamic) components via Shelly.GetComponents.

shelly_virtual_addA

Add a virtual component of type (boolean/number/text/enum/button/group).

Optional config and id (200-299). Returns the new component id. Audit-logged.

shelly_virtual_deleteA

Delete a virtual component by key (<type>:<cid>). Requires confirm:true.

shelly_webhook_listB

List webhooks configured on a device. Local-only.

shelly_webhook_createA

Create a webhook: event (e.g. 'switch.on'), cid component id, urls 1-5.

Optional condition (JS expression) and repeat_period (seconds; 0=always, negative=once). Audit-logged.

shelly_webhook_updateB

Update fields of an existing webhook by id. Audit-logged.

shelly_webhook_deleteA

Delete a webhook by id. Requires confirm:true. Audit-logged.

Prompts

Interactive templates invoked by user choice

NameDescription
shelly_evening_sceneWorkflow: dim configured lights to warm-white and turn plugs off for the evening.
shelly_energy_reportWorkflow: summarize today's power/energy across the fleet.
shelly_diagnoseWorkflow: health-check every device (online, firmware, error fields).

Resources

Contextual data attached and managed by the client

NameDescription
devices_resourceThe current device fleet (identities + online state) as ambient context.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Buggy1111/shelly-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server