var File_google_home_graph_v1_device_proto protoreflect.FileDescriptor
var File_google_home_graph_v1_homegraph_proto protoreflect.FileDescriptor
func RegisterHomeGraphApiServiceServer(s *grpc.Server, srv HomeGraphApiServiceServer)
Third-party device ID for one device.
type AgentDeviceId struct { // Third-party device ID. Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*AgentDeviceId) Descriptor() ([]byte, []int)
Deprecated: Use AgentDeviceId.ProtoReflect.Descriptor instead.
func (x *AgentDeviceId) GetId() string
func (*AgentDeviceId) ProtoMessage()
func (x *AgentDeviceId) ProtoReflect() protoreflect.Message
func (x *AgentDeviceId) Reset()
func (x *AgentDeviceId) String() string
Alternate third-party device ID.
type AgentOtherDeviceId struct { // Project ID for your smart home Action. AgentId string `protobuf:"bytes,1,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"` // Unique third-party device ID. DeviceId string `protobuf:"bytes,2,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"` // contains filtered or unexported fields }
func (*AgentOtherDeviceId) Descriptor() ([]byte, []int)
Deprecated: Use AgentOtherDeviceId.ProtoReflect.Descriptor instead.
func (x *AgentOtherDeviceId) GetAgentId() string
func (x *AgentOtherDeviceId) GetDeviceId() string
func (*AgentOtherDeviceId) ProtoMessage()
func (x *AgentOtherDeviceId) ProtoReflect() protoreflect.Message
func (x *AgentOtherDeviceId) Reset()
func (x *AgentOtherDeviceId) String() string
Request type for the [`DeleteAgentUser`](#google.home.graph.v1.HomeGraphApiService.DeleteAgentUser) call.
type DeleteAgentUserRequest struct { // Request ID used for debugging. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Required. Third-party user ID. AgentUserId string `protobuf:"bytes,2,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // contains filtered or unexported fields }
func (*DeleteAgentUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteAgentUserRequest.ProtoReflect.Descriptor instead.
func (x *DeleteAgentUserRequest) GetAgentUserId() string
func (x *DeleteAgentUserRequest) GetRequestId() string
func (*DeleteAgentUserRequest) ProtoMessage()
func (x *DeleteAgentUserRequest) ProtoReflect() protoreflect.Message
func (x *DeleteAgentUserRequest) Reset()
func (x *DeleteAgentUserRequest) String() string
Third-party device definition.
type Device struct { // Third-party device ID. Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // Hardware type of the device. // See [device // types](https://developers.home.google.com/cloud-to-cloud/guides). Type string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"` // Traits supported by the device. // See [device // traits](https://developers.home.google.com/cloud-to-cloud/traits). Traits []string `protobuf:"bytes,3,rep,name=traits,proto3" json:"traits,omitempty"` // Names given to this device by your smart home Action. Name *DeviceNames `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` // Indicates whether your smart home Action will report state of this device // to Google via // [ReportStateAndNotification][google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification]. WillReportState bool `protobuf:"varint,5,opt,name=will_report_state,json=willReportState,proto3" json:"will_report_state,omitempty"` // Suggested name for the room where this device is installed. // Google attempts to use this value during user setup. RoomHint string `protobuf:"bytes,6,opt,name=room_hint,json=roomHint,proto3" json:"room_hint,omitempty"` // Suggested name for the structure where this device is installed. // Google attempts to use this value during user setup. StructureHint string `protobuf:"bytes,7,opt,name=structure_hint,json=structureHint,proto3" json:"structure_hint,omitempty"` // Device manufacturer, model, hardware version, and software version. DeviceInfo *DeviceInfo `protobuf:"bytes,8,opt,name=device_info,json=deviceInfo,proto3" json:"device_info,omitempty"` // Attributes for the traits supported by the device. Attributes *structpb.Struct `protobuf:"bytes,9,opt,name=attributes,proto3" json:"attributes,omitempty"` // 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. CustomData *structpb.Struct `protobuf:"bytes,10,opt,name=custom_data,json=customData,proto3" json:"custom_data,omitempty"` // 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). OtherDeviceIds []*AgentOtherDeviceId `protobuf:"bytes,11,rep,name=other_device_ids,json=otherDeviceIds,proto3" json:"other_device_ids,omitempty"` // Indicates whether your smart home Action will report notifications // to Google for this device via // [ReportStateAndNotification][google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification]. // // If your smart home Action enables users to control device notifications, // you should update this field and call // [RequestSyncDevices][google.home.graph.v1.HomeGraphApiService.RequestSyncDevices]. NotificationSupportedByAgent bool `protobuf:"varint,12,opt,name=notification_supported_by_agent,json=notificationSupportedByAgent,proto3" json:"notification_supported_by_agent,omitempty"` // contains filtered or unexported fields }
func (*Device) Descriptor() ([]byte, []int)
Deprecated: Use Device.ProtoReflect.Descriptor instead.
func (x *Device) GetAttributes() *structpb.Struct
func (x *Device) GetCustomData() *structpb.Struct
func (x *Device) GetDeviceInfo() *DeviceInfo
func (x *Device) GetId() string
func (x *Device) GetName() *DeviceNames
func (x *Device) GetNotificationSupportedByAgent() bool
func (x *Device) GetOtherDeviceIds() []*AgentOtherDeviceId
func (x *Device) GetRoomHint() string
func (x *Device) GetStructureHint() string
func (x *Device) GetTraits() []string
func (x *Device) GetType() string
func (x *Device) GetWillReportState() bool
func (*Device) ProtoMessage()
func (x *Device) ProtoReflect() protoreflect.Message
func (x *Device) Reset()
func (x *Device) String() string
Device information.
type DeviceInfo struct { // Device manufacturer. Manufacturer string `protobuf:"bytes,1,opt,name=manufacturer,proto3" json:"manufacturer,omitempty"` // Device model. Model string `protobuf:"bytes,2,opt,name=model,proto3" json:"model,omitempty"` // Device hardware version. HwVersion string `protobuf:"bytes,3,opt,name=hw_version,json=hwVersion,proto3" json:"hw_version,omitempty"` // Device software version. SwVersion string `protobuf:"bytes,4,opt,name=sw_version,json=swVersion,proto3" json:"sw_version,omitempty"` // contains filtered or unexported fields }
func (*DeviceInfo) Descriptor() ([]byte, []int)
Deprecated: Use DeviceInfo.ProtoReflect.Descriptor instead.
func (x *DeviceInfo) GetHwVersion() string
func (x *DeviceInfo) GetManufacturer() string
func (x *DeviceInfo) GetModel() string
func (x *DeviceInfo) GetSwVersion() string
func (*DeviceInfo) ProtoMessage()
func (x *DeviceInfo) ProtoReflect() protoreflect.Message
func (x *DeviceInfo) Reset()
func (x *DeviceInfo) String() string
Identifiers used to describe the device.
type DeviceNames struct { // Primary name of the device, generally provided by the user. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Additional names provided by the user for the device. Nicknames []string `protobuf:"bytes,2,rep,name=nicknames,proto3" json:"nicknames,omitempty"` // List of names provided by the manufacturer rather than the user, such as // serial numbers, SKUs, etc. DefaultNames []string `protobuf:"bytes,3,rep,name=default_names,json=defaultNames,proto3" json:"default_names,omitempty"` // contains filtered or unexported fields }
func (*DeviceNames) Descriptor() ([]byte, []int)
Deprecated: Use DeviceNames.ProtoReflect.Descriptor instead.
func (x *DeviceNames) GetDefaultNames() []string
func (x *DeviceNames) GetName() string
func (x *DeviceNames) GetNicknames() []string
func (*DeviceNames) ProtoMessage()
func (x *DeviceNames) ProtoReflect() protoreflect.Message
func (x *DeviceNames) Reset()
func (x *DeviceNames) String() string
HomeGraphApiServiceClient is the client API for HomeGraphApiService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type HomeGraphApiServiceClient interface { // 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][google.home.graph.v1.RequestSyncDevicesRequest]). // This request must be authorized using service account credentials from your // Actions console project. RequestSyncDevices(ctx context.Context, in *RequestSyncDevicesRequest, opts ...grpc.CallOption) (*RequestSyncDevicesResponse, error) // 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][google.home.graph.v1.ReportStateAndNotificationRequest]). // This request must be authorized using service account credentials from your // Actions console project. ReportStateAndNotification(ctx context.Context, in *ReportStateAndNotificationRequest, opts ...grpc.CallOption) (*ReportStateAndNotificationResponse, error) // 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][google.home.graph.v1.DeleteAgentUserRequest]). // This request must be authorized using service account credentials from your // Actions console project. DeleteAgentUser(ctx context.Context, in *DeleteAgentUserRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) // 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][google.home.graph.v1.QueryRequest]). // This request must be authorized using service account credentials from your // Actions console project. Query(ctx context.Context, in *QueryRequest, opts ...grpc.CallOption) (*QueryResponse, error) // 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][google.home.graph.v1.SyncRequest]). // This request must be authorized using service account credentials from your // Actions console project. Sync(ctx context.Context, in *SyncRequest, opts ...grpc.CallOption) (*SyncResponse, error) }
func NewHomeGraphApiServiceClient(cc grpc.ClientConnInterface) HomeGraphApiServiceClient
HomeGraphApiServiceServer is the server API for HomeGraphApiService service.
type HomeGraphApiServiceServer interface { // 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][google.home.graph.v1.RequestSyncDevicesRequest]). // This request must be authorized using service account credentials from your // Actions console project. RequestSyncDevices(context.Context, *RequestSyncDevicesRequest) (*RequestSyncDevicesResponse, error) // 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][google.home.graph.v1.ReportStateAndNotificationRequest]). // This request must be authorized using service account credentials from your // Actions console project. ReportStateAndNotification(context.Context, *ReportStateAndNotificationRequest) (*ReportStateAndNotificationResponse, error) // 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][google.home.graph.v1.DeleteAgentUserRequest]). // This request must be authorized using service account credentials from your // Actions console project. DeleteAgentUser(context.Context, *DeleteAgentUserRequest) (*emptypb.Empty, error) // 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][google.home.graph.v1.QueryRequest]). // This request must be authorized using service account credentials from your // Actions console project. Query(context.Context, *QueryRequest) (*QueryResponse, error) // 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][google.home.graph.v1.SyncRequest]). // This request must be authorized using service account credentials from your // Actions console project. Sync(context.Context, *SyncRequest) (*SyncResponse, error) }
Request type for the [`Query`](#google.home.graph.v1.HomeGraphApiService.Query) call.
type QueryRequest struct { // Request ID used for debugging. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Required. Third-party user ID. AgentUserId string `protobuf:"bytes,2,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // Required. Inputs containing third-party device IDs for which to // get the device states. Inputs []*QueryRequestInput `protobuf:"bytes,3,rep,name=inputs,proto3" json:"inputs,omitempty"` // contains filtered or unexported fields }
func (*QueryRequest) Descriptor() ([]byte, []int)
Deprecated: Use QueryRequest.ProtoReflect.Descriptor instead.
func (x *QueryRequest) GetAgentUserId() string
func (x *QueryRequest) GetInputs() []*QueryRequestInput
func (x *QueryRequest) GetRequestId() string
func (*QueryRequest) ProtoMessage()
func (x *QueryRequest) ProtoReflect() protoreflect.Message
func (x *QueryRequest) Reset()
func (x *QueryRequest) String() string
Device ID inputs to QueryRequest[google.home.graph.v1.QueryRequest].
type QueryRequestInput struct { // Payload containing third-party device IDs. Payload *QueryRequestPayload `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` // contains filtered or unexported fields }
func (*QueryRequestInput) Descriptor() ([]byte, []int)
Deprecated: Use QueryRequestInput.ProtoReflect.Descriptor instead.
func (x *QueryRequestInput) GetPayload() *QueryRequestPayload
func (*QueryRequestInput) ProtoMessage()
func (x *QueryRequestInput) ProtoReflect() protoreflect.Message
func (x *QueryRequestInput) Reset()
func (x *QueryRequestInput) String() string
Payload containing device IDs.
type QueryRequestPayload struct { // Third-party device IDs for which to get the device states. Devices []*AgentDeviceId `protobuf:"bytes,1,rep,name=devices,proto3" json:"devices,omitempty"` // contains filtered or unexported fields }
func (*QueryRequestPayload) Descriptor() ([]byte, []int)
Deprecated: Use QueryRequestPayload.ProtoReflect.Descriptor instead.
func (x *QueryRequestPayload) GetDevices() []*AgentDeviceId
func (*QueryRequestPayload) ProtoMessage()
func (x *QueryRequestPayload) ProtoReflect() protoreflect.Message
func (x *QueryRequestPayload) Reset()
func (x *QueryRequestPayload) String() string
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 QueryResponse struct { // Request ID used for debugging. Copied from the request. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Device states for the devices given in the request. Payload *QueryResponsePayload `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` // contains filtered or unexported fields }
func (*QueryResponse) Descriptor() ([]byte, []int)
Deprecated: Use QueryResponse.ProtoReflect.Descriptor instead.
func (x *QueryResponse) GetPayload() *QueryResponsePayload
func (x *QueryResponse) GetRequestId() string
func (*QueryResponse) ProtoMessage()
func (x *QueryResponse) ProtoReflect() protoreflect.Message
func (x *QueryResponse) Reset()
func (x *QueryResponse) String() string
Payload containing device states information.
type QueryResponsePayload struct { // States of the devices. Map of third-party device ID to struct of device // states. Devices map[string]*structpb.Struct `protobuf:"bytes,1,rep,name=devices,proto3" json:"devices,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` // contains filtered or unexported fields }
func (*QueryResponsePayload) Descriptor() ([]byte, []int)
Deprecated: Use QueryResponsePayload.ProtoReflect.Descriptor instead.
func (x *QueryResponsePayload) GetDevices() map[string]*structpb.Struct
func (*QueryResponsePayload) ProtoMessage()
func (x *QueryResponsePayload) ProtoReflect() protoreflect.Message
func (x *QueryResponsePayload) Reset()
func (x *QueryResponsePayload) String() string
The states and notifications specific to a device.
type ReportStateAndNotificationDevice struct { // 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). States *structpb.Struct `protobuf:"bytes,1,opt,name=states,proto3" json:"states,omitempty"` // Notifications metadata for devices. See the **Device NOTIFICATIONS** // section of the individual trait [reference // guides](https://developers.home.google.com/cloud-to-cloud/traits). Notifications *structpb.Struct `protobuf:"bytes,2,opt,name=notifications,proto3" json:"notifications,omitempty"` // contains filtered or unexported fields }
func (*ReportStateAndNotificationDevice) Descriptor() ([]byte, []int)
Deprecated: Use ReportStateAndNotificationDevice.ProtoReflect.Descriptor instead.
func (x *ReportStateAndNotificationDevice) GetNotifications() *structpb.Struct
func (x *ReportStateAndNotificationDevice) GetStates() *structpb.Struct
func (*ReportStateAndNotificationDevice) ProtoMessage()
func (x *ReportStateAndNotificationDevice) ProtoReflect() protoreflect.Message
func (x *ReportStateAndNotificationDevice) Reset()
func (x *ReportStateAndNotificationDevice) String() string
Request type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call. It may include states, notifications, or both. States and notifications are defined per `device_id` (for example, "123" and "456" 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 } }, } } }
```
type ReportStateAndNotificationRequest struct { // Request ID used for debugging. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Unique identifier per event (for example, a doorbell press). EventId string `protobuf:"bytes,4,opt,name=event_id,json=eventId,proto3" json:"event_id,omitempty"` // Required. Third-party user ID. AgentUserId string `protobuf:"bytes,2,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // Deprecated. // // Deprecated: Do not use. FollowUpToken string `protobuf:"bytes,5,opt,name=follow_up_token,json=followUpToken,proto3" json:"follow_up_token,omitempty"` // Required. State of devices to update and notification metadata for devices. Payload *StateAndNotificationPayload `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"` // contains filtered or unexported fields }
func (*ReportStateAndNotificationRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReportStateAndNotificationRequest.ProtoReflect.Descriptor instead.
func (x *ReportStateAndNotificationRequest) GetAgentUserId() string
func (x *ReportStateAndNotificationRequest) GetEventId() string
func (x *ReportStateAndNotificationRequest) GetFollowUpToken() string
Deprecated: Do not use.
func (x *ReportStateAndNotificationRequest) GetPayload() *StateAndNotificationPayload
func (x *ReportStateAndNotificationRequest) GetRequestId() string
func (*ReportStateAndNotificationRequest) ProtoMessage()
func (x *ReportStateAndNotificationRequest) ProtoReflect() protoreflect.Message
func (x *ReportStateAndNotificationRequest) Reset()
func (x *ReportStateAndNotificationRequest) String() string
Response type for the [`ReportStateAndNotification`](#google.home.graph.v1.HomeGraphApiService.ReportStateAndNotification) call.
type ReportStateAndNotificationResponse struct { // Request ID copied from // [ReportStateAndNotificationRequest][google.home.graph.v1.ReportStateAndNotificationRequest]. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // contains filtered or unexported fields }
func (*ReportStateAndNotificationResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReportStateAndNotificationResponse.ProtoReflect.Descriptor instead.
func (x *ReportStateAndNotificationResponse) GetRequestId() string
func (*ReportStateAndNotificationResponse) ProtoMessage()
func (x *ReportStateAndNotificationResponse) ProtoReflect() protoreflect.Message
func (x *ReportStateAndNotificationResponse) Reset()
func (x *ReportStateAndNotificationResponse) String() string
Request type for the [`RequestSyncDevices`](#google.home.graph.v1.HomeGraphApiService.RequestSyncDevices) call.
type RequestSyncDevicesRequest struct { // Required. Third-party user ID. AgentUserId string `protobuf:"bytes,1,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // 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. Async bool `protobuf:"varint,2,opt,name=async,proto3" json:"async,omitempty"` // contains filtered or unexported fields }
func (*RequestSyncDevicesRequest) Descriptor() ([]byte, []int)
Deprecated: Use RequestSyncDevicesRequest.ProtoReflect.Descriptor instead.
func (x *RequestSyncDevicesRequest) GetAgentUserId() string
func (x *RequestSyncDevicesRequest) GetAsync() bool
func (*RequestSyncDevicesRequest) ProtoMessage()
func (x *RequestSyncDevicesRequest) ProtoReflect() protoreflect.Message
func (x *RequestSyncDevicesRequest) Reset()
func (x *RequestSyncDevicesRequest) String() string
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.
type RequestSyncDevicesResponse struct {
// contains filtered or unexported fields
}
func (*RequestSyncDevicesResponse) Descriptor() ([]byte, []int)
Deprecated: Use RequestSyncDevicesResponse.ProtoReflect.Descriptor instead.
func (*RequestSyncDevicesResponse) ProtoMessage()
func (x *RequestSyncDevicesResponse) ProtoReflect() protoreflect.Message
func (x *RequestSyncDevicesResponse) Reset()
func (x *RequestSyncDevicesResponse) String() string
Payload containing the state and notification information for devices.
type StateAndNotificationPayload struct { // The devices for updating state and sending notifications. Devices *ReportStateAndNotificationDevice `protobuf:"bytes,1,opt,name=devices,proto3" json:"devices,omitempty"` // contains filtered or unexported fields }
func (*StateAndNotificationPayload) Descriptor() ([]byte, []int)
Deprecated: Use StateAndNotificationPayload.ProtoReflect.Descriptor instead.
func (x *StateAndNotificationPayload) GetDevices() *ReportStateAndNotificationDevice
func (*StateAndNotificationPayload) ProtoMessage()
func (x *StateAndNotificationPayload) ProtoReflect() protoreflect.Message
func (x *StateAndNotificationPayload) Reset()
func (x *StateAndNotificationPayload) String() string
Request type for the [`Sync`](#google.home.graph.v1.HomeGraphApiService.Sync) call.
type SyncRequest struct { // Request ID used for debugging. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Required. Third-party user ID. AgentUserId string `protobuf:"bytes,2,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // contains filtered or unexported fields }
func (*SyncRequest) Descriptor() ([]byte, []int)
Deprecated: Use SyncRequest.ProtoReflect.Descriptor instead.
func (x *SyncRequest) GetAgentUserId() string
func (x *SyncRequest) GetRequestId() string
func (*SyncRequest) ProtoMessage()
func (x *SyncRequest) ProtoReflect() protoreflect.Message
func (x *SyncRequest) Reset()
func (x *SyncRequest) String() string
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" } }] } }
```
type SyncResponse struct { // Request ID used for debugging. Copied from the request. RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Devices associated with the third-party user. Payload *SyncResponsePayload `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` // contains filtered or unexported fields }
func (*SyncResponse) Descriptor() ([]byte, []int)
Deprecated: Use SyncResponse.ProtoReflect.Descriptor instead.
func (x *SyncResponse) GetPayload() *SyncResponsePayload
func (x *SyncResponse) GetRequestId() string
func (*SyncResponse) ProtoMessage()
func (x *SyncResponse) ProtoReflect() protoreflect.Message
func (x *SyncResponse) Reset()
func (x *SyncResponse) String() string
Payload containing device information.
type SyncResponsePayload struct { // Third-party user ID AgentUserId string `protobuf:"bytes,1,opt,name=agent_user_id,json=agentUserId,proto3" json:"agent_user_id,omitempty"` // Devices associated with the third-party user. Devices []*Device `protobuf:"bytes,2,rep,name=devices,proto3" json:"devices,omitempty"` // contains filtered or unexported fields }
func (*SyncResponsePayload) Descriptor() ([]byte, []int)
Deprecated: Use SyncResponsePayload.ProtoReflect.Descriptor instead.
func (x *SyncResponsePayload) GetAgentUserId() string
func (x *SyncResponsePayload) GetDevices() []*Device
func (*SyncResponsePayload) ProtoMessage()
func (x *SyncResponsePayload) ProtoReflect() protoreflect.Message
func (x *SyncResponsePayload) Reset()
func (x *SyncResponsePayload) String() string
UnimplementedHomeGraphApiServiceServer can be embedded to have forward compatible implementations.
type UnimplementedHomeGraphApiServiceServer struct { }
func (*UnimplementedHomeGraphApiServiceServer) DeleteAgentUser(context.Context, *DeleteAgentUserRequest) (*emptypb.Empty, error)
func (*UnimplementedHomeGraphApiServiceServer) Query(context.Context, *QueryRequest) (*QueryResponse, error)
func (*UnimplementedHomeGraphApiServiceServer) ReportStateAndNotification(context.Context, *ReportStateAndNotificationRequest) (*ReportStateAndNotificationResponse, error)
func (*UnimplementedHomeGraphApiServiceServer) RequestSyncDevices(context.Context, *RequestSyncDevicesRequest) (*RequestSyncDevicesResponse, error)
func (*UnimplementedHomeGraphApiServiceServer) Sync(context.Context, *SyncRequest) (*SyncResponse, error)