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