Skip to main content
Glama
madhukeshm

LG Washer MCP Server

by madhukeshm

LG 洗衣机 MCP 服务器

一个 MCP 服务器,让 AI 助手能够通过 LG 官方的 ThinQ Connect API 监控和控制 LG ThinQ 洗衣机。

它直接通过 HTTP 与 REST API 通信(不使用 LG SDK)。您的**个人访问令牌(PAT)**用作 Bearer 令牌。

API 的工作原理(简版)

  • 认证Authorization: Bearer <PAT>。无需 OAuth 流程。

  • 区域:您的国家代码决定服务器。印度(IN)→ https://api-kic.lgthinq.com

  • 每个请求还会发送 x-countryx-client-id(您选择的 UUID4)、x-api-key(公钥)、x-message-id(每次请求新生成)、x-service-phase: OP

  • 端点GET /devicesGET /devices/{id}/profileGET /devices/{id}/statePOST /devices/{id}/control

暴露的工具

工具

功能

list_devices

找到您洗衣机的 deviceId

get_washer_profile

查看您的型号的可控属性/值。

get_washer_status

实时状态:是否在运行?、周期、剩余时间。

control_washer

START / STOP / WAKE_UP

control_washer_raw

发送任意控制 JSON,用于特定型号的属性。

⚠️ 大多数 LG 洗衣机只有在机器物理上设置为“远程启动”且已加载周期时,才接受远程 START。API 会恢复/启动预先选定的周期;它通常无法从头开始选择洗涤程序。

设置

uv sync
cp .env.example .env   # then edit .env with your PAT

运行

配置从环境变量(THINQ_PATTHINQ_COUNTRYTHINQ_CLIENT_ID)读取。服务器通过 stdio 使用 MCP 协议通信。

THINQ_PAT=xxx THINQ_COUNTRY=IN uv run washer-mcp

接入 Claude Desktop / Claude Code

添加到您的 MCP 配置中(例如 claude_desktop_config.json):

{
  "mcpServers": {
    "lg-washer": {
      "command": "uv",
      "args": ["--directory", "/Users/sushmanagaraj/c_drive/Coding/LG", "run", "washer-mcp"],
      "env": {
        "THINQ_PAT": "your-pat-here",
        "THINQ_COUNTRY": "IN",
        "THINQ_CLIENT_ID": "your-uuid4-here"
      }
    }
  }
}

对于 Claude Code 特别说明:

claude mcp add lg-washer --env THINQ_PAT=xxx --env THINQ_COUNTRY=IN -- uv --directory /Users/sushmanagaraj/c_drive/Coding/LG run washer-mcp

快速手动测试(无需 MCP 客户端)

uv run python -c "import asyncio, os; from washer_mcp.thinq_client import ThinQClient; \
print(asyncio.run(ThinQClient(os.environ['THINQ_PAT'],'IN',os.environ.get('THINQ_CLIENT_ID','test-id')).list_devices()))"
-
license - not tested
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

  • Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.

  • Control Android TV from any AI. 38 MCP tools: playback, recap, recommend, smart-home, schedules.

  • Give AI agents the LinkedIn tools to find, qualify, engage, and follow up with prospects.

View all MCP Connectors

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/madhukeshm/lg-washer-mcp'

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