@kusinta/iot-schema 0.1.0-beta.20 → 0.1.0-beta.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kusinta/iot-schema",
3
- "version": "0.1.0-beta.20",
3
+ "version": "0.1.0-beta.21",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "files": ["src"],
@@ -23,6 +23,7 @@
23
23
  "./connector/service": "./src/kusinta/iot/connector/v1/connector_service_pb.js",
24
24
  "./webrtc": "./src/kusinta/iot/webrtc/v1/envelope_pb.js",
25
25
  "./webrtc/app-token": "./src/kusinta/iot/webrtc/v1/app_token_pb.js",
26
+ "./webrtc/management": "./src/kusinta/iot/webrtc/v1/management_pb.js",
26
27
  "./registration": "./src/kusinta/iot/registration/v1/registration_pb.js",
27
28
  "./registration/service": "./src/kusinta/iot/registration/v1/registration_service_pb.js",
28
29
  "./signaling": "./src/kusinta/iot/signaling/v1/signaling_pb.js",
@@ -14,7 +14,7 @@ export declare const file_kusinta_iot_device_v1_property_update: GenFile;
14
14
 
15
15
  /**
16
16
  * PropertyUpdate carries a single attribute change from connector to gateway,
17
- * or from gateway to Flutter app.
17
+ * or from gateway to app.
18
18
  *
19
19
  * Resolution rule (normative)
20
20
  *
@@ -46,7 +46,7 @@ export declare const SdpAnswerSchema: GenMessage<SdpAnswer>;
46
46
  /**
47
47
  * candidate is the SDP candidate attribute line. sdp_mid / sdp_mline_index
48
48
  * bind it to a media section: WebRTC's addIceCandidate requires a non-null
49
- * sdpMid (passing null NPEs in the Android JNI layer). Under BUNDLE both are
49
+ * sdpMid (some native WebRTC bindings crash on a null). Under BUNDLE both are
50
50
  * constant ("0" / 0) for a single-m-line session, but they must be carried so
51
51
  * candidates stay correct once additional m-lines (e.g. camera video) exist.
52
52
  *
@@ -78,7 +78,7 @@ export declare const IceCandidateSchema: GenMessage<IceCandidate>;
78
78
  /**
79
79
  * Empty keepalive. The gateway sends this periodically on the GatewayConnect
80
80
  * stream so the otherwise-idle bidi request keeps producing DATA frames, which
81
- * resets HAProxy's inactivity timers (timeout client/server) and stops the relay
81
+ * resets the inactivity timers on any proxy between the two ends and stops it
82
82
  * from tearing the stream down. Carries no routing target and is dropped on receipt.
83
83
  *
84
84
  * @generated from message kusinta.iot.signaling.v1.HeartBeat
@@ -134,7 +134,8 @@ export declare const UserHandshakeAckSchema: GenMessage<UserHandshakeAck>;
134
134
 
135
135
  /**
136
136
  * Messages sent by the building-server gateway (GatewaySignalingService.GatewayConnect stream).
137
- * Auth: x-client-cert-fingerprint metadata header (set by HAProxy from mTLS).
137
+ * Auth: x-client-cert-fingerprint metadata header, set from the client
138
+ * certificate by the mTLS-terminating proxy in front of this service.
138
139
  *
139
140
  * @generated from message kusinta.iot.signaling.v1.GatewayConnectRequest
140
141
  */
@@ -227,7 +228,7 @@ export declare type GatewayConnectResponse = Message<"kusinta.iot.signaling.v1.G
227
228
  export declare const GatewayConnectResponseSchema: GenMessage<GatewayConnectResponse>;
228
229
 
229
230
  /**
230
- * Messages sent by the Flutter app (GatewaySignalingService.UserConnect stream).
231
+ * Messages sent by the app (GatewaySignalingService.UserConnect stream).
231
232
  * Auth: Authorization: Bearer <jwt> in gRPC request metadata (validated by interceptor).
232
233
  *
233
234
  * @generated from message kusinta.iot.signaling.v1.UserConnectRequest
@@ -273,7 +274,7 @@ export declare type UserConnectRequest = Message<"kusinta.iot.signaling.v1.UserC
273
274
  export declare const UserConnectRequestSchema: GenMessage<UserConnectRequest>;
274
275
 
275
276
  /**
276
- * Messages sent by the api-server to the Flutter app.
277
+ * Messages sent by the api-server to the app.
277
278
  *
278
279
  * @generated from message kusinta.iot.signaling.v1.UserConnectResponse
279
280
  */
@@ -14,9 +14,9 @@ export declare const file_kusinta_iot_webrtc_v1_app_token: GenFile;
14
14
 
15
15
  /**
16
16
  * AppTokenClaims is the contract for the payload of the JWT carried in
17
- * AppHandshake.jwt. It is the single source of truth shared between
18
- * mykusinta-api-server (which mints the token) and the gateway (which validates
19
- * it locally against the mykusinta-api-server public key).
17
+ * AppHandshake.jwt. It is the single source of truth shared between the
18
+ * api-server (which mints the token) and the gateway (which validates it
19
+ * locally against the api-server's public key).
20
20
  *
21
21
  * This message is NOT sent on the wire — the wire value stays the signed,
22
22
  * compact JWS string in AppHandshake.jwt. The fields here document the claim
@@ -30,8 +30,8 @@ export declare const file_kusinta_iot_webrtc_v1_app_token: GenFile;
30
30
  export declare type AppTokenClaims = Message<"kusinta.iot.webrtc.v1.AppTokenClaims"> & {
31
31
  /**
32
32
  * Registered claims (RFC 7519).
33
- *
34
- * issuer: "mykusinta-api-server"
33
+ * Issuer: the api-server's issuer identifier, agreed out of band. A fixed
34
+ * string both sides compare exactly — not derived from anything here.
35
35
  *
36
36
  * @generated from field: string iss = 1;
37
37
  */
@@ -71,8 +71,7 @@ export declare type AppTokenClaims = Message<"kusinta.iot.webrtc.v1.AppTokenClai
71
71
  * this is a list. Carried in the JWT as an array of enum NAME strings
72
72
  * (e.g. ["ROLE_RESIDENT", "ROLE_GATEWAY_ADMIN"]), matching proto3 canonical
73
73
  * JSON enum encoding — not integer values. This keeps the claim
74
- * self-describing and aligns with text-typed role storage in
75
- * mykusinta-api-server.
74
+ * self-describing and aligns with text-typed role storage on the api-server.
76
75
  *
77
76
  * @generated from field: repeated kusinta.iot.access.v1.Role roles = 6;
78
77
  */
@@ -98,10 +97,10 @@ export declare type AppTokenClaims = Message<"kusinta.iot.webrtc.v1.AppTokenClai
98
97
  * stripping it.
99
98
  *
100
99
  * Rollout order, since a mandatory claim cannot appear on both sides at once:
101
- * mykusinta-api-server must be issuing cnf on every token BEFORE the gateway
102
- * begins rejecting tokens that lack it. Reverse that order and every live
103
- * session is refused. Tokens are short-TTL, so the gap between the two
104
- * deployments need only exceed one token lifetime.
100
+ * the api-server must be issuing cnf on every token BEFORE the gateway begins
101
+ * rejecting tokens that lack it. Reverse that order and every live session is
102
+ * refused. Tokens are short-TTL, so the gap between the two deployments need
103
+ * only exceed one token lifetime.
105
104
  *
106
105
  * @generated from field: kusinta.iot.webrtc.v1.Confirmation cnf = 7;
107
106
  */
@@ -236,7 +236,7 @@ export declare type CommandError = Message<"kusinta.iot.webrtc.v1.CommandError">
236
236
  export declare const CommandErrorSchema: GenMessage<CommandError>;
237
237
 
238
238
  /**
239
- * CommandResult travels gateway → Flutter app (GatewayMessage) and
239
+ * CommandResult travels gateway → app (GatewayMessage) and
240
240
  * connector → gateway (SessionRequest via connector.proto import).
241
241
  *
242
242
  * @generated from message kusinta.iot.webrtc.v1.CommandResult
@@ -16,7 +16,7 @@ import type { DeviceId } from "../../identity/v1/identity_pb.js";
16
16
  export declare const file_kusinta_iot_webrtc_v1_device_state: GenFile;
17
17
 
18
18
  /**
19
- * Full device state sent to the Flutter app on initial WebRTC connection.
19
+ * Full device state sent to the app on initial WebRTC connection.
20
20
  *
21
21
  * @generated from message kusinta.iot.webrtc.v1.DeviceStateSnapshot
22
22
  */
@@ -44,7 +44,7 @@ export declare type DeviceStateSnapshot = Message<"kusinta.iot.webrtc.v1.DeviceS
44
44
  export declare const DeviceStateSnapshotSchema: GenMessage<DeviceStateSnapshot>;
45
45
 
46
46
  /**
47
- * Single property change event streamed to the Flutter app in real time.
47
+ * Single property change event streamed to the app in real time.
48
48
  *
49
49
  * @generated from message kusinta.iot.webrtc.v1.DevicePropertyEvent
50
50
  */
@@ -5,6 +5,8 @@
5
5
  import type { GenEnum, GenFile, GenMessage } from "@bufbuild/protobuf/codegenv2";
6
6
  import type { Message } from "@bufbuild/protobuf";
7
7
  import type { DeviceId } from "../../identity/v1/identity_pb.js";
8
+ import type { Space } from "../../space/v1/space_pb.js";
9
+ import type { ManagementAck, ManagementRequest, SpaceTree } from "./management_pb.js";
8
10
  import type { Timestamp } from "@bufbuild/protobuf/wkt";
9
11
  import type { DeviceAdded, DevicePropertyEvent, DeviceRemoved, DeviceStateSnapshot } from "./device_state_pb.js";
10
12
  import type { LivePermissionUpdate } from "./permission_push_pb.js";
@@ -56,8 +58,8 @@ export declare type HandshakeRejected = Message<"kusinta.iot.webrtc.v1.Handshake
56
58
  export declare const HandshakeRejectedSchema: GenMessage<HandshakeRejected>;
57
59
 
58
60
  /**
59
- * AppHandshake must be the first message sent by the Flutter app on the data channel.
60
- * The gateway validates the JWT locally using the mykusinta-api-server public key,
61
+ * AppHandshake must be the first message sent by the app on the data channel.
62
+ * The gateway validates the JWT locally using the api-server's public key,
61
63
  * checks that gateway_id in the JWT matches this gateway, then extracts the role.
62
64
  *
63
65
  * @generated from message kusinta.iot.webrtc.v1.AppHandshake
@@ -65,8 +67,8 @@ export declare const HandshakeRejectedSchema: GenMessage<HandshakeRejected>;
65
67
  export declare type AppHandshake = Message<"kusinta.iot.webrtc.v1.AppHandshake"> & {
66
68
  /**
67
69
  * Signed compact JWS. Its payload claims are documented by AppTokenClaims
68
- * in app_token.proto — the shared contract between mykusinta-api-server
69
- * (issuer) and the gateway (validator).
70
+ * in app_token.proto — the shared contract between the api-server (issuer)
71
+ * and the gateway (validator).
70
72
  *
71
73
  * @generated from field: string jwt = 1;
72
74
  */
@@ -163,7 +165,7 @@ export declare type RefusedSubscription = Message<"kusinta.iot.webrtc.v1.Refused
163
165
  export declare const RefusedSubscriptionSchema: GenMessage<RefusedSubscription>;
164
166
 
165
167
  /**
166
- * Answer to SubscribeDevices / UnsubscribeDevices, gateway → Flutter app.
168
+ * Answer to SubscribeDevices / UnsubscribeDevices, gateway → app.
167
169
  * `subscribed` is the effective set after the change, not a delta: an app that
168
170
  * missed an ack or raced two requests re-syncs from it without reconnecting.
169
171
  *
@@ -221,7 +223,7 @@ export declare type PropertyReadRequest = Message<"kusinta.iot.webrtc.v1.Propert
221
223
  export declare const PropertyReadRequestSchema: GenMessage<PropertyReadRequest>;
222
224
 
223
225
  /**
224
- * Session-level error, gateway → Flutter app. Mirrors connector.v1.GatewayError
226
+ * Session-level error, gateway → app. Mirrors connector.v1.GatewayError
225
227
  * on the connector leg; kept separate because the two legs have different
226
228
  * authorization semantics and this one has a closed code vocabulary.
227
229
  *
@@ -255,7 +257,72 @@ export declare type GatewayError = Message<"kusinta.iot.webrtc.v1.GatewayError">
255
257
  export declare const GatewayErrorSchema: GenMessage<GatewayError>;
256
258
 
257
259
  /**
258
- * GatewayMessage: gateway → Flutter app
260
+ * Answer to a ManagementRequest, gateway → app. Lives here rather than beside the
261
+ * requests in management.proto because it carries GatewayError, which is declared
262
+ * in this file; the other direction would be an import cycle.
263
+ *
264
+ * Exactly one result arrives per request, correlated by in_reply_to. A refusal is
265
+ * an ordinary result, not a session-level error: a filing operation the caller may
266
+ * not perform says so and the session continues. Targets the caller cannot reach
267
+ * are refused as NOT_ENTITLED whether or not they exist, so no result here reveals
268
+ * which spaces or devices are out there.
269
+ *
270
+ * @generated from message kusinta.iot.webrtc.v1.ManagementResult
271
+ */
272
+ export declare type ManagementResult = Message<"kusinta.iot.webrtc.v1.ManagementResult"> & {
273
+ /**
274
+ * AppMessage.message_id of the request
275
+ *
276
+ * @generated from field: string in_reply_to = 1;
277
+ */
278
+ inReplyTo: string;
279
+
280
+ /**
281
+ * @generated from oneof kusinta.iot.webrtc.v1.ManagementResult.result
282
+ */
283
+ result: {
284
+ /**
285
+ * refused, or the request was malformed
286
+ *
287
+ * @generated from field: kusinta.iot.webrtc.v1.GatewayError error = 2;
288
+ */
289
+ value: GatewayError;
290
+ case: "error";
291
+ } | {
292
+ /**
293
+ * create_space, update_space
294
+ *
295
+ * @generated from field: kusinta.iot.space.v1.Space space = 3;
296
+ */
297
+ value: Space;
298
+ case: "space";
299
+ } | {
300
+ /**
301
+ * list_spaces
302
+ *
303
+ * @generated from field: kusinta.iot.webrtc.v1.SpaceTree space_tree = 4;
304
+ */
305
+ value: SpaceTree;
306
+ case: "spaceTree";
307
+ } | {
308
+ /**
309
+ * everything else
310
+ *
311
+ * @generated from field: kusinta.iot.webrtc.v1.ManagementAck ack = 5;
312
+ */
313
+ value: ManagementAck;
314
+ case: "ack";
315
+ } | { case: undefined; value?: undefined };
316
+ };
317
+
318
+ /**
319
+ * Describes the message kusinta.iot.webrtc.v1.ManagementResult.
320
+ * Use `create(ManagementResultSchema)` to create a new message.
321
+ */
322
+ export declare const ManagementResultSchema: GenMessage<ManagementResult>;
323
+
324
+ /**
325
+ * GatewayMessage: gateway → app
259
326
  *
260
327
  * @generated from message kusinta.iot.webrtc.v1.GatewayMessage
261
328
  */
@@ -333,6 +400,12 @@ export declare type GatewayMessage = Message<"kusinta.iot.webrtc.v1.GatewayMessa
333
400
  */
334
401
  value: DeviceRemoved;
335
402
  case: "deviceRemoved";
403
+ } | {
404
+ /**
405
+ * @generated from field: kusinta.iot.webrtc.v1.ManagementResult management_result = 14;
406
+ */
407
+ value: ManagementResult;
408
+ case: "managementResult";
336
409
  } | { case: undefined; value?: undefined };
337
410
  };
338
411
 
@@ -343,7 +416,7 @@ export declare type GatewayMessage = Message<"kusinta.iot.webrtc.v1.GatewayMessa
343
416
  export declare const GatewayMessageSchema: GenMessage<GatewayMessage>;
344
417
 
345
418
  /**
346
- * AppMessage: Flutter app → gateway
419
+ * AppMessage: app → gateway
347
420
  *
348
421
  * @generated from message kusinta.iot.webrtc.v1.AppMessage
349
422
  */
@@ -397,6 +470,12 @@ export declare type AppMessage = Message<"kusinta.iot.webrtc.v1.AppMessage"> & {
397
470
  */
398
471
  value: UnsubscribeDevices;
399
472
  case: "unsubscribe";
473
+ } | {
474
+ /**
475
+ * @generated from field: kusinta.iot.webrtc.v1.ManagementRequest management = 9;
476
+ */
477
+ value: ManagementRequest;
478
+ case: "management";
400
479
  } | { case: undefined; value?: undefined };
401
480
  };
402
481
 
@@ -5,15 +5,17 @@
5
5
  import { enumDesc, fileDesc, messageDesc, tsEnum } from "@bufbuild/protobuf/codegenv2";
6
6
  import { file_google_protobuf_timestamp } from "@bufbuild/protobuf/wkt";
7
7
  import { file_kusinta_iot_identity_v1_identity } from "../../identity/v1/identity_pb.js";
8
+ import { file_kusinta_iot_space_v1_space } from "../../space/v1/space_pb.js";
8
9
  import { file_kusinta_iot_webrtc_v1_command } from "./command_pb.js";
9
10
  import { file_kusinta_iot_webrtc_v1_device_state } from "./device_state_pb.js";
11
+ import { file_kusinta_iot_webrtc_v1_management } from "./management_pb.js";
10
12
  import { file_kusinta_iot_webrtc_v1_permission_push } from "./permission_push_pb.js";
11
13
 
12
14
  /**
13
15
  * Describes the file kusinta/iot/webrtc/v1/envelope.proto.
14
16
  */
15
17
  export const file_kusinta_iot_webrtc_v1_envelope = /*@__PURE__*/
16
- fileDesc("CiRrdXNpbnRhL2lvdC93ZWJydGMvdjEvZW52ZWxvcGUucHJvdG8SFWt1c2ludGEuaW90LndlYnJ0Yy52MSIGCgRQaW5nIgYKBFBvbmciIwoRSGFuZHNoYWtlUmVqZWN0ZWQSDgoGcmVhc29uGAEgASgJIlwKDEFwcEhhbmRzaGFrZRILCgNqd3QYASABKAkSPwoUc3Vic2NyaWJlX2RldmljZV9pZHMYAiADKAsyIS5rdXNpbnRhLmlvdC5pZGVudGl0eS52MS5EZXZpY2VJZCJJChBTdWJzY3JpYmVEZXZpY2VzEjUKCmRldmljZV9pZHMYASADKAsyIS5rdXNpbnRhLmlvdC5pZGVudGl0eS52MS5EZXZpY2VJZCJLChJVbnN1YnNjcmliZURldmljZXMSNQoKZGV2aWNlX2lkcxgBIAMoCzIhLmt1c2ludGEuaW90LmlkZW50aXR5LnYxLkRldmljZUlkIpMBChNSZWZ1c2VkU3Vic2NyaXB0aW9uEjQKCWRldmljZV9pZBgBIAEoCzIhLmt1c2ludGEuaW90LmlkZW50aXR5LnYxLkRldmljZUlkEjUKBGNvZGUYAiABKA4yJy5rdXNpbnRhLmlvdC53ZWJydGMudjEuR2F0ZXdheUVycm9yQ29kZRIPCgdtZXNzYWdlGAMgASgJIpoBCg9TdWJzY3JpcHRpb25BY2sSEwoLaW5fcmVwbHlfdG8YASABKAkSNQoKc3Vic2NyaWJlZBgCIAMoCzIhLmt1c2ludG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Ch5HQVRFV0FZX0VSUk9SX0NPREVfVU5TUEVDSUZJRUQQABIjCh9HQVRFV0FZX0VSUk9SX0NPREVfTk9UX0VOVElUTEVEEAESJgoiR0FURVdBWV9FUlJPUl9DT0RFX0lOVkFMSURfUkVRVUVTVBACEiIKHkdBVEVXQVlfRVJST1JfQ09ERV9VTkFWQUlMQUJMRRADEh8KG0dBVEVXQVlfRVJST1JfQ09ERV9JTlRFUk5BTBAEEiwKKEdBVEVXQVlfRVJST1JfQ09ERV9TRVNTSU9OX0xJTUlUX1JFQUNIRUQQBUICSAFiBnByb3RvMw", [file_google_protobuf_timestamp, file_kusinta_iot_identity_v1_identity, file_kusinta_iot_webrtc_v1_command, file_kusinta_iot_webrtc_v1_device_state, file_kusinta_iot_webrtc_v1_permission_push]);
18
+ fileDesc("CiRrdXNpbnRhL2lvdC93ZWJydGMvdjEvZW52ZWxvcGUucHJvdG8SFWt1c2ludGEuaW90LndlYnJ0Yy52MSIGCgRQaW5nIgYKBFBvbmciIwoRSGFuZHNoYWtlUmVqZWN0ZWQSDgoGcmVhc29uGAEgASgJIlwKDEFwcEhhbmRzaGFrZRILCgNqd3QYASABKAkSPwoUc3Vic2NyaWJlX2RldmljZV9pZHMYAiADKAsyIS5rdXNpbnRhLmlvdC5pZGVudGl0eS52MS5EZXZpY2VJZCJJChBTdWJzY3JpYmVEZXZpY2VzEjUKCmRldmljZV9pZHMYASADKAsyIS5rdXNpbnRhLmlvdC5pZGVudGl0eS52MS5EZXZpY2VJZCJLChJVbnN1YnNjcmliZURldmljZXMSNQoKZGV2aWNlX2lkcxgBIAMoCzIhLmt1c2ludGEuaW90LmlkZW50aXR5LnYxLkRldmljZUlkIpMBChNSZWZ1c2VkU3Vic2NyaXB0aW9uEjQKCWRldmljZV9pZBgBIAEoCzIhLmt1c2ludGEuaW90LmlkZW50aXR5LnYxLkRldmljZUlkEjUKBGNvZGUYAiABKA4yJy5rdXNpbnRhLmlvdC53ZWJydGMudjEuR2F0ZXdheUVycm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X2F0GAIgASgLMhouZ29vZ2xlLnByb3RvYnVmLlRpbWVzdGFtcBI4CgloYW5kc2hha2UYAyABKAsyIy5rdXNpbnRhLmlvdC53ZWJydGMudjEuQXBwSGFuZHNoYWtlSAASNwoHY29tbWFuZBgEIAEoCzIkLmt1c2ludGEuaW90LndlYnJ0Yy52MS5EZXZpY2VDb21tYW5kSAASQgoMcmVhZF9yZXF1ZXN0GAUgASgLMioua3VzaW50YS5pb3Qud2VicnRjLnYxLlByb3BlcnR5UmVhZFJlcXVlc3RIABIrCgRwaW5nGAYgASgLMhsua3VzaW50YS5pb3Qud2VicnRjLnYxLlBpbmdIABI8CglzdWJzY3JpYmUYByABKAsyJy5rdXNpbnRhLmlvdC53ZWJydGMudjEuU3Vic2NyaWJlRGV2aWNlc0gAEkAKC3Vuc3Vic2NyaWJlGAggASgLMikua3VzaW50YS5pb3Qud2VicnRjLnYxLlVuc3Vic2NyaWJlRGV2aWNlc0gAEj4KCm1hbmFnZW1lbnQYCSABKAsyKC5rdXNpbnRhLmlvdC53ZWJydGMudjEuTWFuYWdlbWVudFJlcXVlc3RIAEIJCgdwYXlsb2FkKvYBChBHYXRld2F5RXJyb3JDb2RlEiIKHkdBVEVXQVlfRVJST1JfQ09ERV9VTlNQRUNJRklFRBAAEiMKH0dBVEVXQVlfRVJST1JfQ09ERV9OT1RfRU5USVRMRUQQARImCiJHQVRFV0FZX0VSUk9SX0NPREVfSU5WQUxJRF9SRVFVRVNUEAISIgoeR0FURVdBWV9FUlJPUl9DT0RFX1VOQVZBSUxBQkxFEAMSHwobR0FURVdBWV9FUlJPUl9DT0RFX0lOVEVSTkFMEAQSLAooR0FURVdBWV9FUlJPUl9DT0RFX1NFU1NJT05fTElNSVRfUkVBQ0hFRBAFQgJIAWIGcHJvdG8z", [file_google_protobuf_timestamp, file_kusinta_iot_identity_v1_identity, file_kusinta_iot_space_v1_space, file_kusinta_iot_webrtc_v1_command, file_kusinta_iot_webrtc_v1_device_state, file_kusinta_iot_webrtc_v1_management, file_kusinta_iot_webrtc_v1_permission_push]);
17
19
 
18
20
  /**
19
21
  * Describes the message kusinta.iot.webrtc.v1.Ping.
@@ -85,19 +87,26 @@ export const PropertyReadRequestSchema = /*@__PURE__*/
85
87
  export const GatewayErrorSchema = /*@__PURE__*/
86
88
  messageDesc(file_kusinta_iot_webrtc_v1_envelope, 9);
87
89
 
90
+ /**
91
+ * Describes the message kusinta.iot.webrtc.v1.ManagementResult.
92
+ * Use `create(ManagementResultSchema)` to create a new message.
93
+ */
94
+ export const ManagementResultSchema = /*@__PURE__*/
95
+ messageDesc(file_kusinta_iot_webrtc_v1_envelope, 10);
96
+
88
97
  /**
89
98
  * Describes the message kusinta.iot.webrtc.v1.GatewayMessage.
90
99
  * Use `create(GatewayMessageSchema)` to create a new message.
91
100
  */
92
101
  export const GatewayMessageSchema = /*@__PURE__*/
93
- messageDesc(file_kusinta_iot_webrtc_v1_envelope, 10);
102
+ messageDesc(file_kusinta_iot_webrtc_v1_envelope, 11);
94
103
 
95
104
  /**
96
105
  * Describes the message kusinta.iot.webrtc.v1.AppMessage.
97
106
  * Use `create(AppMessageSchema)` to create a new message.
98
107
  */
99
108
  export const AppMessageSchema = /*@__PURE__*/
100
- messageDesc(file_kusinta_iot_webrtc_v1_envelope, 11);
109
+ messageDesc(file_kusinta_iot_webrtc_v1_envelope, 12);
101
110
 
102
111
  /**
103
112
  * Describes the enum kusinta.iot.webrtc.v1.GatewayErrorCode.
@@ -0,0 +1,451 @@
1
+ // @generated by protoc-gen-es v2.12.0 with parameter "target=js+dts,import_extension=js"
2
+ // @generated from file kusinta/iot/webrtc/v1/management.proto (package kusinta.iot.webrtc.v1, syntax proto3)
3
+ /* eslint-disable */
4
+
5
+ import type { GenFile, GenMessage } from "@bufbuild/protobuf/codegenv2";
6
+ import type { Message } from "@bufbuild/protobuf";
7
+ import type { DeviceOwnershipType, SpaceType } from "../../common/v1/types_pb.js";
8
+ import type { DeviceId, SpaceId, UserId } from "../../identity/v1/identity_pb.js";
9
+ import type { Space } from "../../space/v1/space_pb.js";
10
+
11
+ /**
12
+ * Describes the file kusinta/iot/webrtc/v1/management.proto.
13
+ */
14
+ export declare const file_kusinta_iot_webrtc_v1_management: GenFile;
15
+
16
+ /**
17
+ * Creates a space. A space with no parent_space_id is top level, which is a
18
+ * stronger request than it looks: there is no parent whose reach could authorize
19
+ * it, so it is reserved to the gateway's administrator.
20
+ *
21
+ * @generated from message kusinta.iot.webrtc.v1.CreateSpace
22
+ */
23
+ export declare type CreateSpace = Message<"kusinta.iot.webrtc.v1.CreateSpace"> & {
24
+ /**
25
+ * @generated from field: kusinta.iot.common.v1.SpaceType space_type = 1;
26
+ */
27
+ spaceType: SpaceType;
28
+
29
+ /**
30
+ * @generated from field: string name = 2;
31
+ */
32
+ name: string;
33
+
34
+ /**
35
+ * @generated from field: string description = 3;
36
+ */
37
+ description: string;
38
+
39
+ /**
40
+ * meaningful for FLOOR type
41
+ *
42
+ * @generated from field: int32 floor = 4;
43
+ */
44
+ floor: number;
45
+
46
+ /**
47
+ * unset = top level
48
+ *
49
+ * @generated from field: kusinta.iot.identity.v1.SpaceId parent_space_id = 5;
50
+ */
51
+ parentSpaceId?: SpaceId | undefined;
52
+ };
53
+
54
+ /**
55
+ * Describes the message kusinta.iot.webrtc.v1.CreateSpace.
56
+ * Use `create(CreateSpaceSchema)` to create a new message.
57
+ */
58
+ export declare const CreateSpaceSchema: GenMessage<CreateSpace>;
59
+
60
+ /**
61
+ * Changes a space in place. Every descriptive field carries explicit presence:
62
+ * absent means leave it alone, present means set it to this — including to the
63
+ * empty string, which is how a description is cleared.
64
+ *
65
+ * @generated from message kusinta.iot.webrtc.v1.UpdateSpace
66
+ */
67
+ export declare type UpdateSpace = Message<"kusinta.iot.webrtc.v1.UpdateSpace"> & {
68
+ /**
69
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 1;
70
+ */
71
+ spaceId?: SpaceId | undefined;
72
+
73
+ /**
74
+ * @generated from field: optional kusinta.iot.common.v1.SpaceType space_type = 2;
75
+ */
76
+ spaceType?: SpaceType | undefined;
77
+
78
+ /**
79
+ * @generated from field: optional string name = 3;
80
+ */
81
+ name?: string | undefined;
82
+
83
+ /**
84
+ * @generated from field: optional string description = 4;
85
+ */
86
+ description?: string | undefined;
87
+
88
+ /**
89
+ * @generated from field: optional int32 floor = 5;
90
+ */
91
+ floor?: number | undefined;
92
+
93
+ /**
94
+ * Reparenting needs three states, not two: leave the parent alone, move to a
95
+ * new one, or become top level. A bare optional parent_space_id can only
96
+ * express the first two, so detaching gets its own case rather than being
97
+ * spelled as an empty id.
98
+ *
99
+ * @generated from oneof kusinta.iot.webrtc.v1.UpdateSpace.parent_change
100
+ */
101
+ parentChange: {
102
+ /**
103
+ * @generated from field: kusinta.iot.identity.v1.SpaceId parent_space_id = 6;
104
+ */
105
+ value: SpaceId;
106
+ case: "parentSpaceId";
107
+ } | {
108
+ /**
109
+ * @generated from field: bool detach = 7;
110
+ */
111
+ value: boolean;
112
+ case: "detach";
113
+ } | { case: undefined; value?: undefined };
114
+ };
115
+
116
+ /**
117
+ * Describes the message kusinta.iot.webrtc.v1.UpdateSpace.
118
+ * Use `create(UpdateSpaceSchema)` to create a new message.
119
+ */
120
+ export declare const UpdateSpaceSchema: GenMessage<UpdateSpace>;
121
+
122
+ /**
123
+ * Deletes a space. Refused if the space still holds devices or sub-spaces unless
124
+ * cascade is set, so that emptying a building is always something the caller
125
+ * asked for rather than something a stale client did by accident.
126
+ *
127
+ * @generated from message kusinta.iot.webrtc.v1.DeleteSpace
128
+ */
129
+ export declare type DeleteSpace = Message<"kusinta.iot.webrtc.v1.DeleteSpace"> & {
130
+ /**
131
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 1;
132
+ */
133
+ spaceId?: SpaceId | undefined;
134
+
135
+ /**
136
+ * @generated from field: bool cascade = 2;
137
+ */
138
+ cascade: boolean;
139
+ };
140
+
141
+ /**
142
+ * Describes the message kusinta.iot.webrtc.v1.DeleteSpace.
143
+ * Use `create(DeleteSpaceSchema)` to create a new message.
144
+ */
145
+ export declare const DeleteSpaceSchema: GenMessage<DeleteSpace>;
146
+
147
+ /**
148
+ * Adds a user to a space, granting them reach of it and everything beneath it.
149
+ * The user need not be known to the gateway beforehand — identities are minted by
150
+ * the token issuer, and this records that one of them belongs here.
151
+ *
152
+ * @generated from message kusinta.iot.webrtc.v1.AssignUserToSpace
153
+ */
154
+ export declare type AssignUserToSpace = Message<"kusinta.iot.webrtc.v1.AssignUserToSpace"> & {
155
+ /**
156
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 1;
157
+ */
158
+ spaceId?: SpaceId | undefined;
159
+
160
+ /**
161
+ * @generated from field: kusinta.iot.identity.v1.UserId user_id = 2;
162
+ */
163
+ userId?: UserId | undefined;
164
+ };
165
+
166
+ /**
167
+ * Describes the message kusinta.iot.webrtc.v1.AssignUserToSpace.
168
+ * Use `create(AssignUserToSpaceSchema)` to create a new message.
169
+ */
170
+ export declare const AssignUserToSpaceSchema: GenMessage<AssignUserToSpace>;
171
+
172
+ /**
173
+ * Removes a user's membership of a space. Losing reach also drops whatever the
174
+ * user was streaming from it, announced by LivePermissionUpdate.
175
+ *
176
+ * @generated from message kusinta.iot.webrtc.v1.RemoveUserFromSpace
177
+ */
178
+ export declare type RemoveUserFromSpace = Message<"kusinta.iot.webrtc.v1.RemoveUserFromSpace"> & {
179
+ /**
180
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 1;
181
+ */
182
+ spaceId?: SpaceId | undefined;
183
+
184
+ /**
185
+ * @generated from field: kusinta.iot.identity.v1.UserId user_id = 2;
186
+ */
187
+ userId?: UserId | undefined;
188
+ };
189
+
190
+ /**
191
+ * Describes the message kusinta.iot.webrtc.v1.RemoveUserFromSpace.
192
+ * Use `create(RemoveUserFromSpaceSchema)` to create a new message.
193
+ */
194
+ export declare const RemoveUserFromSpaceSchema: GenMessage<RemoveUserFromSpace>;
195
+
196
+ /**
197
+ * Files a device into a space. A device may sit in several spaces at once; this
198
+ * is additive, and filing a device where it already sits is a no-op.
199
+ *
200
+ * @generated from message kusinta.iot.webrtc.v1.PlaceDeviceInSpace
201
+ */
202
+ export declare type PlaceDeviceInSpace = Message<"kusinta.iot.webrtc.v1.PlaceDeviceInSpace"> & {
203
+ /**
204
+ * @generated from field: kusinta.iot.identity.v1.DeviceId device_id = 1;
205
+ */
206
+ deviceId?: DeviceId | undefined;
207
+
208
+ /**
209
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 2;
210
+ */
211
+ spaceId?: SpaceId | undefined;
212
+ };
213
+
214
+ /**
215
+ * Describes the message kusinta.iot.webrtc.v1.PlaceDeviceInSpace.
216
+ * Use `create(PlaceDeviceInSpaceSchema)` to create a new message.
217
+ */
218
+ export declare const PlaceDeviceInSpaceSchema: GenMessage<PlaceDeviceInSpace>;
219
+
220
+ /**
221
+ * Takes a device out of one space, leaving any others intact. A device in no
222
+ * space and with no owner is unfiled, and visible only to the administrator.
223
+ *
224
+ * @generated from message kusinta.iot.webrtc.v1.RemoveDeviceFromSpace
225
+ */
226
+ export declare type RemoveDeviceFromSpace = Message<"kusinta.iot.webrtc.v1.RemoveDeviceFromSpace"> & {
227
+ /**
228
+ * @generated from field: kusinta.iot.identity.v1.DeviceId device_id = 1;
229
+ */
230
+ deviceId?: DeviceId | undefined;
231
+
232
+ /**
233
+ * @generated from field: kusinta.iot.identity.v1.SpaceId space_id = 2;
234
+ */
235
+ spaceId?: SpaceId | undefined;
236
+ };
237
+
238
+ /**
239
+ * Describes the message kusinta.iot.webrtc.v1.RemoveDeviceFromSpace.
240
+ * Use `create(RemoveDeviceFromSpaceSchema)` to create a new message.
241
+ */
242
+ export declare const RemoveDeviceFromSpaceSchema: GenMessage<RemoveDeviceFromSpace>;
243
+
244
+ /**
245
+ * Takes ownership of a device. Ownership is reach in its own right: an owner may
246
+ * see and control their device whatever their gateway-wide role permits, and may
247
+ * file it into spaces they belong to.
248
+ *
249
+ * @generated from message kusinta.iot.webrtc.v1.ClaimDevice
250
+ */
251
+ export declare type ClaimDevice = Message<"kusinta.iot.webrtc.v1.ClaimDevice"> & {
252
+ /**
253
+ * @generated from field: kusinta.iot.identity.v1.DeviceId device_id = 1;
254
+ */
255
+ deviceId?: DeviceId | undefined;
256
+
257
+ /**
258
+ * @generated from field: kusinta.iot.common.v1.DeviceOwnershipType ownership = 2;
259
+ */
260
+ ownership: DeviceOwnershipType;
261
+
262
+ /**
263
+ * @generated from field: kusinta.iot.identity.v1.SpaceId initial_space_id = 3;
264
+ */
265
+ initialSpaceId?: SpaceId | undefined;
266
+
267
+ /**
268
+ * Evidence the claimant is standing at the device: the serial printed on it,
269
+ * matched against DeviceDescriptor.serial_number. Required precisely when the
270
+ * caller cannot already reach the device, which is the ordinary case for a
271
+ * resident claiming something they just bought — an unfiled device is invisible
272
+ * to them, so possession is the only thing left that can distinguish them from
273
+ * someone guessing ids. The administrator, who can already reach it, needs no
274
+ * proof. A device whose connector reports no serial can only be claimed by the
275
+ * administrator.
276
+ *
277
+ * @generated from field: string possession_proof = 4;
278
+ */
279
+ possessionProof: string;
280
+ };
281
+
282
+ /**
283
+ * Describes the message kusinta.iot.webrtc.v1.ClaimDevice.
284
+ * Use `create(ClaimDeviceSchema)` to create a new message.
285
+ */
286
+ export declare const ClaimDeviceSchema: GenMessage<ClaimDevice>;
287
+
288
+ /**
289
+ * Gives up ownership. The device keeps whatever space filing it has; if it has
290
+ * none it becomes unfiled.
291
+ *
292
+ * @generated from message kusinta.iot.webrtc.v1.ReleaseDevice
293
+ */
294
+ export declare type ReleaseDevice = Message<"kusinta.iot.webrtc.v1.ReleaseDevice"> & {
295
+ /**
296
+ * @generated from field: kusinta.iot.identity.v1.DeviceId device_id = 1;
297
+ */
298
+ deviceId?: DeviceId | undefined;
299
+ };
300
+
301
+ /**
302
+ * Describes the message kusinta.iot.webrtc.v1.ReleaseDevice.
303
+ * Use `create(ReleaseDeviceSchema)` to create a new message.
304
+ */
305
+ export declare const ReleaseDeviceSchema: GenMessage<ReleaseDevice>;
306
+
307
+ /**
308
+ * Asks for the spaces the caller can reach. Unset root_space_id means all of
309
+ * them, which for most users is one apartment and for an administrator is the
310
+ * building.
311
+ *
312
+ * @generated from message kusinta.iot.webrtc.v1.ListSpaces
313
+ */
314
+ export declare type ListSpaces = Message<"kusinta.iot.webrtc.v1.ListSpaces"> & {
315
+ /**
316
+ * @generated from field: kusinta.iot.identity.v1.SpaceId root_space_id = 1;
317
+ */
318
+ rootSpaceId?: SpaceId | undefined;
319
+ };
320
+
321
+ /**
322
+ * Describes the message kusinta.iot.webrtc.v1.ListSpaces.
323
+ * Use `create(ListSpacesSchema)` to create a new message.
324
+ */
325
+ export declare const ListSpacesSchema: GenMessage<ListSpaces>;
326
+
327
+ /**
328
+ * The spaces themselves, flat: each Space carries its own parent_space_id, so the
329
+ * structure travels with the elements and a client rebuilds the tree from them.
330
+ * A flat list also degrades honestly when it is truncated — a partial tree with
331
+ * dangling parents is still readable, where a nested one would lose whole
332
+ * subtrees.
333
+ *
334
+ * device_ids on each Space are filtered to what the caller may see. An
335
+ * unfiltered tree would list every device on the gateway by id, which is the
336
+ * enumeration channel the snapshot filter exists to close.
337
+ *
338
+ * @generated from message kusinta.iot.webrtc.v1.SpaceTree
339
+ */
340
+ export declare type SpaceTree = Message<"kusinta.iot.webrtc.v1.SpaceTree"> & {
341
+ /**
342
+ * @generated from field: repeated kusinta.iot.space.v1.Space spaces = 1;
343
+ */
344
+ spaces: Space[];
345
+ };
346
+
347
+ /**
348
+ * Describes the message kusinta.iot.webrtc.v1.SpaceTree.
349
+ * Use `create(SpaceTreeSchema)` to create a new message.
350
+ */
351
+ export declare const SpaceTreeSchema: GenMessage<SpaceTree>;
352
+
353
+ /**
354
+ * The answer to an operation that changes something and has nothing to return.
355
+ * Deliberately empty: ManagementResult.in_reply_to says which request succeeded,
356
+ * and what the change did to the caller's reach arrives on LivePermissionUpdate
357
+ * rather than here.
358
+ *
359
+ * @generated from message kusinta.iot.webrtc.v1.ManagementAck
360
+ */
361
+ export declare type ManagementAck = Message<"kusinta.iot.webrtc.v1.ManagementAck"> & {
362
+ };
363
+
364
+ /**
365
+ * Describes the message kusinta.iot.webrtc.v1.ManagementAck.
366
+ * Use `create(ManagementAckSchema)` to create a new message.
367
+ */
368
+ export declare const ManagementAckSchema: GenMessage<ManagementAck>;
369
+
370
+ /**
371
+ * A single filing operation, app → gateway. One wrapper rather than ten payload
372
+ * cases on AppMessage: authorization for filing depends on the target, not on the
373
+ * message kind, so these can never be gated by a table keyed on the envelope case
374
+ * the way device messages are. Keeping them behind one case means one place that
375
+ * must authorize, and one refusal path that must not leak whether a target exists.
376
+ *
377
+ * @generated from message kusinta.iot.webrtc.v1.ManagementRequest
378
+ */
379
+ export declare type ManagementRequest = Message<"kusinta.iot.webrtc.v1.ManagementRequest"> & {
380
+ /**
381
+ * @generated from oneof kusinta.iot.webrtc.v1.ManagementRequest.request
382
+ */
383
+ request: {
384
+ /**
385
+ * @generated from field: kusinta.iot.webrtc.v1.CreateSpace create_space = 1;
386
+ */
387
+ value: CreateSpace;
388
+ case: "createSpace";
389
+ } | {
390
+ /**
391
+ * @generated from field: kusinta.iot.webrtc.v1.UpdateSpace update_space = 2;
392
+ */
393
+ value: UpdateSpace;
394
+ case: "updateSpace";
395
+ } | {
396
+ /**
397
+ * @generated from field: kusinta.iot.webrtc.v1.DeleteSpace delete_space = 3;
398
+ */
399
+ value: DeleteSpace;
400
+ case: "deleteSpace";
401
+ } | {
402
+ /**
403
+ * @generated from field: kusinta.iot.webrtc.v1.AssignUserToSpace assign_user_to_space = 4;
404
+ */
405
+ value: AssignUserToSpace;
406
+ case: "assignUserToSpace";
407
+ } | {
408
+ /**
409
+ * @generated from field: kusinta.iot.webrtc.v1.RemoveUserFromSpace remove_user_from_space = 5;
410
+ */
411
+ value: RemoveUserFromSpace;
412
+ case: "removeUserFromSpace";
413
+ } | {
414
+ /**
415
+ * @generated from field: kusinta.iot.webrtc.v1.PlaceDeviceInSpace place_device_in_space = 6;
416
+ */
417
+ value: PlaceDeviceInSpace;
418
+ case: "placeDeviceInSpace";
419
+ } | {
420
+ /**
421
+ * @generated from field: kusinta.iot.webrtc.v1.RemoveDeviceFromSpace remove_device_from_space = 7;
422
+ */
423
+ value: RemoveDeviceFromSpace;
424
+ case: "removeDeviceFromSpace";
425
+ } | {
426
+ /**
427
+ * @generated from field: kusinta.iot.webrtc.v1.ClaimDevice claim_device = 8;
428
+ */
429
+ value: ClaimDevice;
430
+ case: "claimDevice";
431
+ } | {
432
+ /**
433
+ * @generated from field: kusinta.iot.webrtc.v1.ReleaseDevice release_device = 9;
434
+ */
435
+ value: ReleaseDevice;
436
+ case: "releaseDevice";
437
+ } | {
438
+ /**
439
+ * @generated from field: kusinta.iot.webrtc.v1.ListSpaces list_spaces = 10;
440
+ */
441
+ value: ListSpaces;
442
+ case: "listSpaces";
443
+ } | { case: undefined; value?: undefined };
444
+ };
445
+
446
+ /**
447
+ * Describes the message kusinta.iot.webrtc.v1.ManagementRequest.
448
+ * Use `create(ManagementRequestSchema)` to create a new message.
449
+ */
450
+ export declare const ManagementRequestSchema: GenMessage<ManagementRequest>;
451
+
@@ -0,0 +1,106 @@
1
+ // @generated by protoc-gen-es v2.12.0 with parameter "target=js+dts,import_extension=js"
2
+ // @generated from file kusinta/iot/webrtc/v1/management.proto (package kusinta.iot.webrtc.v1, syntax proto3)
3
+ /* eslint-disable */
4
+
5
+ import { fileDesc, messageDesc } from "@bufbuild/protobuf/codegenv2";
6
+ import { file_kusinta_iot_common_v1_types } from "../../common/v1/types_pb.js";
7
+ import { file_kusinta_iot_identity_v1_identity } from "../../identity/v1/identity_pb.js";
8
+ import { file_kusinta_iot_space_v1_space } from "../../space/v1/space_pb.js";
9
+
10
+ /**
11
+ * Describes the file kusinta/iot/webrtc/v1/management.proto.
12
+ */
13
+ export const file_kusinta_iot_webrtc_v1_management = /*@__PURE__*/
14
+ fileDesc("CiZrdXNpbnRhL2lvdC93ZWJydGMvd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GVfc3BhY2UYASABKAsyIi5rdXNpbnRhLmlvdC53ZWJydGMudjEuQ3JlYXRlU3BhY2VIABI6Cgx1cGRhdGVfc3BhY2UYAiABKAsyIi5rdXNpbnRhLmlvdC53ZWJydGMudjEuVXBkYXRlU3BhY2VIABI6CgxkZWxldGVfc3BhY2UYAyABKAsyIi5rdXNpbnRhLmlvdC53ZWJydGMudjEuRGVsZXRlU3BhY2VIABJIChRhc3NpZ25fdXNlcl90b19zcGFjZRgEIAEoCzIoLmt1c2ludGEuaW90LndlYnJ0Yy52MS5Bc3NpZ25Vc2VyVG9TcGFjZUgAEkwKFnJlbW92ZV91c2VyX2Zyb21fc3BhY2UYBSABKAsyKi5rdXNpbnRhLmlvdC53ZWJydGMudjEuUmVtb3ZlVXNlckZyb21TcGFjZUgAEkoKFXBsYWNlX2RldmljZV9pbl9zcGFjZRgGIAEoCzIpLmt1c2ludGEuaW90LndlYnJ0Yy52MS5QbGFjZURldmljZUluU3BhY2VIABJQChhyZW1vdmVfZGV2aWNlX2Zyb21fc3BhY2UYByABKAsyLC5rdXNpbnRhLmlvdC53ZWJydGMudjEuUmVtb3ZlRGV2aWNlRnJvbVNwYWNlSAASOgoMY2xhaW1fZGV2aWNlGAggASgLMiIua3VzaW50YS5pb3Qud2VicnRjLnYxLkNsYWltRGV2aWNlSAASPgoOcmVsZWFzZV9kZXZpY2UYCSABKAsyJC5rdXNpbnRhLmlvdC53ZWJydGMudjEuUmVsZWFzZURldmljZUgAEjgKC2xpc3Rfc3BhY2VzGAogASgLMiEua3VzaW50YS5pb3Qud2VicnRjLnYxLkxpc3RTcGFjZXNIAEIJCgdyZXF1ZXN0QgJIAWIGcHJvdG8z", [file_kusinta_iot_common_v1_types, file_kusinta_iot_identity_v1_identity, file_kusinta_iot_space_v1_space]);
15
+
16
+ /**
17
+ * Describes the message kusinta.iot.webrtc.v1.CreateSpace.
18
+ * Use `create(CreateSpaceSchema)` to create a new message.
19
+ */
20
+ export const CreateSpaceSchema = /*@__PURE__*/
21
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 0);
22
+
23
+ /**
24
+ * Describes the message kusinta.iot.webrtc.v1.UpdateSpace.
25
+ * Use `create(UpdateSpaceSchema)` to create a new message.
26
+ */
27
+ export const UpdateSpaceSchema = /*@__PURE__*/
28
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 1);
29
+
30
+ /**
31
+ * Describes the message kusinta.iot.webrtc.v1.DeleteSpace.
32
+ * Use `create(DeleteSpaceSchema)` to create a new message.
33
+ */
34
+ export const DeleteSpaceSchema = /*@__PURE__*/
35
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 2);
36
+
37
+ /**
38
+ * Describes the message kusinta.iot.webrtc.v1.AssignUserToSpace.
39
+ * Use `create(AssignUserToSpaceSchema)` to create a new message.
40
+ */
41
+ export const AssignUserToSpaceSchema = /*@__PURE__*/
42
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 3);
43
+
44
+ /**
45
+ * Describes the message kusinta.iot.webrtc.v1.RemoveUserFromSpace.
46
+ * Use `create(RemoveUserFromSpaceSchema)` to create a new message.
47
+ */
48
+ export const RemoveUserFromSpaceSchema = /*@__PURE__*/
49
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 4);
50
+
51
+ /**
52
+ * Describes the message kusinta.iot.webrtc.v1.PlaceDeviceInSpace.
53
+ * Use `create(PlaceDeviceInSpaceSchema)` to create a new message.
54
+ */
55
+ export const PlaceDeviceInSpaceSchema = /*@__PURE__*/
56
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 5);
57
+
58
+ /**
59
+ * Describes the message kusinta.iot.webrtc.v1.RemoveDeviceFromSpace.
60
+ * Use `create(RemoveDeviceFromSpaceSchema)` to create a new message.
61
+ */
62
+ export const RemoveDeviceFromSpaceSchema = /*@__PURE__*/
63
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 6);
64
+
65
+ /**
66
+ * Describes the message kusinta.iot.webrtc.v1.ClaimDevice.
67
+ * Use `create(ClaimDeviceSchema)` to create a new message.
68
+ */
69
+ export const ClaimDeviceSchema = /*@__PURE__*/
70
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 7);
71
+
72
+ /**
73
+ * Describes the message kusinta.iot.webrtc.v1.ReleaseDevice.
74
+ * Use `create(ReleaseDeviceSchema)` to create a new message.
75
+ */
76
+ export const ReleaseDeviceSchema = /*@__PURE__*/
77
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 8);
78
+
79
+ /**
80
+ * Describes the message kusinta.iot.webrtc.v1.ListSpaces.
81
+ * Use `create(ListSpacesSchema)` to create a new message.
82
+ */
83
+ export const ListSpacesSchema = /*@__PURE__*/
84
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 9);
85
+
86
+ /**
87
+ * Describes the message kusinta.iot.webrtc.v1.SpaceTree.
88
+ * Use `create(SpaceTreeSchema)` to create a new message.
89
+ */
90
+ export const SpaceTreeSchema = /*@__PURE__*/
91
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 10);
92
+
93
+ /**
94
+ * Describes the message kusinta.iot.webrtc.v1.ManagementAck.
95
+ * Use `create(ManagementAckSchema)` to create a new message.
96
+ */
97
+ export const ManagementAckSchema = /*@__PURE__*/
98
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 11);
99
+
100
+ /**
101
+ * Describes the message kusinta.iot.webrtc.v1.ManagementRequest.
102
+ * Use `create(ManagementRequestSchema)` to create a new message.
103
+ */
104
+ export const ManagementRequestSchema = /*@__PURE__*/
105
+ messageDesc(file_kusinta_iot_webrtc_v1_management, 12);
106
+
@@ -13,7 +13,7 @@ import type { DeviceId } from "../../identity/v1/identity_pb.js";
13
13
  export declare const file_kusinta_iot_webrtc_v1_permission_push: GenFile;
14
14
 
15
15
  /**
16
- * Pushed to the Flutter app whenever the user's effective permissions change.
16
+ * Pushed to the app whenever the user's effective permissions change.
17
17
  * change_reason values: "DEVICE_ASSIGNED", "DEVICE_UNASSIGNED", "RESIDENT_CHANGED", "CONSTRAINT_UPDATED"
18
18
  *
19
19
  * @generated from message kusinta.iot.webrtc.v1.LivePermissionUpdate