@@ -33,11 +33,11 @@ option java_multiple_files = true;
3333option java_outer_classname = "DeviceManagerProto" ;
3434option java_package = "com.google.cloud.iot.v1" ;
3535
36-
3736// Internet of Things (IoT) service. Securely connect and manage IoT devices.
3837service DeviceManager {
3938 // Creates a device registry that contains devices.
40- rpc CreateDeviceRegistry (CreateDeviceRegistryRequest ) returns (DeviceRegistry ) {
39+ rpc CreateDeviceRegistry (CreateDeviceRegistryRequest )
40+ returns (DeviceRegistry ) {
4141 option (google.api.http ) = {
4242 post : "/v1/{parent=projects/*/locations/*}/registries"
4343 body : "device_registry"
@@ -52,22 +52,25 @@ service DeviceManager {
5252 }
5353
5454 // Updates a device registry configuration.
55- rpc UpdateDeviceRegistry (UpdateDeviceRegistryRequest ) returns (DeviceRegistry ) {
55+ rpc UpdateDeviceRegistry (UpdateDeviceRegistryRequest )
56+ returns (DeviceRegistry ) {
5657 option (google.api.http ) = {
5758 patch : "/v1/{device_registry.name=projects/*/locations/*/registries/*}"
5859 body : "device_registry"
5960 };
6061 }
6162
6263 // Deletes a device registry configuration.
63- rpc DeleteDeviceRegistry (DeleteDeviceRegistryRequest ) returns (google.protobuf.Empty ) {
64+ rpc DeleteDeviceRegistry (DeleteDeviceRegistryRequest )
65+ returns (google.protobuf.Empty ) {
6466 option (google.api.http ) = {
6567 delete : "/v1/{name=projects/*/locations/*/registries/*}"
6668 };
6769 }
6870
6971 // Lists device registries.
70- rpc ListDeviceRegistries (ListDeviceRegistriesRequest ) returns (ListDeviceRegistriesResponse ) {
72+ rpc ListDeviceRegistries (ListDeviceRegistriesRequest )
73+ returns (ListDeviceRegistriesResponse ) {
7174 option (google.api.http ) = {
7275 get : "/v1/{parent=projects/*/locations/*}/registries"
7376 };
@@ -123,7 +126,8 @@ service DeviceManager {
123126 // Modifies the configuration for the device, which is eventually sent from
124127 // the Cloud IoT Core servers. Returns the modified configuration version and
125128 // its metadata.
126- rpc ModifyCloudToDeviceConfig (ModifyCloudToDeviceConfigRequest ) returns (DeviceConfig ) {
129+ rpc ModifyCloudToDeviceConfig (ModifyCloudToDeviceConfigRequest )
130+ returns (DeviceConfig ) {
127131 option (google.api.http ) = {
128132 post : "/v1/{name=projects/*/locations/*/registries/*/devices/*}:modifyCloudToDeviceConfig"
129133 body : "*"
@@ -136,7 +140,8 @@ service DeviceManager {
136140
137141 // Lists the last few versions of the device configuration in descending
138142 // order (i.e.: newest first).
139- rpc ListDeviceConfigVersions (ListDeviceConfigVersionsRequest ) returns (ListDeviceConfigVersionsResponse ) {
143+ rpc ListDeviceConfigVersions (ListDeviceConfigVersionsRequest )
144+ returns (ListDeviceConfigVersionsResponse ) {
140145 option (google.api.http ) = {
141146 get : "/v1/{name=projects/*/locations/*/registries/*/devices/*}/configVersions"
142147 additional_bindings {
@@ -147,7 +152,8 @@ service DeviceManager {
147152
148153 // Lists the last few versions of the device state in descending order (i.e.:
149154 // newest first).
150- rpc ListDeviceStates (ListDeviceStatesRequest ) returns (ListDeviceStatesResponse ) {
155+ rpc ListDeviceStates (ListDeviceStatesRequest )
156+ returns (ListDeviceStatesResponse ) {
151157 option (google.api.http ) = {
152158 get : "/v1/{name=projects/*/locations/*/registries/*/devices/*}/states"
153159 additional_bindings {
@@ -158,7 +164,8 @@ service DeviceManager {
158164
159165 // Sets the access control policy on the specified resource. Replaces any
160166 // existing policy.
161- rpc SetIamPolicy (google.iam.v1.SetIamPolicyRequest ) returns (google.iam.v1.Policy ) {
167+ rpc SetIamPolicy (google.iam.v1.SetIamPolicyRequest )
168+ returns (google.iam.v1.Policy ) {
162169 option (google.api.http ) = {
163170 post : "/v1/{resource=projects/*/locations/*/registries/*}:setIamPolicy"
164171 body : "*"
@@ -172,7 +179,8 @@ service DeviceManager {
172179 // Gets the access control policy for a resource.
173180 // Returns an empty policy if the resource exists and does not have a policy
174181 // set.
175- rpc GetIamPolicy (google.iam.v1.GetIamPolicyRequest ) returns (google.iam.v1.Policy ) {
182+ rpc GetIamPolicy (google.iam.v1.GetIamPolicyRequest )
183+ returns (google.iam.v1.Policy ) {
176184 option (google.api.http ) = {
177185 post : "/v1/{resource=projects/*/locations/*/registries/*}:getIamPolicy"
178186 body : "*"
@@ -186,7 +194,8 @@ service DeviceManager {
186194 // Returns permissions that a caller has on the specified resource.
187195 // If the resource does not exist, this will return an empty set of
188196 // permissions, not a NOT_FOUND error.
189- rpc TestIamPermissions (google.iam.v1.TestIamPermissionsRequest ) returns (google.iam.v1.TestIamPermissionsResponse ) {
197+ rpc TestIamPermissions (google.iam.v1.TestIamPermissionsRequest )
198+ returns (google.iam.v1.TestIamPermissionsResponse ) {
190199 option (google.api.http ) = {
191200 post : "/v1/{resource=projects/*/locations/*/registries/*}:testIamPermissions"
192201 body : "*"
@@ -210,7 +219,8 @@ service DeviceManager {
210219 // method will return FAILED_PRECONDITION. Otherwise, this method will
211220 // return OK. If the subscription is QoS 1, at least once delivery will be
212221 // guaranteed; for QoS 0, no acknowledgment will be expected from the device.
213- rpc SendCommandToDevice (SendCommandToDeviceRequest ) returns (SendCommandToDeviceResponse ) {
222+ rpc SendCommandToDevice (SendCommandToDeviceRequest )
223+ returns (SendCommandToDeviceResponse ) {
214224 option (google.api.http ) = {
215225 post : "/v1/{name=projects/*/locations/*/registries/*/devices/*}:sendCommandToDevice"
216226 body : "*"
@@ -222,7 +232,8 @@ service DeviceManager {
222232 }
223233
224234 // Associates the device with the gateway.
225- rpc BindDeviceToGateway (BindDeviceToGatewayRequest ) returns (BindDeviceToGatewayResponse ) {
235+ rpc BindDeviceToGateway (BindDeviceToGatewayRequest )
236+ returns (BindDeviceToGatewayResponse ) {
226237 option (google.api.http ) = {
227238 post : "/v1/{parent=projects/*/locations/*/registries/*}:bindDeviceToGateway"
228239 body : "*"
@@ -234,7 +245,8 @@ service DeviceManager {
234245 }
235246
236247 // Deletes the association between the device and the gateway.
237- rpc UnbindDeviceFromGateway (UnbindDeviceFromGatewayRequest ) returns (UnbindDeviceFromGatewayResponse ) {
248+ rpc UnbindDeviceFromGateway (UnbindDeviceFromGatewayRequest )
249+ returns (UnbindDeviceFromGatewayResponse ) {
238250 option (google.api.http ) = {
239251 post : "/v1/{parent=projects/*/locations/*/registries/*}:unbindDeviceFromGateway"
240252 body : "*"
@@ -509,9 +521,7 @@ message SendCommandToDeviceRequest {
509521}
510522
511523// Response for `SendCommandToDevice`.
512- message SendCommandToDeviceResponse {
513-
514- }
524+ message SendCommandToDeviceResponse {}
515525
516526// Request for `BindDeviceToGateway`.
517527message BindDeviceToGatewayRequest {
@@ -530,9 +540,7 @@ message BindDeviceToGatewayRequest {
530540}
531541
532542// Response for `BindDeviceToGateway`.
533- message BindDeviceToGatewayResponse {
534-
535- }
543+ message BindDeviceToGatewayResponse {}
536544
537545// Request for `UnbindDeviceFromGateway`.
538546message UnbindDeviceFromGatewayRequest {
@@ -551,6 +559,4 @@ message UnbindDeviceFromGatewayRequest {
551559}
552560
553561// Response for `UnbindDeviceFromGateway`.
554- message UnbindDeviceFromGatewayResponse {
555-
556- }
562+ message UnbindDeviceFromGatewayResponse {}
0 commit comments