@dxos/protocols 0.8.4-main.fffef41 → 0.8.4-staging.ac66bdf99f

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