{
  "revision": "20261202",
  "mtlsRootUrl": "https://homegraph.mtls.googleapis.com/",
  "schemas": {
    "DeviceMetadata": {
      "type": "object",
      "id": "DeviceMetadata",
      "description": "Metadata for traits of a single device.",
      "properties": {
        "traitCommitTimestamps": {
          "type": "object",
          "additionalProperties": {
            "type": "string",
            "format": "google-datetime"
          },
          "description": "Map from the Trait ID (e.g., \"action.devices.traits.OnOff\") to its last Spanner commit timestamp."
        }
      }
    },
    "ThermostatFanControlTrait": {
      "type": "object",
      "properties": {
        "timerSpeed": {
          "enumDescriptions": [
            "",
            "",
            "",
            "",
            "",
            ""
          ],
          "type": "string",
          "enum": [
            "FAN_SPEED_SETTING_ENUM_UNSPECIFIED",
            "FAN_SPEED_SETTING_OFF",
            "FAN_SPEED_SETTING_STAGE1",
            "FAN_SPEED_SETTING_STAGE2",
            "FAN_SPEED_SETTING_STAGE3",
            "FAN_SPEED_SETTING_AUTO"
          ]
        },
        "timerDuration": {
          "type": "string",
          "format": "int64"
        },
        "timerEnd": {
          "type": "string",
          "format": "int64"
        }
      },
      "description": "This cluster provides fan control capabilities for thermostats.",
      "id": "ThermostatFanControlTrait"
    },
    "JsonTrait": {
      "properties": {
        "id": {
          "type": "string",
          "description": "Required. Identifies the trait by its canonical four-segment capability ID, `capability...`: * Standard or Google Matter (Category 1): `capability.matter.standard.` or `capability.matter.google.`, for example `capability.matter.standard.Thermostat`. * Vendor Matter (Category 2): `capability.matter..`. * Non-Matter (Category 3, from any provider including Google): `capability.generic..`, for example `capability.generic.acme.Warranty`."
        },
        "data": {
          "description": "Optional. Holds the trait attributes, which conform to the trait's registered JSON Schema.",
          "type": "object",
          "additionalProperties": {
            "description": "Properties of the object.",
            "type": "any"
          }
        }
      },
      "type": "object",
      "id": "JsonTrait",
      "description": "Represents a dynamic JSON trait state payload that conforms to `json_trait_schema.md`. This message is used for Category 2 (vendor Matter clusters) and Category 3 (non-Matter capabilities) traits across all wire and internal paths, and for Category 1 traits on external JSON-only wire paths (for example, `Query` with `JSON_TRAIT_ONLY`)."
    },
    "QueryResponse": {
      "description": "Response type for the [`Query`](#google.home.graph.v1.HomeGraphApiService.Query) call. This should follow the same format as the Google smart home `action.devices.QUERY` [response](https://developers.home.google.com/cloud-to-cloud/intents/query). Example: ```json { \"requestId\": \"ff36a3cc-ec34-11e6-b1a0-64510650abcf\", \"payload\": { \"devices\": { \"123\": { \"on\": true, \"online\": true }, \"456\": { \"on\": true, \"online\": true, \"brightness\": 80, \"color\": { \"name\": \"cerulean\", \"spectrumRGB\": 31655 } } } } } ```",
      "type": "object",
      "id": "QueryResponse",
      "properties": {
        "requestId": {
          "type": "string",
          "description": "Request ID used for debugging. Copied from the request."
        },
        "payload": {
          "$ref": "QueryResponsePayload",
          "description": "Device states for the devices given in the request."
        }
      }
    },
    "StateAndNotificationPayload": {
      "properties": {
        "devices": {
          "$ref": "ReportStateAndNotificationDevice",
          "description": "The devices for updating state and sending notifications."
        }
      },
      "id": "StateAndNotificationPayload",
      "type": "object",
      "description": "Payload containing the state and notification information for devices."
    },
    "ReportStateAndNotificationRequest": {
      "properties": {
        "agentUserId": {
          "type": "string",
          "description": "Required. Third-party user ID."
        },
        "eventId": {
          "type": "string",
          "description": "Unique identifier per event (for example, a doorbell press)."
        },
        "payload": {
          "description": "Required. State of devices to update and notification metadata for devices.",
          "$ref": "StateAndNotificationPayload"
        },
        "followUpToken": {
          "type": "string",
          "description": "Deprecated.",
          "deprecated": true
        },
        "requestId": {
          "description": "Request ID used for debugging.",
          "type": "string"
        }
      },
      "description": "Request type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call. It may include states, notifications, home_traits, home_events, or any combination thereof. Smart Home Device Traits (SHDT) `states` and `notifications` are defined per `device_id` (for example, \"123\" and \"456\" in the following example). Google Home Traits `home_traits` and `home_events` are lists of updates or events, each associated with a `device_id` (for example, \"789\" in the following example). Example: ```json { \"requestId\": \"ff36a3cc-ec34-11e6-b1a0-64510650abcf\", \"agentUserId\": \"1234\", \"payload\": { \"devices\": { \"states\": { \"123\": { \"on\": true }, \"456\": { \"on\": true, \"brightness\": 10 }, }, \"homeTraits\": [ { \"deviceId\": \"789\", \"components\": [ { \"componentId\": \"main\", \"traitData\": [ { \"trait\": { \"@type\": \"type.googleapis.com/home.graph.v1.OnOffTrait\", \"onOff\": true } } ] } ] } ], \"homeEvents\": [ { \"deviceId\": \"789\", \"events\": [ { \"componentId\": \"main\", \"events\": [ { \"eventId\": \"event-123\", \"eventTime\": \"2026-01-01T00:00:00Z\", \"event\": { \"@type\": \"type.googleapis.com/home.graph.v1.DoorbellPressTrait.DoorbellPressedEvent\" } } ] } ] } ] } } } ```",
      "type": "object",
      "id": "ReportStateAndNotificationRequest"
    },
    "Device": {
      "properties": {
        "structureHint": {
          "type": "string",
          "description": "Suggested name for the structure where this device is installed. Google attempts to use this value during user setup."
        },
        "customData": {
          "additionalProperties": {
            "description": "Properties of the object.",
            "type": "any"
          },
          "description": "Custom device attributes stored in Home Graph and provided to your smart home Action in each [QUERY](https://developers.home.google.com/cloud-to-cloud/intents/query) and [EXECUTE](https://developers.home.google.com/cloud-to-cloud/intents/execute) intent. Data in this object has a few constraints: No sensitive information, including but not limited to Personally Identifiable Information.",
          "type": "object"
        },
        "deviceInfo": {
          "$ref": "DeviceInfo",
          "description": "Device manufacturer, model, hardware version, and software version."
        },
        "notificationSupportedByAgent": {
          "description": "Indicates whether your smart home Action will report notifications to Google for this device via ReportStateAndNotification. If your smart home Action enables users to control device notifications, you should update this field and call RequestSyncDevices.",
          "type": "boolean"
        },
        "willReportState": {
          "type": "boolean",
          "description": "Indicates whether your smart home Action will report state of this device to Google via ReportStateAndNotification."
        },
        "id": {
          "description": "Third-party device ID.",
          "type": "string"
        },
        "otherDeviceIds": {
          "type": "array",
          "items": {
            "$ref": "AgentOtherDeviceId"
          },
          "description": "Alternate IDs associated with this device. This is used to identify cloud synced devices enabled for [local fulfillment](https://developers.home.google.com/local-home/overview)."
        },
        "roomHint": {
          "description": "Suggested name for the room where this device is installed. Google attempts to use this value during user setup.",
          "type": "string"
        },
        "attributes": {
          "additionalProperties": {
            "type": "any",
            "description": "Properties of the object."
          },
          "description": "Attributes for the traits supported by the device.",
          "type": "object"
        },
        "traits": {
          "items": {
            "type": "string"
          },
          "type": "array",
          "description": "Traits supported by the device. See [device traits](https://developers.home.google.com/cloud-to-cloud/traits)."
        },
        "type": {
          "type": "string",
          "description": "Hardware type of the device. See [device types](https://developers.home.google.com/cloud-to-cloud/guides)."
        },
        "name": {
          "$ref": "DeviceNames",
          "description": "Names given to this device by your smart home Action."
        }
      },
      "id": "Device",
      "type": "object",
      "description": "Third-party device definition."
    },
    "MediaUrlsStruct": {
      "id": "MediaUrlsStruct",
      "type": "object",
      "properties": {
        "hlsMasterPlaylistUrl": {
          "type": "string",
          "description": "URL for a hls master playlist for playback"
        },
        "dashManifestUrl": {
          "type": "string",
          "description": "URL for a dash manifest for playback"
        },
        "thumbnailUrl": {
          "description": "URL for thumbnail image representing the event session",
          "type": "string"
        },
        "previewUrl": {
          "type": "string",
          "description": "URL for animated preview clip representing the event session"
        }
      }
    },
    "DeviceBlameStruct": {
      "type": "object",
      "properties": {
        "blameType": {
          "type": "string",
          "enum": [
            "DEVICE_BLAME_TYPE_ENUM_UNSPECIFIED",
            "LOCK",
            "UNLOCK",
            "MOTION_DETECTION",
            "TOUCH_INTERACTION",
            "VOICE_INTERACTION"
          ],
          "description": "Required. Specifies the device blame type.",
          "enumDescriptions": [
            "Indicates an unspecified device blame type.",
            "Indicates lock interaction.",
            "Indicates unlock interaction.",
            "Indicates motion detection.",
            "Indicates touch interaction.",
            "Indicates voice interaction."
          ]
        }
      },
      "id": "DeviceBlameStruct",
      "description": "Contains metadata about the cause of presence state change attributed to a device."
    },
    "PersonEvent": {
      "id": "PersonEvent",
      "description": "Represents a newly detected person event.",
      "type": "object",
      "properties": {
        "zones": {
          "items": {
            "$ref": "ZoneStruct"
          },
          "description": "Zones where events are detected in.",
          "type": "array"
        },
        "zonesIsEmpty": {
          "type": "boolean",
          "description": "If set, zones is an empty list."
        },
        "commonEventData": {
          "$ref": "CommonEventDataStruct"
        }
      }
    },
    "QueryResponsePayload": {
      "type": "object",
      "id": "QueryResponsePayload",
      "properties": {
        "deviceMetadata": {
          "additionalProperties": {
            "$ref": "DeviceMetadata"
          },
          "type": "object",
          "description": "Map from the Trait ID (e.g., \"action.devices.traits.OnOff\") to its last Spanner commit timestamp. If a trait has no recorded timestamp, it will be omitted from this map."
        },
        "devices": {
          "type": "object",
          "description": "States of the devices. Map of third-party device ID to struct of device states.",
          "additionalProperties": {
            "type": "object",
            "additionalProperties": {
              "type": "any",
              "description": "Properties of the object."
            }
          }
        },
        "homeTraitPayload": {
          "additionalProperties": {
            "$ref": "HomeTraitPayload"
          },
          "description": "Map of device IDs to their Unified Device Data Model (UDDM) or JSON trait payloads. This field is populated when `device_view` is set to `HOME_TRAIT_ONLY`, `HOME_TRAIT_AND_SMART_HOME_TRAIT`, or `JSON_TRAIT_ONLY`.",
          "type": "object"
        }
      },
      "description": "Payload containing device states information."
    },
    "StructurePresenceStateChangeReasonStruct": {
      "properties": {
        "deviceBlame": {
          "description": "Optional. Contains metadata about the cause of presence state change attributed to a device.",
          "$ref": "DeviceBlameStruct"
        },
        "userBlame": {
          "description": "Optional. Contains metadata about the cause of presence state change attributed to a user.",
          "$ref": "UserBlameStruct"
        }
      },
      "description": "Contains the metadata about the cause of the structure presence state change.",
      "type": "object",
      "id": "StructurePresenceStateChangeReasonStruct"
    },
    "EventData": {
      "type": "object",
      "properties": {
        "eventTime": {
          "format": "google-datetime",
          "type": "string",
          "description": "Required. The timestamp of the event."
        },
        "eventId": {
          "type": "string",
          "description": "Required. The unique event ID from the device provider."
        },
        "event": {
          "description": "Optional. The actual event payload.",
          "type": "object",
          "additionalProperties": {
            "type": "any",
            "description": "Properties of the object. Contains field @type with type URL."
          }
        },
        "jsonTraitEvent": {
          "$ref": "JsonTraitEvent",
          "description": "Optional. Contains the dynamic JSON trait event payload."
        }
      },
      "id": "EventData",
      "description": "Contains the details for a single event."
    },
    "QueryRequestInput": {
      "properties": {
        "payload": {
          "$ref": "QueryRequestPayload",
          "description": "Payload containing third-party device IDs."
        }
      },
      "id": "QueryRequestInput",
      "type": "object",
      "description": "Device ID inputs to QueryRequest."
    },
    "RequestSyncDevicesResponse": {
      "description": "Response type for the [`RequestSyncDevices`](#google.home.graph.v1.HomeGraphApiService.RequestSyncDevices) call. Intentionally empty upon success. An HTTP response code is returned with more details upon failure.",
      "properties": {},
      "id": "RequestSyncDevicesResponse",
      "type": "object"
    },
    "TraitData": {
      "properties": {
        "jsonTrait": {
          "$ref": "JsonTrait",
          "description": "Contains the dynamic JSON trait payload."
        },
        "commitTime": {
          "format": "google-datetime",
          "description": "Other metadata for the trait. The time the client update was committed in the server.",
          "type": "string"
        },
        "providerUpdateTime": {
          "format": "google-datetime",
          "description": "The custom timestamp supplied by the provider during a ReportStateAndNotification update (if provided). This field is returned as part of the `QueryResponse`.",
          "type": "string"
        },
        "trait": {
          "type": "object",
          "description": "The Provider Home API trait payload.",
          "additionalProperties": {
            "type": "any",
            "description": "Properties of the object. Contains field @type with type URL."
          }
        }
      },
      "id": "TraitData",
      "type": "object",
      "description": "Contains the trait payload for a single trait."
    },
    "RequestSyncDevicesRequest": {
      "id": "RequestSyncDevicesRequest",
      "description": "Request type for the [`RequestSyncDevices`](#google.home.graph.v1.HomeGraphApiService.RequestSyncDevices) call.",
      "type": "object",
      "properties": {
        "async": {
          "type": "boolean",
          "description": "Optional. If set, the request will be added to a queue and a response will be returned immediately. This enables concurrent requests for the given `agent_user_id`, but the caller will not receive any error responses."
        },
        "agentUserId": {
          "description": "Required. Third-party user ID.",
          "type": "string"
        }
      }
    },
    "DeviceInfo": {
      "description": "Device information.",
      "properties": {
        "model": {
          "type": "string",
          "description": "Device model."
        },
        "manufacturer": {
          "type": "string",
          "description": "Device manufacturer."
        },
        "swVersion": {
          "type": "string",
          "description": "Device software version."
        },
        "hwVersion": {
          "description": "Device hardware version.",
          "type": "string"
        }
      },
      "id": "DeviceInfo",
      "type": "object"
    },
    "EveUtilityTrait": {
      "properties": {
        "obstructionDetected": {
          "type": "boolean",
          "readOnly": true
        },
        "acceptedCommandList": {
          "items": {
            "enumDeprecated": [
              true
            ],
            "enumDescriptions": [
              "Deprecated: This enum exists only to conform to AIP guidelines and should never be used."
            ],
            "type": "string",
            "enum": [
              "COMMANDS_UNSPECIFIED"
            ]
          },
          "description": "Required. Output only. Accepted command list for this trait",
          "readOnly": true,
          "type": "array"
        },
        "weatherTrend": {
          "format": "int32",
          "readOnly": true,
          "type": "integer"
        },
        "loggingControlPoint": {
          "type": "string",
          "format": "byte"
        },
        "holdPosition": {
          "type": "boolean"
        },
        "wattAccumulated": {
          "format": "double",
          "type": "number",
          "readOnly": true
        },
        "voltage": {
          "format": "double",
          "readOnly": true,
          "type": "number"
        },
        "rloc16": {
          "format": "int32",
          "type": "integer",
          "readOnly": true
        },
        "current": {
          "format": "double",
          "type": "number",
          "readOnly": true
        },
        "openCount": {
          "format": "int64",
          "type": "string"
        },
        "accumulatedControlPoint": {
          "type": "string",
          "format": "int64"
        },
        "getConfig": {
          "type": "string",
          "readOnly": true,
          "format": "byte"
        },
        "childLock": {
          "type": "boolean"
        },
        "loggingMetadata": {
          "type": "string",
          "format": "byte",
          "readOnly": true
        },
        "motionSensitivity": {
          "type": "integer",
          "format": "int32"
        },
        "lastEventTime": {
          "readOnly": true,
          "format": "int64",
          "type": "string"
        },
        "statusFault": {
          "readOnly": true,
          "format": "int32",
          "type": "integer"
        },
        "altitude": {
          "format": "double",
          "type": "number"
        },
        "watt": {
          "readOnly": true,
          "type": "number",
          "format": "double"
        },
        "loggingData": {
          "format": "byte",
          "readOnly": true,
          "type": "string"
        },
        "airPressure": {
          "type": "number",
          "format": "double",
          "readOnly": true
        },
        "setConfig": {
          "type": "string",
          "format": "byte"
        },
        "loggingTime": {
          "type": "string",
          "format": "byte"
        }
      },
      "id": "EveUtilityTrait",
      "type": "object"
    },
    "SyncResponse": {
      "id": "SyncResponse",
      "type": "object",
      "properties": {
        "requestId": {
          "type": "string",
          "description": "Request ID used for debugging. Copied from the request."
        },
        "payload": {
          "description": "Devices associated with the third-party user.",
          "$ref": "SyncResponsePayload"
        }
      },
      "description": "Response type for the [`Sync`](#google.home.graph.v1.HomeGraphApiService.Sync) call. This should follow the same format as the Google smart home `action.devices.SYNC` [response](https://developers.home.google.com/cloud-to-cloud/intents/sync). Example: ```json { \"requestId\": \"ff36a3cc-ec34-11e6-b1a0-64510650abcf\", \"payload\": { \"agentUserId\": \"1836.15267389\", \"devices\": [{ \"id\": \"123\", \"type\": \"action.devices.types.OUTLET\", \"traits\": [ \"action.devices.traits.OnOff\" ], \"name\": { \"defaultNames\": [\"My Outlet 1234\"], \"name\": \"Night light\", \"nicknames\": [\"wall plug\"] }, \"willReportState\": false, \"deviceInfo\": { \"manufacturer\": \"lights-out-inc\", \"model\": \"hs1234\", \"hwVersion\": \"3.2\", \"swVersion\": \"11.4\" }, \"customData\": { \"fooValue\": 74, \"barValue\": true, \"bazValue\": \"foo\" } }] } } ```"
    },
    "HomeTraitPayload": {
      "properties": {
        "rootComponent": {
          "$ref": "Component",
          "description": "The root component of the device as reported by the provider."
        }
      },
      "id": "HomeTraitPayload",
      "description": "Container for UDDM or JSON trait data associated with a device.",
      "type": "object"
    },
    "CameraEventStreamTrait": {
      "id": "CameraEventStreamTrait",
      "properties": {},
      "description": "This cluster defines the camera event stream used by GHP for their Cloud-to-Cloud eventing flow",
      "type": "object"
    },
    "UserBlameStruct": {
      "id": "UserBlameStruct",
      "description": "Contains metadata about the cause of presence state change attributed to a user.",
      "properties": {
        "blameType": {
          "enumDescriptions": [
            "Indicates an unspecified user blame type.",
            "Indicates phone location.",
            "Indicates manual change."
          ],
          "type": "string",
          "enum": [
            "USER_BLAME_TYPE_ENUM_UNSPECIFIED",
            "PHONE_LOCATION",
            "MANUAL_CHANGE"
          ],
          "description": "Required. Specifies the user blame type."
        },
        "userEmail": {
          "type": "string",
          "description": "Required. Specifies the email of the user."
        }
      },
      "type": "object"
    },
    "SyncResponsePayload": {
      "id": "SyncResponsePayload",
      "description": "Payload containing device information.",
      "type": "object",
      "properties": {
        "agentUserId": {
          "type": "string",
          "description": "Third-party user ID"
        },
        "devices": {
          "type": "array",
          "items": {
            "$ref": "Device"
          },
          "description": "Devices associated with the third-party user."
        }
      }
    },
    "StructurePresenceStateChangeEvent": {
      "properties": {
        "reason": {
          "description": "Optional. Specifies the presence state change reason.",
          "$ref": "StructurePresenceStateChangeReasonStruct"
        },
        "presenceState": {
          "type": "string",
          "enum": [
            "STRUCTURE_PRESENCE_STATE_ENUM_UNSPECIFIED",
            "HOME",
            "AWAY"
          ],
          "description": "Required. Specifies the presence state.",
          "enumDescriptions": [
            "Indicates an unknown presence state.",
            "Indicates home presence state.",
            "Indicates away presence state."
          ]
        }
      },
      "type": "object",
      "id": "StructurePresenceStateChangeEvent",
      "description": "Sent when the structure presence state changes."
    },
    "Result": {
      "description": "Result of reporting state and notifications for a single device.",
      "type": "object",
      "id": "Result",
      "properties": {
        "homeTraitCommitTime": {
          "type": "string",
          "description": "The trait commit timestamp of the state update in Home Graph.",
          "format": "google-datetime"
        }
      }
    },
    "ReportStateAndNotificationResponse": {
      "type": "object",
      "properties": {
        "deviceResults": {
          "description": "Map from agent device ID to the result of reporting state and notifications. This is only populated for UDDM updates for now.",
          "type": "object",
          "additionalProperties": {
            "$ref": "Result"
          }
        },
        "requestId": {
          "description": "Request ID copied from ReportStateAndNotificationRequest.",
          "type": "string"
        }
      },
      "id": "ReportStateAndNotificationResponse",
      "description": "Response type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call."
    },
    "ZoneStruct": {
      "properties": {
        "label": {
          "type": "string",
          "description": "Name of the zone."
        },
        "zoneId": {
          "format": "int64",
          "description": "Id of the zone",
          "type": "string"
        }
      },
      "id": "ZoneStruct",
      "type": "object"
    },
    "MotionEvent": {
      "type": "object",
      "description": "Represents a newly detected motion event.",
      "properties": {
        "zonesIsEmpty": {
          "description": "If set, zones is an empty list.",
          "type": "boolean"
        },
        "zones": {
          "items": {
            "$ref": "ZoneStruct"
          },
          "description": "Zones where events are detected in.",
          "type": "array"
        },
        "commonEventData": {
          "$ref": "CommonEventDataStruct"
        }
      },
      "id": "MotionEvent"
    },
    "CommonEventDataStruct": {
      "id": "CommonEventDataStruct",
      "properties": {
        "sessionId": {
          "description": "Camera event session id. Used for identifying a unique event session",
          "type": "string"
        },
        "mediaUrls": {
          "$ref": "MediaUrlsStruct",
          "description": "Contains media urls for the event"
        },
        "trackId": {
          "description": "Id of the track this object belongs to",
          "type": "string"
        }
      },
      "type": "object",
      "description": "Common camera event data."
    },
    "HomeTraitUpdates": {
      "properties": {
        "deviceId": {
          "type": "string",
          "description": "Required. Unique identifier for the device."
        },
        "components": {
          "type": "array",
          "description": "Required. Trait updates for each component.",
          "items": {
            "$ref": "ComponentTraitUpdates"
          }
        }
      },
      "description": "Contains the set of updates for a device.",
      "type": "object",
      "id": "HomeTraitUpdates"
    },
    "AgentDeviceId": {
      "properties": {
        "id": {
          "description": "Third-party device ID.",
          "type": "string"
        }
      },
      "id": "AgentDeviceId",
      "type": "object",
      "description": "Third-party device ID for one device."
    },
    "AgentOtherDeviceId": {
      "id": "AgentOtherDeviceId",
      "properties": {
        "deviceId": {
          "type": "string",
          "description": "Unique third-party device ID."
        },
        "agentId": {
          "description": "Project ID for your smart home Action.",
          "type": "string"
        }
      },
      "type": "object",
      "description": "Alternate third-party device ID."
    },
    "SyncRequest": {
      "id": "SyncRequest",
      "type": "object",
      "properties": {
        "requestId": {
          "description": "Request ID used for debugging.",
          "type": "string"
        },
        "agentUserId": {
          "type": "string",
          "description": "Required. Third-party user ID."
        }
      },
      "description": "Request type for the [`Sync`](#google.home.graph.v1.HomeGraphApiService.Sync) call."
    },
    "ReportStateAndNotificationDevice": {
      "properties": {
        "notifications": {
          "description": "Notifications metadata for devices. See the **Device NOTIFICATIONS** section of the individual trait [reference guides](https://developers.home.google.com/cloud-to-cloud/traits).",
          "additionalProperties": {
            "description": "Properties of the object.",
            "type": "any"
          },
          "type": "object"
        },
        "states": {
          "description": "States of devices to update. See the **Device STATES** section of the individual trait [reference guides](https://developers.home.google.com/cloud-to-cloud/traits).",
          "type": "object",
          "additionalProperties": {
            "description": "Properties of the object.",
            "type": "any"
          }
        },
        "homeTraits": {
          "description": "Optional. UDDM/WHDM trait updates.",
          "type": "array",
          "items": {
            "$ref": "HomeTraitUpdates"
          }
        },
        "homeEvents": {
          "items": {
            "$ref": "HomeEvents"
          },
          "type": "array",
          "description": "Optional. UDDM/WHDM trait events"
        }
      },
      "id": "ReportStateAndNotificationDevice",
      "type": "object",
      "description": "The states and notifications specific to a device."
    },
    "Events": {
      "properties": {
        "componentId": {
          "description": "Optional. The ID of the provider component if the events are associated with a specific component. Optional for WHDM events, required for UDDM and JSON events.",
          "type": "string"
        },
        "events": {
          "description": "Required. List of events associated with the component.",
          "type": "array",
          "items": {
            "$ref": "EventData"
          }
        }
      },
      "id": "Events",
      "type": "object",
      "description": "Contains a set of events for a specific component."
    },
    "QueryRequestPayload": {
      "properties": {
        "devices": {
          "description": "Third-party device IDs for which to get the device states.",
          "items": {
            "$ref": "AgentDeviceId"
          },
          "type": "array"
        }
      },
      "id": "QueryRequestPayload",
      "type": "object",
      "description": "Payload containing device IDs."
    },
    "Empty": {
      "properties": {},
      "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }",
      "type": "object",
      "id": "Empty"
    },
    "PartnerPresenceSignalTrait": {
      "description": "Provides attributes and events related to partner presence signals. See PartnerPresenceSignal trait:",
      "id": "PartnerPresenceSignalTrait",
      "type": "object",
      "properties": {}
    },
    "QueryRequest": {
      "type": "object",
      "properties": {
        "inputs": {
          "items": {
            "$ref": "QueryRequestInput"
          },
          "type": "array",
          "description": "Required. Inputs containing third-party device IDs for which to get the device states."
        },
        "agentUserId": {
          "type": "string",
          "description": "Required. Third-party user ID."
        },
        "requestId": {
          "description": "Request ID used for debugging.",
          "type": "string"
        },
        "includeDeviceMetadata": {
          "description": "Optional. If true, the response will include device metadata in the device_metadata field.",
          "type": "boolean"
        },
        "deviceView": {
          "enumDescriptions": [
            "Default value. Equivalent to `SMART_HOME_TRAIT_ONLY`.",
            "Return only standard Smart Home traits in the `devices` map.",
            "Return only Unified Device Data Model (UDDM) traits in the `home_trait_payload` map.",
            "Return both standard Smart Home traits and UDDM traits.",
            "Return all component traits in `JsonTrait` format (`TraitData.json_trait` in `home_trait_payload`), converting persisted UDDM traits to `JsonTrait` on read."
          ],
          "description": "Optional. Specifies the type of device data to be returned in the response. This allows callers to request traditional Smart Home traits, Unified Device Data Model (UDDM) traits, or both. If unspecified, defaults to `SMART_HOME_TRAIT_ONLY`.",
          "type": "string",
          "enum": [
            "DEVICE_VIEW_UNSPECIFIED",
            "SMART_HOME_TRAIT_ONLY",
            "HOME_TRAIT_ONLY",
            "HOME_TRAIT_AND_SMART_HOME_TRAIT",
            "JSON_TRAIT_ONLY"
          ]
        }
      },
      "id": "QueryRequest",
      "description": "Request type for the [`Query`](#google.home.graph.v1.HomeGraphApiService.Query) call."
    },
    "JsonTraitEvent": {
      "id": "JsonTraitEvent",
      "properties": {
        "id": {
          "type": "string",
          "description": "Required. Identifies the event as `.`, where `` is the PascalCase key in the schema's `x-capability-info.events`, for example `capability.matter.standard.DoorLock.LockOperation` or `capability.generic.acme.Warranty.ClaimUpdated`."
        },
        "data": {
          "additionalProperties": {
            "type": "any",
            "description": "Properties of the object."
          },
          "description": "Optional. Holds the event payload fields, which conform to the event's registered JSON Schema.",
          "type": "object"
        }
      },
      "type": "object",
      "description": "Represents a dynamic JSON event payload that conforms to `json_trait_schema.md`."
    },
    "Component": {
      "type": "object",
      "description": "Component of a provider device.",
      "properties": {
        "deviceTypes": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Required. List of Device types associated with this component. Supported device types are defined in cs//depot/google3/home/homeservicelayer/uddm/types/uddm_device_types.proto and the type string is the enum name, for example: ON_OFF_LIGHT =\u003e \"ON_OFF_LIGHT\"."
        },
        "id": {
          "description": "Required. ID of the component from the device provider.",
          "type": "string"
        },
        "traitData": {
          "description": "Required. List of trait data associated with the component.",
          "type": "array",
          "items": {
            "$ref": "TraitData"
          }
        },
        "childComponents": {
          "description": "Optional. Child components.",
          "type": "array",
          "items": {
            "$ref": "Component"
          }
        }
      },
      "id": "Component"
    },
    "DeviceNames": {
      "type": "object",
      "properties": {
        "nicknames": {
          "items": {
            "type": "string"
          },
          "description": "Additional names provided by the user for the device.",
          "type": "array"
        },
        "defaultNames": {
          "description": "List of names provided by the manufacturer rather than the user, such as serial numbers, SKUs, etc.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "name": {
          "description": "Primary name of the device, generally provided by the user. Names will be truncated if over the 60 Unicode code point (character) limit and no errors will be thrown. Developers are responsible for handling long names.",
          "type": "string"
        }
      },
      "id": "DeviceNames",
      "description": "Identifiers used to describe the device."
    },
    "ComponentTraitUpdates": {
      "id": "ComponentTraitUpdates",
      "description": "Contains the set of updates for a component.",
      "type": "object",
      "properties": {
        "traitData": {
          "items": {
            "$ref": "TraitData"
          },
          "type": "array",
          "description": "Required. The updated trait data for the component."
        },
        "componentId": {
          "type": "string",
          "description": "Required. ID of the component from the device provider."
        }
      }
    },
    "HomeEvents": {
      "description": "Contains the set of events for an item.",
      "properties": {
        "events": {
          "items": {
            "$ref": "Events"
          },
          "description": "Required. List of events for the item.",
          "type": "array"
        },
        "deviceId": {
          "type": "string",
          "description": "Required. / Unique identifier for the device."
        }
      },
      "type": "object",
      "id": "HomeEvents"
    }
  },
  "basePath": "",
  "resources": {
    "agentUsers": {
      "methods": {
        "delete": {
          "parameterOrder": [
            "agentUserId"
          ],
          "scopes": [
            "https://www.googleapis.com/auth/homegraph"
          ],
          "description": "Unlinks the given third-party user from your smart home Action. All data related to this user will be deleted. For more details on how users link their accounts, see [fulfillment and authentication](https://developers.home.google.com/cloud-to-cloud/primer/fulfillment). The third-party user's identity is passed in via the `agent_user_id` (see DeleteAgentUserRequest). This request must be authorized using service account credentials from your Actions console project.",
          "response": {
            "$ref": "Empty"
          },
          "flatPath": "v1/agentUsers/{agentUsersId}",
          "id": "homegraph.agentUsers.delete",
          "path": "v1/{+agentUserId}",
          "parameters": {
            "requestId": {
              "type": "string",
              "description": "Request ID used for debugging.",
              "location": "query"
            },
            "agentUserId": {
              "pattern": "^agentUsers/.*$",
              "type": "string",
              "location": "path",
              "required": true,
              "description": "Required. Third-party user ID."
            }
          },
          "httpMethod": "DELETE"
        }
      }
    },
    "devices": {
      "methods": {
        "query": {
          "response": {
            "$ref": "QueryResponse"
          },
          "description": "Gets the current states in Home Graph for the given set of the third-party user's devices. The third-party user's identity is passed in via the `agent_user_id` (see QueryRequest). This request must be authorized using service account credentials from your Actions console project.",
          "request": {
            "$ref": "QueryRequest"
          },
          "flatPath": "v1/devices:query",
          "parameters": {},
          "path": "v1/devices:query",
          "parameterOrder": [],
          "id": "homegraph.devices.query",
          "scopes": [
            "https://www.googleapis.com/auth/homegraph"
          ],
          "httpMethod": "POST"
        },
        "sync": {
          "path": "v1/devices:sync",
          "parameters": {},
          "description": "Gets all the devices associated with the given third-party user. The third-party user's identity is passed in via the `agent_user_id` (see SyncRequest). This request must be authorized using service account credentials from your Actions console project.",
          "httpMethod": "POST",
          "id": "homegraph.devices.sync",
          "request": {
            "$ref": "SyncRequest"
          },
          "flatPath": "v1/devices:sync",
          "parameterOrder": [],
          "scopes": [
            "https://www.googleapis.com/auth/homegraph"
          ],
          "response": {
            "$ref": "SyncResponse"
          }
        },
        "reportStateAndNotification": {
          "scopes": [
            "https://www.googleapis.com/auth/homegraph"
          ],
          "flatPath": "v1/devices:reportStateAndNotification",
          "response": {
            "$ref": "ReportStateAndNotificationResponse"
          },
          "id": "homegraph.devices.reportStateAndNotification",
          "parameters": {},
          "path": "v1/devices:reportStateAndNotification",
          "request": {
            "$ref": "ReportStateAndNotificationRequest"
          },
          "description": "Reports device state and optionally sends device notifications. Called by your smart home Action when the state of a third-party device changes or you need to send a notification about the device. See [Implement Report State](https://developers.home.google.com/cloud-to-cloud/integration/report-state) for more information. This method updates the device state according to its declared [traits](https://developers.home.google.com/cloud-to-cloud/primer/device-types-and-traits). Publishing a new state value outside of these traits will result in an `INVALID_ARGUMENT` error response. The third-party user's identity is passed in via the `agent_user_id` (see ReportStateAndNotificationRequest). This request must be authorized using service account credentials from your Actions console project.",
          "httpMethod": "POST",
          "parameterOrder": []
        },
        "requestSync": {
          "request": {
            "$ref": "RequestSyncDevicesRequest"
          },
          "response": {
            "$ref": "RequestSyncDevicesResponse"
          },
          "parameters": {},
          "scopes": [
            "https://www.googleapis.com/auth/homegraph"
          ],
          "parameterOrder": [],
          "httpMethod": "POST",
          "description": "Requests Google to send an `action.devices.SYNC` [intent](https://developers.home.google.com/cloud-to-cloud/intents/sync) to your smart home Action to update device metadata for the given user. The third-party user's identity is passed via the `agent_user_id` (see RequestSyncDevicesRequest). This request must be authorized using service account credentials from your Actions console project.",
          "flatPath": "v1/devices:requestSync",
          "id": "homegraph.devices.requestSync",
          "path": "v1/devices:requestSync"
        }
      }
    }
  },
  "protocol": "rest",
  "baseUrl": "https://homegraph.googleapis.com/",
  "id": "homegraph:v1",
  "canonicalName": "Home Graph Service",
  "fullyEncodeReservedExpansion": true,
  "auth": {
    "oauth2": {
      "scopes": {
        "https://www.googleapis.com/auth/homegraph": {
          "description": "Private Service: https://www.googleapis.com/auth/homegraph"
        }
      }
    }
  },
  "version": "v1",
  "ownerName": "Google",
  "parameters": {
    "upload_protocol": {
      "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").",
      "location": "query",
      "type": "string"
    },
    "alt": {
      "default": "json",
      "type": "string",
      "enum": [
        "json",
        "media",
        "proto"
      ],
      "description": "Data format for response.",
      "location": "query",
      "enumDescriptions": [
        "Responses with Content-Type of application/json",
        "Media download with context-dependent Content-Type",
        "Responses with Content-Type of application/x-protobuf"
      ]
    },
    "$.xgafv": {
      "description": "V1 error format.",
      "enumDescriptions": [
        "v1 error format",
        "v2 error format"
      ],
      "location": "query",
      "type": "string",
      "enum": [
        "1",
        "2"
      ]
    },
    "fields": {
      "type": "string",
      "location": "query",
      "description": "Selector specifying which fields to include in a partial response."
    },
    "uploadType": {
      "type": "string",
      "location": "query",
      "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\")."
    },
    "quotaUser": {
      "location": "query",
      "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.",
      "type": "string"
    },
    "oauth_token": {
      "description": "OAuth 2.0 token for the current user.",
      "type": "string",
      "location": "query"
    },
    "access_token": {
      "description": "OAuth access token.",
      "type": "string",
      "location": "query"
    },
    "key": {
      "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
      "type": "string",
      "location": "query"
    },
    "prettyPrint": {
      "description": "Returns response with indentations and line breaks.",
      "type": "boolean",
      "location": "query",
      "default": "true"
    },
    "callback": {
      "description": "JSONP",
      "type": "string",
      "location": "query"
    }
  },
  "rootUrl": "https://homegraph.googleapis.com/",
  "ownerDomain": "google.com",
  "kind": "discovery#restDescription",
  "description": "",
  "servicePath": "",
  "name": "homegraph",
  "batchPath": "batch",
  "icons": {
    "x16": "http://www.google.com/images/icons/product/search-16.gif",
    "x32": "http://www.google.com/images/icons/product/search-32.gif"
  },
  "version_module": true,
  "documentationLink": "https://developers.home.google.com/cloud-to-cloud/get-started",
  "discoveryVersion": "v1",
  "title": "HomeGraph API"
}
