Getting started
Getting started
- In the IGH app (an administrator): Settings → Integrations → Add integration → API. Choose what it shows, choose its settings, Save.
- Get a credential:
- a script: on the integration's page, Create key. The key (
igh_key_…) is shown once: store it in a secret store. - an AI agent: turn Agent access on and add the MCP address from the integration's page to the agent (see Agents); or use the device flow (see Authentication and Accept agent).
- a script: on the integration's page, Create key. The key (
- Make the first call through the cloud:
curl -sS https://api.igh.app/v1/integration -H "Authorization: Bearer $IGH_KEY"
The answer names the house, the integration and its settings (GET /v1/integration).
4. On the home network, fetch and pin the gateway's CA first (TLS and CA pinning), then call the gateway directly:
curl -sS --cacert igh-ca.pem https://igh-<serial>.local:8490/v1/house -H "Authorization: Bearer $IGH_KEY"
- Read the home with
GET /v1/house, control a device withPOST /v1/devices/{id}/control, and subscribe to changes on Events (WebSocket).
Examples
Which home and integration does this key belong to, and what may it do?
GET /v1/integration
Answer 200:
{
"house": "Cohen Home",
"gateway": "8F3K2M9Q4T7W",
"integration": {
"id": "5b0e6c1a-2f4d-4c3b-9a8e-7d6f5e4c3b2a",
"name": "Scripts",
"credential": {
"kind": "key",
"name": "",
"platform": "",
"label": "API: Scripts"
},
"settings": {
"advanced_config": "read",
"structural": "off",
"automations": "on",
"schedules": "off",
"allow_unlock": "off",
"agent_access": "on",
"cloud_access": "on",
"mdns": "on"
}
}
}
IGH home API 1.1.0. Generated from the doc source; do not edit.