@dxos/protocols 2.28.0

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 (113) hide show
  1. package/dist/src/index.d.ts +1 -0
  2. package/dist/src/index.d.ts.map +1 -0
  3. package/dist/src/index.js +5 -0
  4. package/dist/src/index.js.map +1 -0
  5. package/dist/src/proto/gen/dxos/bot.d.ts +109 -0
  6. package/dist/src/proto/gen/dxos/bot.d.ts.map +1 -0
  7. package/dist/src/proto/gen/dxos/bot.js +14 -0
  8. package/dist/src/proto/gen/dxos/bot.js.map +1 -0
  9. package/dist/src/proto/gen/dxos/client.d.ts +179 -0
  10. package/dist/src/proto/gen/dxos/client.d.ts.map +1 -0
  11. package/dist/src/proto/gen/dxos/client.js +11 -0
  12. package/dist/src/proto/gen/dxos/client.js.map +1 -0
  13. package/dist/src/proto/gen/dxos/config.d.ts +210 -0
  14. package/dist/src/proto/gen/dxos/config.d.ts.map +1 -0
  15. package/dist/src/proto/gen/dxos/config.js +29 -0
  16. package/dist/src/proto/gen/dxos/config.js.map +1 -0
  17. package/dist/src/proto/gen/dxos/credentials/auth.d.ts +11 -0
  18. package/dist/src/proto/gen/dxos/credentials/auth.d.ts.map +1 -0
  19. package/dist/src/proto/gen/dxos/credentials/auth.js +3 -0
  20. package/dist/src/proto/gen/dxos/credentials/auth.js.map +1 -0
  21. package/dist/src/proto/gen/dxos/credentials/greet.d.ts +39 -0
  22. package/dist/src/proto/gen/dxos/credentials/greet.d.ts.map +1 -0
  23. package/dist/src/proto/gen/dxos/credentials/greet.js +15 -0
  24. package/dist/src/proto/gen/dxos/credentials/greet.js.map +1 -0
  25. package/dist/src/proto/gen/dxos/credentials/identity.d.ts +10 -0
  26. package/dist/src/proto/gen/dxos/credentials/identity.d.ts.map +1 -0
  27. package/dist/src/proto/gen/dxos/credentials/identity.js +3 -0
  28. package/dist/src/proto/gen/dxos/credentials/identity.js.map +1 -0
  29. package/dist/src/proto/gen/dxos/credentials/party.d.ts +49 -0
  30. package/dist/src/proto/gen/dxos/credentials/party.d.ts.map +1 -0
  31. package/dist/src/proto/gen/dxos/credentials/party.js +15 -0
  32. package/dist/src/proto/gen/dxos/credentials/party.js.map +1 -0
  33. package/dist/src/proto/gen/dxos/credentials.d.ts +25 -0
  34. package/dist/src/proto/gen/dxos/credentials.d.ts.map +1 -0
  35. package/dist/src/proto/gen/dxos/credentials.js +3 -0
  36. package/dist/src/proto/gen/dxos/credentials.js.map +1 -0
  37. package/dist/src/proto/gen/dxos/devtools.d.ts +196 -0
  38. package/dist/src/proto/gen/dxos/devtools.d.ts.map +1 -0
  39. package/dist/src/proto/gen/dxos/devtools.js +3 -0
  40. package/dist/src/proto/gen/dxos/devtools.js.map +1 -0
  41. package/dist/src/proto/gen/dxos/echo/feed.d.ts +69 -0
  42. package/dist/src/proto/gen/dxos/echo/feed.d.ts.map +1 -0
  43. package/dist/src/proto/gen/dxos/echo/feed.js +13 -0
  44. package/dist/src/proto/gen/dxos/echo/feed.js.map +1 -0
  45. package/dist/src/proto/gen/dxos/echo/invitation.d.ts +20 -0
  46. package/dist/src/proto/gen/dxos/echo/invitation.d.ts.map +1 -0
  47. package/dist/src/proto/gen/dxos/echo/invitation.js +12 -0
  48. package/dist/src/proto/gen/dxos/echo/invitation.js.map +1 -0
  49. package/dist/src/proto/gen/dxos/echo/metadata.d.ts +19 -0
  50. package/dist/src/proto/gen/dxos/echo/metadata.d.ts.map +1 -0
  51. package/dist/src/proto/gen/dxos/echo/metadata.js +3 -0
  52. package/dist/src/proto/gen/dxos/echo/metadata.js.map +1 -0
  53. package/dist/src/proto/gen/dxos/echo/service.d.ts +47 -0
  54. package/dist/src/proto/gen/dxos/echo/service.d.ts.map +1 -0
  55. package/dist/src/proto/gen/dxos/echo/service.js +3 -0
  56. package/dist/src/proto/gen/dxos/echo/service.js.map +1 -0
  57. package/dist/src/proto/gen/dxos/echo/snapshot.d.ts +51 -0
  58. package/dist/src/proto/gen/dxos/echo/snapshot.d.ts.map +1 -0
  59. package/dist/src/proto/gen/dxos/echo/snapshot.js +3 -0
  60. package/dist/src/proto/gen/dxos/echo/snapshot.js.map +1 -0
  61. package/dist/src/proto/gen/dxos/halo/keys.d.ts +59 -0
  62. package/dist/src/proto/gen/dxos/halo/keys.d.ts.map +1 -0
  63. package/dist/src/proto/gen/dxos/halo/keys.js +13 -0
  64. package/dist/src/proto/gen/dxos/halo/keys.js.map +1 -0
  65. package/dist/src/proto/gen/dxos/rpc.d.ts +41 -0
  66. package/dist/src/proto/gen/dxos/rpc.d.ts.map +1 -0
  67. package/dist/src/proto/gen/dxos/rpc.js +12 -0
  68. package/dist/src/proto/gen/dxos/rpc.js.map +1 -0
  69. package/dist/src/proto/gen/google/protobuf.d.ts +277 -0
  70. package/dist/src/proto/gen/google/protobuf.d.ts.map +1 -0
  71. package/dist/src/proto/gen/google/protobuf.js +58 -0
  72. package/dist/src/proto/gen/google/protobuf.js.map +1 -0
  73. package/dist/src/proto/gen/index.d.ts +249 -0
  74. package/dist/src/proto/gen/index.d.ts.map +1 -0
  75. package/dist/src/proto/gen/index.js +7 -0
  76. package/dist/src/proto/gen/index.js.map +1 -0
  77. package/dist/tsconfig.tsbuildinfo +1 -0
  78. package/package.json +35 -0
  79. package/src/index.ts +3 -0
  80. package/src/proto/dxos/bot.proto +120 -0
  81. package/src/proto/dxos/client.proto +237 -0
  82. package/src/proto/dxos/config.proto +254 -0
  83. package/src/proto/dxos/devtools.proto +271 -0
  84. package/src/proto/dxos/echo/feed.proto +93 -0
  85. package/src/proto/dxos/echo/invitation.proto +29 -0
  86. package/src/proto/dxos/echo/metadata.proto +30 -0
  87. package/src/proto/dxos/echo/service.proto +64 -0
  88. package/src/proto/dxos/echo/snapshot.proto +88 -0
  89. package/src/proto/dxos/halo/auth.proto +20 -0
  90. package/src/proto/dxos/halo/greet.proto +125 -0
  91. package/src/proto/dxos/halo/identity.proto +24 -0
  92. package/src/proto/dxos/halo/keys.proto +88 -0
  93. package/src/proto/dxos/halo/party.proto +127 -0
  94. package/src/proto/dxos/halo/signed.proto +42 -0
  95. package/src/proto/dxos/rpc.proto +59 -0
  96. package/src/proto/gen/dxos/bot.ts +120 -0
  97. package/src/proto/gen/dxos/client.ts +190 -0
  98. package/src/proto/gen/dxos/config.ts +225 -0
  99. package/src/proto/gen/dxos/credentials/auth.ts +26 -0
  100. package/src/proto/gen/dxos/credentials/greet.ts +53 -0
  101. package/src/proto/gen/dxos/credentials/identity.ts +25 -0
  102. package/src/proto/gen/dxos/credentials/party.ts +63 -0
  103. package/src/proto/gen/dxos/credentials.ts +39 -0
  104. package/src/proto/gen/dxos/devtools.ts +206 -0
  105. package/src/proto/gen/dxos/echo/feed.ts +84 -0
  106. package/src/proto/gen/dxos/echo/invitation.ts +36 -0
  107. package/src/proto/gen/dxos/echo/metadata.ts +33 -0
  108. package/src/proto/gen/dxos/echo/service.ts +59 -0
  109. package/src/proto/gen/dxos/echo/snapshot.ts +66 -0
  110. package/src/proto/gen/dxos/halo/keys.ts +74 -0
  111. package/src/proto/gen/dxos/rpc.ts +56 -0
  112. package/src/proto/gen/google/protobuf.ts +293 -0
  113. package/src/proto/gen/index.ts +248 -0
@@ -0,0 +1,190 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "./bot";
3
+ import * as dxos_config from "./config";
4
+ import * as dxos_credentials from "./credentials";
5
+ import * as dxos_credentials_auth from "./credentials/auth";
6
+ import * as dxos_credentials_greet from "./credentials/greet";
7
+ import * as dxos_credentials_identity from "./credentials/identity";
8
+ import * as dxos_credentials_party from "./credentials/party";
9
+ import * as dxos_devtools from "./devtools";
10
+ import * as dxos_echo_feed from "./echo/feed";
11
+ import * as dxos_echo_invitation from "./echo/invitation";
12
+ import * as dxos_echo_metadata from "./echo/metadata";
13
+ import * as dxos_echo_service from "./echo/service";
14
+ import * as dxos_echo_snapshot from "./echo/snapshot";
15
+ import * as dxos_halo_keys from "./halo/keys";
16
+ import * as dxos_rpc from "./rpc";
17
+ import * as google_protobuf from "../google/protobuf";
18
+ export interface SystemService {
19
+ getConfig: (request: void) => Promise<dxos_config.Config>;
20
+ reset: (request: void) => Promise<void>;
21
+ }
22
+ export enum InvitationState {
23
+ WAITING_FOR_CONNECTION = 1,
24
+ CONNECTED = 2,
25
+ SUCCESS = 3,
26
+ ERROR = 4
27
+ }
28
+ /**
29
+ * Invitation process created by sender.
30
+ */
31
+ export interface InvitationRequest {
32
+ descriptor?: dxos_echo_invitation.InvitationDescriptor;
33
+ state?: InvitationState;
34
+ /**
35
+ * Only if state == ERROR.
36
+ */
37
+ error?: string;
38
+ }
39
+ /**
40
+ * Invitation that is being redeemed.
41
+ */
42
+ export interface RedeemedInvitation {
43
+ id?: string;
44
+ state?: InvitationState;
45
+ /**
46
+ * Only if state == ERROR.
47
+ */
48
+ error?: string;
49
+ /**
50
+ * Only on party invitations that are finished.
51
+ */
52
+ partyKey?: dxos_halo_keys.PubKey;
53
+ }
54
+ export interface AuthenticateInvitationRequest {
55
+ /**
56
+ * Id from corresponding RedeemedInvitation.
57
+ */
58
+ processId?: string;
59
+ secret?: Uint8Array;
60
+ }
61
+ export interface Profile {
62
+ publicKey: dxos_halo_keys.PubKey;
63
+ username?: string;
64
+ }
65
+ export interface SubscribeProfileResponse {
66
+ profile?: Profile;
67
+ }
68
+ export interface CreateProfileRequest {
69
+ username?: string;
70
+ publicKey?: Uint8Array;
71
+ secretKey?: Uint8Array;
72
+ }
73
+ export interface RecoverProfileRequest {
74
+ seedPhrase?: string;
75
+ }
76
+ export interface Contact {
77
+ publicKey?: dxos_halo_keys.PubKey;
78
+ displayName?: string;
79
+ }
80
+ export interface Contacts {
81
+ contacts?: Contact[];
82
+ }
83
+ export interface ProfileService {
84
+ subscribeProfile: (request: void) => Stream<SubscribeProfileResponse>;
85
+ createProfile: (request: CreateProfileRequest) => Promise<Profile>;
86
+ recoverProfile: (request: RecoverProfileRequest) => Promise<Profile>;
87
+ createInvitation: (request: void) => Stream<InvitationRequest>;
88
+ acceptInvitation: (request: dxos_echo_invitation.InvitationDescriptor) => Stream<RedeemedInvitation>;
89
+ authenticateInvitation: (request: AuthenticateInvitationRequest) => Promise<void>;
90
+ }
91
+ export interface AddKeyRecordRequest {
92
+ keyRecord?: dxos_halo_keys.KeyRecord;
93
+ }
94
+ export interface SignRequest {
95
+ /**
96
+ * - The public key of the key that is supposed to be used for signing.
97
+ */
98
+ publicKey?: dxos_halo_keys.PubKey;
99
+ payload?: Uint8Array;
100
+ }
101
+ export interface SignResponse {
102
+ signed?: Uint8Array;
103
+ }
104
+ export interface SetPreferenceRequest {
105
+ key?: string;
106
+ value?: string;
107
+ }
108
+ export interface GetPreferenceRequest {
109
+ key?: string;
110
+ }
111
+ export interface GetPreferenceResponse {
112
+ value?: string;
113
+ }
114
+ export interface HaloService {
115
+ subscribeContacts: (request: void) => Stream<Contacts>;
116
+ addKeyRecord: (request: AddKeyRecordRequest) => Promise<void>;
117
+ sign: (request: SignRequest) => Promise<SignResponse>;
118
+ setGlobalPreference: (request: SetPreferenceRequest) => Promise<void>;
119
+ getGlobalPreference: (request: GetPreferenceRequest) => Promise<GetPreferenceResponse>;
120
+ setDevicePreference: (request: SetPreferenceRequest) => Promise<void>;
121
+ getDevicePreference: (request: GetPreferenceRequest) => Promise<GetPreferenceResponse>;
122
+ }
123
+ export interface Party {
124
+ publicKey: dxos_halo_keys.PubKey;
125
+ isOpen: boolean;
126
+ isActive: boolean;
127
+ members?: Party.Member[];
128
+ }
129
+ export namespace Party {
130
+ export interface Member {
131
+ publicKey: dxos_halo_keys.PubKey;
132
+ displayName?: string;
133
+ }
134
+ }
135
+ export interface SubscribePartyRequest {
136
+ partyKey: dxos_halo_keys.PubKey;
137
+ }
138
+ export interface SubscribePartyResponse {
139
+ party?: Party;
140
+ }
141
+ export interface SubscribePartiesResponse {
142
+ parties?: Party[];
143
+ }
144
+ export interface CreateInvitationRequest {
145
+ partyKey: dxos_halo_keys.PubKey;
146
+ /**
147
+ * When specified the invitation will be of OFFLINE type, not requiring secret exchange.
148
+ */
149
+ inviteeKey?: dxos_halo_keys.PubKey;
150
+ }
151
+ export interface PartyActivationOptions {
152
+ global?: boolean;
153
+ device?: boolean;
154
+ }
155
+ export interface SetPartyStateRequest {
156
+ partyKey: dxos_halo_keys.PubKey;
157
+ open?: boolean;
158
+ activeGlobal?: boolean;
159
+ activeDevice?: boolean;
160
+ }
161
+ export interface SubscribeMembersRequest {
162
+ partyKey: dxos_halo_keys.PubKey;
163
+ }
164
+ export interface SubscribeMembersResponse {
165
+ members?: SubscribeMembersResponse.PartyMember[];
166
+ }
167
+ export namespace SubscribeMembersResponse {
168
+ export interface PartyMember {
169
+ publicKey: dxos_halo_keys.PubKey;
170
+ displayName?: string;
171
+ }
172
+ }
173
+ export interface CreateSnaspotRequest {
174
+ partyKey?: dxos_halo_keys.PubKey;
175
+ }
176
+ export interface PartyService {
177
+ subscribeToParty: (request: SubscribePartyRequest) => Stream<SubscribePartyResponse>;
178
+ subscribeParties: (request: void) => Stream<SubscribePartiesResponse>;
179
+ createParty: (request: void) => Promise<Party>;
180
+ cloneParty: (request: dxos_echo_snapshot.PartySnapshot) => Promise<Party>;
181
+ /**
182
+ * Open and close or activate and deactivate a party.
183
+ */
184
+ setPartyState: (request: SetPartyStateRequest) => Promise<Party>;
185
+ createInvitation: (request: CreateInvitationRequest) => Stream<InvitationRequest>;
186
+ acceptInvitation: (request: dxos_echo_invitation.InvitationDescriptor) => Stream<RedeemedInvitation>;
187
+ authenticateInvitation: (request: AuthenticateInvitationRequest) => Promise<void>;
188
+ subscribeMembers: (request: SubscribeMembersRequest) => Stream<SubscribeMembersResponse>;
189
+ createSnapshot: (request: CreateSnaspotRequest) => Promise<dxos_echo_snapshot.PartySnapshot>;
190
+ }
@@ -0,0 +1,225 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "./bot";
3
+ import * as dxos_client from "./client";
4
+ import * as dxos_credentials from "./credentials";
5
+ import * as dxos_credentials_auth from "./credentials/auth";
6
+ import * as dxos_credentials_greet from "./credentials/greet";
7
+ import * as dxos_credentials_identity from "./credentials/identity";
8
+ import * as dxos_credentials_party from "./credentials/party";
9
+ import * as dxos_devtools from "./devtools";
10
+ import * as dxos_echo_feed from "./echo/feed";
11
+ import * as dxos_echo_invitation from "./echo/invitation";
12
+ import * as dxos_echo_metadata from "./echo/metadata";
13
+ import * as dxos_echo_service from "./echo/service";
14
+ import * as dxos_echo_snapshot from "./echo/snapshot";
15
+ import * as dxos_halo_keys from "./halo/keys";
16
+ import * as dxos_rpc from "./rpc";
17
+ import * as google_protobuf from "../google/protobuf";
18
+ export interface Config {
19
+ version?: number;
20
+ module?: Module;
21
+ build?: Build;
22
+ runtime?: Runtime;
23
+ }
24
+ export interface Module {
25
+ name?: string;
26
+ type?: string;
27
+ version?: string;
28
+ author?: string;
29
+ license?: string;
30
+ description?: string;
31
+ repository?: string;
32
+ repositoryVersion?: string;
33
+ keywords?: string[];
34
+ displayName?: string;
35
+ npmUrl?: string;
36
+ build?: Module.Build;
37
+ record?: Module.Record;
38
+ }
39
+ export namespace Module {
40
+ export interface Record {
41
+ app?: Module.Record.App;
42
+ }
43
+ export namespace Record {
44
+ export interface App {
45
+ contentType?: string[];
46
+ }
47
+ }
48
+ export interface Build {
49
+ version?: string;
50
+ commitHash?: string;
51
+ timestamp?: google_protobuf.Timestamp;
52
+ }
53
+ }
54
+ export interface Build {
55
+ command?: string;
56
+ out?: string;
57
+ }
58
+ export interface Runtime {
59
+ client?: Runtime.Client;
60
+ app?: Runtime.App;
61
+ cli?: Runtime.CLI;
62
+ props?: Runtime.Props;
63
+ services?: Runtime.Services;
64
+ system?: Runtime.System;
65
+ }
66
+ export namespace Runtime {
67
+ export interface Client {
68
+ /**
69
+ * Options:
70
+ * - (env) = "DEBUG"
71
+ */
72
+ debug?: string;
73
+ storage?: Runtime.Client.Storage;
74
+ enableSnapshots?: boolean;
75
+ /**
76
+ * Milliseconds
77
+ */
78
+ snapshotInterval?: number;
79
+ /**
80
+ * Milliseconds
81
+ */
82
+ invitationExpiration?: number;
83
+ mode?: Runtime.Client.Mode;
84
+ }
85
+ export namespace Client {
86
+ export enum Mode {
87
+ AUTOMATIC = 0,
88
+ LOCAL = 1,
89
+ REMOTE = 2
90
+ }
91
+ export interface Storage {
92
+ persistent?: boolean;
93
+ storageType?: Runtime.Client.Storage.StorageDriver;
94
+ keyStorage?: Runtime.Client.Storage.StorageDriver;
95
+ path?: string;
96
+ }
97
+ export namespace Storage {
98
+ export enum StorageDriver {
99
+ RAM = 0,
100
+ IDB = 1,
101
+ CHROME = 2,
102
+ FIREFOX = 3,
103
+ NODE = 4,
104
+ LEVELJS = 11,
105
+ JSONDOWN = 12
106
+ }
107
+ }
108
+ }
109
+ export interface App {
110
+ org?: string;
111
+ theme?: string;
112
+ website?: string;
113
+ /**
114
+ * Options:
115
+ * - (env) = "PUBLIC_URL"
116
+ */
117
+ publicUrl?: string;
118
+ }
119
+ export interface CLI {
120
+ nodePath?: string;
121
+ app?: Runtime.CLI.AppServe;
122
+ console?: Runtime.CLI.Package;
123
+ mdns?: Runtime.CLI.Package;
124
+ signal?: Runtime.CLI.Package;
125
+ npmClient?: string;
126
+ channel?: string;
127
+ }
128
+ export namespace CLI {
129
+ export interface AppServe {
130
+ serve?: Runtime.CLI.AppServe.Serve;
131
+ }
132
+ export namespace AppServe {
133
+ export interface Serve {
134
+ config?: string;
135
+ loginApp?: string;
136
+ keyPhrase?: string;
137
+ }
138
+ }
139
+ export interface Package {
140
+ package?: string;
141
+ channel?: string;
142
+ bin?: string;
143
+ config?: string;
144
+ }
145
+ }
146
+ export interface Props {
147
+ title?: string;
148
+ }
149
+ export interface System {
150
+ debug?: string;
151
+ }
152
+ export interface Services {
153
+ kube?: Runtime.Services.Kube;
154
+ app?: Runtime.Services.AppServer;
155
+ dxns?: Runtime.Services.Dxns;
156
+ ipfs?: Runtime.Services.Ipfs;
157
+ signal?: Runtime.Services.Signal;
158
+ ice?: Runtime.Services.Ice[];
159
+ machine?: Runtime.Services.Machine;
160
+ bot?: Runtime.Services.BotFactory;
161
+ }
162
+ export namespace Services {
163
+ export interface Kube {
164
+ endpoints?: Runtime.Services.Kube.Endpoints;
165
+ publicUrl?: string;
166
+ }
167
+ export namespace Kube {
168
+ export interface Endpoints {
169
+ logs?: string;
170
+ services?: string;
171
+ cert?: string;
172
+ }
173
+ }
174
+ export interface AppServer {
175
+ prefix?: string;
176
+ server?: string;
177
+ }
178
+ export interface Dxns {
179
+ /**
180
+ * DXNS endpoint.
181
+ */
182
+ server?: string;
183
+ /**
184
+ * Substrate account URI. This is a secret.
185
+ * KUBEs do not serve this with the config but we store it in profile.yml.
186
+ *
187
+ * TODO(dmaretskyi): Deprecate this and move it to keyring.
188
+ */
189
+ accountUri?: string;
190
+ /**
191
+ * Public Polkadot Address.
192
+ */
193
+ address?: string;
194
+ /**
195
+ * Public address of a DXNS Account.
196
+ */
197
+ account?: string;
198
+ faucet?: string;
199
+ }
200
+ export interface Ipfs {
201
+ server?: string;
202
+ gateway?: string;
203
+ }
204
+ export interface Signal {
205
+ server?: string;
206
+ api?: string;
207
+ status?: string;
208
+ }
209
+ export interface Ice {
210
+ urls?: string;
211
+ username?: string;
212
+ credential?: string;
213
+ }
214
+ export interface Machine {
215
+ doAccessToken?: string;
216
+ githubAccessToken?: string;
217
+ githubUsername?: string;
218
+ dnsDomain?: string;
219
+ npmAccessToken?: string;
220
+ }
221
+ export interface BotFactory {
222
+ topic?: string;
223
+ }
224
+ }
225
+ }
@@ -0,0 +1,26 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "../bot";
3
+ import * as dxos_client from "../client";
4
+ import * as dxos_config from "../config";
5
+ import * as dxos_credentials from "../credentials";
6
+ import * as dxos_credentials_greet from "./greet";
7
+ import * as dxos_credentials_identity from "./identity";
8
+ import * as dxos_credentials_party from "./party";
9
+ import * as dxos_devtools from "../devtools";
10
+ import * as dxos_echo_feed from "../echo/feed";
11
+ import * as dxos_echo_invitation from "../echo/invitation";
12
+ import * as dxos_echo_metadata from "../echo/metadata";
13
+ import * as dxos_echo_service from "../echo/service";
14
+ import * as dxos_echo_snapshot from "../echo/snapshot";
15
+ import * as dxos_halo_keys from "../halo/keys";
16
+ import * as dxos_rpc from "../rpc";
17
+ import * as google_protobuf from "../../google/protobuf";
18
+ /**
19
+ * The payload for a SignedMessage sent during handshake for replication authentication.
20
+ */
21
+ export interface Auth {
22
+ partyKey?: dxos_halo_keys.PubKey;
23
+ deviceKey?: dxos_halo_keys.PubKey;
24
+ identityKey?: dxos_halo_keys.PubKey;
25
+ feedKey?: dxos_halo_keys.PubKey;
26
+ }
@@ -0,0 +1,53 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "../bot";
3
+ import * as dxos_client from "../client";
4
+ import * as dxos_config from "../config";
5
+ import * as dxos_credentials from "../credentials";
6
+ import * as dxos_credentials_auth from "./auth";
7
+ import * as dxos_credentials_identity from "./identity";
8
+ import * as dxos_credentials_party from "./party";
9
+ import * as dxos_devtools from "../devtools";
10
+ import * as dxos_echo_feed from "../echo/feed";
11
+ import * as dxos_echo_invitation from "../echo/invitation";
12
+ import * as dxos_echo_metadata from "../echo/metadata";
13
+ import * as dxos_echo_service from "../echo/service";
14
+ import * as dxos_echo_snapshot from "../echo/snapshot";
15
+ import * as dxos_halo_keys from "../halo/keys";
16
+ import * as dxos_rpc from "../rpc";
17
+ import * as google_protobuf from "../../google/protobuf";
18
+ /**
19
+ * A Greeter command.
20
+ */
21
+ export interface Command {
22
+ command?: Command.Type;
23
+ secret?: Uint8Array;
24
+ params?: google_protobuf.Any[];
25
+ }
26
+ export namespace Command {
27
+ export enum Type {
28
+ BEGIN = 0,
29
+ HANDSHAKE = 1,
30
+ NOTARIZE = 2,
31
+ FINISH = 3,
32
+ CLAIM = 10
33
+ }
34
+ }
35
+ export interface BeginResponse {
36
+ info?: Partial<Record<string, google_protobuf.Any>>;
37
+ }
38
+ export interface HandshakeResponse {
39
+ nonce?: Uint8Array;
40
+ partyKey?: dxos_halo_keys.PubKey;
41
+ }
42
+ export interface NotarizeResponse {
43
+ copies?: google_protobuf.Any[];
44
+ hints?: KeyHint[];
45
+ }
46
+ export interface KeyHint {
47
+ publicKey?: dxos_halo_keys.PubKey;
48
+ type?: dxos_halo_keys.KeyType;
49
+ }
50
+ export interface ClaimResponse {
51
+ id?: Uint8Array;
52
+ rendezvousKey?: Uint8Array;
53
+ }
@@ -0,0 +1,25 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "../bot";
3
+ import * as dxos_client from "../client";
4
+ import * as dxos_config from "../config";
5
+ import * as dxos_credentials from "../credentials";
6
+ import * as dxos_credentials_auth from "./auth";
7
+ import * as dxos_credentials_greet from "./greet";
8
+ import * as dxos_credentials_party from "./party";
9
+ import * as dxos_devtools from "../devtools";
10
+ import * as dxos_echo_feed from "../echo/feed";
11
+ import * as dxos_echo_invitation from "../echo/invitation";
12
+ import * as dxos_echo_metadata from "../echo/metadata";
13
+ import * as dxos_echo_service from "../echo/service";
14
+ import * as dxos_echo_snapshot from "../echo/snapshot";
15
+ import * as dxos_halo_keys from "../halo/keys";
16
+ import * as dxos_rpc from "../rpc";
17
+ import * as google_protobuf from "../../google/protobuf";
18
+ export interface IdentityInfo {
19
+ publicKey?: dxos_halo_keys.PubKey;
20
+ displayName?: string;
21
+ }
22
+ export interface DeviceInfo {
23
+ publicKey?: dxos_halo_keys.PubKey;
24
+ displayName?: string;
25
+ }
@@ -0,0 +1,63 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "../bot";
3
+ import * as dxos_client from "../client";
4
+ import * as dxos_config from "../config";
5
+ import * as dxos_credentials from "../credentials";
6
+ import * as dxos_credentials_auth from "./auth";
7
+ import * as dxos_credentials_greet from "./greet";
8
+ import * as dxos_credentials_identity from "./identity";
9
+ import * as dxos_devtools from "../devtools";
10
+ import * as dxos_echo_feed from "../echo/feed";
11
+ import * as dxos_echo_invitation from "../echo/invitation";
12
+ import * as dxos_echo_metadata from "../echo/metadata";
13
+ import * as dxos_echo_service from "../echo/service";
14
+ import * as dxos_echo_snapshot from "../echo/snapshot";
15
+ import * as dxos_halo_keys from "../halo/keys";
16
+ import * as dxos_rpc from "../rpc";
17
+ import * as google_protobuf from "../../google/protobuf";
18
+ export interface PartyCredential {
19
+ type?: PartyCredential.Type;
20
+ envelope?: Envelope;
21
+ partyGenesis?: PartyGenesis;
22
+ keyAdmit?: KeyAdmit;
23
+ feedAdmit?: FeedAdmit;
24
+ feedGenesis?: FeedGenesis;
25
+ }
26
+ export namespace PartyCredential {
27
+ export enum Type {
28
+ ENVELOPE = 0,
29
+ PARTY_GENESIS = 1,
30
+ FEED_GENESIS = 2,
31
+ KEY_ADMIT = 3,
32
+ FEED_ADMIT = 4
33
+ }
34
+ }
35
+ export interface PartyGenesis {
36
+ partyKey?: dxos_halo_keys.PubKey;
37
+ feedKey?: dxos_halo_keys.PubKey;
38
+ admitKey?: dxos_halo_keys.PubKey;
39
+ admitKeyType?: dxos_halo_keys.KeyType;
40
+ }
41
+ export interface KeyAdmit {
42
+ partyKey?: dxos_halo_keys.PubKey;
43
+ admitKey?: dxos_halo_keys.PubKey;
44
+ admitKeyType?: dxos_halo_keys.KeyType;
45
+ }
46
+ export interface FeedAdmit {
47
+ partyKey?: dxos_halo_keys.PubKey;
48
+ feedKey?: dxos_halo_keys.PubKey;
49
+ }
50
+ export interface FeedGenesis {
51
+ feedKey?: dxos_halo_keys.PubKey;
52
+ ownerKey?: dxos_halo_keys.PubKey;
53
+ }
54
+ export interface Envelope {
55
+ partyKey?: dxos_halo_keys.PubKey;
56
+ message?: dxos_credentials.Message;
57
+ }
58
+ export interface PartyInvitation {
59
+ id?: Uint8Array;
60
+ partyKey?: dxos_halo_keys.PubKey;
61
+ issuerKey?: dxos_halo_keys.PubKey;
62
+ inviteeKey?: dxos_halo_keys.PubKey;
63
+ }
@@ -0,0 +1,39 @@
1
+ import type { Stream } from "@dxos/codec-protobuf";
2
+ import * as dxos_bot from "./bot";
3
+ import * as dxos_client from "./client";
4
+ import * as dxos_config from "./config";
5
+ import * as dxos_credentials_auth from "./credentials/auth";
6
+ import * as dxos_credentials_greet from "./credentials/greet";
7
+ import * as dxos_credentials_identity from "./credentials/identity";
8
+ import * as dxos_credentials_party from "./credentials/party";
9
+ import * as dxos_devtools from "./devtools";
10
+ import * as dxos_echo_feed from "./echo/feed";
11
+ import * as dxos_echo_invitation from "./echo/invitation";
12
+ import * as dxos_echo_metadata from "./echo/metadata";
13
+ import * as dxos_echo_service from "./echo/service";
14
+ import * as dxos_echo_snapshot from "./echo/snapshot";
15
+ import * as dxos_halo_keys from "./halo/keys";
16
+ import * as dxos_rpc from "./rpc";
17
+ import * as google_protobuf from "../google/protobuf";
18
+ export interface Message {
19
+ payload: google_protobuf.Any;
20
+ }
21
+ /**
22
+ * A generic container message used whenever messages are signed (e.g. PartyCredential)
23
+ */
24
+ export interface SignedMessage {
25
+ signed: SignedMessage.Signed;
26
+ signatures?: SignedMessage.Signature[];
27
+ }
28
+ export namespace SignedMessage {
29
+ export interface Signed {
30
+ created: string;
31
+ nonce: Uint8Array;
32
+ payload: google_protobuf.Any;
33
+ }
34
+ export interface Signature {
35
+ key: dxos_halo_keys.PubKey;
36
+ signature: Uint8Array;
37
+ keyChain?: dxos_halo_keys.KeyChain;
38
+ }
39
+ }