@dxos/protocols 0.8.4-main.72ec0f3 → 0.8.4-main.74a063c4e0

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