@dcl/protocol 1.0.0-13373633961.commit-e07ccb6 → 1.0.0-13589257140.commit-dc6f088

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.
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.SocialServiceDefinition = exports.GetFriendshipStatusResponse_Ok = exports.GetFriendshipStatusResponse = exports.GetFriendshipStatusPayload = exports.FriendConnectivityUpdate = exports.FriendshipUpdate_CancelResponse = exports.FriendshipUpdate_DeleteResponse = exports.FriendshipUpdate_RejectResponse = exports.FriendshipUpdate_AcceptResponse = exports.FriendshipUpdate_RequestResponse = exports.FriendshipUpdate = exports.UpsertFriendshipResponse_Accepted = exports.UpsertFriendshipResponse = exports.PaginatedFriendshipRequestsResponse = exports.PaginatedFriendsProfilesResponse = exports.PaginatedResponse = exports.GetMutualFriendsPayload = exports.UpsertFriendshipPayload_CancelPayload = exports.UpsertFriendshipPayload_DeletePayload = exports.UpsertFriendshipPayload_RejectPayload = exports.UpsertFriendshipPayload_AcceptPayload = exports.UpsertFriendshipPayload_RequestPayload = exports.UpsertFriendshipPayload = exports.GetFriendshipRequestsPayload = exports.GetFriendsPayload = exports.FriendshipRequests = exports.FriendshipRequestResponse = exports.Pagination = exports.FriendProfile = exports.User = exports.InternalServerError = exports.InvalidFriendshipAction = exports.FriendshipStatus = exports.ConnectivityStatus = exports.protobufPackage = void 0;
6
+ exports.SocialServiceDefinition = exports.GetFriendshipStatusResponse_Ok = exports.GetFriendshipStatusResponse = exports.GetFriendshipStatusPayload = exports.FriendshipUpdate_CancelResponse = exports.FriendshipUpdate_DeleteResponse = exports.FriendshipUpdate_RejectResponse = exports.FriendshipUpdate_AcceptResponse = exports.FriendshipUpdate = exports.UpsertFriendshipResponse_Accepted = exports.UpsertFriendshipResponse = exports.PaginatedFriendshipRequestsResponse = exports.PaginatedUsersResponse = exports.PaginatedResponse = exports.GetMutualFriendsPayload = exports.UpsertFriendshipPayload_CancelPayload = exports.UpsertFriendshipPayload_DeletePayload = exports.UpsertFriendshipPayload_RejectPayload = exports.UpsertFriendshipPayload_AcceptPayload = exports.UpsertFriendshipPayload_RequestPayload = exports.UpsertFriendshipPayload = exports.GetFriendshipRequestsPayload = exports.GetFriendsPayload = exports.FriendshipRequests = exports.FriendshipRequestResponse = exports.Pagination = exports.User = exports.InternalServerError = exports.InvalidFriendshipAction = exports.FriendshipStatus = exports.ConnectivityStatus = exports.protobufPackage = void 0;
7
7
  exports.connectivityStatusFromJSON = connectivityStatusFromJSON;
8
8
  exports.connectivityStatusToJSON = connectivityStatusToJSON;
9
9
  exports.friendshipStatusFromJSON = friendshipStatusFromJSON;
@@ -59,7 +59,6 @@ var FriendshipStatus;
59
59
  FriendshipStatus[FriendshipStatus["REJECTED"] = 4] = "REJECTED";
60
60
  FriendshipStatus[FriendshipStatus["DELETED"] = 5] = "DELETED";
61
61
  FriendshipStatus[FriendshipStatus["BLOCKED"] = 6] = "BLOCKED";
62
- FriendshipStatus[FriendshipStatus["NONE"] = 7] = "NONE";
63
62
  FriendshipStatus[FriendshipStatus["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
64
63
  })(FriendshipStatus || (exports.FriendshipStatus = FriendshipStatus = {}));
65
64
  function friendshipStatusFromJSON(object) {
@@ -85,9 +84,6 @@ function friendshipStatusFromJSON(object) {
85
84
  case 6:
86
85
  case "BLOCKED":
87
86
  return FriendshipStatus.BLOCKED;
88
- case 7:
89
- case "NONE":
90
- return FriendshipStatus.NONE;
91
87
  case -1:
92
88
  case "UNRECOGNIZED":
93
89
  default:
@@ -110,8 +106,6 @@ function friendshipStatusToJSON(object) {
110
106
  return "DELETED";
111
107
  case FriendshipStatus.BLOCKED:
112
108
  return "BLOCKED";
113
- case FriendshipStatus.NONE:
114
- return "NONE";
115
109
  case FriendshipStatus.UNRECOGNIZED:
116
110
  default:
117
111
  return "UNRECOGNIZED";
@@ -261,100 +255,6 @@ var User;
261
255
  }
262
256
  User.fromPartial = fromPartial;
263
257
  })(User || (exports.User = User = {}));
264
- function createBaseFriendProfile() {
265
- return { address: "", name: "", hasClaimedName: false, profilePictureUrl: "" };
266
- }
267
- var FriendProfile;
268
- (function (FriendProfile) {
269
- function encode(message, writer = minimal_1.default.Writer.create()) {
270
- if (message.address !== "") {
271
- writer.uint32(10).string(message.address);
272
- }
273
- if (message.name !== "") {
274
- writer.uint32(18).string(message.name);
275
- }
276
- if (message.hasClaimedName === true) {
277
- writer.uint32(24).bool(message.hasClaimedName);
278
- }
279
- if (message.profilePictureUrl !== "") {
280
- writer.uint32(34).string(message.profilePictureUrl);
281
- }
282
- return writer;
283
- }
284
- FriendProfile.encode = encode;
285
- function decode(input, length) {
286
- const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
287
- let end = length === undefined ? reader.len : reader.pos + length;
288
- const message = createBaseFriendProfile();
289
- while (reader.pos < end) {
290
- const tag = reader.uint32();
291
- switch (tag >>> 3) {
292
- case 1:
293
- if (tag !== 10) {
294
- break;
295
- }
296
- message.address = reader.string();
297
- continue;
298
- case 2:
299
- if (tag !== 18) {
300
- break;
301
- }
302
- message.name = reader.string();
303
- continue;
304
- case 3:
305
- if (tag !== 24) {
306
- break;
307
- }
308
- message.hasClaimedName = reader.bool();
309
- continue;
310
- case 4:
311
- if (tag !== 34) {
312
- break;
313
- }
314
- message.profilePictureUrl = reader.string();
315
- continue;
316
- }
317
- if ((tag & 7) === 4 || tag === 0) {
318
- break;
319
- }
320
- reader.skipType(tag & 7);
321
- }
322
- return message;
323
- }
324
- FriendProfile.decode = decode;
325
- function fromJSON(object) {
326
- return {
327
- address: isSet(object.address) ? String(object.address) : "",
328
- name: isSet(object.name) ? String(object.name) : "",
329
- hasClaimedName: isSet(object.hasClaimedName) ? Boolean(object.hasClaimedName) : false,
330
- profilePictureUrl: isSet(object.profilePictureUrl) ? String(object.profilePictureUrl) : "",
331
- };
332
- }
333
- FriendProfile.fromJSON = fromJSON;
334
- function toJSON(message) {
335
- const obj = {};
336
- message.address !== undefined && (obj.address = message.address);
337
- message.name !== undefined && (obj.name = message.name);
338
- message.hasClaimedName !== undefined && (obj.hasClaimedName = message.hasClaimedName);
339
- message.profilePictureUrl !== undefined && (obj.profilePictureUrl = message.profilePictureUrl);
340
- return obj;
341
- }
342
- FriendProfile.toJSON = toJSON;
343
- function create(base) {
344
- return FriendProfile.fromPartial(base !== null && base !== void 0 ? base : {});
345
- }
346
- FriendProfile.create = create;
347
- function fromPartial(object) {
348
- var _a, _b, _c, _d;
349
- const message = createBaseFriendProfile();
350
- message.address = (_a = object.address) !== null && _a !== void 0 ? _a : "";
351
- message.name = (_b = object.name) !== null && _b !== void 0 ? _b : "";
352
- message.hasClaimedName = (_c = object.hasClaimedName) !== null && _c !== void 0 ? _c : false;
353
- message.profilePictureUrl = (_d = object.profilePictureUrl) !== null && _d !== void 0 ? _d : "";
354
- return message;
355
- }
356
- FriendProfile.fromPartial = fromPartial;
357
- })(FriendProfile || (exports.FriendProfile = FriendProfile = {}));
358
258
  function createBasePagination() {
359
259
  return { limit: 0, offset: 0 };
360
260
  }
@@ -426,13 +326,13 @@ var Pagination;
426
326
  Pagination.fromPartial = fromPartial;
427
327
  })(Pagination || (exports.Pagination = Pagination = {}));
428
328
  function createBaseFriendshipRequestResponse() {
429
- return { friend: undefined, createdAt: 0, message: undefined, id: "" };
329
+ return { user: undefined, createdAt: 0, message: undefined };
430
330
  }
431
331
  var FriendshipRequestResponse;
432
332
  (function (FriendshipRequestResponse) {
433
333
  function encode(message, writer = minimal_1.default.Writer.create()) {
434
- if (message.friend !== undefined) {
435
- FriendProfile.encode(message.friend, writer.uint32(10).fork()).ldelim();
334
+ if (message.user !== undefined) {
335
+ User.encode(message.user, writer.uint32(10).fork()).ldelim();
436
336
  }
437
337
  if (message.createdAt !== 0) {
438
338
  writer.uint32(16).int64(message.createdAt);
@@ -440,9 +340,6 @@ var FriendshipRequestResponse;
440
340
  if (message.message !== undefined) {
441
341
  writer.uint32(26).string(message.message);
442
342
  }
443
- if (message.id !== "") {
444
- writer.uint32(34).string(message.id);
445
- }
446
343
  return writer;
447
344
  }
448
345
  FriendshipRequestResponse.encode = encode;
@@ -457,7 +354,7 @@ var FriendshipRequestResponse;
457
354
  if (tag !== 10) {
458
355
  break;
459
356
  }
460
- message.friend = FriendProfile.decode(reader, reader.uint32());
357
+ message.user = User.decode(reader, reader.uint32());
461
358
  continue;
462
359
  case 2:
463
360
  if (tag !== 16) {
@@ -471,12 +368,6 @@ var FriendshipRequestResponse;
471
368
  }
472
369
  message.message = reader.string();
473
370
  continue;
474
- case 4:
475
- if (tag !== 34) {
476
- break;
477
- }
478
- message.id = reader.string();
479
- continue;
480
371
  }
481
372
  if ((tag & 7) === 4 || tag === 0) {
482
373
  break;
@@ -488,19 +379,17 @@ var FriendshipRequestResponse;
488
379
  FriendshipRequestResponse.decode = decode;
489
380
  function fromJSON(object) {
490
381
  return {
491
- friend: isSet(object.friend) ? FriendProfile.fromJSON(object.friend) : undefined,
382
+ user: isSet(object.user) ? User.fromJSON(object.user) : undefined,
492
383
  createdAt: isSet(object.createdAt) ? Number(object.createdAt) : 0,
493
384
  message: isSet(object.message) ? String(object.message) : undefined,
494
- id: isSet(object.id) ? String(object.id) : "",
495
385
  };
496
386
  }
497
387
  FriendshipRequestResponse.fromJSON = fromJSON;
498
388
  function toJSON(message) {
499
389
  const obj = {};
500
- message.friend !== undefined && (obj.friend = message.friend ? FriendProfile.toJSON(message.friend) : undefined);
390
+ message.user !== undefined && (obj.user = message.user ? User.toJSON(message.user) : undefined);
501
391
  message.createdAt !== undefined && (obj.createdAt = Math.round(message.createdAt));
502
392
  message.message !== undefined && (obj.message = message.message);
503
- message.id !== undefined && (obj.id = message.id);
504
393
  return obj;
505
394
  }
506
395
  FriendshipRequestResponse.toJSON = toJSON;
@@ -509,14 +398,11 @@ var FriendshipRequestResponse;
509
398
  }
510
399
  FriendshipRequestResponse.create = create;
511
400
  function fromPartial(object) {
512
- var _a, _b, _c;
401
+ var _a, _b;
513
402
  const message = createBaseFriendshipRequestResponse();
514
- message.friend = (object.friend !== undefined && object.friend !== null)
515
- ? FriendProfile.fromPartial(object.friend)
516
- : undefined;
403
+ message.user = (object.user !== undefined && object.user !== null) ? User.fromPartial(object.user) : undefined;
517
404
  message.createdAt = (_a = object.createdAt) !== null && _a !== void 0 ? _a : 0;
518
405
  message.message = (_b = object.message) !== null && _b !== void 0 ? _b : undefined;
519
- message.id = (_c = object.id) !== null && _c !== void 0 ? _c : "";
520
406
  return message;
521
407
  }
522
408
  FriendshipRequestResponse.fromPartial = fromPartial;
@@ -587,7 +473,7 @@ var FriendshipRequests;
587
473
  FriendshipRequests.fromPartial = fromPartial;
588
474
  })(FriendshipRequests || (exports.FriendshipRequests = FriendshipRequests = {}));
589
475
  function createBaseGetFriendsPayload() {
590
- return { pagination: undefined };
476
+ return { pagination: undefined, status: undefined };
591
477
  }
592
478
  var GetFriendsPayload;
593
479
  (function (GetFriendsPayload) {
@@ -595,6 +481,9 @@ var GetFriendsPayload;
595
481
  if (message.pagination !== undefined) {
596
482
  Pagination.encode(message.pagination, writer.uint32(10).fork()).ldelim();
597
483
  }
484
+ if (message.status !== undefined) {
485
+ writer.uint32(16).int32(message.status);
486
+ }
598
487
  return writer;
599
488
  }
600
489
  GetFriendsPayload.encode = encode;
@@ -611,6 +500,12 @@ var GetFriendsPayload;
611
500
  }
612
501
  message.pagination = Pagination.decode(reader, reader.uint32());
613
502
  continue;
503
+ case 2:
504
+ if (tag !== 16) {
505
+ break;
506
+ }
507
+ message.status = reader.int32();
508
+ continue;
614
509
  }
615
510
  if ((tag & 7) === 4 || tag === 0) {
616
511
  break;
@@ -621,13 +516,18 @@ var GetFriendsPayload;
621
516
  }
622
517
  GetFriendsPayload.decode = decode;
623
518
  function fromJSON(object) {
624
- return { pagination: isSet(object.pagination) ? Pagination.fromJSON(object.pagination) : undefined };
519
+ return {
520
+ pagination: isSet(object.pagination) ? Pagination.fromJSON(object.pagination) : undefined,
521
+ status: isSet(object.status) ? connectivityStatusFromJSON(object.status) : undefined,
522
+ };
625
523
  }
626
524
  GetFriendsPayload.fromJSON = fromJSON;
627
525
  function toJSON(message) {
628
526
  const obj = {};
629
527
  message.pagination !== undefined &&
630
528
  (obj.pagination = message.pagination ? Pagination.toJSON(message.pagination) : undefined);
529
+ message.status !== undefined &&
530
+ (obj.status = message.status !== undefined ? connectivityStatusToJSON(message.status) : undefined);
631
531
  return obj;
632
532
  }
633
533
  GetFriendsPayload.toJSON = toJSON;
@@ -636,10 +536,12 @@ var GetFriendsPayload;
636
536
  }
637
537
  GetFriendsPayload.create = create;
638
538
  function fromPartial(object) {
539
+ var _a;
639
540
  const message = createBaseGetFriendsPayload();
640
541
  message.pagination = (object.pagination !== undefined && object.pagination !== null)
641
542
  ? Pagination.fromPartial(object.pagination)
642
543
  : undefined;
544
+ message.status = (_a = object.status) !== null && _a !== void 0 ? _a : undefined;
643
545
  return message;
644
546
  }
645
547
  GetFriendsPayload.fromPartial = fromPartial;
@@ -1305,25 +1207,25 @@ var PaginatedResponse;
1305
1207
  }
1306
1208
  PaginatedResponse.fromPartial = fromPartial;
1307
1209
  })(PaginatedResponse || (exports.PaginatedResponse = PaginatedResponse = {}));
1308
- function createBasePaginatedFriendsProfilesResponse() {
1309
- return { friends: [], paginationData: undefined };
1210
+ function createBasePaginatedUsersResponse() {
1211
+ return { users: [], paginationData: undefined };
1310
1212
  }
1311
- var PaginatedFriendsProfilesResponse;
1312
- (function (PaginatedFriendsProfilesResponse) {
1213
+ var PaginatedUsersResponse;
1214
+ (function (PaginatedUsersResponse) {
1313
1215
  function encode(message, writer = minimal_1.default.Writer.create()) {
1314
- for (const v of message.friends) {
1315
- FriendProfile.encode(v, writer.uint32(10).fork()).ldelim();
1216
+ for (const v of message.users) {
1217
+ User.encode(v, writer.uint32(10).fork()).ldelim();
1316
1218
  }
1317
1219
  if (message.paginationData !== undefined) {
1318
1220
  PaginatedResponse.encode(message.paginationData, writer.uint32(18).fork()).ldelim();
1319
1221
  }
1320
1222
  return writer;
1321
1223
  }
1322
- PaginatedFriendsProfilesResponse.encode = encode;
1224
+ PaginatedUsersResponse.encode = encode;
1323
1225
  function decode(input, length) {
1324
1226
  const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
1325
1227
  let end = length === undefined ? reader.len : reader.pos + length;
1326
- const message = createBasePaginatedFriendsProfilesResponse();
1228
+ const message = createBasePaginatedUsersResponse();
1327
1229
  while (reader.pos < end) {
1328
1230
  const tag = reader.uint32();
1329
1231
  switch (tag >>> 3) {
@@ -1331,7 +1233,7 @@ var PaginatedFriendsProfilesResponse;
1331
1233
  if (tag !== 10) {
1332
1234
  break;
1333
1235
  }
1334
- message.friends.push(FriendProfile.decode(reader, reader.uint32()));
1236
+ message.users.push(User.decode(reader, reader.uint32()));
1335
1237
  continue;
1336
1238
  case 2:
1337
1239
  if (tag !== 18) {
@@ -1347,42 +1249,42 @@ var PaginatedFriendsProfilesResponse;
1347
1249
  }
1348
1250
  return message;
1349
1251
  }
1350
- PaginatedFriendsProfilesResponse.decode = decode;
1252
+ PaginatedUsersResponse.decode = decode;
1351
1253
  function fromJSON(object) {
1352
1254
  return {
1353
- friends: Array.isArray(object === null || object === void 0 ? void 0 : object.friends) ? object.friends.map((e) => FriendProfile.fromJSON(e)) : [],
1255
+ users: Array.isArray(object === null || object === void 0 ? void 0 : object.users) ? object.users.map((e) => User.fromJSON(e)) : [],
1354
1256
  paginationData: isSet(object.paginationData) ? PaginatedResponse.fromJSON(object.paginationData) : undefined,
1355
1257
  };
1356
1258
  }
1357
- PaginatedFriendsProfilesResponse.fromJSON = fromJSON;
1259
+ PaginatedUsersResponse.fromJSON = fromJSON;
1358
1260
  function toJSON(message) {
1359
1261
  const obj = {};
1360
- if (message.friends) {
1361
- obj.friends = message.friends.map((e) => e ? FriendProfile.toJSON(e) : undefined);
1262
+ if (message.users) {
1263
+ obj.users = message.users.map((e) => e ? User.toJSON(e) : undefined);
1362
1264
  }
1363
1265
  else {
1364
- obj.friends = [];
1266
+ obj.users = [];
1365
1267
  }
1366
1268
  message.paginationData !== undefined &&
1367
1269
  (obj.paginationData = message.paginationData ? PaginatedResponse.toJSON(message.paginationData) : undefined);
1368
1270
  return obj;
1369
1271
  }
1370
- PaginatedFriendsProfilesResponse.toJSON = toJSON;
1272
+ PaginatedUsersResponse.toJSON = toJSON;
1371
1273
  function create(base) {
1372
- return PaginatedFriendsProfilesResponse.fromPartial(base !== null && base !== void 0 ? base : {});
1274
+ return PaginatedUsersResponse.fromPartial(base !== null && base !== void 0 ? base : {});
1373
1275
  }
1374
- PaginatedFriendsProfilesResponse.create = create;
1276
+ PaginatedUsersResponse.create = create;
1375
1277
  function fromPartial(object) {
1376
1278
  var _a;
1377
- const message = createBasePaginatedFriendsProfilesResponse();
1378
- message.friends = ((_a = object.friends) === null || _a === void 0 ? void 0 : _a.map((e) => FriendProfile.fromPartial(e))) || [];
1279
+ const message = createBasePaginatedUsersResponse();
1280
+ message.users = ((_a = object.users) === null || _a === void 0 ? void 0 : _a.map((e) => User.fromPartial(e))) || [];
1379
1281
  message.paginationData = (object.paginationData !== undefined && object.paginationData !== null)
1380
1282
  ? PaginatedResponse.fromPartial(object.paginationData)
1381
1283
  : undefined;
1382
1284
  return message;
1383
1285
  }
1384
- PaginatedFriendsProfilesResponse.fromPartial = fromPartial;
1385
- })(PaginatedFriendsProfilesResponse || (exports.PaginatedFriendsProfilesResponse = PaginatedFriendsProfilesResponse = {}));
1286
+ PaginatedUsersResponse.fromPartial = fromPartial;
1287
+ })(PaginatedUsersResponse || (exports.PaginatedUsersResponse = PaginatedUsersResponse = {}));
1386
1288
  function createBasePaginatedFriendshipRequestsResponse() {
1387
1289
  return { response: undefined, paginationData: undefined };
1388
1290
  }
@@ -1632,7 +1534,7 @@ var UpsertFriendshipResponse;
1632
1534
  UpsertFriendshipResponse.fromPartial = fromPartial;
1633
1535
  })(UpsertFriendshipResponse || (exports.UpsertFriendshipResponse = UpsertFriendshipResponse = {}));
1634
1536
  function createBaseUpsertFriendshipResponse_Accepted() {
1635
- return { id: "", createdAt: 0, friend: undefined, message: undefined };
1537
+ return { id: "", createdAt: 0 };
1636
1538
  }
1637
1539
  var UpsertFriendshipResponse_Accepted;
1638
1540
  (function (UpsertFriendshipResponse_Accepted) {
@@ -1643,12 +1545,6 @@ var UpsertFriendshipResponse_Accepted;
1643
1545
  if (message.createdAt !== 0) {
1644
1546
  writer.uint32(16).int64(message.createdAt);
1645
1547
  }
1646
- if (message.friend !== undefined) {
1647
- FriendProfile.encode(message.friend, writer.uint32(26).fork()).ldelim();
1648
- }
1649
- if (message.message !== undefined) {
1650
- writer.uint32(34).string(message.message);
1651
- }
1652
1548
  return writer;
1653
1549
  }
1654
1550
  UpsertFriendshipResponse_Accepted.encode = encode;
@@ -1671,18 +1567,6 @@ var UpsertFriendshipResponse_Accepted;
1671
1567
  }
1672
1568
  message.createdAt = longToNumber(reader.int64());
1673
1569
  continue;
1674
- case 3:
1675
- if (tag !== 26) {
1676
- break;
1677
- }
1678
- message.friend = FriendProfile.decode(reader, reader.uint32());
1679
- continue;
1680
- case 4:
1681
- if (tag !== 34) {
1682
- break;
1683
- }
1684
- message.message = reader.string();
1685
- continue;
1686
1570
  }
1687
1571
  if ((tag & 7) === 4 || tag === 0) {
1688
1572
  break;
@@ -1696,8 +1580,6 @@ var UpsertFriendshipResponse_Accepted;
1696
1580
  return {
1697
1581
  id: isSet(object.id) ? String(object.id) : "",
1698
1582
  createdAt: isSet(object.createdAt) ? Number(object.createdAt) : 0,
1699
- friend: isSet(object.friend) ? FriendProfile.fromJSON(object.friend) : undefined,
1700
- message: isSet(object.message) ? String(object.message) : undefined,
1701
1583
  };
1702
1584
  }
1703
1585
  UpsertFriendshipResponse_Accepted.fromJSON = fromJSON;
@@ -1705,8 +1587,6 @@ var UpsertFriendshipResponse_Accepted;
1705
1587
  const obj = {};
1706
1588
  message.id !== undefined && (obj.id = message.id);
1707
1589
  message.createdAt !== undefined && (obj.createdAt = Math.round(message.createdAt));
1708
- message.friend !== undefined && (obj.friend = message.friend ? FriendProfile.toJSON(message.friend) : undefined);
1709
- message.message !== undefined && (obj.message = message.message);
1710
1590
  return obj;
1711
1591
  }
1712
1592
  UpsertFriendshipResponse_Accepted.toJSON = toJSON;
@@ -1715,14 +1595,10 @@ var UpsertFriendshipResponse_Accepted;
1715
1595
  }
1716
1596
  UpsertFriendshipResponse_Accepted.create = create;
1717
1597
  function fromPartial(object) {
1718
- var _a, _b, _c;
1598
+ var _a, _b;
1719
1599
  const message = createBaseUpsertFriendshipResponse_Accepted();
1720
1600
  message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
1721
1601
  message.createdAt = (_b = object.createdAt) !== null && _b !== void 0 ? _b : 0;
1722
- message.friend = (object.friend !== undefined && object.friend !== null)
1723
- ? FriendProfile.fromPartial(object.friend)
1724
- : undefined;
1725
- message.message = (_c = object.message) !== null && _c !== void 0 ? _c : undefined;
1726
1602
  return message;
1727
1603
  }
1728
1604
  UpsertFriendshipResponse_Accepted.fromPartial = fromPartial;
@@ -1736,7 +1612,7 @@ var FriendshipUpdate;
1736
1612
  var _a;
1737
1613
  switch ((_a = message.update) === null || _a === void 0 ? void 0 : _a.$case) {
1738
1614
  case "request":
1739
- FriendshipUpdate_RequestResponse.encode(message.update.request, writer.uint32(10).fork()).ldelim();
1615
+ FriendshipRequestResponse.encode(message.update.request, writer.uint32(10).fork()).ldelim();
1740
1616
  break;
1741
1617
  case "accept":
1742
1618
  FriendshipUpdate_AcceptResponse.encode(message.update.accept, writer.uint32(18).fork()).ldelim();
@@ -1765,10 +1641,7 @@ var FriendshipUpdate;
1765
1641
  if (tag !== 10) {
1766
1642
  break;
1767
1643
  }
1768
- message.update = {
1769
- $case: "request",
1770
- request: FriendshipUpdate_RequestResponse.decode(reader, reader.uint32()),
1771
- };
1644
+ message.update = { $case: "request", request: FriendshipRequestResponse.decode(reader, reader.uint32()) };
1772
1645
  continue;
1773
1646
  case 2:
1774
1647
  if (tag !== 18) {
@@ -1806,7 +1679,7 @@ var FriendshipUpdate;
1806
1679
  function fromJSON(object) {
1807
1680
  return {
1808
1681
  update: isSet(object.request)
1809
- ? { $case: "request", request: FriendshipUpdate_RequestResponse.fromJSON(object.request) }
1682
+ ? { $case: "request", request: FriendshipRequestResponse.fromJSON(object.request) }
1810
1683
  : isSet(object.accept)
1811
1684
  ? { $case: "accept", accept: FriendshipUpdate_AcceptResponse.fromJSON(object.accept) }
1812
1685
  : isSet(object.reject)
@@ -1823,9 +1696,7 @@ var FriendshipUpdate;
1823
1696
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
1824
1697
  const obj = {};
1825
1698
  ((_a = message.update) === null || _a === void 0 ? void 0 : _a.$case) === "request" &&
1826
- (obj.request = ((_b = message.update) === null || _b === void 0 ? void 0 : _b.request)
1827
- ? FriendshipUpdate_RequestResponse.toJSON((_c = message.update) === null || _c === void 0 ? void 0 : _c.request)
1828
- : undefined);
1699
+ (obj.request = ((_b = message.update) === null || _b === void 0 ? void 0 : _b.request) ? FriendshipRequestResponse.toJSON((_c = message.update) === null || _c === void 0 ? void 0 : _c.request) : undefined);
1829
1700
  ((_d = message.update) === null || _d === void 0 ? void 0 : _d.$case) === "accept" &&
1830
1701
  (obj.accept = ((_e = message.update) === null || _e === void 0 ? void 0 : _e.accept)
1831
1702
  ? FriendshipUpdate_AcceptResponse.toJSON((_f = message.update) === null || _f === void 0 ? void 0 : _f.accept)
@@ -1853,10 +1724,7 @@ var FriendshipUpdate;
1853
1724
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
1854
1725
  const message = createBaseFriendshipUpdate();
1855
1726
  if (((_a = object.update) === null || _a === void 0 ? void 0 : _a.$case) === "request" && ((_b = object.update) === null || _b === void 0 ? void 0 : _b.request) !== undefined && ((_c = object.update) === null || _c === void 0 ? void 0 : _c.request) !== null) {
1856
- message.update = {
1857
- $case: "request",
1858
- request: FriendshipUpdate_RequestResponse.fromPartial(object.update.request),
1859
- };
1727
+ message.update = { $case: "request", request: FriendshipRequestResponse.fromPartial(object.update.request) };
1860
1728
  }
1861
1729
  if (((_d = object.update) === null || _d === void 0 ? void 0 : _d.$case) === "accept" && ((_e = object.update) === null || _e === void 0 ? void 0 : _e.accept) !== undefined && ((_f = object.update) === null || _f === void 0 ? void 0 : _f.accept) !== null) {
1862
1730
  message.update = { $case: "accept", accept: FriendshipUpdate_AcceptResponse.fromPartial(object.update.accept) };
@@ -1874,102 +1742,6 @@ var FriendshipUpdate;
1874
1742
  }
1875
1743
  FriendshipUpdate.fromPartial = fromPartial;
1876
1744
  })(FriendshipUpdate || (exports.FriendshipUpdate = FriendshipUpdate = {}));
1877
- function createBaseFriendshipUpdate_RequestResponse() {
1878
- return { friend: undefined, createdAt: 0, message: undefined, id: "" };
1879
- }
1880
- var FriendshipUpdate_RequestResponse;
1881
- (function (FriendshipUpdate_RequestResponse) {
1882
- function encode(message, writer = minimal_1.default.Writer.create()) {
1883
- if (message.friend !== undefined) {
1884
- FriendProfile.encode(message.friend, writer.uint32(10).fork()).ldelim();
1885
- }
1886
- if (message.createdAt !== 0) {
1887
- writer.uint32(16).int64(message.createdAt);
1888
- }
1889
- if (message.message !== undefined) {
1890
- writer.uint32(26).string(message.message);
1891
- }
1892
- if (message.id !== "") {
1893
- writer.uint32(34).string(message.id);
1894
- }
1895
- return writer;
1896
- }
1897
- FriendshipUpdate_RequestResponse.encode = encode;
1898
- function decode(input, length) {
1899
- const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
1900
- let end = length === undefined ? reader.len : reader.pos + length;
1901
- const message = createBaseFriendshipUpdate_RequestResponse();
1902
- while (reader.pos < end) {
1903
- const tag = reader.uint32();
1904
- switch (tag >>> 3) {
1905
- case 1:
1906
- if (tag !== 10) {
1907
- break;
1908
- }
1909
- message.friend = FriendProfile.decode(reader, reader.uint32());
1910
- continue;
1911
- case 2:
1912
- if (tag !== 16) {
1913
- break;
1914
- }
1915
- message.createdAt = longToNumber(reader.int64());
1916
- continue;
1917
- case 3:
1918
- if (tag !== 26) {
1919
- break;
1920
- }
1921
- message.message = reader.string();
1922
- continue;
1923
- case 4:
1924
- if (tag !== 34) {
1925
- break;
1926
- }
1927
- message.id = reader.string();
1928
- continue;
1929
- }
1930
- if ((tag & 7) === 4 || tag === 0) {
1931
- break;
1932
- }
1933
- reader.skipType(tag & 7);
1934
- }
1935
- return message;
1936
- }
1937
- FriendshipUpdate_RequestResponse.decode = decode;
1938
- function fromJSON(object) {
1939
- return {
1940
- friend: isSet(object.friend) ? FriendProfile.fromJSON(object.friend) : undefined,
1941
- createdAt: isSet(object.createdAt) ? Number(object.createdAt) : 0,
1942
- message: isSet(object.message) ? String(object.message) : undefined,
1943
- id: isSet(object.id) ? String(object.id) : "",
1944
- };
1945
- }
1946
- FriendshipUpdate_RequestResponse.fromJSON = fromJSON;
1947
- function toJSON(message) {
1948
- const obj = {};
1949
- message.friend !== undefined && (obj.friend = message.friend ? FriendProfile.toJSON(message.friend) : undefined);
1950
- message.createdAt !== undefined && (obj.createdAt = Math.round(message.createdAt));
1951
- message.message !== undefined && (obj.message = message.message);
1952
- message.id !== undefined && (obj.id = message.id);
1953
- return obj;
1954
- }
1955
- FriendshipUpdate_RequestResponse.toJSON = toJSON;
1956
- function create(base) {
1957
- return FriendshipUpdate_RequestResponse.fromPartial(base !== null && base !== void 0 ? base : {});
1958
- }
1959
- FriendshipUpdate_RequestResponse.create = create;
1960
- function fromPartial(object) {
1961
- var _a, _b, _c;
1962
- const message = createBaseFriendshipUpdate_RequestResponse();
1963
- message.friend = (object.friend !== undefined && object.friend !== null)
1964
- ? FriendProfile.fromPartial(object.friend)
1965
- : undefined;
1966
- message.createdAt = (_a = object.createdAt) !== null && _a !== void 0 ? _a : 0;
1967
- message.message = (_b = object.message) !== null && _b !== void 0 ? _b : undefined;
1968
- message.id = (_c = object.id) !== null && _c !== void 0 ? _c : "";
1969
- return message;
1970
- }
1971
- FriendshipUpdate_RequestResponse.fromPartial = fromPartial;
1972
- })(FriendshipUpdate_RequestResponse || (exports.FriendshipUpdate_RequestResponse = FriendshipUpdate_RequestResponse = {}));
1973
1745
  function createBaseFriendshipUpdate_AcceptResponse() {
1974
1746
  return { user: undefined };
1975
1747
  }
@@ -2190,78 +1962,6 @@ var FriendshipUpdate_CancelResponse;
2190
1962
  }
2191
1963
  FriendshipUpdate_CancelResponse.fromPartial = fromPartial;
2192
1964
  })(FriendshipUpdate_CancelResponse || (exports.FriendshipUpdate_CancelResponse = FriendshipUpdate_CancelResponse = {}));
2193
- function createBaseFriendConnectivityUpdate() {
2194
- return { friend: undefined, status: 0 };
2195
- }
2196
- var FriendConnectivityUpdate;
2197
- (function (FriendConnectivityUpdate) {
2198
- function encode(message, writer = minimal_1.default.Writer.create()) {
2199
- if (message.friend !== undefined) {
2200
- FriendProfile.encode(message.friend, writer.uint32(10).fork()).ldelim();
2201
- }
2202
- if (message.status !== 0) {
2203
- writer.uint32(16).int32(message.status);
2204
- }
2205
- return writer;
2206
- }
2207
- FriendConnectivityUpdate.encode = encode;
2208
- function decode(input, length) {
2209
- const reader = input instanceof minimal_1.default.Reader ? input : minimal_1.default.Reader.create(input);
2210
- let end = length === undefined ? reader.len : reader.pos + length;
2211
- const message = createBaseFriendConnectivityUpdate();
2212
- while (reader.pos < end) {
2213
- const tag = reader.uint32();
2214
- switch (tag >>> 3) {
2215
- case 1:
2216
- if (tag !== 10) {
2217
- break;
2218
- }
2219
- message.friend = FriendProfile.decode(reader, reader.uint32());
2220
- continue;
2221
- case 2:
2222
- if (tag !== 16) {
2223
- break;
2224
- }
2225
- message.status = reader.int32();
2226
- continue;
2227
- }
2228
- if ((tag & 7) === 4 || tag === 0) {
2229
- break;
2230
- }
2231
- reader.skipType(tag & 7);
2232
- }
2233
- return message;
2234
- }
2235
- FriendConnectivityUpdate.decode = decode;
2236
- function fromJSON(object) {
2237
- return {
2238
- friend: isSet(object.friend) ? FriendProfile.fromJSON(object.friend) : undefined,
2239
- status: isSet(object.status) ? connectivityStatusFromJSON(object.status) : 0,
2240
- };
2241
- }
2242
- FriendConnectivityUpdate.fromJSON = fromJSON;
2243
- function toJSON(message) {
2244
- const obj = {};
2245
- message.friend !== undefined && (obj.friend = message.friend ? FriendProfile.toJSON(message.friend) : undefined);
2246
- message.status !== undefined && (obj.status = connectivityStatusToJSON(message.status));
2247
- return obj;
2248
- }
2249
- FriendConnectivityUpdate.toJSON = toJSON;
2250
- function create(base) {
2251
- return FriendConnectivityUpdate.fromPartial(base !== null && base !== void 0 ? base : {});
2252
- }
2253
- FriendConnectivityUpdate.create = create;
2254
- function fromPartial(object) {
2255
- var _a;
2256
- const message = createBaseFriendConnectivityUpdate();
2257
- message.friend = (object.friend !== undefined && object.friend !== null)
2258
- ? FriendProfile.fromPartial(object.friend)
2259
- : undefined;
2260
- message.status = (_a = object.status) !== null && _a !== void 0 ? _a : 0;
2261
- return message;
2262
- }
2263
- FriendConnectivityUpdate.fromPartial = fromPartial;
2264
- })(FriendConnectivityUpdate || (exports.FriendConnectivityUpdate = FriendConnectivityUpdate = {}));
2265
1965
  function createBaseGetFriendshipStatusPayload() {
2266
1966
  return { user: undefined };
2267
1967
  }
@@ -2502,7 +2202,7 @@ exports.SocialServiceDefinition = {
2502
2202
  name: "GetFriends",
2503
2203
  requestType: GetFriendsPayload,
2504
2204
  requestStream: false,
2505
- responseType: PaginatedFriendsProfilesResponse,
2205
+ responseType: PaginatedUsersResponse,
2506
2206
  responseStream: false,
2507
2207
  options: {},
2508
2208
  },
@@ -2511,7 +2211,7 @@ exports.SocialServiceDefinition = {
2511
2211
  name: "GetMutualFriends",
2512
2212
  requestType: GetMutualFriendsPayload,
2513
2213
  requestStream: false,
2514
- responseType: PaginatedFriendsProfilesResponse,
2214
+ responseType: PaginatedUsersResponse,
2515
2215
  responseStream: false,
2516
2216
  options: {},
2517
2217
  },
@@ -2551,7 +2251,6 @@ exports.SocialServiceDefinition = {
2551
2251
  responseStream: true,
2552
2252
  options: {},
2553
2253
  },
2554
- /** Get the friendship status between the authenticated user and the one in the parameter */
2555
2254
  getFriendshipStatus: {
2556
2255
  name: "GetFriendshipStatus",
2557
2256
  requestType: GetFriendshipStatusPayload,
@@ -2560,15 +2259,6 @@ exports.SocialServiceDefinition = {
2560
2259
  responseStream: false,
2561
2260
  options: {},
2562
2261
  },
2563
- /** Subscribe to connectivity updates of friends: ONLINE, OFFLINE, AWAY */
2564
- subscribeToFriendConnectivityUpdates: {
2565
- name: "SubscribeToFriendConnectivityUpdates",
2566
- requestType: empty_gen_1.Empty,
2567
- requestStream: false,
2568
- responseType: FriendConnectivityUpdate,
2569
- responseStream: true,
2570
- options: {},
2571
- },
2572
2262
  },
2573
2263
  };
2574
2264
  const tsProtoGlobalThis = (() => {