dvdgeisler / DirigeraClient

Dirigera Client API: Java written client API to interface IKEA's new smarthome hub DIRIGERA
MIT License
76 stars 12 forks source link

TREDANSEN with TRÅDFRI remote #78

Open dreadted opened 1 year ago

dreadted commented 1 year ago
{
  "hub": {
    "id": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
    "relationId": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
    "type": "gateway",
    "deviceType": "gateway",
    "createdAt": "2023-01-03T23:05:59.452Z",
    "isReachable": true,
    "lastSeen": "2023-04-12T13:04:07.022Z",
    "attributes": {
      "customName": "My Home",
      "model": "DIRIGERA Hub for smart products",
      "manufacturer": "IKEA of Sweden",
      "firmwareVersion": "2.256.5",
      "hardwareVersion": "P2.5",
      "serialNumber": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "identifyStarted": "2023-04-01T04:19:14.000Z",
      "identifyPeriod": -1,
      "otaStatus": "upToDate",
      "otaState": "readyToCheck",
      "otaProgress": 0,
      "otaPolicy": "autoDownload",
      "otaScheduleStart": "00:00",
      "otaScheduleEnd": "00:00",
      "permittingJoin": false,
      "backendConnected": true,
      "backendConnectionPersistent": true,
      "backendOnboardingComplete": true,
      "backendRegion": "eu-central-1",
      "backendCountryCode": "SE",
      "userConsents": [
        {
          "name": "analytics",
          "value": "enabled"
        },
        {
          "name": "diagnostics",
          "value": "enabled"
        }
      ],
      "logLevel": 3,
      "coredump": false,
      "timezone": "Europe/Stockholm",
      "nextSunSet": null,
      "nextSunRise": null,
      "countryCode": "XZ",
      "isOn": false
    },
    "capabilities": {
      "canSend": [],
      "canReceive": [
        "customName",
        "permittingJoin",
        "userConsents",
        "logLevel",
        "time",
        "timezone",
        "countryCode",
        "coordinates"
      ]
    },
    "deviceSet": [],
    "remoteLinks": []
  },
  "devices": [
    {
      "id": "a7xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
      "type": "controller",
      "deviceType": "blindsController",
      "createdAt": "2023-03-25T00:32:36.000Z",
      "isReachable": true,
      "lastSeen": "2023-04-11T20:18:47.000Z",
      "attributes": {
        "customName": "My remote",
        "model": "TRADFRI open/close remote",
        "manufacturer": "IKEA of Sweden",
        "firmwareVersion": "24.4.5",
        "hardwareVersion": "1",
        "serialNumber": "xxxxxxxxxxxxxx61",
        "productCode": "E1766",
        "batteryPercentage": 100,
        "isOn": false,
        "lightLevel": 1,
        "blindsCurrentLevel": 0,
        "blindsState": "",
        "permittingJoin": false,
        "otaStatus": "upToDate",
        "otaState": "readyToCheck",
        "otaProgress": 0,
        "otaPolicy": "autoUpdate",
        "otaScheduleStart": "00:00",
        "otaScheduleEnd": "00:00"
      },
      "capabilities": {
        "canSend": ["isOn", "lightLevel", "blindsState"],
        "canReceive": ["customName"]
      },
      "room": {
        "id": "3exxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "name": "My room",
        "color": "ikea_red_no_39",
        "icon": "rooms_bed"
      },
      "deviceSet": [],
      "remoteLinks": [],
      "isHidden": false
    },
    {
      "id": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
      "relationId": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "type": "gateway",
      "deviceType": "gateway",
      "createdAt": "2023-01-03T23:05:59.452Z",
      "isReachable": true,
      "lastSeen": "2023-04-12T13:04:07.022Z",
      "attributes": {
        "customName": "My Home",
        "model": "DIRIGERA Hub for smart products",
        "manufacturer": "IKEA of Sweden",
        "firmwareVersion": "2.256.5",
        "hardwareVersion": "P2.5",
        "serialNumber": "d4xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "identifyStarted": "2023-04-01T04:19:14.000Z",
        "identifyPeriod": -1,
        "otaStatus": "upToDate",
        "otaState": "readyToCheck",
        "otaProgress": 0,
        "otaPolicy": "autoDownload",
        "otaScheduleStart": "00:00",
        "otaScheduleEnd": "00:00",
        "permittingJoin": false,
        "backendConnected": true,
        "backendConnectionPersistent": true,
        "backendOnboardingComplete": true,
        "backendRegion": "eu-central-1",
        "backendCountryCode": "SE",
        "userConsents": [
          {
            "name": "analytics",
            "value": "enabled"
          },
          {
            "name": "diagnostics",
            "value": "enabled"
          }
        ],
        "logLevel": 3,
        "coredump": false,
        "timezone": "Europe/Stockholm",
        "nextSunSet": null,
        "nextSunRise": null,
        "countryCode": "XZ",
        "isOn": false
      },
      "capabilities": {
        "canSend": [],
        "canReceive": [
          "customName",
          "permittingJoin",
          "userConsents",
          "logLevel",
          "time",
          "timezone",
          "countryCode",
          "coordinates"
        ]
      },
      "deviceSet": [],
      "remoteLinks": []
    },
    {
      "id": "f5xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
      "type": "blinds",
      "deviceType": "blinds",
      "createdAt": "2023-04-11T19:06:10.000Z",
      "isReachable": true,
      "lastSeen": "2023-04-12T07:18:45.000Z",
      "attributes": {
        "customName": "My blinds",
        "firmwareVersion": "24.4.10",
        "hardwareVersion": "1",
        "manufacturer": "IKEA of Sweden",
        "model": "TREDANSEN block-out cellul blind",
        "productCode": "E2022",
        "serialNumber": "xxxxxxxxxxxxxxF9",
        "batteryPercentage": 51,
        "blindsCurrentLevel": 0,
        "blindsState": "stopped",
        "blindsTargetLevel": 0,
        "permittingJoin": false,
        "otaPolicy": "autoUpdate",
        "otaProgress": 0,
        "otaScheduleEnd": "00:00",
        "otaScheduleStart": "00:00",
        "otaState": "readyToCheck",
        "otaStatus": "upToDate"
      },
      "capabilities": {
        "canSend": [],
        "canReceive": [
          "customName",
          "blindsCurrentLevel",
          "blindsTargetLevel",
          "blindsState"
        ]
      },
      "room": {
        "id": "3exxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "name": "My room",
        "color": "ikea_red_no_39",
        "icon": "rooms_bed"
      },
      "deviceSet": [],
      "remoteLinks": ["a7xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1"],
      "isHidden": false
    }
  ],
  "scenes": [
    {
      "id": "29xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "info": {
        "name": "Evening",
        "icon": "scenes_sun_horizon"
      },
      "type": "userScene",
      "triggers": [
        {
          "id": "a2xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
          "type": "app",
          "triggeredAt": "2023-03-31T19:18:57.961Z",
          "disabled": false
        },
        {
          "id": "56xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
          "type": "time",
          "triggeredAt": "2023-04-11T19:30:00.794Z",
          "disabled": false,
          "trigger": {
            "days": ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"],
            "time": "21:30"
          },
          "nextTriggerAt": "2023-04-12T19:30:00.000Z"
        }
      ],
      "actions": [
        {
          "id": "f5xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
          "type": "device",
          "deviceId": "f5xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
          "attributes": {
            "blindsTargetLevel": 80
          }
        }
      ],
      "commands": [],
      "createdAt": "2023-03-24T17:29:52.168Z",
      "lastCompleted": "2023-04-11T19:30:00.806Z",
      "lastTriggered": "2023-04-11T19:30:00.806Z",
      "undoAllowedDuration": 30
    },
    {
      "id": "27xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "info": {
        "name": "Morning",
        "icon": "scenes_sun_horizon"
      },
      "type": "userScene",
      "triggers": [
        {
          "id": "fbxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
          "type": "app",
          "triggeredAt": "2023-04-01T01:57:35.683Z",
          "disabled": false
        },
        {
          "id": "08xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
          "type": "time",
          "triggeredAt": "2023-04-12T06:00:00.642Z",
          "disabled": false,
          "trigger": {
            "days": ["Mon", "Tue", "Wed", "Thu", "Fri"],
            "time": "08:00"
          },
          "nextTriggerAt": "2023-04-13T06:00:00.000Z"
        }
      ],
      "actions": [
        {
          "id": "f5xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
          "type": "device",
          "deviceId": "f5xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx_1",
          "attributes": {
            "blindsTargetLevel": 0
          }
        }
      ],
      "commands": [],
      "createdAt": "2023-03-24T17:28:44.898Z",
      "lastCompleted": "2023-04-12T06:00:00.650Z",
      "lastTriggered": "2023-04-12T06:00:00.650Z",
      "undoAllowedDuration": 30
    }
  ],
  "rooms": [
    {
      "id": "3exxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "name": "My room",
      "color": "ikea_red_no_39",
      "icon": "rooms_bed"
    }
  ],
  "deviceSets": [],
  "music": {
    "playlists": [],
    "favorites": []
  }
}