@dcl/protocol 1.0.0-6160718705.commit-03626d7 → 1.0.0-6313239013.commit-438d6b3
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.
- package/README.md +1 -11
- package/out-js/decentraland/kernel/apis/engine_api.gen.d.ts +29 -0
- package/out-js/decentraland/kernel/apis/engine_api.gen.js +109 -1
- package/out-js/decentraland/kernel/apis/engine_api.gen.js.map +1 -1
- package/out-ts/decentraland/kernel/apis/engine_api.gen.ts +115 -0
- package/package.json +2 -2
- package/proto/decentraland/kernel/apis/engine_api.proto +7 -0
- package/out-js/bff-services.gen.d.ts +0 -1
- package/out-js/bff-services.gen.js +0 -6
- package/out-js/bff-services.gen.js.map +0 -1
- package/out-js/decentraland/bff/authentication_service.gen.d.ts +0 -115
- package/out-js/decentraland/bff/authentication_service.gen.js +0 -386
- package/out-js/decentraland/bff/authentication_service.gen.js.map +0 -1
- package/out-js/decentraland/bff/comms_director_service.gen.d.ts +0 -89
- package/out-js/decentraland/bff/comms_director_service.gen.js +0 -250
- package/out-js/decentraland/bff/comms_director_service.gen.js.map +0 -1
- package/out-js/decentraland/bff/comms_service.gen.d.ts +0 -106
- package/out-js/decentraland/bff/comms_service.gen.js +0 -189
- package/out-js/decentraland/bff/comms_service.gen.js.map +0 -1
- package/out-js/decentraland/bff/http_endpoints.gen.d.ts +0 -168
- package/out-js/decentraland/bff/http_endpoints.gen.js +0 -949
- package/out-js/decentraland/bff/http_endpoints.gen.js.map +0 -1
- package/out-js/decentraland/bff/topics_service.gen.d.ts +0 -110
- package/out-js/decentraland/bff/topics_service.gen.js +0 -421
- package/out-js/decentraland/bff/topics_service.gen.js.map +0 -1
- package/out-js/google/protobuf/empty.gen.d.ts +0 -38
- package/out-js/google/protobuf/empty.gen.js +0 -54
- package/out-js/google/protobuf/empty.gen.js.map +0 -1
- package/out-ts/bff-services.gen.ts +0 -3
- package/out-ts/decentraland/bff/authentication_service.gen.ts +0 -421
- package/out-ts/decentraland/bff/comms_director_service.gen.ts +0 -273
- package/out-ts/decentraland/bff/comms_service.gen.ts +0 -212
- package/out-ts/decentraland/bff/http_endpoints.gen.ts +0 -1100
- package/out-ts/decentraland/bff/topics_service.gen.ts +0 -478
- package/out-ts/google/protobuf/empty.gen.ts +0 -72
- package/proto/decentraland/bff/authentication_service.proto +0 -39
- package/proto/decentraland/bff/comms_director_service.proto +0 -33
- package/proto/decentraland/bff/comms_service.proto +0 -25
- package/proto/decentraland/bff/http_endpoints.proto +0 -81
- package/proto/decentraland/bff/topics_service.proto +0 -34
- package/public/bff-services.proto +0 -16
|
@@ -1,478 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import _m0 from "protobufjs/minimal";
|
|
3
|
-
|
|
4
|
-
export const protobufPackage = "decentraland.bff";
|
|
5
|
-
|
|
6
|
-
export interface SubscriptionRequest {
|
|
7
|
-
topic: string;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export interface PeerTopicSubscriptionResultElem {
|
|
11
|
-
payload: Uint8Array;
|
|
12
|
-
topic: string;
|
|
13
|
-
sender: string;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export interface SystemTopicSubscriptionResultElem {
|
|
17
|
-
payload: Uint8Array;
|
|
18
|
-
topic: string;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export interface PublishToTopicRequest {
|
|
22
|
-
topic: string;
|
|
23
|
-
payload: Uint8Array;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export interface PublishToTopicResult {
|
|
27
|
-
ok: boolean;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
function createBaseSubscriptionRequest(): SubscriptionRequest {
|
|
31
|
-
return { topic: "" };
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
export namespace SubscriptionRequest {
|
|
35
|
-
export function encode(message: SubscriptionRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
36
|
-
if (message.topic !== "") {
|
|
37
|
-
writer.uint32(10).string(message.topic);
|
|
38
|
-
}
|
|
39
|
-
return writer;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): SubscriptionRequest {
|
|
43
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
44
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
45
|
-
const message = createBaseSubscriptionRequest();
|
|
46
|
-
while (reader.pos < end) {
|
|
47
|
-
const tag = reader.uint32();
|
|
48
|
-
switch (tag >>> 3) {
|
|
49
|
-
case 1:
|
|
50
|
-
if (tag !== 10) {
|
|
51
|
-
break;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
message.topic = reader.string();
|
|
55
|
-
continue;
|
|
56
|
-
}
|
|
57
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
58
|
-
break;
|
|
59
|
-
}
|
|
60
|
-
reader.skipType(tag & 7);
|
|
61
|
-
}
|
|
62
|
-
return message;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
export function fromJSON(object: any): SubscriptionRequest {
|
|
66
|
-
return { topic: isSet(object.topic) ? String(object.topic) : "" };
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
export function toJSON(message: SubscriptionRequest): unknown {
|
|
70
|
-
const obj: any = {};
|
|
71
|
-
message.topic !== undefined && (obj.topic = message.topic);
|
|
72
|
-
return obj;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
export function create<I extends Exact<DeepPartial<SubscriptionRequest>, I>>(base?: I): SubscriptionRequest {
|
|
76
|
-
return SubscriptionRequest.fromPartial(base ?? {});
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
export function fromPartial<I extends Exact<DeepPartial<SubscriptionRequest>, I>>(object: I): SubscriptionRequest {
|
|
80
|
-
const message = createBaseSubscriptionRequest();
|
|
81
|
-
message.topic = object.topic ?? "";
|
|
82
|
-
return message;
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
function createBasePeerTopicSubscriptionResultElem(): PeerTopicSubscriptionResultElem {
|
|
87
|
-
return { payload: new Uint8Array(0), topic: "", sender: "" };
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
export namespace PeerTopicSubscriptionResultElem {
|
|
91
|
-
export function encode(
|
|
92
|
-
message: PeerTopicSubscriptionResultElem,
|
|
93
|
-
writer: _m0.Writer = _m0.Writer.create(),
|
|
94
|
-
): _m0.Writer {
|
|
95
|
-
if (message.payload.length !== 0) {
|
|
96
|
-
writer.uint32(10).bytes(message.payload);
|
|
97
|
-
}
|
|
98
|
-
if (message.topic !== "") {
|
|
99
|
-
writer.uint32(18).string(message.topic);
|
|
100
|
-
}
|
|
101
|
-
if (message.sender !== "") {
|
|
102
|
-
writer.uint32(26).string(message.sender);
|
|
103
|
-
}
|
|
104
|
-
return writer;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): PeerTopicSubscriptionResultElem {
|
|
108
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
109
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
110
|
-
const message = createBasePeerTopicSubscriptionResultElem();
|
|
111
|
-
while (reader.pos < end) {
|
|
112
|
-
const tag = reader.uint32();
|
|
113
|
-
switch (tag >>> 3) {
|
|
114
|
-
case 1:
|
|
115
|
-
if (tag !== 10) {
|
|
116
|
-
break;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
message.payload = reader.bytes();
|
|
120
|
-
continue;
|
|
121
|
-
case 2:
|
|
122
|
-
if (tag !== 18) {
|
|
123
|
-
break;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
message.topic = reader.string();
|
|
127
|
-
continue;
|
|
128
|
-
case 3:
|
|
129
|
-
if (tag !== 26) {
|
|
130
|
-
break;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
message.sender = reader.string();
|
|
134
|
-
continue;
|
|
135
|
-
}
|
|
136
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
137
|
-
break;
|
|
138
|
-
}
|
|
139
|
-
reader.skipType(tag & 7);
|
|
140
|
-
}
|
|
141
|
-
return message;
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
export function fromJSON(object: any): PeerTopicSubscriptionResultElem {
|
|
145
|
-
return {
|
|
146
|
-
payload: isSet(object.payload) ? bytesFromBase64(object.payload) : new Uint8Array(0),
|
|
147
|
-
topic: isSet(object.topic) ? String(object.topic) : "",
|
|
148
|
-
sender: isSet(object.sender) ? String(object.sender) : "",
|
|
149
|
-
};
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
export function toJSON(message: PeerTopicSubscriptionResultElem): unknown {
|
|
153
|
-
const obj: any = {};
|
|
154
|
-
message.payload !== undefined &&
|
|
155
|
-
(obj.payload = base64FromBytes(message.payload !== undefined ? message.payload : new Uint8Array(0)));
|
|
156
|
-
message.topic !== undefined && (obj.topic = message.topic);
|
|
157
|
-
message.sender !== undefined && (obj.sender = message.sender);
|
|
158
|
-
return obj;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export function create<I extends Exact<DeepPartial<PeerTopicSubscriptionResultElem>, I>>(
|
|
162
|
-
base?: I,
|
|
163
|
-
): PeerTopicSubscriptionResultElem {
|
|
164
|
-
return PeerTopicSubscriptionResultElem.fromPartial(base ?? {});
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
export function fromPartial<I extends Exact<DeepPartial<PeerTopicSubscriptionResultElem>, I>>(
|
|
168
|
-
object: I,
|
|
169
|
-
): PeerTopicSubscriptionResultElem {
|
|
170
|
-
const message = createBasePeerTopicSubscriptionResultElem();
|
|
171
|
-
message.payload = object.payload ?? new Uint8Array(0);
|
|
172
|
-
message.topic = object.topic ?? "";
|
|
173
|
-
message.sender = object.sender ?? "";
|
|
174
|
-
return message;
|
|
175
|
-
}
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
function createBaseSystemTopicSubscriptionResultElem(): SystemTopicSubscriptionResultElem {
|
|
179
|
-
return { payload: new Uint8Array(0), topic: "" };
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
export namespace SystemTopicSubscriptionResultElem {
|
|
183
|
-
export function encode(
|
|
184
|
-
message: SystemTopicSubscriptionResultElem,
|
|
185
|
-
writer: _m0.Writer = _m0.Writer.create(),
|
|
186
|
-
): _m0.Writer {
|
|
187
|
-
if (message.payload.length !== 0) {
|
|
188
|
-
writer.uint32(10).bytes(message.payload);
|
|
189
|
-
}
|
|
190
|
-
if (message.topic !== "") {
|
|
191
|
-
writer.uint32(18).string(message.topic);
|
|
192
|
-
}
|
|
193
|
-
return writer;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): SystemTopicSubscriptionResultElem {
|
|
197
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
198
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
199
|
-
const message = createBaseSystemTopicSubscriptionResultElem();
|
|
200
|
-
while (reader.pos < end) {
|
|
201
|
-
const tag = reader.uint32();
|
|
202
|
-
switch (tag >>> 3) {
|
|
203
|
-
case 1:
|
|
204
|
-
if (tag !== 10) {
|
|
205
|
-
break;
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
message.payload = reader.bytes();
|
|
209
|
-
continue;
|
|
210
|
-
case 2:
|
|
211
|
-
if (tag !== 18) {
|
|
212
|
-
break;
|
|
213
|
-
}
|
|
214
|
-
|
|
215
|
-
message.topic = reader.string();
|
|
216
|
-
continue;
|
|
217
|
-
}
|
|
218
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
219
|
-
break;
|
|
220
|
-
}
|
|
221
|
-
reader.skipType(tag & 7);
|
|
222
|
-
}
|
|
223
|
-
return message;
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
export function fromJSON(object: any): SystemTopicSubscriptionResultElem {
|
|
227
|
-
return {
|
|
228
|
-
payload: isSet(object.payload) ? bytesFromBase64(object.payload) : new Uint8Array(0),
|
|
229
|
-
topic: isSet(object.topic) ? String(object.topic) : "",
|
|
230
|
-
};
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
export function toJSON(message: SystemTopicSubscriptionResultElem): unknown {
|
|
234
|
-
const obj: any = {};
|
|
235
|
-
message.payload !== undefined &&
|
|
236
|
-
(obj.payload = base64FromBytes(message.payload !== undefined ? message.payload : new Uint8Array(0)));
|
|
237
|
-
message.topic !== undefined && (obj.topic = message.topic);
|
|
238
|
-
return obj;
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
export function create<I extends Exact<DeepPartial<SystemTopicSubscriptionResultElem>, I>>(
|
|
242
|
-
base?: I,
|
|
243
|
-
): SystemTopicSubscriptionResultElem {
|
|
244
|
-
return SystemTopicSubscriptionResultElem.fromPartial(base ?? {});
|
|
245
|
-
}
|
|
246
|
-
|
|
247
|
-
export function fromPartial<I extends Exact<DeepPartial<SystemTopicSubscriptionResultElem>, I>>(
|
|
248
|
-
object: I,
|
|
249
|
-
): SystemTopicSubscriptionResultElem {
|
|
250
|
-
const message = createBaseSystemTopicSubscriptionResultElem();
|
|
251
|
-
message.payload = object.payload ?? new Uint8Array(0);
|
|
252
|
-
message.topic = object.topic ?? "";
|
|
253
|
-
return message;
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
function createBasePublishToTopicRequest(): PublishToTopicRequest {
|
|
258
|
-
return { topic: "", payload: new Uint8Array(0) };
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
export namespace PublishToTopicRequest {
|
|
262
|
-
export function encode(message: PublishToTopicRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
263
|
-
if (message.topic !== "") {
|
|
264
|
-
writer.uint32(10).string(message.topic);
|
|
265
|
-
}
|
|
266
|
-
if (message.payload.length !== 0) {
|
|
267
|
-
writer.uint32(18).bytes(message.payload);
|
|
268
|
-
}
|
|
269
|
-
return writer;
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): PublishToTopicRequest {
|
|
273
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
274
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
275
|
-
const message = createBasePublishToTopicRequest();
|
|
276
|
-
while (reader.pos < end) {
|
|
277
|
-
const tag = reader.uint32();
|
|
278
|
-
switch (tag >>> 3) {
|
|
279
|
-
case 1:
|
|
280
|
-
if (tag !== 10) {
|
|
281
|
-
break;
|
|
282
|
-
}
|
|
283
|
-
|
|
284
|
-
message.topic = reader.string();
|
|
285
|
-
continue;
|
|
286
|
-
case 2:
|
|
287
|
-
if (tag !== 18) {
|
|
288
|
-
break;
|
|
289
|
-
}
|
|
290
|
-
|
|
291
|
-
message.payload = reader.bytes();
|
|
292
|
-
continue;
|
|
293
|
-
}
|
|
294
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
295
|
-
break;
|
|
296
|
-
}
|
|
297
|
-
reader.skipType(tag & 7);
|
|
298
|
-
}
|
|
299
|
-
return message;
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
export function fromJSON(object: any): PublishToTopicRequest {
|
|
303
|
-
return {
|
|
304
|
-
topic: isSet(object.topic) ? String(object.topic) : "",
|
|
305
|
-
payload: isSet(object.payload) ? bytesFromBase64(object.payload) : new Uint8Array(0),
|
|
306
|
-
};
|
|
307
|
-
}
|
|
308
|
-
|
|
309
|
-
export function toJSON(message: PublishToTopicRequest): unknown {
|
|
310
|
-
const obj: any = {};
|
|
311
|
-
message.topic !== undefined && (obj.topic = message.topic);
|
|
312
|
-
message.payload !== undefined &&
|
|
313
|
-
(obj.payload = base64FromBytes(message.payload !== undefined ? message.payload : new Uint8Array(0)));
|
|
314
|
-
return obj;
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
export function create<I extends Exact<DeepPartial<PublishToTopicRequest>, I>>(base?: I): PublishToTopicRequest {
|
|
318
|
-
return PublishToTopicRequest.fromPartial(base ?? {});
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
export function fromPartial<I extends Exact<DeepPartial<PublishToTopicRequest>, I>>(
|
|
322
|
-
object: I,
|
|
323
|
-
): PublishToTopicRequest {
|
|
324
|
-
const message = createBasePublishToTopicRequest();
|
|
325
|
-
message.topic = object.topic ?? "";
|
|
326
|
-
message.payload = object.payload ?? new Uint8Array(0);
|
|
327
|
-
return message;
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
|
|
331
|
-
function createBasePublishToTopicResult(): PublishToTopicResult {
|
|
332
|
-
return { ok: false };
|
|
333
|
-
}
|
|
334
|
-
|
|
335
|
-
export namespace PublishToTopicResult {
|
|
336
|
-
export function encode(message: PublishToTopicResult, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
337
|
-
if (message.ok === true) {
|
|
338
|
-
writer.uint32(8).bool(message.ok);
|
|
339
|
-
}
|
|
340
|
-
return writer;
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): PublishToTopicResult {
|
|
344
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
345
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
346
|
-
const message = createBasePublishToTopicResult();
|
|
347
|
-
while (reader.pos < end) {
|
|
348
|
-
const tag = reader.uint32();
|
|
349
|
-
switch (tag >>> 3) {
|
|
350
|
-
case 1:
|
|
351
|
-
if (tag !== 8) {
|
|
352
|
-
break;
|
|
353
|
-
}
|
|
354
|
-
|
|
355
|
-
message.ok = reader.bool();
|
|
356
|
-
continue;
|
|
357
|
-
}
|
|
358
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
359
|
-
break;
|
|
360
|
-
}
|
|
361
|
-
reader.skipType(tag & 7);
|
|
362
|
-
}
|
|
363
|
-
return message;
|
|
364
|
-
}
|
|
365
|
-
|
|
366
|
-
export function fromJSON(object: any): PublishToTopicResult {
|
|
367
|
-
return { ok: isSet(object.ok) ? Boolean(object.ok) : false };
|
|
368
|
-
}
|
|
369
|
-
|
|
370
|
-
export function toJSON(message: PublishToTopicResult): unknown {
|
|
371
|
-
const obj: any = {};
|
|
372
|
-
message.ok !== undefined && (obj.ok = message.ok);
|
|
373
|
-
return obj;
|
|
374
|
-
}
|
|
375
|
-
|
|
376
|
-
export function create<I extends Exact<DeepPartial<PublishToTopicResult>, I>>(base?: I): PublishToTopicResult {
|
|
377
|
-
return PublishToTopicResult.fromPartial(base ?? {});
|
|
378
|
-
}
|
|
379
|
-
|
|
380
|
-
export function fromPartial<I extends Exact<DeepPartial<PublishToTopicResult>, I>>(object: I): PublishToTopicResult {
|
|
381
|
-
const message = createBasePublishToTopicResult();
|
|
382
|
-
message.ok = object.ok ?? false;
|
|
383
|
-
return message;
|
|
384
|
-
}
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
export type TopicsServiceDefinition = typeof TopicsServiceDefinition;
|
|
388
|
-
export const TopicsServiceDefinition = {
|
|
389
|
-
name: "TopicsService",
|
|
390
|
-
fullName: "decentraland.bff.TopicsService",
|
|
391
|
-
methods: {
|
|
392
|
-
peerSubscription: {
|
|
393
|
-
name: "PeerSubscription",
|
|
394
|
-
requestType: SubscriptionRequest,
|
|
395
|
-
requestStream: false,
|
|
396
|
-
responseType: PeerTopicSubscriptionResultElem,
|
|
397
|
-
responseStream: true,
|
|
398
|
-
options: {},
|
|
399
|
-
},
|
|
400
|
-
systemSubscription: {
|
|
401
|
-
name: "SystemSubscription",
|
|
402
|
-
requestType: SubscriptionRequest,
|
|
403
|
-
requestStream: false,
|
|
404
|
-
responseType: SystemTopicSubscriptionResultElem,
|
|
405
|
-
responseStream: true,
|
|
406
|
-
options: {},
|
|
407
|
-
},
|
|
408
|
-
/** send a peer message to a topic */
|
|
409
|
-
publishToTopic: {
|
|
410
|
-
name: "PublishToTopic",
|
|
411
|
-
requestType: PublishToTopicRequest,
|
|
412
|
-
requestStream: false,
|
|
413
|
-
responseType: PublishToTopicResult,
|
|
414
|
-
responseStream: false,
|
|
415
|
-
options: {},
|
|
416
|
-
},
|
|
417
|
-
},
|
|
418
|
-
} as const;
|
|
419
|
-
|
|
420
|
-
declare const self: any | undefined;
|
|
421
|
-
declare const window: any | undefined;
|
|
422
|
-
declare const global: any | undefined;
|
|
423
|
-
const tsProtoGlobalThis: any = (() => {
|
|
424
|
-
if (typeof globalThis !== "undefined") {
|
|
425
|
-
return globalThis;
|
|
426
|
-
}
|
|
427
|
-
if (typeof self !== "undefined") {
|
|
428
|
-
return self;
|
|
429
|
-
}
|
|
430
|
-
if (typeof window !== "undefined") {
|
|
431
|
-
return window;
|
|
432
|
-
}
|
|
433
|
-
if (typeof global !== "undefined") {
|
|
434
|
-
return global;
|
|
435
|
-
}
|
|
436
|
-
throw "Unable to locate global object";
|
|
437
|
-
})();
|
|
438
|
-
|
|
439
|
-
function bytesFromBase64(b64: string): Uint8Array {
|
|
440
|
-
if (tsProtoGlobalThis.Buffer) {
|
|
441
|
-
return Uint8Array.from(tsProtoGlobalThis.Buffer.from(b64, "base64"));
|
|
442
|
-
} else {
|
|
443
|
-
const bin = tsProtoGlobalThis.atob(b64);
|
|
444
|
-
const arr = new Uint8Array(bin.length);
|
|
445
|
-
for (let i = 0; i < bin.length; ++i) {
|
|
446
|
-
arr[i] = bin.charCodeAt(i);
|
|
447
|
-
}
|
|
448
|
-
return arr;
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
|
-
|
|
452
|
-
function base64FromBytes(arr: Uint8Array): string {
|
|
453
|
-
if (tsProtoGlobalThis.Buffer) {
|
|
454
|
-
return tsProtoGlobalThis.Buffer.from(arr).toString("base64");
|
|
455
|
-
} else {
|
|
456
|
-
const bin: string[] = [];
|
|
457
|
-
arr.forEach((byte) => {
|
|
458
|
-
bin.push(String.fromCharCode(byte));
|
|
459
|
-
});
|
|
460
|
-
return tsProtoGlobalThis.btoa(bin.join(""));
|
|
461
|
-
}
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
465
|
-
|
|
466
|
-
export type DeepPartial<T> = T extends Builtin ? T
|
|
467
|
-
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
468
|
-
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
469
|
-
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
470
|
-
: Partial<T>;
|
|
471
|
-
|
|
472
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
473
|
-
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
474
|
-
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
475
|
-
|
|
476
|
-
function isSet(value: any): boolean {
|
|
477
|
-
return value !== null && value !== undefined;
|
|
478
|
-
}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import _m0 from "protobufjs/minimal";
|
|
3
|
-
|
|
4
|
-
export const protobufPackage = "google.protobuf";
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* A generic empty message that you can re-use to avoid defining duplicated
|
|
8
|
-
* empty messages in your APIs. A typical example is to use it as the request
|
|
9
|
-
* or the response type of an API method. For instance:
|
|
10
|
-
*
|
|
11
|
-
* service Foo {
|
|
12
|
-
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
|
|
13
|
-
* }
|
|
14
|
-
*/
|
|
15
|
-
export interface Empty {
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
function createBaseEmpty(): Empty {
|
|
19
|
-
return {};
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export namespace Empty {
|
|
23
|
-
export function encode(_: Empty, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
24
|
-
return writer;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): Empty {
|
|
28
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
29
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
30
|
-
const message = createBaseEmpty();
|
|
31
|
-
while (reader.pos < end) {
|
|
32
|
-
const tag = reader.uint32();
|
|
33
|
-
switch (tag >>> 3) {
|
|
34
|
-
}
|
|
35
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
36
|
-
break;
|
|
37
|
-
}
|
|
38
|
-
reader.skipType(tag & 7);
|
|
39
|
-
}
|
|
40
|
-
return message;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export function fromJSON(_: any): Empty {
|
|
44
|
-
return {};
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
export function toJSON(_: Empty): unknown {
|
|
48
|
-
const obj: any = {};
|
|
49
|
-
return obj;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
export function create<I extends Exact<DeepPartial<Empty>, I>>(base?: I): Empty {
|
|
53
|
-
return Empty.fromPartial(base ?? {});
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
export function fromPartial<I extends Exact<DeepPartial<Empty>, I>>(_: I): Empty {
|
|
57
|
-
const message = createBaseEmpty();
|
|
58
|
-
return message;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
63
|
-
|
|
64
|
-
export type DeepPartial<T> = T extends Builtin ? T
|
|
65
|
-
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
66
|
-
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
67
|
-
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
68
|
-
: Partial<T>;
|
|
69
|
-
|
|
70
|
-
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
71
|
-
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
72
|
-
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
syntax = "proto3";
|
|
2
|
-
|
|
3
|
-
import "google/protobuf/empty.proto";
|
|
4
|
-
|
|
5
|
-
package decentraland.bff;
|
|
6
|
-
|
|
7
|
-
enum DisconnectionReason {
|
|
8
|
-
DR_KICKED = 0;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
message GetChallengeRequest {
|
|
12
|
-
string address = 1;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
message GetChallengeResponse {
|
|
16
|
-
string challenge_to_sign = 1;
|
|
17
|
-
bool already_connected = 2;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
message SignedChallenge {
|
|
21
|
-
string auth_chain_json = 1;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
message WelcomePeerInformation {
|
|
25
|
-
string peer_id = 1;
|
|
26
|
-
|
|
27
|
-
// list of available modules in this BFF
|
|
28
|
-
repeated string available_modules = 2;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
message DisconnectionMessage {
|
|
32
|
-
DisconnectionReason reason = 1;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
service BffAuthenticationService {
|
|
36
|
-
rpc GetChallenge(GetChallengeRequest) returns (GetChallengeResponse) {}
|
|
37
|
-
rpc Authenticate(SignedChallenge) returns (WelcomePeerInformation) {}
|
|
38
|
-
rpc GetDisconnectionMessage(google.protobuf.Empty) returns (DisconnectionMessage) {}
|
|
39
|
-
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
syntax = "proto3";
|
|
2
|
-
|
|
3
|
-
// CommsDirector are formalized at https://rfc.decentraland.org/adr/ADR-81
|
|
4
|
-
|
|
5
|
-
import "google/protobuf/empty.proto";
|
|
6
|
-
import "decentraland/common/vectors.proto";
|
|
7
|
-
|
|
8
|
-
package decentraland.bff;
|
|
9
|
-
|
|
10
|
-
message WorldCommand {
|
|
11
|
-
oneof command {
|
|
12
|
-
SetCommsAdapter set_comms_adapter = 1;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
message SetCommsAdapter {
|
|
17
|
-
string connection_string = 1;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
message Heartbeat {
|
|
21
|
-
decentraland.common.Position position = 1;
|
|
22
|
-
optional string desired_room = 2;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
service CommsDirectorService {
|
|
26
|
-
// every couple seconds AND at the beginning, the explorers must send a heartbeat
|
|
27
|
-
// to make the comms director aware of their location
|
|
28
|
-
rpc SendHeartbeat(Heartbeat) returns (google.protobuf.Empty) {}
|
|
29
|
-
|
|
30
|
-
// before sending the first heartbeat, it is required that the explorers subscribe
|
|
31
|
-
// to a list of comms commands
|
|
32
|
-
rpc GetCommsCommands(google.protobuf.Empty) returns (stream WorldCommand) {}
|
|
33
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
syntax = "proto3";
|
|
2
|
-
package decentraland.bff;
|
|
3
|
-
|
|
4
|
-
import "decentraland/bff/topics_service.proto";
|
|
5
|
-
|
|
6
|
-
message Subscription {
|
|
7
|
-
uint32 subscription_id = 1;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
message UnsubscriptionResult {
|
|
11
|
-
bool ok = 1;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
service CommsService {
|
|
15
|
-
rpc SubscribeToPeerMessages(SubscriptionRequest) returns (Subscription) {}
|
|
16
|
-
rpc GetPeerMessages(Subscription) returns (stream PeerTopicSubscriptionResultElem) {}
|
|
17
|
-
rpc UnsubscribeToPeerMessages(Subscription) returns (UnsubscriptionResult) {}
|
|
18
|
-
|
|
19
|
-
rpc SubscribeToSystemMessages(SubscriptionRequest) returns (Subscription) {}
|
|
20
|
-
rpc GetSystemMessages(Subscription) returns (stream SystemTopicSubscriptionResultElem) {}
|
|
21
|
-
rpc UnsubscribeToSystemMessages(Subscription) returns (UnsubscriptionResult) {}
|
|
22
|
-
|
|
23
|
-
// send a peer message to a topic
|
|
24
|
-
rpc PublishToTopic(PublishToTopicRequest) returns (PublishToTopicResult) {}
|
|
25
|
-
}
|