{
  "schemaVersion": "1.0",
  "item": {
    "slug": "switchbot",
    "name": "SwitchBot Smart Home Control",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/dAAAb/switchbot",
    "canonicalUrl": "https://clawhub.ai/dAAAb/switchbot",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/switchbot",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=switchbot",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "scripts/switchbot.py"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "slug": "switchbot",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-09T15:06:52.481Z",
      "expiresAt": "2026-05-16T15:06:52.481Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=switchbot",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=switchbot",
        "contentDisposition": "attachment; filename=\"switchbot-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "switchbot"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/switchbot"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/switchbot",
    "agentPageUrl": "https://openagent3.xyz/skills/switchbot/agent",
    "manifestUrl": "https://openagent3.xyz/skills/switchbot/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/switchbot/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "SwitchBot Smart Home Control",
        "body": "Control SwitchBot devices through the Cloud API v1.1."
      },
      {
        "title": "First-Time Setup",
        "body": "Guide your human through these steps:"
      },
      {
        "title": "1. Get API Credentials",
        "body": "Ask your human to:\n\nOpen SwitchBot App on their phone\nGo to Profile (bottom right)\nTap Preferences (or Settings)\nFind About → Developer Options\nCopy Token and Secret Key"
      },
      {
        "title": "2. Store Credentials Securely",
        "body": "mkdir -p ~/.config/switchbot\nchmod 700 ~/.config/switchbot\n\ncat > ~/.config/switchbot/credentials.json << 'EOF'\n{\n  \"token\": \"YOUR_TOKEN_HERE\",\n  \"secret\": \"YOUR_SECRET_HERE\"\n}\nEOF\nchmod 600 ~/.config/switchbot/credentials.json"
      },
      {
        "title": "3. Discover Devices",
        "body": "Run the discovery script to find all devices:\n\npython3 <skill_path>/scripts/switchbot.py list"
      },
      {
        "title": "4. Update Your TOOLS.md",
        "body": "After discovery, note your device IDs in TOOLS.md for quick reference:\n\n## SwitchBot Devices\n| Device | ID | Type |\n|--------|-----|------|\n| Living Room Curtain | ABC123 | Curtain3 |\n| Bedroom Light | DEF456 | Plug Mini |"
      },
      {
        "title": "List All Devices",
        "body": "python3 <skill_path>/scripts/switchbot.py list"
      },
      {
        "title": "Curtain Control",
        "body": "# Open curtain (position 0 = fully open)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> open\n\n# Close curtain (position 100 = fully closed)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> close\n\n# Set specific position (0-100)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> 50"
      },
      {
        "title": "Plug/Light Control",
        "body": "python3 <skill_path>/scripts/switchbot.py plug <device_id> on\npython3 <skill_path>/scripts/switchbot.py plug <device_id> off"
      },
      {
        "title": "Check Sensor Status",
        "body": "python3 <skill_path>/scripts/switchbot.py status <device_id>"
      },
      {
        "title": "Generic Command",
        "body": "python3 <skill_path>/scripts/switchbot.py command <device_id> <command> [parameter]"
      },
      {
        "title": "Supported Devices",
        "body": "Device TypeCommandsCurtain / Curtain3open, close, setPositionPlug Mini / PlugturnOn, turnOff, toggleBotpress, turnOn, turnOffLight / Strip LightturnOn, turnOff, setBrightness, setColorLocklock, unlockHumidifierturnOn, turnOff, setModeMeter / MeterPlus(read-only: temperature, humidity)Hub / Hub Mini / Hub 2(gateway only)"
      },
      {
        "title": "Error Handling",
        "body": "Status CodeMeaning100Success151Device offline152Command not supported160Unknown command161Invalid parameters190Internal error"
      },
      {
        "title": "Tips for Agents",
        "body": "First interaction: If no credentials exist, guide the human through setup\nDevice aliases: Create friendly names in TOOLS.md (e.g., \"living room\" → device ID)\nBatch operations: Multiple devices can be controlled in sequence\nStatus checks: Use status command before reporting sensor readings\nError recovery: If device is offline (151), suggest checking Hub connection"
      },
      {
        "title": "Security Notes",
        "body": "Credentials file should be chmod 600\nNever log or display the token/secret\nAPI calls are made over HTTPS to api.switch-bot.com"
      }
    ],
    "body": "SwitchBot Smart Home Control\n\nControl SwitchBot devices through the Cloud API v1.1.\n\nFirst-Time Setup\n\nGuide your human through these steps:\n\n1. Get API Credentials\n\nAsk your human to:\n\nOpen SwitchBot App on their phone\nGo to Profile (bottom right)\nTap Preferences (or Settings)\nFind About → Developer Options\nCopy Token and Secret Key\n2. Store Credentials Securely\nmkdir -p ~/.config/switchbot\nchmod 700 ~/.config/switchbot\n\ncat > ~/.config/switchbot/credentials.json << 'EOF'\n{\n  \"token\": \"YOUR_TOKEN_HERE\",\n  \"secret\": \"YOUR_SECRET_HERE\"\n}\nEOF\nchmod 600 ~/.config/switchbot/credentials.json\n\n3. Discover Devices\n\nRun the discovery script to find all devices:\n\npython3 <skill_path>/scripts/switchbot.py list\n\n4. Update Your TOOLS.md\n\nAfter discovery, note your device IDs in TOOLS.md for quick reference:\n\n## SwitchBot Devices\n| Device | ID | Type |\n|--------|-----|------|\n| Living Room Curtain | ABC123 | Curtain3 |\n| Bedroom Light | DEF456 | Plug Mini |\n\nUsage\nList All Devices\npython3 <skill_path>/scripts/switchbot.py list\n\nCurtain Control\n# Open curtain (position 0 = fully open)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> open\n\n# Close curtain (position 100 = fully closed)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> close\n\n# Set specific position (0-100)\npython3 <skill_path>/scripts/switchbot.py curtain <device_id> 50\n\nPlug/Light Control\npython3 <skill_path>/scripts/switchbot.py plug <device_id> on\npython3 <skill_path>/scripts/switchbot.py plug <device_id> off\n\nCheck Sensor Status\npython3 <skill_path>/scripts/switchbot.py status <device_id>\n\nGeneric Command\npython3 <skill_path>/scripts/switchbot.py command <device_id> <command> [parameter]\n\nSupported Devices\nDevice Type\tCommands\nCurtain / Curtain3\topen, close, setPosition\nPlug Mini / Plug\tturnOn, turnOff, toggle\nBot\tpress, turnOn, turnOff\nLight / Strip Light\tturnOn, turnOff, setBrightness, setColor\nLock\tlock, unlock\nHumidifier\tturnOn, turnOff, setMode\nMeter / MeterPlus\t(read-only: temperature, humidity)\nHub / Hub Mini / Hub 2\t(gateway only)\nError Handling\nStatus Code\tMeaning\n100\tSuccess\n151\tDevice offline\n152\tCommand not supported\n160\tUnknown command\n161\tInvalid parameters\n190\tInternal error\nTips for Agents\nFirst interaction: If no credentials exist, guide the human through setup\nDevice aliases: Create friendly names in TOOLS.md (e.g., \"living room\" → device ID)\nBatch operations: Multiple devices can be controlled in sequence\nStatus checks: Use status command before reporting sensor readings\nError recovery: If device is offline (151), suggest checking Hub connection\nSecurity Notes\nCredentials file should be chmod 600\nNever log or display the token/secret\nAPI calls are made over HTTPS to api.switch-bot.com"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/dAAAb/switchbot",
    "publisherUrl": "https://clawhub.ai/dAAAb/switchbot",
    "owner": "dAAAb",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/switchbot",
    "downloadUrl": "https://openagent3.xyz/downloads/switchbot",
    "agentUrl": "https://openagent3.xyz/skills/switchbot/agent",
    "manifestUrl": "https://openagent3.xyz/skills/switchbot/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/switchbot/agent.md"
  }
}