# com.google.home

## Interfaces

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/BasicCameraEventDetails` | Represents basic camera event details associated with a home brief. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/BatchScope` | The scope for the lifecycle of a batch. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Batchable` | The Batchable interface allows entities/objects to be batched together. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/BitmapDescriptor` | Bitmaps are effectively enumerations if you unroll the individual bits in the mask into their own enum values. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/ClusterStruct` | Interface for a Cluster Struct field. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CommandDescriptor` | Interface implemented by every trait command. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeferredResponse` | Represents the response of a command which will be populated after the batch completes. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Descriptor` | A tagging interface to describe a field, such as StructDescriptor |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceHistoryItem` | A history item generated by a device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EnumDescriptor` | Descriptor representing an enumeration, with its name and a map of its numeric values to value labels. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Event` | Interface tagging for events. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Field` | Interface describing a Field of a Trait, Command, Event or Struct |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericEvent` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericTrait` | A `https://developers.home.google.com/reference/kotlin/com/google/home/Trait` that contains data represented generically as a `https://developers.home.google.com/reference/kotlin/com/google/home/FieldMap` |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GhpCoreMetadata` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasComponentId` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasConnectivityState` | Represents the state of a device (`https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`,Component,`https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType`,`https://developers.home.google.com/reference/kotlin/com/google/home/Trait`). |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasCustomAppData` | Interface for a Key-Value Controller. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasDeviceTypes` | This interface allows for getting device types from a Device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasEvents` | Interface implemented by objects that have observable events. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasGenericEvents` | Interface implemented by GenericDeviceType objects that have observable events. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasGenericTraits` | This interface is only present to allow the sample app to see all traits present on a device (even with TraitId collisions). flatMap + .toSet on the collection of traits from the genericTypes() isn't quite the same, since it doesn't contain traits outside of the type's defined set. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasGenericTypes` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasHomeDevices` | Query devices within the implementation context (`https://developers.home.google.com/reference/kotlin/com/google/home/HomeManager`, `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`, `https://developers.home.google.com/reference/kotlin/com/google/home/Room`) the caller has permissions to access. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasId` | Entities in the SDK present a stable ID for comparing `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-collection/index.html`s and retrieving entities directly. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasName` | Interface for objects that have a name and can set it. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasParts` | Interface for objects that have parts. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasRooms` | Query `https://developers.home.google.com/reference/kotlin/com/google/home/Room`s the caller has permissions to access. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasStructures` | Query `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`s the caller has permissions to access. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HasTraits` | An entity with associated traits and trait metadata. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryItem` | The semantic representation of a history item. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryItemsPage` | Represents a page of history items. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryItemsPage.Error` | Represents a failed fetch of a history items page. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryItemsPage.Success` | Represents a successful fetch of a history items page. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryManager` | A manager for history items. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBrief` | Represents a single home brief. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBriefsManager` | A manager for home briefs. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBriefsPage` | Represents a page of home briefs. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBriefsPage.Error` | Represents a failed fetch of a home briefs page. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBriefsPage.Success` | Represents a successful fetch of a home briefs page. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeClientWithProvidedAccount` | Interface for Home APIs that provides access to provided account specific functionality. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` | A device supporting traits, commands, and subscriptions. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeEntityType` | Common base interface for all first-class hydrated entities in the Home Graph. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeErrorDetails` | Extra structured details about a HomeError. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectChangeEvent` | Base interface expanded into different events for the streaming API. |
| `HomeObjectType` | Tagging interface for all objects' types (`https://developers.home.google.com/reference/kotlin/com/google/home/Structure`, `https://developers.home.google.com/reference/kotlin/com/google/home/Room` or `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`). |
| `InternalDeviceTypeFactory` | A tagging interface for actual implementation of `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` Factories. |
| `InternalEventFactory` | A tagging interface for actual implementation of Factories. |
| `InternalTraitFactory` | A tagging interface for actual implementation of Factories. |
| `InternalTypeFactory` | A tagging interface for actual implementation of Factories. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider` | Interface for objects that expose a reactive flow of parts, such as `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` and `https://developers.home.google.com/reference/kotlin/com/google/home/HomeEntityType`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Room` | An object that represents a Room in a `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/RoomHistoryItem` | A history item generated by a room. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableAttribute` | A searchable attribute (the field of an event) for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableCameraEventType` | A searchable camera event type for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableEvent` | A searchable event for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableId` | A searchable ID for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableItem` | A schema for available history filters. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SearchableTrait` | A searchable trait for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent` | An event that represents a change in the state of a trait. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/StructDescriptor` | Interface implemented by logical struct types. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Structure` | The top-level organizing construct for the `https://developers.home.google.com/reference/kotlin/com/google/home/Home`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/StructureHistoryItem` | A history item generated by a structure. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/StructureManagement` | This provides methods to manage structures associated with the associated user's account. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Tag` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Trait` | Base class for traits and generated Matter clusters. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TraitProvider` | A functional interface for returning a trait instance from the current data snapshot. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TraitStateInvalidation` | This API provides the ability to invalidate state retrieved through subscriptions to the target device in the cases where state is not being reported correctly, either intentionally (e.g attributes in Matter traits with the "C" quality) or unintentionally due to poor implementations. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Updatable` | This interface keeps the lifecycle of mutable objects within the scope of the `https://developers.home.google.com/reference/kotlin/com/google/home/Updatable#update(kotlin.Function1,kotlin.Function1)` function. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/UserAccount` | User identifier to be used with `https://developers.home.google.com/reference/kotlin/com/google/home/Home#getClient(android.content.Context,com.google.home.HomeConfig)` to return a `https://developers.home.google.com/reference/kotlin/com/google/home/HomeClientWithProvidedAccount`. |

## Classes

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/AccountInfoParcelable` | Unified identity wrapper for IPC. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgent` | Metadata describing a linkable 3P cloud agent. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgentsResponse` | Response containing available linkable agents. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/BaseHomeError` | Base class for HomeError and MatterError. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/BatchableCommand` | Represents a command that can be batched with other commands. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter` | Filter by Camera Event Type. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CloudAccountLinkingWebBroker.Result` | Result of parsing a WebBroker redirect deep-link. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CloudAccountLinkingWebBroker.Result.Failure` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CloudAccountLinkingWebBroker.Result.Success` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentScreenOptions` | Options to customize the consent screen. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CustomFilter` | Custom filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionEligibility` | Sealed class that represents the eligibility of a matter device for decommissioning. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionEligibility.EligibleWithSideEffects` | The device is eligible for decommissioning, but there could be side effects on other devices. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionEligibility.Ineligible` | The device is not eligible for decommissioning. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason` | Sealed class that represents the reason why a device is not eligible for decommissioning. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.BridgedDevice` | The device is a bridged device, and cannot be decommissioned directly (the primary bridge must be decommissioned first). |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.Other` | Other reason why the device is not eligible for decommissioning. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionSideEffects` | Sealed class that represents the side effects of decommissioning a device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionSideEffects.Bridge` | The device is a bridge, and decommissioning it will affect other bridged devices. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionSideEffects.MultipleAffectedDevices` | Decommissioning the device will affect multiple devices. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup` | Domain entity representing a device group in the Home Graph. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` | Abstract base class for all generated DeviceType classes. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType.Metadata` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory` | Wrapper for companion objects to subclass to create shorter syntax. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EntityTypeFactory` | Wrapper for companion objects to subclass to create shorter syntax, so that call sites can name the entity itself (e.g. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EnumEntry` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EventFactory` | Wrapper for companion objects to subclass to create shorter syntax. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EventFilter` | Event filter using the existing SDK event definitions. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FactoryRegistry` | A registry of traits and device types to be used by the SDK. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentResult` | The result of a feature consent request. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType` | Platform-independent data class for feature consent. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FilterSchema` | Schema for a history filter. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GalErrorDetails` | Details for a GAL error. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericDeviceType` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericEventImpl` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericEventProvider` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericPartsProvider` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/GenericTraitProvider` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter` | Base class for all filters. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter.DisjunctiveClause` | A clause that can be part of a disjunction (OR-ed). |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Home` | Entry point for the Home API. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeConfig` | Stores common config for configuring the behavior of the SDK. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeError` | Representation of an error that happened during an API call. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectAddedEvent` | When a `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`, `https://developers.home.google.com/reference/kotlin/com/google/home/Room` or `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` is added to the corresponding top level flow, this event is issued with the newly added home object. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectInitialEvent` | Event issued during data priming. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectRemovedEvent` | When a `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`, `https://developers.home.google.com/reference/kotlin/com/google/home/Room` or `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` is deleted, this event is issued with the id of the deleted home object. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectUpdatedEvent` | When a `https://developers.home.google.com/reference/kotlin/com/google/home/Structure`, `https://developers.home.google.com/reference/kotlin/com/google/home/Room` or `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` is modified, this event is issued with the modified home object. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectsFlow` | A `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html` of a `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html` of home objects. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Id` | Opaque holder for an ID. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/IdFilter` | Filter by ID. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/MatterError` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/PermissionsResult` | The result of a request for home permissions. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/RoomType` | Room type definition. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SourceConnectivity` | Data source metadata for a single trait. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/StructureType` | Structure type definition. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TimestampFilter` | Filter by timestamp. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Trait.TraitMetadata` | General metadata common to all traits. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory` | Wrapper for companions to subclass to create shorter syntax. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TraitFilter` | Trait filter using the existing SDK trait definitions. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/TypeFactory` | Wrapper for companion objects to subclass to create shorter syntax. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/UserAccount.FederatedAccount` | A federated account associated with a `https://developers.home.google.com/reference/kotlin/com/google/home/HomeClientWithProvidedAccount`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/UserAccount.GoogleAccount` | A Google account associated with a `https://developers.home.google.com/reference/kotlin/com/google/home/HomeClientWithProvidedAccount`. |

## Exceptions

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException` | The exception thrown if any issue is encountered during an API call. |

## Objects

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Animal` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.CoAlarm` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.DogBark` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Doorbell` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.FamiliarFace` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.GarageDoorClosed` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.GarageDoorOpened` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.GlassBreak` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Motion` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.PackageDelivered` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.PackageInTransit` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.PackageRetrieved` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Person` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.PersonTalking` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.RecordingCoAlarm` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.RecordingSmokeAlarm` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.SecurityAlarm` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.SmokeAlarm` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Sound` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.UnfamiliarFace` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CameraEventTypeFilter.Vehicle` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/CloudAccountLinkingWebBroker` | WebBroker helper for CICTOCAL (Cloud-Initiated Cloud-to-Cloud Account Linking) flow. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionEligibility.Eligible` | The device is eligible for decommissioning with no side effects. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.ConsentRequired` | A consent token is required to decommission this device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.MultiSourceDevice` | The device is connected through multiple sources, e.g. matter and cloud. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.NonMatterDevice` | The device is not a Matter device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DecommissionIneligibleReason.NotAuthorized` | The user is not authorized to decommission the device. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup.Companion` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EmptyPartsProvider` | A `https://developers.home.google.com/reference/kotlin/com/google/home/PartsProvider` for objects that expose no parts. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FactoryConstants` | Constants for conveniently getting a `https://developers.home.google.com/reference/kotlin/com/google/home/FactoryRegistry` with traits, device and entity types. |
| `Home.Companion` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException.Codes` |   |
| `HomeException.Companion` |   |
| `HomeException.Companion.AutomationApiErrors` |   |
| `HomeException.Companion.HistoryApiErrors` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException.Companion.PaginatedApiErrors` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/NoOpDescriptor` | Default (empty) implementation of `https://developers.home.google.com/reference/kotlin/com/google/home/Descriptor` |
| `RoomType.Companion` |   |
| `StructureType.Companion` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SubErrorCodes` | Error codes for sub errors. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SubErrorCodes.AutomationApi` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SubErrorCodes.FailedPrecondition` | Error codes for `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException#failedPrecondition(kotlin.String,java.lang.Exception,kotlin.Array)`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SubErrorCodes.HistoryApi` |   |
| `SubErrorCodes.Internal` |   |
| `https://developers.home.google.com/reference/kotlin/com/google/home/SubErrorCodes.PaginatedApi` | Error codes for paginated API errors (e.g. HomeBriefs). |
| `https://developers.home.google.com/reference/kotlin/com/google/home/UserAccount.CommunalAccount` | A communal account associated with a `https://developers.home.google.com/reference/kotlin/com/google/home/HomeClientWithProvidedAccount`. |

## Enums

|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/ConnectivityState` | Represents the state of a device (`https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`,Component,`https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType`,`https://developers.home.google.com/reference/kotlin/com/google/home/Trait`). |
| `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus` | enum representing the consent status of a feature. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/EventImportance` | The Event importance as reported. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FederatedInvitationRedeemStatus` | The status of a federated invitation redemption. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/ForcePermissionFlow` | Flows for forcing the permission-granting UI. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeConfig.HomePlatformScope` | The selected device scopes version to use when initializing the SDK. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeErrorDomain` | Enum representing the domain of a `https://developers.home.google.com/reference/kotlin/com/google/home/HomeError`. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/LocalityType` | The network locality of a request or route. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Operator` | Operator for timestamp comparison. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/PermissionsResultStatus` | Statuses for a permissions request. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/PermissionsState` | The state of permissions to access home data for the requesting client. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/Type` | This enum lists the types of Kotlin variables which represent trait fields. |

## Type aliases

|---|---|
| `DescriptorMap` | A Map of `https://developers.home.google.com/reference/kotlin/com/google/home/TagId`s to `https://developers.home.google.com/reference/kotlin/com/google/home/Field`s that represents a 'descriptor' for most types of encapsulated data in UDDM/WHDM (e.g. Structs, Commands, Events) |
| `FieldMap` | Field-Value map represents the format for generic trait content. |
| `PartId` | An opaque identifier for a part. |
| `PartTags` | Set of tags that can be used to identify a part uniquely within a device having same `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType`. |
| `TagId` |   |
| `TagMap` |   |

## Top-level functions summary

|---|---|
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#compareTag(com.google.home.Tag,com.google.home.Tag)(tag1: https://developers.home.google.com/reference/kotlin/com/google/home/Tag, tag2: https://developers.home.google.com/reference/kotlin/com/google/home/Tag)` |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#compareTags(kotlin.collections.Collection,kotlin.collections.Collection)(tags1: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-collection/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Tag>, tags2: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-collection/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Tag>)` |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter` | `https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#historyFilter(kotlin.Function1)(init: https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter.Companion.() -> https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter)` Creates a `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter` using a type-safe DSL. |

## Extension functions summary

|---|---|
| `inline https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent<T>` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://developers.home.google.com/reference/kotlin/com/google/home/Event.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Event).asStateChangeOf()()` Casts the `https://developers.home.google.com/reference/kotlin/com/google/home/Event` to a `https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent` of the trait T, or throws an Exception if it is not a StateChangeEvent. |
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType>>>` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).consentedDeviceTypes()()` Gets an observable flow indicating the device types for which the user has consented for the app. |
| `operator https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType> https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.collections.Set).contains(com.google.home.DeviceTypeFactory)(factory: https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<T>)` Helper on sets of `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` to allow convenience syntax similar to DimmableLightDevice in types where types is a Set. |
| `suspend https://developers.home.google.com/reference/kotlin/com/google/home/Room` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).createRoom(kotlin.String)(name: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` Create a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.HomeDevice).deleteHistory()()` Extension function to delete the history items for a device. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).deleteHistory(kotlin.collections.List)(eventTypeIds: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html>)` Extension function to delete the history items with the given event type IDs for the structure. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).deleteRoom(com.google.home.Id)(roomId: https://developers.home.google.com/reference/kotlin/com/google/home/Id)` Delete a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure, based on the Room's ID. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).deleteRoom(com.google.home.Room)(room: https://developers.home.google.com/reference/kotlin/com/google/home/Room)` Delete a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeObjectsFlow<https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice>` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.DeviceGroup).devices(kotlin.Boolean,com.google.home.HomeManager)( enableMultipartDevices: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html, homeManager: https://developers.home.google.com/reference/kotlin/com/google/home/HomeManager )` Returns a flow of `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`s that belong to this `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup`. |
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType, https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus>>` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).featureConsentStatus()()` Gets an observable flow indicating the feature consent status for the structure. |
| `suspend https://developers.home.google.com/reference/kotlin/com/google/home/google/UserMetadataTrait.UserMetadataValues?` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).fetchUserMetadata()()` Fetches signed-in user metadata. |
| `operator T?` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType> https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.collections.Set).get(com.google.home.DeviceTypeFactory)(factory: https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<T>)` Direct accessor to the `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` that auto-casts the result. |
| `operator T?` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Trait>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.collections.Set).get(com.google.home.TraitFactory)(factory: https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory<T>)` Direct accessor to the `https://developers.home.google.com/reference/kotlin/com/google/home/Trait` that auto-casts the result. |
| `suspend https://developers.home.google.com/reference/kotlin/com/google/home/HistoryItemsPage` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.HomeDevice).getHistoryItems(kotlin.Int)(pageSize: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)` |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryManager` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).getHistoryManager(kotlin.Int)(pageSize: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)` Extension function to get the history manager for a structure. |
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeBriefsManager` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).getHomeBriefsManager()()` Extension function to get the home briefs manager for a structure. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-collection/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/LocalityType>` | `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.DeviceType).getLocalityTypes()()` Returns all distinct data source localities of this device type's traits. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).initiateCloudAccountLink(com.google.home.AvailableAgent,kotlin.String)( agent: https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgent, baseUrl: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html )` Initiates the CICToCAL (Cloud-Initiated Cloud-to-Cloud Account Linking) flow by resolving the user's email metadata from the structure and constructing the WebBroker URL. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).initiateCloudLink(kotlin.String)(oauthCode: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` Initiate a link to the 3P cloud. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Field, https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html?>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.collections.Map).isEqualTo(kotlin.Any)(other: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html?)` |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/google/CloudAccountLinking.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.google.CloudAccountLinking).isOnline()()` |
| `inline https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://developers.home.google.com/reference/kotlin/com/google/home/Event.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Event).isStateChangeOf()()` Returns whether the `https://developers.home.google.com/reference/kotlin/com/google/home/Event` is a `https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent` of the trait T. |
| `suspend https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgentsResponse` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).listAvailableAgents(kotlin.String,kotlin.Int)(pageToken: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html?, pageSize: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html?)` Lists available 3P agents for Cloud Account Linking. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).moveDevicesToRoom(com.google.home.Id,kotlin.collections.List)(roomId: https://developers.home.google.com/reference/kotlin/com/google/home/Id, deviceIds: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Id>)` Move `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` devices to a different `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure, based on IDs. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).moveDevicesToRoom(com.google.home.Room,kotlin.collections.List)(room: https://developers.home.google.com/reference/kotlin/com/google/home/Room, devices: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice>)` Move `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` devices to a different `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure. |
| `suspend https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html` | `https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).setAsCloudLinkDefault()()` Set the current structure as the default for the user's devices. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-u-long/index.html, https://developers.home.google.com/reference/kotlin/com/google/home/EnumEntry>` | `<E : https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html<E> & https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/ClusterBitmapFlag> https://developers.home.google.com/reference/kotlin/kotlin/enums/EnumEntries<E>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.enums.EnumEntries).toBitmapDescriptor()()` |
| `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus` | `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/ConsentStatus.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.platform.traits.ConsentStatus).toConsentStatus()()` Converts the protobuf `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/ConsentStatus` enum to the `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus` enum. |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-u-int/index.html, https://developers.home.google.com/reference/kotlin/com/google/home/Field>` | `<E : https://developers.home.google.com/reference/kotlin/com/google/home/Field & https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html<E>> https://developers.home.google.com/reference/kotlin/kotlin/enums/EnumEntries<E>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.enums.EnumEntries).toDescriptorMap()()` |
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-u-long/index.html, https://developers.home.google.com/reference/kotlin/com/google/home/EnumEntry>` | `<E : https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-enum/index.html<E> & https://developers.home.google.com/reference/kotlin/com/google/home/matter/serialization/ClusterEnum> https://developers.home.google.com/reference/kotlin/kotlin/enums/EnumEntries<E>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlin.enums.EnumEntries).toEnumDescriptor()()` |
| `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType` | `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/Feature.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.platform.traits.Feature).toFeatureConsentType()()` Converts the protobuf `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/Feature` enum to the `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType` data class. |
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<T?>` | `<T : https://developers.home.google.com/reference/kotlin/com/google/home/Trait> https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType>.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(kotlinx.coroutines.flow.Flow).trait(com.google.home.TraitFactory)(factory: https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory<T>)` Returns a flow of the trait of type T from this device type. |
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/google/UserPresenceSettings>` | `@https://developers.home.google.com/reference/kotlin/com/google/home/annotation/HomeExperimentalApi https://developers.home.google.com/reference/kotlin/com/google/home/Structure.https://developers.home.google.com/reference/kotlin/com/google/home/package-summary#(com.google.home.Structure).userPresenceSettings()()` Gets an observable flow indicating the user presence settings for the structure. |

## Top-level functions

### compareTag

```
fun compareTag(tag1: Tag, tag2: Tag): Boolean
```

### compareTags

```
fun compareTags(tags1: Collection<Tag>, tags2: Collection<Tag>): Boolean
```

### historyFilter

```
fun historyFilter(init: HistoryFilter.Companion.() -> HistoryFilter): HistoryFilter
```

Creates a `https://developers.home.google.com/reference/kotlin/com/google/home/HistoryFilter` using a type-safe DSL.

## Extension functions

### asStateChangeOf

```
inline fun <T : Trait> Event.asStateChangeOf(): StateChangeEvent<T>
```

Casts the `https://developers.home.google.com/reference/kotlin/com/google/home/Event` to a `https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent` of the trait T, or throws an Exception if it is not a StateChangeEvent.

### consentedDeviceTypes

```
@HomeExperimentalApi
fun Structure.consentedDeviceTypes(): Flow<Set<DeviceTypeFactory<DeviceType>>>
```

Gets an observable flow indicating the device types for which the user has consented for the app.

| Returns |
|---|---|
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-set/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceTypeFactory<https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType>>>` | a flow of ConsentedDeviceTypesData. |

### contains

```
operator fun <T : DeviceType> Set<DeviceType>.contains(factory: DeviceTypeFactory<T>): Boolean
```

Helper on sets of `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` to allow convenience syntax similar to DimmableLightDevice in types where types is a Set.

### createRoom

```
suspend fun Structure.createRoom(name: String): Room
```

Create a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure.

| Parameters |
|---|---|
| `name: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html` | the name of the `Room` to create. |

| Returns |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/Room` | the newly created `Room`. |

### deleteHistory

```
@HomeExperimentalApi
suspend fun HomeDevice.deleteHistory(): Unit
```

Extension function to delete the history items for a device.

### deleteHistory

```
@HomeExperimentalApi
suspend fun Structure.deleteHistory(eventTypeIds: List<String>): Unit
```

Extension function to delete the history items with the given event type IDs for the structure.

### deleteRoom

```
suspend fun Structure.deleteRoom(roomId: Id): Unit
```

Delete a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure, based on the Room's ID.

| Parameters |
|---|---|
| `roomId: https://developers.home.google.com/reference/kotlin/com/google/home/Id` | the ID of the `Room` to delete. |

### deleteRoom

```
suspend fun Structure.deleteRoom(room: Room): Unit
```

Delete a `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure.

| Parameters |
|---|---|
| `room: https://developers.home.google.com/reference/kotlin/com/google/home/Room` | the `Room` to delete. |

### devices

```
@HomeExperimentalApi
fun DeviceGroup.devices(
    enableMultipartDevices: Boolean = false,
    homeManager: HomeManager = requireNotNull(this.homeManager) {
      "HomeManager is required to resolve group devices when not provided during hydration"
    }
): HomeObjectsFlow<HomeDevice>
```

Returns a flow of `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`s that belong to this `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceGroup`.

Resolves members reactively by filtering `https://developers.home.google.com/reference/kotlin/com/google/home/HomeManager#devices(kotlin.Boolean)` based on `https://developers.home.google.com/reference/kotlin/com/google/home/google/GroupMembership`.

| Parameters |
|---|---|
| `enableMultipartDevices: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html = false` | Whether to enable the multipart devices. When enabled, the flow emits multipart devices organized in a hierarchy of `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType`s. When disabled, the flow emits the individual parts of multipart devices as separate `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice`s. |
| `homeManager: https://developers.home.google.com/reference/kotlin/com/google/home/HomeManager = requireNotNull(this.homeManager) { "HomeManager is required to resolve group devices when not provided during hydration" }` | The `https://developers.home.google.com/reference/kotlin/com/google/home/HomeManager` used to query devices. Defaults to the instance provided during hydration. |

### featureConsentStatus

```
@HomeExperimentalApi
fun Structure.featureConsentStatus(): Flow<Map<FeatureConsentType, ConsentStatus>>
```

Gets an observable flow indicating the feature consent status for the structure.

| Returns |
|---|---|
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-map/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType, https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus>>` | a flow of maps, where each map is from a `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType` to its corresponding `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus`. |

### fetchUserMetadata

```
@HomeExperimentalApi
suspend fun Structure.fetchUserMetadata(): UserMetadataTrait.UserMetadataValues?
```

Fetches signed-in user metadata.

| Returns |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/google/UserMetadataTrait.UserMetadataValues?` | a UserMetadata object containing the user's metadata. |

### get

```
operator fun <T : DeviceType> Set<DeviceType>.get(factory: DeviceTypeFactory<T>): T?
```

Direct accessor to the `https://developers.home.google.com/reference/kotlin/com/google/home/DeviceType` that auto-casts the result. Returns null if the DeviceType with the requested type is not present.

### get

```
operator fun <T : Trait> Set<Trait>.get(factory: TraitFactory<T>): T?
```

Direct accessor to the `https://developers.home.google.com/reference/kotlin/com/google/home/Trait` that auto-casts the result. Returns null if the trait with the requested type is not present.

### getHistoryItems

```
@HomeExperimentalApi
suspend fun HomeDevice.getHistoryItems(pageSize: Int = 20): HistoryItemsPage
```

### getHistoryManager

```
@HomeExperimentalApi
fun Structure.getHistoryManager(pageSize: Int = 20): HistoryManager
```

Extension function to get the history manager for a structure.

### getHomeBriefsManager

```
@HomeExperimentalApi
fun Structure.getHomeBriefsManager(): HomeBriefsManager
```

Extension function to get the home briefs manager for a structure.

### getLocalityTypes

```
fun DeviceType.getLocalityTypes(): Collection<LocalityType>
```

Returns all distinct data source localities of this device type's traits.

### initiateCloudAccountLink

```
suspend fun Structure.initiateCloudAccountLink(
    agent: AvailableAgent,
    baseUrl: String = CloudAccountLinkingWebBroker.DEFAULT_LINK_BASE_URL
): String
```

Initiates the CICToCAL (Cloud-Initiated Cloud-to-Cloud Account Linking) flow by resolving the user's email metadata from the structure and constructing the WebBroker URL.

| Parameters |
|---|---|
| `agent: https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgent` | The `https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgent` to link. |
| `baseUrl: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html = CloudAccountLinkingWebBroker.DEFAULT_LINK_BASE_URL` | Optional custom base URL for WebBroker (defaults to `https://developers.home.google.com/reference/kotlin/com/google/home/CloudAccountLinkingWebBroker#DEFAULT_LINK_BASE_URL()`). |

| Returns |
|---|---|
| `https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html` | The complete WebBroker URL with query parameters (agent_id, structure_id, email). |

### initiateCloudLink

```
suspend fun Structure.initiateCloudLink(oauthCode: String): Unit
```

Initiate a link to the 3P cloud. Uses the current structure as the default for new devices.

| Parameters |
|---|---|
| `oauthCode: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html` | The OAuth authorization code which is short-lived and used to start an exchange for the Refresh/Access tokens. It originates from the calling app's OAuth server, provided by the app to the SDK. To learn more about how this token is used, see https://developers.home.google.com/cloud-to-cloud/project/authorization#handle_token_exchange_requests |

| Throws |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException` | if the operation did not succeed. HomeException has suberrors to detail the specific error message and code. |

### isEqualTo

```
fun Map<Field, Any?>.isEqualTo(other: Any?): Boolean
```

### isOnline

```
fun CloudAccountLinking.isOnline(): Boolean
```

### isStateChangeOf

```
inline fun <T : Trait> Event.isStateChangeOf(): Boolean
```

Returns whether the `https://developers.home.google.com/reference/kotlin/com/google/home/Event` is a `https://developers.home.google.com/reference/kotlin/com/google/home/StateChangeEvent` of the trait T.

### listAvailableAgents

```
suspend fun Structure.listAvailableAgents(pageToken: String? = null, pageSize: Int? = null): AvailableAgentsResponse
```

Lists available 3P agents for Cloud Account Linking.

| Parameters |
|---|---|
| `pageToken: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html? = null` | The pagination page token. |
| `pageSize: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html? = null` | The maximum number of agents to return. |

| Returns |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/AvailableAgentsResponse` | The list of available agents and the next page token. |

| Throws |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException` | if the operation did not succeed. HomeException has suberrors to detail the specific error message and code. |

### moveDevicesToRoom

```
suspend fun Structure.moveDevicesToRoom(roomId: Id, deviceIds: List<Id>): Unit
```

Move `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` devices to a different `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure, based on IDs.

| Parameters |
|---|---|
| `roomId: https://developers.home.google.com/reference/kotlin/com/google/home/Id` | the ID of the `Room` to move devices to. |
| `deviceIds: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/Id>` | the list of device IDs for the `HomeDevice` devices to move. |

### moveDevicesToRoom

```
suspend fun Structure.moveDevicesToRoom(room: Room, devices: List<HomeDevice>): Unit
```

Move `https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice` devices to a different `https://developers.home.google.com/reference/kotlin/com/google/home/Room` within a Structure.

| Parameters |
|---|---|
| `room: https://developers.home.google.com/reference/kotlin/com/google/home/Room` | the `Room` to move devices to. |
| `devices: https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/HomeDevice>` | the list of `HomeDevice` devices to move. |

### setAsCloudLinkDefault

```
suspend fun Structure.setAsCloudLinkDefault(): Unit
```

Set the current structure as the default for the user's devices. This structure will be used anytime a new device is received via the cloud sync, as long as the sync response does not specify a structure explicitly.

| Throws |
|---|---|
| `https://developers.home.google.com/reference/kotlin/com/google/home/HomeException` | if the operation did not succeed. HomeException has suberrors to detail the specific error message and code. |

### toBitmapDescriptor

```
fun <E : Enum<E> & ClusterBitmapFlag> EnumEntries<E>.toBitmapDescriptor(): Map<ULong, EnumEntry>
```

### toConsentStatus

```
fun ConsentStatus.toConsentStatus(): ConsentStatus
```

Converts the protobuf `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/ConsentStatus` enum to the `https://developers.home.google.com/reference/kotlin/com/google/home/ConsentStatus` enum.

### toDescriptorMap

```
fun <E : Field & Enum<E>> EnumEntries<E>.toDescriptorMap(): Map<UInt, Field>
```

### toEnumDescriptor

```
fun <E : Enum<E> & ClusterEnum> EnumEntries<E>.toEnumDescriptor(): Map<ULong, EnumEntry>
```

### toFeatureConsentType

```
fun Feature.toFeatureConsentType(): FeatureConsentType
```

Converts the protobuf `https://developers.home.google.com/reference/kotlin/com/google/home/platform/traits/Feature` enum to the `https://developers.home.google.com/reference/kotlin/com/google/home/FeatureConsentType` data class.

### trait

```
fun <T : Trait> Flow<DeviceType>.trait(factory: TraitFactory<T>): Flow<T?>
```

Returns a flow of the trait of type T from this device type. Allows for convenience syntax similar to `device.type(DimmableLightDevice).trait(OnOff)`.

| Parameters |
|---|---|
| `factory: https://developers.home.google.com/reference/kotlin/com/google/home/TraitFactory<T>` | the factory for the trait to get. |

| Returns |
|---|---|
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<T?>` | a flow of the trait of type T from this device type. |

### userPresenceSettings

```
@HomeExperimentalApi
fun Structure.userPresenceSettings(): Flow<UserPresenceSettings>
```

Gets an observable flow indicating the user presence settings for the structure.

| Returns |
|---|---|
| `https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/index.html<https://developers.home.google.com/reference/kotlin/com/google/home/google/UserPresenceSettings>` | a flow of `https://developers.home.google.com/reference/kotlin/com/google/home/google/UserPresenceSettings`. |