@dxos/protocols 0.8.4-main.937b3ca → 0.8.4-main.9be5663bfe

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.
Files changed (206) hide show
  1. package/README.md +1 -1
  2. package/dist/src/FeedProtocol.d.ts +528 -0
  3. package/dist/src/FeedProtocol.d.ts.map +1 -0
  4. package/dist/src/FeedProtocol.js +237 -0
  5. package/dist/src/FeedProtocol.js.map +1 -0
  6. package/dist/src/FunctionProtocol.d.ts +2 -2
  7. package/dist/src/FunctionProtocol.d.ts.map +1 -1
  8. package/dist/src/buf/proto/gen/dxos/client/queue_pb.d.ts +42 -0
  9. package/dist/src/buf/proto/gen/dxos/client/queue_pb.d.ts.map +1 -1
  10. package/dist/src/buf/proto/gen/dxos/client/queue_pb.js +7 -2
  11. package/dist/src/buf/proto/gen/dxos/client/queue_pb.js.map +1 -1
  12. package/dist/src/buf/proto/gen/dxos/client/services_pb.d.ts +33 -3
  13. package/dist/src/buf/proto/gen/dxos/client/services_pb.d.ts.map +1 -1
  14. package/dist/src/buf/proto/gen/dxos/client/services_pb.js +46 -37
  15. package/dist/src/buf/proto/gen/dxos/client/services_pb.js.map +1 -1
  16. package/dist/src/buf/proto/gen/dxos/config_pb.d.ts +0 -4
  17. package/dist/src/buf/proto/gen/dxos/config_pb.d.ts.map +1 -1
  18. package/dist/src/buf/proto/gen/dxos/config_pb.js +1 -1
  19. package/dist/src/buf/proto/gen/dxos/config_pb.js.map +1 -1
  20. package/dist/src/buf/proto/gen/dxos/echo/metadata_pb.d.ts +6 -0
  21. package/dist/src/buf/proto/gen/dxos/echo/metadata_pb.d.ts.map +1 -1
  22. package/dist/src/buf/proto/gen/dxos/echo/metadata_pb.js +1 -1
  23. package/dist/src/buf/proto/gen/dxos/echo/metadata_pb.js.map +1 -1
  24. package/dist/src/buf/proto/gen/dxos/edge/messenger_pb.d.ts +28 -0
  25. package/dist/src/buf/proto/gen/dxos/edge/messenger_pb.d.ts.map +1 -1
  26. package/dist/src/buf/proto/gen/dxos/edge/messenger_pb.js +10 -5
  27. package/dist/src/buf/proto/gen/dxos/edge/messenger_pb.js.map +1 -1
  28. package/dist/src/buf/proto/gen/dxos/google_pb.js +1 -1
  29. package/dist/src/buf/proto/gen/dxos/halo/credentials_pb.d.ts +39 -0
  30. package/dist/src/buf/proto/gen/dxos/halo/credentials_pb.d.ts.map +1 -1
  31. package/dist/src/buf/proto/gen/dxos/halo/credentials_pb.js +27 -2
  32. package/dist/src/buf/proto/gen/dxos/halo/credentials_pb.js.map +1 -1
  33. package/dist/src/buf/proto/gen/dxos/tracing_pb.js +1 -1
  34. package/dist/src/codec.test.js +1 -1
  35. package/dist/src/edge/EdgeFunctionEnv.d.ts +12 -24
  36. package/dist/src/edge/EdgeFunctionEnv.d.ts.map +1 -1
  37. package/dist/src/edge/edge.d.ts +165 -0
  38. package/dist/src/edge/edge.d.ts.map +1 -1
  39. package/dist/src/edge/edge.js +13 -0
  40. package/dist/src/edge/edge.js.map +1 -1
  41. package/dist/src/edge/errors.d.ts +1 -1
  42. package/dist/src/edge/errors.js +1 -1
  43. package/dist/src/edge/index.d.ts +3 -3
  44. package/dist/src/edge/index.js +3 -3
  45. package/dist/src/errors/encoding.d.ts +1 -1
  46. package/dist/src/errors/encoding.d.ts.map +1 -1
  47. package/dist/src/errors/encoding.js +1 -1
  48. package/dist/src/errors/encoding.js.map +1 -1
  49. package/dist/src/errors/errors.d.ts +1 -1
  50. package/dist/src/errors/errors.d.ts.map +1 -1
  51. package/dist/src/errors/errors.js +1 -1
  52. package/dist/src/errors/errors.js.map +1 -1
  53. package/dist/src/errors/errors.test.js +1 -1
  54. package/dist/src/errors/helpers.d.ts +1 -1
  55. package/dist/src/errors/index.d.ts +5 -5
  56. package/dist/src/errors/index.js +5 -5
  57. package/dist/src/index.d.ts +12 -12
  58. package/dist/src/index.d.ts.map +1 -1
  59. package/dist/src/index.js +11 -12
  60. package/dist/src/index.js.map +1 -1
  61. package/dist/src/indexing.test.js +1 -1
  62. package/dist/src/proto/gen/dxos/client/services.d.ts +786 -751
  63. package/dist/src/proto/gen/dxos/client/services.d.ts.map +1 -1
  64. package/dist/src/proto/gen/dxos/client/services.js +95 -94
  65. package/dist/src/proto/gen/dxos/client/services.js.map +1 -1
  66. package/dist/src/proto/gen/dxos/config.d.ts +0 -5
  67. package/dist/src/proto/gen/dxos/config.d.ts.map +1 -1
  68. package/dist/src/proto/gen/dxos/config.js.map +1 -1
  69. package/dist/src/proto/gen/dxos/devtools/host.d.ts +31 -31
  70. package/dist/src/proto/gen/dxos/devtools/host.d.ts.map +1 -1
  71. package/dist/src/proto/gen/dxos/echo/metadata.d.ts +4 -0
  72. package/dist/src/proto/gen/dxos/echo/metadata.d.ts.map +1 -1
  73. package/dist/src/proto/gen/dxos/echo/metadata.js.map +1 -1
  74. package/dist/src/proto/gen/dxos/edge/messenger.d.ts +24 -0
  75. package/dist/src/proto/gen/dxos/edge/messenger.d.ts.map +1 -1
  76. package/dist/src/proto/gen/dxos/edge/messenger.js.map +1 -1
  77. package/dist/src/proto/gen/dxos/halo/credentials.d.ts +15 -1
  78. package/dist/src/proto/gen/dxos/halo/credentials.d.ts.map +1 -1
  79. package/dist/src/proto/gen/dxos/halo/credentials.js +9 -0
  80. package/dist/src/proto/gen/dxos/halo/credentials.js.map +1 -1
  81. package/dist/src/proto/gen/google/protobuf.d.ts +326 -40
  82. package/dist/src/proto/gen/google/protobuf.d.ts.map +1 -1
  83. package/dist/src/proto/gen/google/protobuf.js +127 -1
  84. package/dist/src/proto/gen/google/protobuf.js.map +1 -1
  85. package/dist/src/proto/gen/index.d.ts +28 -0
  86. package/dist/src/proto/gen/index.d.ts.map +1 -1
  87. package/dist/src/proto/gen/index.js +1 -1
  88. package/dist/src/proto/gen/index.js.map +1 -1
  89. package/dist/src/proto/index.d.ts +2 -2
  90. package/dist/src/proto/index.js +1 -1
  91. package/dist/src/proto/types.d.ts +1 -1
  92. package/dist/src/space-archive.d.ts +60 -1
  93. package/dist/src/space-archive.d.ts.map +1 -1
  94. package/dist/src/space-archive.js +13 -1
  95. package/dist/src/space-archive.js.map +1 -1
  96. package/dist/src/types.d.ts +2 -2
  97. package/dist/tsconfig.tsbuildinfo +1 -1
  98. package/package.json +14 -14
  99. package/src/FeedProtocol.ts +320 -0
  100. package/src/FunctionProtocol.ts +2 -4
  101. package/src/buf/proto/gen/dxos/agent/dashboard_pb.ts +1 -1
  102. package/src/buf/proto/gen/dxos/agent/echo-proxy_pb.ts +1 -1
  103. package/src/buf/proto/gen/dxos/agent/epoch_pb.ts +1 -1
  104. package/src/buf/proto/gen/dxos/agent/functions_pb.ts +1 -1
  105. package/src/buf/proto/gen/dxos/bot_pb.ts +1 -1
  106. package/src/buf/proto/gen/dxos/client/invitation_pb.ts +1 -1
  107. package/src/buf/proto/gen/dxos/client/logging_pb.ts +1 -1
  108. package/src/buf/proto/gen/dxos/client/queue_pb.ts +51 -2
  109. package/src/buf/proto/gen/dxos/client/services_pb.ts +77 -40
  110. package/src/buf/proto/gen/dxos/config_pb.ts +2 -7
  111. package/src/buf/proto/gen/dxos/devtools/diagnostics_pb.ts +1 -1
  112. package/src/buf/proto/gen/dxos/devtools/host_pb.ts +1 -1
  113. package/src/buf/proto/gen/dxos/devtools/swarm_pb.ts +1 -1
  114. package/src/buf/proto/gen/dxos/echo/blob_pb.ts +1 -1
  115. package/src/buf/proto/gen/dxos/echo/feed_pb.ts +1 -1
  116. package/src/buf/proto/gen/dxos/echo/filter_pb.ts +1 -1
  117. package/src/buf/proto/gen/dxos/echo/indexing_pb.ts +1 -1
  118. package/src/buf/proto/gen/dxos/echo/metadata_pb.ts +9 -2
  119. package/src/buf/proto/gen/dxos/echo/model/document_pb.ts +1 -1
  120. package/src/buf/proto/gen/dxos/echo/model/messenger_pb.ts +1 -1
  121. package/src/buf/proto/gen/dxos/echo/model/text_pb.ts +1 -1
  122. package/src/buf/proto/gen/dxos/echo/object_pb.ts +1 -1
  123. package/src/buf/proto/gen/dxos/echo/query_pb.ts +1 -1
  124. package/src/buf/proto/gen/dxos/echo/service_pb.ts +1 -1
  125. package/src/buf/proto/gen/dxos/echo/snapshot_pb.ts +1 -1
  126. package/src/buf/proto/gen/dxos/echo/timeframe_pb.ts +1 -1
  127. package/src/buf/proto/gen/dxos/edge/calls_pb.ts +1 -1
  128. package/src/buf/proto/gen/dxos/edge/messenger_pb.ts +39 -6
  129. package/src/buf/proto/gen/dxos/edge/signal_pb.ts +1 -1
  130. package/src/buf/proto/gen/dxos/error_pb.ts +1 -1
  131. package/src/buf/proto/gen/dxos/field_options_pb.ts +1 -1
  132. package/src/buf/proto/gen/dxos/google_pb.ts +1 -1
  133. package/src/buf/proto/gen/dxos/gravity_pb.ts +1 -1
  134. package/src/buf/proto/gen/dxos/halo/credentials/auth_pb.ts +1 -1
  135. package/src/buf/proto/gen/dxos/halo/credentials/greet_pb.ts +1 -1
  136. package/src/buf/proto/gen/dxos/halo/credentials/identity_pb.ts +1 -1
  137. package/src/buf/proto/gen/dxos/halo/credentials_pb.ts +49 -3
  138. package/src/buf/proto/gen/dxos/halo/invitations_pb.ts +1 -1
  139. package/src/buf/proto/gen/dxos/halo/keyring_pb.ts +1 -1
  140. package/src/buf/proto/gen/dxos/halo/keys_pb.ts +1 -1
  141. package/src/buf/proto/gen/dxos/halo/signed_pb.ts +1 -1
  142. package/src/buf/proto/gen/dxos/iframe_pb.ts +1 -1
  143. package/src/buf/proto/gen/dxos/keys_pb.ts +1 -1
  144. package/src/buf/proto/gen/dxos/mesh/bridge_pb.ts +1 -1
  145. package/src/buf/proto/gen/dxos/mesh/broadcast_pb.ts +1 -1
  146. package/src/buf/proto/gen/dxos/mesh/messaging_pb.ts +1 -1
  147. package/src/buf/proto/gen/dxos/mesh/muxer_pb.ts +1 -1
  148. package/src/buf/proto/gen/dxos/mesh/presence_pb.ts +1 -1
  149. package/src/buf/proto/gen/dxos/mesh/protocol_pb.ts +1 -1
  150. package/src/buf/proto/gen/dxos/mesh/replicator_pb.ts +1 -1
  151. package/src/buf/proto/gen/dxos/mesh/signal_pb.ts +1 -1
  152. package/src/buf/proto/gen/dxos/mesh/swarm_pb.ts +1 -1
  153. package/src/buf/proto/gen/dxos/mesh/teleport/admission-discovery_pb.ts +1 -1
  154. package/src/buf/proto/gen/dxos/mesh/teleport/auth_pb.ts +1 -1
  155. package/src/buf/proto/gen/dxos/mesh/teleport/automerge_pb.ts +1 -1
  156. package/src/buf/proto/gen/dxos/mesh/teleport/blobsync_pb.ts +1 -1
  157. package/src/buf/proto/gen/dxos/mesh/teleport/control_pb.ts +1 -1
  158. package/src/buf/proto/gen/dxos/mesh/teleport/gossip_pb.ts +1 -1
  159. package/src/buf/proto/gen/dxos/mesh/teleport/notarization_pb.ts +1 -1
  160. package/src/buf/proto/gen/dxos/mesh/teleport/replicator_pb.ts +1 -1
  161. package/src/buf/proto/gen/dxos/registry_pb.ts +1 -1
  162. package/src/buf/proto/gen/dxos/rpc_pb.ts +1 -1
  163. package/src/buf/proto/gen/dxos/service/agentmanager_pb.ts +1 -1
  164. package/src/buf/proto/gen/dxos/service/publisher_pb.ts +1 -1
  165. package/src/buf/proto/gen/dxos/service/supervisor_pb.ts +1 -1
  166. package/src/buf/proto/gen/dxos/service/tunnel_pb.ts +1 -1
  167. package/src/buf/proto/gen/dxos/tracing_pb.ts +1 -1
  168. package/src/buf/proto/gen/dxos/type_pb.ts +1 -1
  169. package/src/buf/proto/gen/dxos/value_pb.ts +1 -1
  170. package/src/buf/proto/gen/example/testing/data_pb.ts +1 -1
  171. package/src/buf/proto/gen/example/testing/rpc_pb.ts +1 -1
  172. package/src/codec.test.ts +1 -1
  173. package/src/edge/EdgeFunctionEnv.ts +25 -27
  174. package/src/edge/edge.ts +120 -0
  175. package/src/edge/errors.ts +1 -1
  176. package/src/edge/index.ts +3 -3
  177. package/src/errors/encoding.ts +2 -3
  178. package/src/errors/errors.test.ts +1 -1
  179. package/src/errors/errors.ts +2 -3
  180. package/src/errors/helpers.ts +1 -1
  181. package/src/errors/index.ts +5 -5
  182. package/src/index.ts +12 -14
  183. package/src/indexing.test.ts +1 -1
  184. package/src/proto/dxos/client/queue.proto +11 -0
  185. package/src/proto/dxos/client/services.proto +9 -1
  186. package/src/proto/dxos/config.proto +1 -3
  187. package/src/proto/dxos/echo/metadata.proto +3 -0
  188. package/src/proto/dxos/edge/messenger.proto +10 -0
  189. package/src/proto/dxos/halo/credentials.proto +15 -0
  190. package/src/proto/gen/dxos/client/services.ts +786 -751
  191. package/src/proto/gen/dxos/config.ts +0 -5
  192. package/src/proto/gen/dxos/devtools/host.ts +31 -31
  193. package/src/proto/gen/dxos/echo/metadata.ts +4 -0
  194. package/src/proto/gen/dxos/edge/messenger.ts +24 -0
  195. package/src/proto/gen/dxos/halo/credentials.ts +15 -1
  196. package/src/proto/gen/google/protobuf.ts +326 -40
  197. package/src/proto/gen/index.ts +29 -1
  198. package/src/proto/index.ts +2 -2
  199. package/src/proto/types.ts +1 -1
  200. package/src/space-archive.ts +70 -1
  201. package/src/types.ts +2 -2
  202. package/dist/src/queue.d.ts +0 -3
  203. package/dist/src/queue.d.ts.map +0 -1
  204. package/dist/src/queue.js +0 -5
  205. package/dist/src/queue.js.map +0 -1
  206. package/src/queue.ts +0 -14
@@ -67,962 +67,492 @@ import * as example_testing_rpc from "../../example/testing/rpc.js";
67
67
  import * as google_protobuf from "../../google/protobuf.js";
68
68
  /**
69
69
  * Defined in:
70
- * {@link file://./../../../dxos/client/logging.proto}
70
+ * {@link file://./../../../dxos/client/services.proto}
71
71
  */
72
- export interface Metrics {
73
- timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
74
- values?: Metrics.KeyPair[];
72
+ export enum SystemStatus {
73
+ INACTIVE = 0,
74
+ ACTIVE = 1
75
75
  }
76
- export namespace Metrics {
77
- /**
78
- * Defined in:
79
- * {@link file://./../../../dxos/client/logging.proto}
80
- */
81
- export interface KeyPair {
82
- /**
83
- * Options:
84
- * - proto3_optional = true
85
- */
86
- key?: string;
87
- /**
88
- * Options:
89
- * - proto3_optional = true
90
- */
91
- value?: dxos_value.Value;
92
- /**
93
- * Options:
94
- * - proto3_optional = true
95
- */
96
- stats?: dxos_value.Stats;
97
- }
76
+ /**
77
+ * Defined in:
78
+ * {@link file://./../../../dxos/client/services.proto}
79
+ */
80
+ export interface UpdateStatusRequest {
81
+ status: SystemStatus;
98
82
  }
99
83
  /**
100
84
  * Defined in:
101
- * {@link file://./../../../dxos/client/logging.proto}
85
+ * {@link file://./../../../dxos/client/services.proto}
102
86
  */
103
- export interface ControlMetricsRequest {
104
- /**
105
- * Options:
106
- * - proto3_optional = true
107
- */
108
- reset?: boolean;
87
+ export interface QueryStatusRequest {
109
88
  /**
110
89
  * Options:
111
90
  * - proto3_optional = true
112
91
  */
113
- record?: boolean;
92
+ interval?: number;
114
93
  }
115
94
  /**
116
95
  * Defined in:
117
- * {@link file://./../../../dxos/client/logging.proto}
96
+ * {@link file://./../../../dxos/client/services.proto}
118
97
  */
119
- export interface ControlMetricsResponse {
120
- /**
121
- * Options:
122
- * - proto3_optional = true
123
- */
124
- recording?: boolean;
98
+ export interface QueryStatusResponse {
99
+ status: SystemStatus;
125
100
  }
126
101
  /**
127
102
  * Defined in:
128
- * {@link file://./../../../dxos/client/logging.proto}
103
+ * {@link file://./../../../dxos/client/services.proto}
129
104
  */
130
- export interface QueryMetricsRequest {
105
+ export interface GetDiagnosticsRequest {
131
106
  /**
132
107
  * Options:
133
108
  * - proto3_optional = true
134
109
  */
135
- interval?: number;
110
+ keys?: GetDiagnosticsRequest.KEY_OPTION;
136
111
  }
137
- /**
138
- * Defined in:
139
- * {@link file://./../../../dxos/client/logging.proto}
140
- */
141
- export interface QueryMetricsResponse {
142
- timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
143
- metrics: Metrics;
112
+ export namespace GetDiagnosticsRequest {
113
+ /**
114
+ * Defined in:
115
+ * {@link file://./../../../dxos/client/services.proto}
116
+ */
117
+ export enum KEY_OPTION {
118
+ NONE = 0,
119
+ TRUNCATE = 1,
120
+ HUMANIZE = 2
121
+ }
144
122
  }
145
123
  /**
146
124
  * Defined in:
147
- * {@link file://./../../../dxos/client/logging.proto}
125
+ * {@link file://./../../../dxos/client/services.proto}
148
126
  */
149
- export enum LogLevel {
150
- NONE = 0,
151
- TRACE = 5,
152
- DEBUG = 10,
153
- VERBOSE = 11,
154
- INFO = 12,
155
- WARN = 13,
156
- ERROR = 14
127
+ export interface GetDiagnosticsResponse {
128
+ timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
129
+ diagnostics: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
157
130
  }
158
131
  /**
159
132
  * Defined in:
160
- * {@link file://./../../../dxos/client/logging.proto}
133
+ * {@link file://./../../../dxos/client/services.proto}
161
134
  */
162
- export interface QueryLogsRequest {
163
- filters?: QueryLogsRequest.Filter[];
135
+ export interface Platform {
136
+ type: Platform.PLATFORM_TYPE;
164
137
  /**
138
+ * The User-Agent string from a browser
139
+ *
165
140
  * Options:
166
141
  * - proto3_optional = true
167
142
  */
168
- options?: QueryLogsRequest.MatchingOptions;
169
- }
170
- export namespace QueryLogsRequest {
143
+ userAgent?: string;
171
144
  /**
172
- * Defined in:
173
- * {@link file://./../../../dxos/client/logging.proto}
145
+ * e.g process.platform from node, e.g. 'darwin', 'linux', 'win32'
146
+ *
147
+ * Options:
148
+ * - proto3_optional = true
174
149
  */
175
- export enum MatchingOptions {
176
- NONE = 0,
177
- INCLUSIVE = 1,
178
- EXPLICIT = 2
179
- }
150
+ platform?: string;
180
151
  /**
181
- * Defined in:
182
- * {@link file://./../../../dxos/client/logging.proto}
152
+ * the Node.JS arch string, e.g. 'arm64', 'x64'
153
+ *
154
+ * Options:
155
+ * - proto3_optional = true
183
156
  */
184
- export interface Filter {
185
- level: LogLevel;
186
- /**
187
- * Options:
188
- * - proto3_optional = true
189
- */
190
- pattern?: string;
191
- }
192
- }
193
- /**
194
- * Defined in:
195
- * {@link file://./../../../dxos/client/logging.proto}
196
- */
197
- export interface LogEntry {
198
- level: LogLevel;
199
- message: string;
157
+ arch?: string;
200
158
  /**
159
+ * the node.js version string
160
+ *
201
161
  * Options:
202
162
  * - proto3_optional = true
203
163
  */
204
- context?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
164
+ runtime?: string;
205
165
  /**
166
+ * the number of seconds the client has been up
167
+ *
206
168
  * Options:
207
169
  * - proto3_optional = true
208
170
  */
209
- meta?: LogEntry.Meta;
171
+ uptime?: number;
210
172
  /**
173
+ * e.g. NodeJS.MemoryUsage, subject to change
174
+ *
211
175
  * Options:
212
176
  * - proto3_optional = true
213
177
  */
214
- error?: dxos_error.Error;
215
- timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
178
+ memory?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
216
179
  }
217
- export namespace LogEntry {
180
+ export namespace Platform {
218
181
  /**
219
182
  * Defined in:
220
- * {@link file://./../../../dxos/client/logging.proto}
183
+ * {@link file://./../../../dxos/client/services.proto}
221
184
  */
222
- export interface Meta {
223
- file: string;
224
- line: number;
225
- /**
226
- * Options:
227
- * - proto3_optional = true
228
- */
229
- scope?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
230
- /**
231
- * Options:
232
- * - proto3_optional = true
233
- */
234
- resourceId?: number;
185
+ export enum PLATFORM_TYPE {
186
+ BROWSER = 0,
187
+ SHARED_WORKER = 1,
188
+ NODE = 2,
189
+ DEDICATED_WORKER = 3
235
190
  }
236
191
  }
237
192
  /**
238
193
  * Defined in:
239
- * {@link file://./../../../dxos/client/logging.proto}
240
- */
241
- export interface LoggingService {
242
- controlMetrics: (request: ControlMetricsRequest, options?: RequestOptions) => Promise<ControlMetricsResponse>;
243
- queryMetrics: (request: QueryMetricsRequest, options?: RequestOptions) => Stream<QueryMetricsResponse>;
244
- queryLogs: (request: QueryLogsRequest, options?: RequestOptions) => Stream<LogEntry>;
245
- }
246
- /**
247
- * Defined in:
248
- * {@link file://./../../../dxos/client/invitation.proto}
249
- */
250
- export interface AdmissionKeypair {
251
- publicKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
252
- /**
253
- * Options:
254
- * - proto3_optional = true
255
- */
256
- privateKey?: ReturnType<(typeof substitutions)["dxos.keys.PrivateKey"]["decode"]>;
257
- }
258
- /**
259
- * Runtime state of the space object.
260
- *
261
- * Defined in:
262
- * {@link file://./../../../dxos/client/invitation.proto}
263
- */
264
- export enum SpaceState {
265
- INVALID = 0,
266
- SPACE_INACTIVE = 2,
267
- SPACE_ACTIVE = 6,
268
- SPACE_CLOSED = 1,
269
- SPACE_CONTROL_ONLY = 7,
270
- SPACE_INITIALIZING = 4,
271
- SPACE_READY = 3,
272
- SPACE_ERROR = 5,
273
- SPACE_REQUIRES_MIGRATION = 8
274
- }
275
- /**
276
- * Represents the invitation state passed between client and service.
277
- *
278
- * Defined in:
279
- * {@link file://./../../../dxos/client/invitation.proto}
194
+ * {@link file://./../../../dxos/client/services.proto}
280
195
  */
281
- export interface Invitation {
196
+ export interface SystemService {
282
197
  /**
283
- * Local identifier (random).
198
+ * Get the static config of the client.
284
199
  */
285
- invitationId: string;
200
+ getConfig: (request: void, options?: RequestOptions) => Promise<dxos_config.Config>;
286
201
  /**
287
- * Determines the behavior of the invitation.
202
+ * Get the diagnostics snapshot.
288
203
  */
289
- type: Invitation.Type;
204
+ getDiagnostics: (request: GetDiagnosticsRequest, options?: RequestOptions) => Promise<GetDiagnosticsResponse>;
290
205
  /**
291
- * Kind of access the invitation will grant.
206
+ * Update the status of the client. Used to re-activate an inactive client.
292
207
  */
293
- kind: Invitation.Kind;
208
+ updateStatus: (request: UpdateStatusRequest, options?: RequestOptions) => Promise<void>;
294
209
  /**
295
- * How the invitation is authenticated.
210
+ * Stream the status of the client.
296
211
  */
297
- authMethod: Invitation.AuthMethod;
212
+ queryStatus: (request: QueryStatusRequest, options?: RequestOptions) => Stream<QueryStatusResponse>;
298
213
  /**
299
- * Swarm rendezvous (random).
214
+ * Reset the client.
300
215
  */
301
- swarmKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
216
+ reset: (request: void, options?: RequestOptions) => Promise<void>;
302
217
  /**
303
- * Local state.
218
+ * Get platform Information
304
219
  */
305
- state: Invitation.State;
220
+ getPlatform: (request: void, options?: RequestOptions) => Promise<Platform>;
221
+ }
222
+ /**
223
+ * Defined in:
224
+ * {@link file://./../../../dxos/client/services.proto}
225
+ */
226
+ export interface Identity {
227
+ did: string;
228
+ identityKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
306
229
  /**
307
- * Timeout for guest to complete invitation once connected (ms).
308
- *
309
230
  * Options:
310
231
  * - proto3_optional = true
311
232
  */
312
- timeout?: number;
233
+ spaceKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
313
234
  /**
314
- * Guest's identity.
315
- *
316
235
  * Options:
317
236
  * - proto3_optional = true
318
237
  */
319
- identityKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
320
- /**
321
- * Space to join (only present if kind is SPACE).
322
- *
323
- * Options:
324
- * - proto3_optional = true
325
- */
326
- spaceKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
327
- /**
328
- * Authentication code created by host (only present if auth_method is SHARED_SECRET).
329
- *
330
- * Options:
331
- * - proto3_optional = true
332
- */
333
- authCode?: string;
334
- /**
335
- * Path or identifier to navigate to after successful authentication.
336
- *
337
- * Options:
338
- * - proto3_optional = true
339
- */
340
- target?: string;
341
- /**
342
- * Host should resume invitation on startup until timeout.
343
- *
344
- * Options:
345
- * - proto3_optional = true
346
- */
347
- persistent?: boolean;
348
- /**
349
- * Options:
350
- * - proto3_optional = true
351
- */
352
- created?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
353
- /**
354
- * Options:
355
- * - proto3_optional = true
356
- */
357
- lifetime?: number;
358
- /**
359
- * Whether an invitation can be used multiple times.
360
- *
361
- * Options:
362
- * - proto3_optional = true
363
- */
364
- multiUse?: boolean;
365
- /**
366
- * Guest's keypair required for AuthMethod.KNOWN_PUBLIC_KEY.
367
- *
368
- * Options:
369
- * - proto3_optional = true
370
- */
371
- guestKeypair?: AdmissionKeypair;
372
- /**
373
- * Present on Type.DELEGATED invitations.
374
- *
375
- * Options:
376
- * - proto3_optional = true
377
- */
378
- delegationCredentialId?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
379
- /**
380
- * Role of the admitted member, defaults to ADMIN.
381
- *
382
- * Options:
383
- * - proto3_optional = true
384
- */
385
- role?: dxos_halo_credentials.SpaceMember.Role;
386
- /**
387
- * Id of a the space to join (only present if kind is SPACE).
388
- *
389
- * Options:
390
- * - proto3_optional = true
391
- */
392
- spaceId?: string;
238
+ profile?: dxos_halo_credentials.ProfileDocument;
393
239
  }
394
- export namespace Invitation {
240
+ /**
241
+ * Defined in:
242
+ * {@link file://./../../../dxos/client/services.proto}
243
+ */
244
+ export interface RequestRecoveryChallengeResponse {
245
+ deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
246
+ controlFeedKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
247
+ challenge: string;
248
+ }
249
+ /**
250
+ * Defined in:
251
+ * {@link file://./../../../dxos/client/services.proto}
252
+ */
253
+ export interface RecoverIdentityRequest {
254
+ recoveryCode?: string;
255
+ external?: RecoverIdentityRequest.ExternalSignature;
256
+ token?: string;
257
+ }
258
+ export namespace RecoverIdentityRequest {
395
259
  /**
396
260
  * Defined in:
397
- * {@link file://./../../../dxos/client/invitation.proto}
261
+ * {@link file://./../../../dxos/client/services.proto}
398
262
  */
399
- export enum Type {
400
- INTERACTIVE = 0,
401
- DELEGATED = 1,
402
- MULTIUSE = 2
263
+ export interface ExternalSignature {
264
+ lookupKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
265
+ deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
266
+ controlFeedKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
267
+ signature: Uint8Array;
268
+ /**
269
+ * Options:
270
+ * - proto3_optional = true
271
+ */
272
+ clientDataJson?: Uint8Array;
273
+ /**
274
+ * Options:
275
+ * - proto3_optional = true
276
+ */
277
+ authenticatorData?: Uint8Array;
403
278
  }
279
+ }
280
+ /**
281
+ * Defined in:
282
+ * {@link file://./../../../dxos/client/services.proto}
283
+ */
284
+ export interface RecoveryCredentialData {
404
285
  /**
405
- * Defined in:
406
- * {@link file://./../../../dxos/client/invitation.proto}
286
+ * Recovery key used to validate recovery challenge signature.
407
287
  */
408
- export enum Kind {
409
- DEVICE = 0,
410
- SPACE = 1
411
- }
288
+ recoveryKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
412
289
  /**
413
- * Defined in:
414
- * {@link file://./../../../dxos/client/invitation.proto}
290
+ * Public key used to identify the recovery key.
415
291
  */
416
- export enum AuthMethod {
417
- NONE = 0,
418
- SHARED_SECRET = 1,
419
- KNOWN_PUBLIC_KEY = 2
420
- }
292
+ lookupKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
421
293
  /**
422
- * Defined in:
423
- * {@link file://./../../../dxos/client/invitation.proto}
294
+ * Algorithm used to generate the recovery key.
424
295
  */
425
- export enum State {
426
- INIT = 0,
427
- CONNECTING = 1,
428
- CONNECTED = 2,
429
- READY_FOR_AUTHENTICATION = 3,
430
- AUTHENTICATING = 4,
431
- SUCCESS = 5,
432
- CANCELLED = 6,
433
- TIMEOUT = 7,
434
- ERROR = 8,
435
- EXPIRED = 9
436
- }
296
+ algorithm: string;
437
297
  }
438
298
  /**
439
299
  * Defined in:
440
- * {@link file://./../../../dxos/client/queue.proto}
300
+ * {@link file://./../../../dxos/client/services.proto}
441
301
  */
442
- export interface QueueQuery {
443
- spaceId: string;
444
- /**
445
- * Options:
446
- * - proto3_optional = true
447
- */
448
- queuesNamespace?: string;
449
- /**
450
- * Queries the whole space if missing.
451
- */
452
- queueIds?: string[];
302
+ export interface CreateRecoveryCredentialRequest {
453
303
  /**
454
- * Filter items after this cursor. Exclusive.
304
+ * If not provided, a new key will be generated.
455
305
  *
456
306
  * Options:
457
307
  * - proto3_optional = true
458
308
  */
459
- after?: string;
309
+ data?: RecoveryCredentialData;
310
+ }
311
+ /**
312
+ * Defined in:
313
+ * {@link file://./../../../dxos/client/services.proto}
314
+ */
315
+ export interface CreateRecoveryCredentialResponse {
460
316
  /**
461
- * Filter items before this cursor. Exclusive.
462
- *
463
317
  * Options:
464
318
  * - proto3_optional = true
465
319
  */
466
- before?: string;
320
+ recoveryCode?: string;
321
+ }
322
+ /**
323
+ * Defined in:
324
+ * {@link file://./../../../dxos/client/services.proto}
325
+ */
326
+ export interface QueryIdentityResponse {
467
327
  /**
468
- * Filter items after this position. Inclusive.
469
- *
470
328
  * Options:
471
329
  * - proto3_optional = true
472
330
  */
473
- beginPosition?: string;
331
+ identity?: Identity;
332
+ }
333
+ /**
334
+ * Defined in:
335
+ * {@link file://./../../../dxos/client/services.proto}
336
+ */
337
+ export interface SignPresentationRequest {
338
+ presentation: dxos_halo_credentials.Presentation;
474
339
  /**
475
- * Filter items before this position. Exclusive.
476
- *
477
340
  * Options:
478
341
  * - proto3_optional = true
479
342
  */
480
- endPosition?: string;
343
+ nonce?: Uint8Array;
344
+ }
345
+ /**
346
+ * Defined in:
347
+ * {@link file://./../../../dxos/client/services.proto}
348
+ */
349
+ export interface CreateIdentityRequest {
481
350
  /**
482
351
  * Options:
483
352
  * - proto3_optional = true
484
353
  */
485
- limit?: number;
354
+ profile?: dxos_halo_credentials.ProfileDocument;
486
355
  /**
487
356
  * Options:
488
357
  * - proto3_optional = true
489
358
  */
490
- reverse?: boolean;
491
- objectIds?: string[];
359
+ deviceProfile?: dxos_halo_credentials.DeviceProfileDocument;
492
360
  }
493
361
  /**
494
362
  * Defined in:
495
- * {@link file://./../../../dxos/client/queue.proto}
363
+ * {@link file://./../../../dxos/client/services.proto}
496
364
  */
497
- export interface QueueQueryResult {
498
- objects?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>[];
499
- /**
500
- * Cursor to query the next items. Can be passed to `after` in query to keep querying.
501
- */
502
- nextCursor: string;
503
- prevCursor: string;
365
+ export interface IdentityService {
366
+ createIdentity: (request: CreateIdentityRequest, options?: RequestOptions) => Promise<Identity>;
367
+ requestRecoveryChallenge: (request: void, options?: RequestOptions) => Promise<RequestRecoveryChallengeResponse>;
368
+ recoverIdentity: (request: RecoverIdentityRequest, options?: RequestOptions) => Promise<Identity>;
369
+ createRecoveryCredential: (request: CreateRecoveryCredentialRequest, options?: RequestOptions) => Promise<CreateRecoveryCredentialResponse>;
370
+ queryIdentity: (request: void, options?: RequestOptions) => Stream<QueryIdentityResponse>;
371
+ updateProfile: (request: dxos_halo_credentials.ProfileDocument, options?: RequestOptions) => Promise<Identity>;
372
+ signPresentation: (request: SignPresentationRequest, options?: RequestOptions) => Promise<dxos_halo_credentials.Presentation>;
373
+ createAuthCredential: (request: void, options?: RequestOptions) => Promise<dxos_halo_credentials.Credential>;
504
374
  }
505
375
  /**
506
376
  * Defined in:
507
- * {@link file://./../../../dxos/client/queue.proto}
377
+ * {@link file://./../../../dxos/client/services.proto}
508
378
  */
509
- export interface QueryQueueRequest {
510
- query: QueueQuery;
379
+ export enum DeviceKind {
380
+ CURRENT = 0,
381
+ TRUSTED = 1
511
382
  }
512
383
  /**
513
384
  * Defined in:
514
- * {@link file://./../../../dxos/client/queue.proto}
385
+ * {@link file://./../../../dxos/client/services.proto}
515
386
  */
516
- export interface InsertIntoQueueRequest {
517
- subspaceTag: string;
518
- spaceId: string;
519
- queueId: string;
520
- objects?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>[];
387
+ export interface Device {
388
+ deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
389
+ kind: DeviceKind;
390
+ /**
391
+ * Options:
392
+ * - proto3_optional = true
393
+ */
394
+ profile?: dxos_halo_credentials.DeviceProfileDocument;
395
+ presence: Device.PresenceState;
521
396
  }
522
- /**
523
- * Defined in:
524
- * {@link file://./../../../dxos/client/queue.proto}
525
- */
526
- export interface DeleteFromQueueRequest {
527
- subspaceTag: string;
528
- spaceId: string;
529
- queueId: string;
530
- objectIds?: string[];
531
- }
532
- /**
533
- * Defined in:
534
- * {@link file://./../../../dxos/client/queue.proto}
535
- */
536
- export interface QueueService {
537
- queryQueue: (request: QueryQueueRequest, options?: RequestOptions) => Promise<QueueQueryResult>;
538
- insertIntoQueue: (request: InsertIntoQueueRequest, options?: RequestOptions) => Promise<void>;
539
- deleteFromQueue: (request: DeleteFromQueueRequest, options?: RequestOptions) => Promise<void>;
397
+ export namespace Device {
398
+ /**
399
+ * Defined in:
400
+ * {@link file://./../../../dxos/client/services.proto}
401
+ */
402
+ export enum PresenceState {
403
+ OFFLINE = 0,
404
+ ONLINE = 1,
405
+ REMOVED = 2
406
+ }
540
407
  }
541
408
  /**
542
409
  * Defined in:
543
410
  * {@link file://./../../../dxos/client/services.proto}
544
411
  */
545
- export enum SystemStatus {
546
- INACTIVE = 0,
547
- ACTIVE = 1
412
+ export interface QueryDevicesResponse {
413
+ devices?: Device[];
548
414
  }
549
415
  /**
550
416
  * Defined in:
551
417
  * {@link file://./../../../dxos/client/services.proto}
552
418
  */
553
- export interface UpdateStatusRequest {
554
- status: SystemStatus;
419
+ export interface DevicesService {
420
+ updateDevice: (request: dxos_halo_credentials.DeviceProfileDocument, options?: RequestOptions) => Promise<Device>;
421
+ queryDevices: (request: void, options?: RequestOptions) => Stream<QueryDevicesResponse>;
555
422
  }
556
423
  /**
557
424
  * Defined in:
558
425
  * {@link file://./../../../dxos/client/services.proto}
559
426
  */
560
- export interface QueryStatusRequest {
427
+ export interface Contact {
428
+ identityKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
561
429
  /**
562
430
  * Options:
563
431
  * - proto3_optional = true
564
432
  */
565
- interval?: number;
433
+ profile?: dxos_halo_credentials.ProfileDocument;
434
+ commonSpaces?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>[];
566
435
  }
567
436
  /**
568
437
  * Defined in:
569
438
  * {@link file://./../../../dxos/client/services.proto}
570
439
  */
571
- export interface QueryStatusResponse {
572
- status: SystemStatus;
440
+ export interface ContactBook {
441
+ contacts?: Contact[];
573
442
  }
574
443
  /**
575
444
  * Defined in:
576
445
  * {@link file://./../../../dxos/client/services.proto}
577
446
  */
578
- export interface GetDiagnosticsRequest {
579
- /**
580
- * Options:
581
- * - proto3_optional = true
582
- */
583
- keys?: GetDiagnosticsRequest.KEY_OPTION;
447
+ export interface ContactsService {
448
+ getContacts: (request: void, options?: RequestOptions) => Promise<ContactBook>;
449
+ queryContacts: (request: void, options?: RequestOptions) => Stream<ContactBook>;
584
450
  }
585
- export namespace GetDiagnosticsRequest {
451
+ /**
452
+ * Defined in:
453
+ * {@link file://./../../../dxos/client/services.proto}
454
+ */
455
+ export interface SpaceMember {
456
+ identity: Identity;
457
+ presence: SpaceMember.PresenceState;
458
+ peerStates?: dxos_mesh_presence.PeerState[];
459
+ role: dxos_halo_credentials.SpaceMember.Role;
460
+ }
461
+ export namespace SpaceMember {
586
462
  /**
587
463
  * Defined in:
588
464
  * {@link file://./../../../dxos/client/services.proto}
589
465
  */
590
- export enum KEY_OPTION {
591
- NONE = 0,
592
- TRUNCATE = 1,
593
- HUMANIZE = 2
466
+ export enum PresenceState {
467
+ OFFLINE = 0,
468
+ ONLINE = 1
594
469
  }
595
470
  }
596
471
  /**
597
472
  * Defined in:
598
473
  * {@link file://./../../../dxos/client/services.proto}
599
474
  */
600
- export interface GetDiagnosticsResponse {
601
- timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
602
- diagnostics: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
603
- }
604
- /**
605
- * Defined in:
606
- * {@link file://./../../../dxos/client/services.proto}
607
- */
608
- export interface Platform {
609
- type: Platform.PLATFORM_TYPE;
610
- /**
611
- * The User-Agent string from a browser
612
- *
613
- * Options:
614
- * - proto3_optional = true
615
- */
616
- userAgent?: string;
475
+ export interface Space {
476
+ id: string;
477
+ spaceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
478
+ state: SpaceState;
617
479
  /**
618
- * e.g process.platform from node, e.g. 'darwin', 'linux', 'win32'
619
- *
620
480
  * Options:
621
481
  * - proto3_optional = true
622
482
  */
623
- platform?: string;
483
+ pipeline?: Space.PipelineState;
624
484
  /**
625
- * the Node.JS arch string, e.g. 'arm64', 'x64'
626
- *
627
485
  * Options:
628
486
  * - proto3_optional = true
629
487
  */
630
- arch?: string;
488
+ error?: dxos_error.Error;
631
489
  /**
632
- * the node.js version string
633
- *
634
490
  * Options:
635
491
  * - proto3_optional = true
636
492
  */
637
- runtime?: string;
493
+ edgeReplication?: dxos_echo_metadata.EdgeReplicationSetting;
494
+ tags?: string[];
495
+ membershipPolicy: dxos_halo_credentials.MembershipPolicy;
496
+ members?: SpaceMember[];
638
497
  /**
639
- * the number of seconds the client has been up
640
- *
641
498
  * Options:
642
499
  * - proto3_optional = true
643
500
  */
644
- uptime?: number;
501
+ creator?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
645
502
  /**
646
- * e.g. NodeJS.MemoryUsage, subject to change
647
- *
648
503
  * Options:
649
504
  * - proto3_optional = true
650
505
  */
651
- memory?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
506
+ cache?: dxos_echo_metadata.SpaceCache;
507
+ metrics: Space.Metrics;
652
508
  }
653
- export namespace Platform {
509
+ export namespace Space {
654
510
  /**
655
511
  * Defined in:
656
512
  * {@link file://./../../../dxos/client/services.proto}
657
513
  */
658
- export enum PLATFORM_TYPE {
659
- BROWSER = 0,
660
- SHARED_WORKER = 1,
661
- NODE = 2
514
+ export interface Metrics {
515
+ /**
516
+ * Options:
517
+ * - proto3_optional = true
518
+ */
519
+ open?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
520
+ /**
521
+ * Options:
522
+ * - proto3_optional = true
523
+ */
524
+ pipelineInitBegin?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
525
+ /**
526
+ * Options:
527
+ * - proto3_optional = true
528
+ */
529
+ controlPipelineReady?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
530
+ /**
531
+ * Options:
532
+ * - proto3_optional = true
533
+ */
534
+ dataPipelineOpen?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
535
+ /**
536
+ * Options:
537
+ * - proto3_optional = true
538
+ */
539
+ dataPipelineReady?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
540
+ /**
541
+ * Options:
542
+ * - proto3_optional = true
543
+ */
544
+ ready?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
662
545
  }
663
- }
664
- /**
665
- * Defined in:
666
- * {@link file://./../../../dxos/client/services.proto}
667
- */
668
- export interface SystemService {
669
- /**
670
- * Get the static config of the client.
671
- */
672
- getConfig: (request: void, options?: RequestOptions) => Promise<dxos_config.Config>;
673
- /**
674
- * Get the diagnostics snapshot.
675
- */
676
- getDiagnostics: (request: GetDiagnosticsRequest, options?: RequestOptions) => Promise<GetDiagnosticsResponse>;
677
- /**
678
- * Update the status of the client. Used to re-activate an inactive client.
679
- */
680
- updateStatus: (request: UpdateStatusRequest, options?: RequestOptions) => Promise<void>;
681
- /**
682
- * Stream the status of the client.
683
- */
684
- queryStatus: (request: QueryStatusRequest, options?: RequestOptions) => Stream<QueryStatusResponse>;
685
- /**
686
- * Reset the client.
687
- */
688
- reset: (request: void, options?: RequestOptions) => Promise<void>;
689
- /**
690
- * Get platform Information
691
- */
692
- getPlatform: (request: void, options?: RequestOptions) => Promise<Platform>;
693
- }
694
- /**
695
- * Defined in:
696
- * {@link file://./../../../dxos/client/services.proto}
697
- */
698
- export interface Identity {
699
- did: string;
700
- identityKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
701
- /**
702
- * Options:
703
- * - proto3_optional = true
704
- */
705
- spaceKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
706
- /**
707
- * Options:
708
- * - proto3_optional = true
709
- */
710
- profile?: dxos_halo_credentials.ProfileDocument;
711
- }
712
- /**
713
- * Defined in:
714
- * {@link file://./../../../dxos/client/services.proto}
715
- */
716
- export interface RequestRecoveryChallengeResponse {
717
- deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
718
- controlFeedKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
719
- challenge: string;
720
- }
721
- /**
722
- * Defined in:
723
- * {@link file://./../../../dxos/client/services.proto}
724
- */
725
- export interface RecoverIdentityRequest {
726
- recoveryCode?: string;
727
- external?: RecoverIdentityRequest.ExternalSignature;
728
- token?: string;
729
- }
730
- export namespace RecoverIdentityRequest {
731
546
  /**
732
547
  * Defined in:
733
548
  * {@link file://./../../../dxos/client/services.proto}
734
549
  */
735
- export interface ExternalSignature {
736
- lookupKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
737
- deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
738
- controlFeedKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
739
- signature: Uint8Array;
550
+ export interface PipelineState {
740
551
  /**
741
552
  * Options:
742
553
  * - proto3_optional = true
743
554
  */
744
- clientDataJson?: Uint8Array;
745
- /**
746
- * Options:
747
- * - proto3_optional = true
748
- */
749
- authenticatorData?: Uint8Array;
750
- }
751
- }
752
- /**
753
- * Defined in:
754
- * {@link file://./../../../dxos/client/services.proto}
755
- */
756
- export interface RecoveryCredentialData {
757
- /**
758
- * Recovery key used to validate recovery challenge signature.
759
- */
760
- recoveryKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
761
- /**
762
- * Public key used to identify the recovery key.
763
- */
764
- lookupKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
765
- /**
766
- * Algorithm used to generate the recovery key.
767
- */
768
- algorithm: string;
769
- }
770
- /**
771
- * Defined in:
772
- * {@link file://./../../../dxos/client/services.proto}
773
- */
774
- export interface CreateRecoveryCredentialRequest {
775
- /**
776
- * If not provided, a new key will be generated.
777
- *
778
- * Options:
779
- * - proto3_optional = true
780
- */
781
- data?: RecoveryCredentialData;
782
- }
783
- /**
784
- * Defined in:
785
- * {@link file://./../../../dxos/client/services.proto}
786
- */
787
- export interface CreateRecoveryCredentialResponse {
788
- /**
789
- * Options:
790
- * - proto3_optional = true
791
- */
792
- recoveryCode?: string;
793
- }
794
- /**
795
- * Defined in:
796
- * {@link file://./../../../dxos/client/services.proto}
797
- */
798
- export interface QueryIdentityResponse {
799
- /**
800
- * Options:
801
- * - proto3_optional = true
802
- */
803
- identity?: Identity;
804
- }
805
- /**
806
- * Defined in:
807
- * {@link file://./../../../dxos/client/services.proto}
808
- */
809
- export interface SignPresentationRequest {
810
- presentation: dxos_halo_credentials.Presentation;
811
- /**
812
- * Options:
813
- * - proto3_optional = true
814
- */
815
- nonce?: Uint8Array;
816
- }
817
- /**
818
- * Defined in:
819
- * {@link file://./../../../dxos/client/services.proto}
820
- */
821
- export interface CreateIdentityRequest {
822
- /**
823
- * Options:
824
- * - proto3_optional = true
825
- */
826
- profile?: dxos_halo_credentials.ProfileDocument;
827
- /**
828
- * Options:
829
- * - proto3_optional = true
830
- */
831
- deviceProfile?: dxos_halo_credentials.DeviceProfileDocument;
832
- }
833
- /**
834
- * Defined in:
835
- * {@link file://./../../../dxos/client/services.proto}
836
- */
837
- export interface IdentityService {
838
- createIdentity: (request: CreateIdentityRequest, options?: RequestOptions) => Promise<Identity>;
839
- requestRecoveryChallenge: (request: void, options?: RequestOptions) => Promise<RequestRecoveryChallengeResponse>;
840
- recoverIdentity: (request: RecoverIdentityRequest, options?: RequestOptions) => Promise<Identity>;
841
- createRecoveryCredential: (request: CreateRecoveryCredentialRequest, options?: RequestOptions) => Promise<CreateRecoveryCredentialResponse>;
842
- queryIdentity: (request: void, options?: RequestOptions) => Stream<QueryIdentityResponse>;
843
- updateProfile: (request: dxos_halo_credentials.ProfileDocument, options?: RequestOptions) => Promise<Identity>;
844
- signPresentation: (request: SignPresentationRequest, options?: RequestOptions) => Promise<dxos_halo_credentials.Presentation>;
845
- createAuthCredential: (request: void, options?: RequestOptions) => Promise<dxos_halo_credentials.Credential>;
846
- }
847
- /**
848
- * Defined in:
849
- * {@link file://./../../../dxos/client/services.proto}
850
- */
851
- export enum DeviceKind {
852
- CURRENT = 0,
853
- TRUSTED = 1
854
- }
855
- /**
856
- * Defined in:
857
- * {@link file://./../../../dxos/client/services.proto}
858
- */
859
- export interface Device {
860
- deviceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
861
- kind: DeviceKind;
862
- /**
863
- * Options:
864
- * - proto3_optional = true
865
- */
866
- profile?: dxos_halo_credentials.DeviceProfileDocument;
867
- presence: Device.PresenceState;
868
- }
869
- export namespace Device {
870
- /**
871
- * Defined in:
872
- * {@link file://./../../../dxos/client/services.proto}
873
- */
874
- export enum PresenceState {
875
- OFFLINE = 0,
876
- ONLINE = 1,
877
- REMOVED = 2
878
- }
879
- }
880
- /**
881
- * Defined in:
882
- * {@link file://./../../../dxos/client/services.proto}
883
- */
884
- export interface QueryDevicesResponse {
885
- devices?: Device[];
886
- }
887
- /**
888
- * Defined in:
889
- * {@link file://./../../../dxos/client/services.proto}
890
- */
891
- export interface DevicesService {
892
- updateDevice: (request: dxos_halo_credentials.DeviceProfileDocument, options?: RequestOptions) => Promise<Device>;
893
- queryDevices: (request: void, options?: RequestOptions) => Stream<QueryDevicesResponse>;
894
- }
895
- /**
896
- * Defined in:
897
- * {@link file://./../../../dxos/client/services.proto}
898
- */
899
- export interface Contact {
900
- identityKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
901
- /**
902
- * Options:
903
- * - proto3_optional = true
904
- */
905
- profile?: dxos_halo_credentials.ProfileDocument;
906
- commonSpaces?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>[];
907
- }
908
- /**
909
- * Defined in:
910
- * {@link file://./../../../dxos/client/services.proto}
911
- */
912
- export interface ContactBook {
913
- contacts?: Contact[];
914
- }
915
- /**
916
- * Defined in:
917
- * {@link file://./../../../dxos/client/services.proto}
918
- */
919
- export interface ContactsService {
920
- getContacts: (request: void, options?: RequestOptions) => Promise<ContactBook>;
921
- queryContacts: (request: void, options?: RequestOptions) => Stream<ContactBook>;
922
- }
923
- /**
924
- * Defined in:
925
- * {@link file://./../../../dxos/client/services.proto}
926
- */
927
- export interface SpaceMember {
928
- identity: Identity;
929
- presence: SpaceMember.PresenceState;
930
- peerStates?: dxos_mesh_presence.PeerState[];
931
- role: dxos_halo_credentials.SpaceMember.Role;
932
- }
933
- export namespace SpaceMember {
934
- /**
935
- * Defined in:
936
- * {@link file://./../../../dxos/client/services.proto}
937
- */
938
- export enum PresenceState {
939
- OFFLINE = 0,
940
- ONLINE = 1
941
- }
942
- }
943
- /**
944
- * Defined in:
945
- * {@link file://./../../../dxos/client/services.proto}
946
- */
947
- export interface Space {
948
- id: string;
949
- spaceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
950
- state: SpaceState;
951
- /**
952
- * Options:
953
- * - proto3_optional = true
954
- */
955
- pipeline?: Space.PipelineState;
956
- /**
957
- * Options:
958
- * - proto3_optional = true
959
- */
960
- error?: dxos_error.Error;
961
- /**
962
- * Options:
963
- * - proto3_optional = true
964
- */
965
- edgeReplication?: dxos_echo_metadata.EdgeReplicationSetting;
966
- members?: SpaceMember[];
967
- /**
968
- * Options:
969
- * - proto3_optional = true
970
- */
971
- creator?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
972
- /**
973
- * Options:
974
- * - proto3_optional = true
975
- */
976
- cache?: dxos_echo_metadata.SpaceCache;
977
- metrics: Space.Metrics;
978
- }
979
- export namespace Space {
980
- /**
981
- * Defined in:
982
- * {@link file://./../../../dxos/client/services.proto}
983
- */
984
- export interface Metrics {
985
- /**
986
- * Options:
987
- * - proto3_optional = true
988
- */
989
- open?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
990
- /**
991
- * Options:
992
- * - proto3_optional = true
993
- */
994
- pipelineInitBegin?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
995
- /**
996
- * Options:
997
- * - proto3_optional = true
998
- */
999
- controlPipelineReady?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1000
- /**
1001
- * Options:
1002
- * - proto3_optional = true
1003
- */
1004
- dataPipelineOpen?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1005
- /**
1006
- * Options:
1007
- * - proto3_optional = true
1008
- */
1009
- dataPipelineReady?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1010
- /**
1011
- * Options:
1012
- * - proto3_optional = true
1013
- */
1014
- ready?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1015
- }
1016
- /**
1017
- * Defined in:
1018
- * {@link file://./../../../dxos/client/services.proto}
1019
- */
1020
- export interface PipelineState {
1021
- /**
1022
- * Options:
1023
- * - proto3_optional = true
1024
- */
1025
- controlFeedKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
555
+ controlFeedKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1026
556
  /**
1027
557
  * Options:
1028
558
  * - proto3_optional = true
@@ -1123,7 +653,15 @@ export namespace Space {
1123
653
  * Defined in:
1124
654
  * {@link file://./../../../dxos/client/services.proto}
1125
655
  */
1126
- export interface UpdateSpaceRequest {
656
+ export interface CreateSpaceRequest {
657
+ tags?: string[];
658
+ membershipPolicy: dxos_halo_credentials.MembershipPolicy;
659
+ }
660
+ /**
661
+ * Defined in:
662
+ * {@link file://./../../../dxos/client/services.proto}
663
+ */
664
+ export interface UpdateSpaceRequest {
1127
665
  spaceKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1128
666
  /**
1129
667
  * Allowed values: ACTIVE, INACTIVE.
@@ -1318,7 +856,7 @@ export interface ImportSpaceResponse {
1318
856
  * {@link file://./../../../dxos/client/services.proto}
1319
857
  */
1320
858
  export interface SpacesService {
1321
- createSpace: (request: void, options?: RequestOptions) => Promise<Space>;
859
+ createSpace: (request: CreateSpaceRequest, options?: RequestOptions) => Promise<Space>;
1322
860
  updateSpace: (request: UpdateSpaceRequest, options?: RequestOptions) => Promise<void>;
1323
861
  querySpaces: (request: void, options?: RequestOptions) => Stream<QuerySpacesResponse>;
1324
862
  updateMemberRole: (request: UpdateMemberRoleRequest, options?: RequestOptions) => Promise<void>;
@@ -1559,3 +1097,500 @@ export namespace QueryAgentStatusResponse {
1559
1097
  NOT_FOUND = 3
1560
1098
  }
1561
1099
  }
1100
+ /**
1101
+ * Defined in:
1102
+ * {@link file://./../../../dxos/client/queue.proto}
1103
+ */
1104
+ export interface QueueQuery {
1105
+ spaceId: string;
1106
+ /**
1107
+ * Options:
1108
+ * - proto3_optional = true
1109
+ */
1110
+ queuesNamespace?: string;
1111
+ /**
1112
+ * Queries the whole space if missing.
1113
+ */
1114
+ queueIds?: string[];
1115
+ /**
1116
+ * Filter items after this cursor. Exclusive.
1117
+ *
1118
+ * Options:
1119
+ * - proto3_optional = true
1120
+ */
1121
+ after?: string;
1122
+ /**
1123
+ * Filter items before this cursor. Exclusive.
1124
+ *
1125
+ * Options:
1126
+ * - proto3_optional = true
1127
+ */
1128
+ before?: string;
1129
+ /**
1130
+ * Filter items after this position. Inclusive.
1131
+ *
1132
+ * Options:
1133
+ * - proto3_optional = true
1134
+ */
1135
+ beginPosition?: string;
1136
+ /**
1137
+ * Filter items before this position. Exclusive.
1138
+ *
1139
+ * Options:
1140
+ * - proto3_optional = true
1141
+ */
1142
+ endPosition?: string;
1143
+ /**
1144
+ * Options:
1145
+ * - proto3_optional = true
1146
+ */
1147
+ limit?: number;
1148
+ /**
1149
+ * Options:
1150
+ * - proto3_optional = true
1151
+ */
1152
+ reverse?: boolean;
1153
+ objectIds?: string[];
1154
+ }
1155
+ /**
1156
+ * Defined in:
1157
+ * {@link file://./../../../dxos/client/queue.proto}
1158
+ */
1159
+ export interface QueueQueryResult {
1160
+ objects?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>[];
1161
+ /**
1162
+ * Cursor to query the next items. Can be passed to `after` in query to keep querying.
1163
+ */
1164
+ nextCursor: string;
1165
+ prevCursor: string;
1166
+ }
1167
+ /**
1168
+ * Defined in:
1169
+ * {@link file://./../../../dxos/client/queue.proto}
1170
+ */
1171
+ export interface QueryQueueRequest {
1172
+ query: QueueQuery;
1173
+ }
1174
+ /**
1175
+ * Defined in:
1176
+ * {@link file://./../../../dxos/client/queue.proto}
1177
+ */
1178
+ export interface InsertIntoQueueRequest {
1179
+ subspaceTag: string;
1180
+ spaceId: string;
1181
+ queueId: string;
1182
+ objects?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>[];
1183
+ }
1184
+ /**
1185
+ * Defined in:
1186
+ * {@link file://./../../../dxos/client/queue.proto}
1187
+ */
1188
+ export interface DeleteFromQueueRequest {
1189
+ subspaceTag: string;
1190
+ spaceId: string;
1191
+ queueId: string;
1192
+ objectIds?: string[];
1193
+ }
1194
+ /**
1195
+ * Defined in:
1196
+ * {@link file://./../../../dxos/client/queue.proto}
1197
+ */
1198
+ export interface SyncQueueRequest {
1199
+ subspaceTag: string;
1200
+ spaceId: string;
1201
+ queueId: string;
1202
+ /**
1203
+ * Whether to push local changes to the server. Defaults to true.
1204
+ *
1205
+ * Options:
1206
+ * - proto3_optional = true
1207
+ */
1208
+ shouldPush?: boolean;
1209
+ /**
1210
+ * Whether to pull remote changes from the server. Defaults to true.
1211
+ *
1212
+ * Options:
1213
+ * - proto3_optional = true
1214
+ */
1215
+ shouldPull?: boolean;
1216
+ }
1217
+ /**
1218
+ * Defined in:
1219
+ * {@link file://./../../../dxos/client/queue.proto}
1220
+ */
1221
+ export interface QueueService {
1222
+ queryQueue: (request: QueryQueueRequest, options?: RequestOptions) => Promise<QueueQueryResult>;
1223
+ insertIntoQueue: (request: InsertIntoQueueRequest, options?: RequestOptions) => Promise<void>;
1224
+ deleteFromQueue: (request: DeleteFromQueueRequest, options?: RequestOptions) => Promise<void>;
1225
+ syncQueue: (request: SyncQueueRequest, options?: RequestOptions) => Promise<void>;
1226
+ }
1227
+ /**
1228
+ * Defined in:
1229
+ * {@link file://./../../../dxos/client/logging.proto}
1230
+ */
1231
+ export interface Metrics {
1232
+ timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1233
+ values?: Metrics.KeyPair[];
1234
+ }
1235
+ export namespace Metrics {
1236
+ /**
1237
+ * Defined in:
1238
+ * {@link file://./../../../dxos/client/logging.proto}
1239
+ */
1240
+ export interface KeyPair {
1241
+ /**
1242
+ * Options:
1243
+ * - proto3_optional = true
1244
+ */
1245
+ key?: string;
1246
+ /**
1247
+ * Options:
1248
+ * - proto3_optional = true
1249
+ */
1250
+ value?: dxos_value.Value;
1251
+ /**
1252
+ * Options:
1253
+ * - proto3_optional = true
1254
+ */
1255
+ stats?: dxos_value.Stats;
1256
+ }
1257
+ }
1258
+ /**
1259
+ * Defined in:
1260
+ * {@link file://./../../../dxos/client/logging.proto}
1261
+ */
1262
+ export interface ControlMetricsRequest {
1263
+ /**
1264
+ * Options:
1265
+ * - proto3_optional = true
1266
+ */
1267
+ reset?: boolean;
1268
+ /**
1269
+ * Options:
1270
+ * - proto3_optional = true
1271
+ */
1272
+ record?: boolean;
1273
+ }
1274
+ /**
1275
+ * Defined in:
1276
+ * {@link file://./../../../dxos/client/logging.proto}
1277
+ */
1278
+ export interface ControlMetricsResponse {
1279
+ /**
1280
+ * Options:
1281
+ * - proto3_optional = true
1282
+ */
1283
+ recording?: boolean;
1284
+ }
1285
+ /**
1286
+ * Defined in:
1287
+ * {@link file://./../../../dxos/client/logging.proto}
1288
+ */
1289
+ export interface QueryMetricsRequest {
1290
+ /**
1291
+ * Options:
1292
+ * - proto3_optional = true
1293
+ */
1294
+ interval?: number;
1295
+ }
1296
+ /**
1297
+ * Defined in:
1298
+ * {@link file://./../../../dxos/client/logging.proto}
1299
+ */
1300
+ export interface QueryMetricsResponse {
1301
+ timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1302
+ metrics: Metrics;
1303
+ }
1304
+ /**
1305
+ * Defined in:
1306
+ * {@link file://./../../../dxos/client/logging.proto}
1307
+ */
1308
+ export enum LogLevel {
1309
+ NONE = 0,
1310
+ TRACE = 5,
1311
+ DEBUG = 10,
1312
+ VERBOSE = 11,
1313
+ INFO = 12,
1314
+ WARN = 13,
1315
+ ERROR = 14
1316
+ }
1317
+ /**
1318
+ * Defined in:
1319
+ * {@link file://./../../../dxos/client/logging.proto}
1320
+ */
1321
+ export interface QueryLogsRequest {
1322
+ filters?: QueryLogsRequest.Filter[];
1323
+ /**
1324
+ * Options:
1325
+ * - proto3_optional = true
1326
+ */
1327
+ options?: QueryLogsRequest.MatchingOptions;
1328
+ }
1329
+ export namespace QueryLogsRequest {
1330
+ /**
1331
+ * Defined in:
1332
+ * {@link file://./../../../dxos/client/logging.proto}
1333
+ */
1334
+ export enum MatchingOptions {
1335
+ NONE = 0,
1336
+ INCLUSIVE = 1,
1337
+ EXPLICIT = 2
1338
+ }
1339
+ /**
1340
+ * Defined in:
1341
+ * {@link file://./../../../dxos/client/logging.proto}
1342
+ */
1343
+ export interface Filter {
1344
+ level: LogLevel;
1345
+ /**
1346
+ * Options:
1347
+ * - proto3_optional = true
1348
+ */
1349
+ pattern?: string;
1350
+ }
1351
+ }
1352
+ /**
1353
+ * Defined in:
1354
+ * {@link file://./../../../dxos/client/logging.proto}
1355
+ */
1356
+ export interface LogEntry {
1357
+ level: LogLevel;
1358
+ message: string;
1359
+ /**
1360
+ * Options:
1361
+ * - proto3_optional = true
1362
+ */
1363
+ context?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
1364
+ /**
1365
+ * Options:
1366
+ * - proto3_optional = true
1367
+ */
1368
+ meta?: LogEntry.Meta;
1369
+ /**
1370
+ * Options:
1371
+ * - proto3_optional = true
1372
+ */
1373
+ error?: dxos_error.Error;
1374
+ timestamp: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1375
+ }
1376
+ export namespace LogEntry {
1377
+ /**
1378
+ * Defined in:
1379
+ * {@link file://./../../../dxos/client/logging.proto}
1380
+ */
1381
+ export interface Meta {
1382
+ file: string;
1383
+ line: number;
1384
+ /**
1385
+ * Options:
1386
+ * - proto3_optional = true
1387
+ */
1388
+ scope?: ReturnType<(typeof substitutions)["google.protobuf.Struct"]["decode"]>;
1389
+ /**
1390
+ * Options:
1391
+ * - proto3_optional = true
1392
+ */
1393
+ resourceId?: number;
1394
+ }
1395
+ }
1396
+ /**
1397
+ * Defined in:
1398
+ * {@link file://./../../../dxos/client/logging.proto}
1399
+ */
1400
+ export interface LoggingService {
1401
+ controlMetrics: (request: ControlMetricsRequest, options?: RequestOptions) => Promise<ControlMetricsResponse>;
1402
+ queryMetrics: (request: QueryMetricsRequest, options?: RequestOptions) => Stream<QueryMetricsResponse>;
1403
+ queryLogs: (request: QueryLogsRequest, options?: RequestOptions) => Stream<LogEntry>;
1404
+ }
1405
+ /**
1406
+ * Defined in:
1407
+ * {@link file://./../../../dxos/client/invitation.proto}
1408
+ */
1409
+ export interface AdmissionKeypair {
1410
+ publicKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1411
+ /**
1412
+ * Options:
1413
+ * - proto3_optional = true
1414
+ */
1415
+ privateKey?: ReturnType<(typeof substitutions)["dxos.keys.PrivateKey"]["decode"]>;
1416
+ }
1417
+ /**
1418
+ * Runtime state of the space object.
1419
+ *
1420
+ * Defined in:
1421
+ * {@link file://./../../../dxos/client/invitation.proto}
1422
+ */
1423
+ export enum SpaceState {
1424
+ INVALID = 0,
1425
+ SPACE_INACTIVE = 2,
1426
+ SPACE_ACTIVE = 6,
1427
+ SPACE_CLOSED = 1,
1428
+ SPACE_CONTROL_ONLY = 7,
1429
+ SPACE_INITIALIZING = 4,
1430
+ SPACE_READY = 3,
1431
+ SPACE_ERROR = 5,
1432
+ SPACE_REQUIRES_MIGRATION = 8
1433
+ }
1434
+ /**
1435
+ * Represents the invitation state passed between client and service.
1436
+ *
1437
+ * Defined in:
1438
+ * {@link file://./../../../dxos/client/invitation.proto}
1439
+ */
1440
+ export interface Invitation {
1441
+ /**
1442
+ * Local identifier (random).
1443
+ */
1444
+ invitationId: string;
1445
+ /**
1446
+ * Determines the behavior of the invitation.
1447
+ */
1448
+ type: Invitation.Type;
1449
+ /**
1450
+ * Kind of access the invitation will grant.
1451
+ */
1452
+ kind: Invitation.Kind;
1453
+ /**
1454
+ * How the invitation is authenticated.
1455
+ */
1456
+ authMethod: Invitation.AuthMethod;
1457
+ /**
1458
+ * Swarm rendezvous (random).
1459
+ */
1460
+ swarmKey: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1461
+ /**
1462
+ * Local state.
1463
+ */
1464
+ state: Invitation.State;
1465
+ /**
1466
+ * Timeout for guest to complete invitation once connected (ms).
1467
+ *
1468
+ * Options:
1469
+ * - proto3_optional = true
1470
+ */
1471
+ timeout?: number;
1472
+ /**
1473
+ * Guest's identity.
1474
+ *
1475
+ * Options:
1476
+ * - proto3_optional = true
1477
+ */
1478
+ identityKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1479
+ /**
1480
+ * Space to join (only present if kind is SPACE).
1481
+ *
1482
+ * Options:
1483
+ * - proto3_optional = true
1484
+ */
1485
+ spaceKey?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1486
+ /**
1487
+ * Authentication code created by host (only present if auth_method is SHARED_SECRET).
1488
+ *
1489
+ * Options:
1490
+ * - proto3_optional = true
1491
+ */
1492
+ authCode?: string;
1493
+ /**
1494
+ * Path or identifier to navigate to after successful authentication.
1495
+ *
1496
+ * Options:
1497
+ * - proto3_optional = true
1498
+ */
1499
+ target?: string;
1500
+ /**
1501
+ * Host should resume invitation on startup until timeout.
1502
+ *
1503
+ * Options:
1504
+ * - proto3_optional = true
1505
+ */
1506
+ persistent?: boolean;
1507
+ /**
1508
+ * Options:
1509
+ * - proto3_optional = true
1510
+ */
1511
+ created?: ReturnType<(typeof substitutions)["google.protobuf.Timestamp"]["decode"]>;
1512
+ /**
1513
+ * Options:
1514
+ * - proto3_optional = true
1515
+ */
1516
+ lifetime?: number;
1517
+ /**
1518
+ * Whether an invitation can be used multiple times.
1519
+ *
1520
+ * Options:
1521
+ * - proto3_optional = true
1522
+ */
1523
+ multiUse?: boolean;
1524
+ /**
1525
+ * Guest's keypair required for AuthMethod.KNOWN_PUBLIC_KEY.
1526
+ *
1527
+ * Options:
1528
+ * - proto3_optional = true
1529
+ */
1530
+ guestKeypair?: AdmissionKeypair;
1531
+ /**
1532
+ * Present on Type.DELEGATED invitations.
1533
+ *
1534
+ * Options:
1535
+ * - proto3_optional = true
1536
+ */
1537
+ delegationCredentialId?: ReturnType<(typeof substitutions)["dxos.keys.PublicKey"]["decode"]>;
1538
+ /**
1539
+ * Role of the admitted member, defaults to ADMIN.
1540
+ *
1541
+ * Options:
1542
+ * - proto3_optional = true
1543
+ */
1544
+ role?: dxos_halo_credentials.SpaceMember.Role;
1545
+ /**
1546
+ * Id of a the space to join (only present if kind is SPACE).
1547
+ *
1548
+ * Options:
1549
+ * - proto3_optional = true
1550
+ */
1551
+ spaceId?: string;
1552
+ }
1553
+ export namespace Invitation {
1554
+ /**
1555
+ * Defined in:
1556
+ * {@link file://./../../../dxos/client/invitation.proto}
1557
+ */
1558
+ export enum Type {
1559
+ INTERACTIVE = 0,
1560
+ DELEGATED = 1,
1561
+ MULTIUSE = 2
1562
+ }
1563
+ /**
1564
+ * Defined in:
1565
+ * {@link file://./../../../dxos/client/invitation.proto}
1566
+ */
1567
+ export enum Kind {
1568
+ DEVICE = 0,
1569
+ SPACE = 1
1570
+ }
1571
+ /**
1572
+ * Defined in:
1573
+ * {@link file://./../../../dxos/client/invitation.proto}
1574
+ */
1575
+ export enum AuthMethod {
1576
+ NONE = 0,
1577
+ SHARED_SECRET = 1,
1578
+ KNOWN_PUBLIC_KEY = 2
1579
+ }
1580
+ /**
1581
+ * Defined in:
1582
+ * {@link file://./../../../dxos/client/invitation.proto}
1583
+ */
1584
+ export enum State {
1585
+ INIT = 0,
1586
+ CONNECTING = 1,
1587
+ CONNECTED = 2,
1588
+ READY_FOR_AUTHENTICATION = 3,
1589
+ AUTHENTICATING = 4,
1590
+ SUCCESS = 5,
1591
+ CANCELLED = 6,
1592
+ TIMEOUT = 7,
1593
+ ERROR = 8,
1594
+ EXPIRED = 9
1595
+ }
1596
+ }