UNPKG

@sanlim/home-assistant-switch-mcp-server

Version:
12 lines (11 loc) 341 B
export class HomeAssistantSwitchRequestService { client; constructor(client) { this.client = client; } async callSwitchService({ entity_id, service, }) { const endpoint = `services/switch/${service}`; const data = { entity_id }; return this.client.makeRequest(endpoint, 'POST', data); } }