naijarea-ts 1.0.2 → 1.0.6

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/dist/account.js CHANGED
@@ -5,19 +5,55 @@
5
5
  // protoc v6.33.2
6
6
  // source: account.proto
7
7
  Object.defineProperty(exports, "__esModule", { value: true });
8
- exports.AccountServiceDefinition = exports.Representative = exports.OnboardingProgress = exports.AccountStatus = exports.Account = exports.ApplyForRepresentativeResponse = exports.ApplyForRepresentativeRequest = exports.OnboardResponse = exports.OnboardRequest = exports.UploadPhotoResponse = exports.UploadPhotoRequest = exports.UpdatePasswordRequest = exports.UpdateProfileResponse = exports.UpdateProfileRequest = exports.GetProfileResponse = exports.GetProfileRequest = exports.protobufPackage = void 0;
8
+ exports.AccountServiceDefinition = exports.GetStatusResponse = exports.GetStatusRequest = exports.GetAccountRepostsResponse = exports.GetAccountRepostsRequest = exports.GetAccountLikesResponse = exports.GetAccountLikesRequest = exports.GetAccountMediaResponse = exports.GetAccountMediaRequest = exports.GetAccountRepliesResponse = exports.GetAccountRepliesRequest = exports.GetAccountPostsResponse = exports.GetAccountPostsRequest = exports.GetFollowingResponse = exports.GetFollowingRequest = exports.GetFollowersResponse = exports.GetFollowersRequest = exports.UnfollowUserResponse = exports.UnfollowUserRequest = exports.FollowUserResponse = exports.FollowUserRequest = exports.Representative = exports.OnboardingProgress = exports.AccountStatus = exports.Profile = exports.Account = exports.ProfileStats = exports.ApplyForRepresentativeResponse = exports.ApplyForRepresentativeRequest = exports.OnboardResponse = exports.OnboardRequest = exports.UploadPhotoResponse = exports.UploadPhotoRequest = exports.UpdatePasswordRequest = exports.UpdateProfileResponse = exports.UpdateProfileRequest = exports.GetProfileResponse = exports.GetProfileRequest = exports.protobufPackage = void 0;
9
9
  /* eslint-disable */
10
10
  const wire_1 = require("@bufbuild/protobuf/wire");
11
11
  const common_1 = require("./common");
12
+ const lookup_1 = require("./lookup");
13
+ const posts_1 = require("./posts");
12
14
  exports.protobufPackage = "pb";
13
15
  function createBaseGetProfileRequest() {
14
- return { accountId: "" };
16
+ return {
17
+ accountId: "",
18
+ postsPage: 0,
19
+ postsPageSize: 0,
20
+ repliesPage: 0,
21
+ repliesPageSize: 0,
22
+ mediaPage: 0,
23
+ mediaPageSize: 0,
24
+ likesPage: 0,
25
+ likesPageSize: 0,
26
+ };
15
27
  }
16
28
  exports.GetProfileRequest = {
17
29
  encode(message, writer = new wire_1.BinaryWriter()) {
18
30
  if (message.accountId !== "") {
19
31
  writer.uint32(10).string(message.accountId);
20
32
  }
33
+ if (message.postsPage !== 0) {
34
+ writer.uint32(16).int32(message.postsPage);
35
+ }
36
+ if (message.postsPageSize !== 0) {
37
+ writer.uint32(24).int32(message.postsPageSize);
38
+ }
39
+ if (message.repliesPage !== 0) {
40
+ writer.uint32(32).int32(message.repliesPage);
41
+ }
42
+ if (message.repliesPageSize !== 0) {
43
+ writer.uint32(40).int32(message.repliesPageSize);
44
+ }
45
+ if (message.mediaPage !== 0) {
46
+ writer.uint32(48).int32(message.mediaPage);
47
+ }
48
+ if (message.mediaPageSize !== 0) {
49
+ writer.uint32(56).int32(message.mediaPageSize);
50
+ }
51
+ if (message.likesPage !== 0) {
52
+ writer.uint32(64).int32(message.likesPage);
53
+ }
54
+ if (message.likesPageSize !== 0) {
55
+ writer.uint32(72).int32(message.likesPageSize);
56
+ }
21
57
  return writer;
22
58
  },
23
59
  decode(input, length) {
@@ -34,6 +70,62 @@ exports.GetProfileRequest = {
34
70
  message.accountId = reader.string();
35
71
  continue;
36
72
  }
73
+ case 2: {
74
+ if (tag !== 16) {
75
+ break;
76
+ }
77
+ message.postsPage = reader.int32();
78
+ continue;
79
+ }
80
+ case 3: {
81
+ if (tag !== 24) {
82
+ break;
83
+ }
84
+ message.postsPageSize = reader.int32();
85
+ continue;
86
+ }
87
+ case 4: {
88
+ if (tag !== 32) {
89
+ break;
90
+ }
91
+ message.repliesPage = reader.int32();
92
+ continue;
93
+ }
94
+ case 5: {
95
+ if (tag !== 40) {
96
+ break;
97
+ }
98
+ message.repliesPageSize = reader.int32();
99
+ continue;
100
+ }
101
+ case 6: {
102
+ if (tag !== 48) {
103
+ break;
104
+ }
105
+ message.mediaPage = reader.int32();
106
+ continue;
107
+ }
108
+ case 7: {
109
+ if (tag !== 56) {
110
+ break;
111
+ }
112
+ message.mediaPageSize = reader.int32();
113
+ continue;
114
+ }
115
+ case 8: {
116
+ if (tag !== 64) {
117
+ break;
118
+ }
119
+ message.likesPage = reader.int32();
120
+ continue;
121
+ }
122
+ case 9: {
123
+ if (tag !== 72) {
124
+ break;
125
+ }
126
+ message.likesPageSize = reader.int32();
127
+ continue;
128
+ }
37
129
  }
38
130
  if ((tag & 7) === 4 || tag === 0) {
39
131
  break;
@@ -43,32 +135,74 @@ exports.GetProfileRequest = {
43
135
  return message;
44
136
  },
45
137
  fromJSON(object) {
46
- return { accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "" };
138
+ return {
139
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
140
+ postsPage: isSet(object.postsPage) ? globalThis.Number(object.postsPage) : 0,
141
+ postsPageSize: isSet(object.postsPageSize) ? globalThis.Number(object.postsPageSize) : 0,
142
+ repliesPage: isSet(object.repliesPage) ? globalThis.Number(object.repliesPage) : 0,
143
+ repliesPageSize: isSet(object.repliesPageSize) ? globalThis.Number(object.repliesPageSize) : 0,
144
+ mediaPage: isSet(object.mediaPage) ? globalThis.Number(object.mediaPage) : 0,
145
+ mediaPageSize: isSet(object.mediaPageSize) ? globalThis.Number(object.mediaPageSize) : 0,
146
+ likesPage: isSet(object.likesPage) ? globalThis.Number(object.likesPage) : 0,
147
+ likesPageSize: isSet(object.likesPageSize) ? globalThis.Number(object.likesPageSize) : 0,
148
+ };
47
149
  },
48
150
  toJSON(message) {
49
151
  const obj = {};
50
152
  if (message.accountId !== "") {
51
153
  obj.accountId = message.accountId;
52
154
  }
155
+ if (message.postsPage !== 0) {
156
+ obj.postsPage = Math.round(message.postsPage);
157
+ }
158
+ if (message.postsPageSize !== 0) {
159
+ obj.postsPageSize = Math.round(message.postsPageSize);
160
+ }
161
+ if (message.repliesPage !== 0) {
162
+ obj.repliesPage = Math.round(message.repliesPage);
163
+ }
164
+ if (message.repliesPageSize !== 0) {
165
+ obj.repliesPageSize = Math.round(message.repliesPageSize);
166
+ }
167
+ if (message.mediaPage !== 0) {
168
+ obj.mediaPage = Math.round(message.mediaPage);
169
+ }
170
+ if (message.mediaPageSize !== 0) {
171
+ obj.mediaPageSize = Math.round(message.mediaPageSize);
172
+ }
173
+ if (message.likesPage !== 0) {
174
+ obj.likesPage = Math.round(message.likesPage);
175
+ }
176
+ if (message.likesPageSize !== 0) {
177
+ obj.likesPageSize = Math.round(message.likesPageSize);
178
+ }
53
179
  return obj;
54
180
  },
55
181
  create(base) {
56
182
  return exports.GetProfileRequest.fromPartial(base !== null && base !== void 0 ? base : {});
57
183
  },
58
184
  fromPartial(object) {
59
- var _a;
185
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
60
186
  const message = createBaseGetProfileRequest();
61
187
  message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
188
+ message.postsPage = (_b = object.postsPage) !== null && _b !== void 0 ? _b : 0;
189
+ message.postsPageSize = (_c = object.postsPageSize) !== null && _c !== void 0 ? _c : 0;
190
+ message.repliesPage = (_d = object.repliesPage) !== null && _d !== void 0 ? _d : 0;
191
+ message.repliesPageSize = (_e = object.repliesPageSize) !== null && _e !== void 0 ? _e : 0;
192
+ message.mediaPage = (_f = object.mediaPage) !== null && _f !== void 0 ? _f : 0;
193
+ message.mediaPageSize = (_g = object.mediaPageSize) !== null && _g !== void 0 ? _g : 0;
194
+ message.likesPage = (_h = object.likesPage) !== null && _h !== void 0 ? _h : 0;
195
+ message.likesPageSize = (_j = object.likesPageSize) !== null && _j !== void 0 ? _j : 0;
62
196
  return message;
63
197
  },
64
198
  };
65
199
  function createBaseGetProfileResponse() {
66
- return { account: undefined };
200
+ return { profile: undefined };
67
201
  }
68
202
  exports.GetProfileResponse = {
69
203
  encode(message, writer = new wire_1.BinaryWriter()) {
70
- if (message.account !== undefined) {
71
- exports.Account.encode(message.account, writer.uint32(10).fork()).join();
204
+ if (message.profile !== undefined) {
205
+ exports.Profile.encode(message.profile, writer.uint32(10).fork()).join();
72
206
  }
73
207
  return writer;
74
208
  },
@@ -83,7 +217,7 @@ exports.GetProfileResponse = {
83
217
  if (tag !== 10) {
84
218
  break;
85
219
  }
86
- message.account = exports.Account.decode(reader, reader.uint32());
220
+ message.profile = exports.Profile.decode(reader, reader.uint32());
87
221
  continue;
88
222
  }
89
223
  }
@@ -95,12 +229,12 @@ exports.GetProfileResponse = {
95
229
  return message;
96
230
  },
97
231
  fromJSON(object) {
98
- return { account: isSet(object.account) ? exports.Account.fromJSON(object.account) : undefined };
232
+ return { profile: isSet(object.profile) ? exports.Profile.fromJSON(object.profile) : undefined };
99
233
  },
100
234
  toJSON(message) {
101
235
  const obj = {};
102
- if (message.account !== undefined) {
103
- obj.account = exports.Account.toJSON(message.account);
236
+ if (message.profile !== undefined) {
237
+ obj.profile = exports.Profile.toJSON(message.profile);
104
238
  }
105
239
  return obj;
106
240
  },
@@ -109,8 +243,8 @@ exports.GetProfileResponse = {
109
243
  },
110
244
  fromPartial(object) {
111
245
  const message = createBaseGetProfileResponse();
112
- message.account = (object.account !== undefined && object.account !== null)
113
- ? exports.Account.fromPartial(object.account)
246
+ message.profile = (object.profile !== undefined && object.profile !== null)
247
+ ? exports.Profile.fromPartial(object.profile)
114
248
  : undefined;
115
249
  return message;
116
250
  },
@@ -124,6 +258,8 @@ function createBaseUpdateProfileRequest() {
124
258
  location: "",
125
259
  stateId: "",
126
260
  localGovernmentId: "",
261
+ constituencyId: "",
262
+ districtId: "",
127
263
  pollingUnit: "",
128
264
  };
129
265
  }
@@ -150,8 +286,14 @@ exports.UpdateProfileRequest = {
150
286
  if (message.localGovernmentId !== "") {
151
287
  writer.uint32(58).string(message.localGovernmentId);
152
288
  }
289
+ if (message.constituencyId !== "") {
290
+ writer.uint32(66).string(message.constituencyId);
291
+ }
292
+ if (message.districtId !== "") {
293
+ writer.uint32(74).string(message.districtId);
294
+ }
153
295
  if (message.pollingUnit !== "") {
154
- writer.uint32(66).string(message.pollingUnit);
296
+ writer.uint32(82).string(message.pollingUnit);
155
297
  }
156
298
  return writer;
157
299
  },
@@ -215,6 +357,20 @@ exports.UpdateProfileRequest = {
215
357
  if (tag !== 66) {
216
358
  break;
217
359
  }
360
+ message.constituencyId = reader.string();
361
+ continue;
362
+ }
363
+ case 9: {
364
+ if (tag !== 74) {
365
+ break;
366
+ }
367
+ message.districtId = reader.string();
368
+ continue;
369
+ }
370
+ case 10: {
371
+ if (tag !== 82) {
372
+ break;
373
+ }
218
374
  message.pollingUnit = reader.string();
219
375
  continue;
220
376
  }
@@ -235,6 +391,8 @@ exports.UpdateProfileRequest = {
235
391
  location: isSet(object.location) ? globalThis.String(object.location) : "",
236
392
  stateId: isSet(object.stateId) ? globalThis.String(object.stateId) : "",
237
393
  localGovernmentId: isSet(object.localGovernmentId) ? globalThis.String(object.localGovernmentId) : "",
394
+ constituencyId: isSet(object.constituencyId) ? globalThis.String(object.constituencyId) : "",
395
+ districtId: isSet(object.districtId) ? globalThis.String(object.districtId) : "",
238
396
  pollingUnit: isSet(object.pollingUnit) ? globalThis.String(object.pollingUnit) : "",
239
397
  };
240
398
  },
@@ -261,6 +419,12 @@ exports.UpdateProfileRequest = {
261
419
  if (message.localGovernmentId !== "") {
262
420
  obj.localGovernmentId = message.localGovernmentId;
263
421
  }
422
+ if (message.constituencyId !== "") {
423
+ obj.constituencyId = message.constituencyId;
424
+ }
425
+ if (message.districtId !== "") {
426
+ obj.districtId = message.districtId;
427
+ }
264
428
  if (message.pollingUnit !== "") {
265
429
  obj.pollingUnit = message.pollingUnit;
266
430
  }
@@ -270,7 +434,7 @@ exports.UpdateProfileRequest = {
270
434
  return exports.UpdateProfileRequest.fromPartial(base !== null && base !== void 0 ? base : {});
271
435
  },
272
436
  fromPartial(object) {
273
- var _a, _b, _c, _d, _e, _f, _g, _h;
437
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
274
438
  const message = createBaseUpdateProfileRequest();
275
439
  message.name = (_a = object.name) !== null && _a !== void 0 ? _a : "";
276
440
  message.phoneNumber = (_b = object.phoneNumber) !== null && _b !== void 0 ? _b : "";
@@ -279,7 +443,9 @@ exports.UpdateProfileRequest = {
279
443
  message.location = (_e = object.location) !== null && _e !== void 0 ? _e : "";
280
444
  message.stateId = (_f = object.stateId) !== null && _f !== void 0 ? _f : "";
281
445
  message.localGovernmentId = (_g = object.localGovernmentId) !== null && _g !== void 0 ? _g : "";
282
- message.pollingUnit = (_h = object.pollingUnit) !== null && _h !== void 0 ? _h : "";
446
+ message.constituencyId = (_h = object.constituencyId) !== null && _h !== void 0 ? _h : "";
447
+ message.districtId = (_j = object.districtId) !== null && _j !== void 0 ? _j : "";
448
+ message.pollingUnit = (_k = object.pollingUnit) !== null && _k !== void 0 ? _k : "";
283
449
  return message;
284
450
  },
285
451
  };
@@ -565,6 +731,8 @@ function createBaseOnboardRequest() {
565
731
  location: "",
566
732
  stateId: "",
567
733
  localGovernmentId: "",
734
+ constituencyId: "",
735
+ districtId: "",
568
736
  pollingUnit: "",
569
737
  kycData: new Uint8Array(0),
570
738
  };
@@ -592,11 +760,17 @@ exports.OnboardRequest = {
592
760
  if (message.localGovernmentId !== "") {
593
761
  writer.uint32(58).string(message.localGovernmentId);
594
762
  }
763
+ if (message.constituencyId !== "") {
764
+ writer.uint32(66).string(message.constituencyId);
765
+ }
766
+ if (message.districtId !== "") {
767
+ writer.uint32(74).string(message.districtId);
768
+ }
595
769
  if (message.pollingUnit !== "") {
596
- writer.uint32(66).string(message.pollingUnit);
770
+ writer.uint32(82).string(message.pollingUnit);
597
771
  }
598
772
  if (message.kycData.length !== 0) {
599
- writer.uint32(74).bytes(message.kycData);
773
+ writer.uint32(90).bytes(message.kycData);
600
774
  }
601
775
  return writer;
602
776
  },
@@ -660,13 +834,27 @@ exports.OnboardRequest = {
660
834
  if (tag !== 66) {
661
835
  break;
662
836
  }
663
- message.pollingUnit = reader.string();
837
+ message.constituencyId = reader.string();
664
838
  continue;
665
839
  }
666
840
  case 9: {
667
841
  if (tag !== 74) {
668
842
  break;
669
843
  }
844
+ message.districtId = reader.string();
845
+ continue;
846
+ }
847
+ case 10: {
848
+ if (tag !== 82) {
849
+ break;
850
+ }
851
+ message.pollingUnit = reader.string();
852
+ continue;
853
+ }
854
+ case 11: {
855
+ if (tag !== 90) {
856
+ break;
857
+ }
670
858
  message.kycData = reader.bytes();
671
859
  continue;
672
860
  }
@@ -687,6 +875,8 @@ exports.OnboardRequest = {
687
875
  location: isSet(object.location) ? globalThis.String(object.location) : "",
688
876
  stateId: isSet(object.stateId) ? globalThis.String(object.stateId) : "",
689
877
  localGovernmentId: isSet(object.localGovernmentId) ? globalThis.String(object.localGovernmentId) : "",
878
+ constituencyId: isSet(object.constituencyId) ? globalThis.String(object.constituencyId) : "",
879
+ districtId: isSet(object.districtId) ? globalThis.String(object.districtId) : "",
690
880
  pollingUnit: isSet(object.pollingUnit) ? globalThis.String(object.pollingUnit) : "",
691
881
  kycData: isSet(object.kycData) ? bytesFromBase64(object.kycData) : new Uint8Array(0),
692
882
  };
@@ -714,6 +904,12 @@ exports.OnboardRequest = {
714
904
  if (message.localGovernmentId !== "") {
715
905
  obj.localGovernmentId = message.localGovernmentId;
716
906
  }
907
+ if (message.constituencyId !== "") {
908
+ obj.constituencyId = message.constituencyId;
909
+ }
910
+ if (message.districtId !== "") {
911
+ obj.districtId = message.districtId;
912
+ }
717
913
  if (message.pollingUnit !== "") {
718
914
  obj.pollingUnit = message.pollingUnit;
719
915
  }
@@ -726,7 +922,7 @@ exports.OnboardRequest = {
726
922
  return exports.OnboardRequest.fromPartial(base !== null && base !== void 0 ? base : {});
727
923
  },
728
924
  fromPartial(object) {
729
- var _a, _b, _c, _d, _e, _f, _g, _h, _j;
925
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
730
926
  const message = createBaseOnboardRequest();
731
927
  message.name = (_a = object.name) !== null && _a !== void 0 ? _a : "";
732
928
  message.phoneNumber = (_b = object.phoneNumber) !== null && _b !== void 0 ? _b : "";
@@ -735,8 +931,10 @@ exports.OnboardRequest = {
735
931
  message.location = (_e = object.location) !== null && _e !== void 0 ? _e : "";
736
932
  message.stateId = (_f = object.stateId) !== null && _f !== void 0 ? _f : "";
737
933
  message.localGovernmentId = (_g = object.localGovernmentId) !== null && _g !== void 0 ? _g : "";
738
- message.pollingUnit = (_h = object.pollingUnit) !== null && _h !== void 0 ? _h : "";
739
- message.kycData = (_j = object.kycData) !== null && _j !== void 0 ? _j : new Uint8Array(0);
934
+ message.constituencyId = (_h = object.constituencyId) !== null && _h !== void 0 ? _h : "";
935
+ message.districtId = (_j = object.districtId) !== null && _j !== void 0 ? _j : "";
936
+ message.pollingUnit = (_k = object.pollingUnit) !== null && _k !== void 0 ? _k : "";
937
+ message.kycData = (_l = object.kycData) !== null && _l !== void 0 ? _l : new Uint8Array(0);
740
938
  return message;
741
939
  },
742
940
  };
@@ -1016,10 +1214,95 @@ exports.ApplyForRepresentativeResponse = {
1016
1214
  return message;
1017
1215
  },
1018
1216
  };
1217
+ function createBaseProfileStats() {
1218
+ return { postsCount: 0, followersCount: 0, followingCount: 0 };
1219
+ }
1220
+ exports.ProfileStats = {
1221
+ encode(message, writer = new wire_1.BinaryWriter()) {
1222
+ if (message.postsCount !== 0) {
1223
+ writer.uint32(8).int64(message.postsCount);
1224
+ }
1225
+ if (message.followersCount !== 0) {
1226
+ writer.uint32(16).int64(message.followersCount);
1227
+ }
1228
+ if (message.followingCount !== 0) {
1229
+ writer.uint32(24).int64(message.followingCount);
1230
+ }
1231
+ return writer;
1232
+ },
1233
+ decode(input, length) {
1234
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
1235
+ const end = length === undefined ? reader.len : reader.pos + length;
1236
+ const message = createBaseProfileStats();
1237
+ while (reader.pos < end) {
1238
+ const tag = reader.uint32();
1239
+ switch (tag >>> 3) {
1240
+ case 1: {
1241
+ if (tag !== 8) {
1242
+ break;
1243
+ }
1244
+ message.postsCount = longToNumber(reader.int64());
1245
+ continue;
1246
+ }
1247
+ case 2: {
1248
+ if (tag !== 16) {
1249
+ break;
1250
+ }
1251
+ message.followersCount = longToNumber(reader.int64());
1252
+ continue;
1253
+ }
1254
+ case 3: {
1255
+ if (tag !== 24) {
1256
+ break;
1257
+ }
1258
+ message.followingCount = longToNumber(reader.int64());
1259
+ continue;
1260
+ }
1261
+ }
1262
+ if ((tag & 7) === 4 || tag === 0) {
1263
+ break;
1264
+ }
1265
+ reader.skip(tag & 7);
1266
+ }
1267
+ return message;
1268
+ },
1269
+ fromJSON(object) {
1270
+ return {
1271
+ postsCount: isSet(object.postsCount) ? globalThis.Number(object.postsCount) : 0,
1272
+ followersCount: isSet(object.followersCount) ? globalThis.Number(object.followersCount) : 0,
1273
+ followingCount: isSet(object.followingCount) ? globalThis.Number(object.followingCount) : 0,
1274
+ };
1275
+ },
1276
+ toJSON(message) {
1277
+ const obj = {};
1278
+ if (message.postsCount !== 0) {
1279
+ obj.postsCount = Math.round(message.postsCount);
1280
+ }
1281
+ if (message.followersCount !== 0) {
1282
+ obj.followersCount = Math.round(message.followersCount);
1283
+ }
1284
+ if (message.followingCount !== 0) {
1285
+ obj.followingCount = Math.round(message.followingCount);
1286
+ }
1287
+ return obj;
1288
+ },
1289
+ create(base) {
1290
+ return exports.ProfileStats.fromPartial(base !== null && base !== void 0 ? base : {});
1291
+ },
1292
+ fromPartial(object) {
1293
+ var _a, _b, _c;
1294
+ const message = createBaseProfileStats();
1295
+ message.postsCount = (_a = object.postsCount) !== null && _a !== void 0 ? _a : 0;
1296
+ message.followersCount = (_b = object.followersCount) !== null && _b !== void 0 ? _b : 0;
1297
+ message.followingCount = (_c = object.followingCount) !== null && _c !== void 0 ? _c : 0;
1298
+ return message;
1299
+ },
1300
+ };
1019
1301
  function createBaseAccount() {
1020
1302
  return {
1021
1303
  id: "",
1022
1304
  name: "",
1305
+ username: "",
1023
1306
  email: "",
1024
1307
  photoUrl: "",
1025
1308
  coverPhotoUrl: "",
@@ -1027,15 +1310,23 @@ function createBaseAccount() {
1027
1310
  gender: "",
1028
1311
  dob: "",
1029
1312
  location: "",
1030
- stateId: "",
1031
- localGovernmentId: "",
1032
- accountTypeId: "",
1313
+ bio: "",
1314
+ website: "",
1315
+ state: undefined,
1316
+ localGovernment: undefined,
1317
+ constituency: undefined,
1318
+ district: undefined,
1319
+ accountType: undefined,
1033
1320
  pollingUnit: "",
1034
1321
  emailVerified: false,
1322
+ verified: false,
1035
1323
  status: "",
1036
1324
  kyced: false,
1037
1325
  createdAt: "",
1038
1326
  updatedAt: "",
1327
+ isFollowing: false,
1328
+ isFollowedBy: false,
1329
+ isOwnProfile: false,
1039
1330
  };
1040
1331
  }
1041
1332
  exports.Account = {
@@ -1046,53 +1337,80 @@ exports.Account = {
1046
1337
  if (message.name !== "") {
1047
1338
  writer.uint32(18).string(message.name);
1048
1339
  }
1340
+ if (message.username !== "") {
1341
+ writer.uint32(26).string(message.username);
1342
+ }
1049
1343
  if (message.email !== "") {
1050
- writer.uint32(26).string(message.email);
1344
+ writer.uint32(34).string(message.email);
1051
1345
  }
1052
1346
  if (message.photoUrl !== "") {
1053
- writer.uint32(34).string(message.photoUrl);
1347
+ writer.uint32(42).string(message.photoUrl);
1054
1348
  }
1055
1349
  if (message.coverPhotoUrl !== "") {
1056
- writer.uint32(42).string(message.coverPhotoUrl);
1350
+ writer.uint32(50).string(message.coverPhotoUrl);
1057
1351
  }
1058
1352
  if (message.phoneNumber !== "") {
1059
- writer.uint32(50).string(message.phoneNumber);
1353
+ writer.uint32(58).string(message.phoneNumber);
1060
1354
  }
1061
1355
  if (message.gender !== "") {
1062
- writer.uint32(58).string(message.gender);
1356
+ writer.uint32(66).string(message.gender);
1063
1357
  }
1064
1358
  if (message.dob !== "") {
1065
- writer.uint32(66).string(message.dob);
1359
+ writer.uint32(74).string(message.dob);
1066
1360
  }
1067
1361
  if (message.location !== "") {
1068
- writer.uint32(74).string(message.location);
1362
+ writer.uint32(82).string(message.location);
1069
1363
  }
1070
- if (message.stateId !== "") {
1071
- writer.uint32(82).string(message.stateId);
1364
+ if (message.bio !== "") {
1365
+ writer.uint32(90).string(message.bio);
1072
1366
  }
1073
- if (message.localGovernmentId !== "") {
1074
- writer.uint32(90).string(message.localGovernmentId);
1367
+ if (message.website !== "") {
1368
+ writer.uint32(98).string(message.website);
1369
+ }
1370
+ if (message.state !== undefined) {
1371
+ lookup_1.State.encode(message.state, writer.uint32(106).fork()).join();
1372
+ }
1373
+ if (message.localGovernment !== undefined) {
1374
+ lookup_1.LocalGovernment.encode(message.localGovernment, writer.uint32(114).fork()).join();
1075
1375
  }
1076
- if (message.accountTypeId !== "") {
1077
- writer.uint32(98).string(message.accountTypeId);
1376
+ if (message.constituency !== undefined) {
1377
+ lookup_1.Constituency.encode(message.constituency, writer.uint32(122).fork()).join();
1378
+ }
1379
+ if (message.district !== undefined) {
1380
+ lookup_1.District.encode(message.district, writer.uint32(130).fork()).join();
1381
+ }
1382
+ if (message.accountType !== undefined) {
1383
+ lookup_1.AccountType.encode(message.accountType, writer.uint32(138).fork()).join();
1078
1384
  }
1079
1385
  if (message.pollingUnit !== "") {
1080
- writer.uint32(106).string(message.pollingUnit);
1386
+ writer.uint32(146).string(message.pollingUnit);
1081
1387
  }
1082
1388
  if (message.emailVerified !== false) {
1083
- writer.uint32(112).bool(message.emailVerified);
1389
+ writer.uint32(152).bool(message.emailVerified);
1390
+ }
1391
+ if (message.verified !== false) {
1392
+ writer.uint32(160).bool(message.verified);
1084
1393
  }
1085
1394
  if (message.status !== "") {
1086
- writer.uint32(122).string(message.status);
1395
+ writer.uint32(170).string(message.status);
1087
1396
  }
1088
1397
  if (message.kyced !== false) {
1089
- writer.uint32(128).bool(message.kyced);
1398
+ writer.uint32(176).bool(message.kyced);
1090
1399
  }
1091
1400
  if (message.createdAt !== "") {
1092
- writer.uint32(138).string(message.createdAt);
1401
+ writer.uint32(186).string(message.createdAt);
1093
1402
  }
1094
1403
  if (message.updatedAt !== "") {
1095
- writer.uint32(146).string(message.updatedAt);
1404
+ writer.uint32(194).string(message.updatedAt);
1405
+ }
1406
+ if (message.isFollowing !== false) {
1407
+ writer.uint32(200).bool(message.isFollowing);
1408
+ }
1409
+ if (message.isFollowedBy !== false) {
1410
+ writer.uint32(208).bool(message.isFollowedBy);
1411
+ }
1412
+ if (message.isOwnProfile !== false) {
1413
+ writer.uint32(216).bool(message.isOwnProfile);
1096
1414
  }
1097
1415
  return writer;
1098
1416
  },
@@ -1121,142 +1439,214 @@ exports.Account = {
1121
1439
  if (tag !== 26) {
1122
1440
  break;
1123
1441
  }
1124
- message.email = reader.string();
1442
+ message.username = reader.string();
1125
1443
  continue;
1126
1444
  }
1127
1445
  case 4: {
1128
1446
  if (tag !== 34) {
1129
1447
  break;
1130
1448
  }
1131
- message.photoUrl = reader.string();
1449
+ message.email = reader.string();
1132
1450
  continue;
1133
1451
  }
1134
1452
  case 5: {
1135
1453
  if (tag !== 42) {
1136
1454
  break;
1137
1455
  }
1138
- message.coverPhotoUrl = reader.string();
1456
+ message.photoUrl = reader.string();
1139
1457
  continue;
1140
1458
  }
1141
1459
  case 6: {
1142
1460
  if (tag !== 50) {
1143
1461
  break;
1144
1462
  }
1145
- message.phoneNumber = reader.string();
1463
+ message.coverPhotoUrl = reader.string();
1146
1464
  continue;
1147
1465
  }
1148
1466
  case 7: {
1149
1467
  if (tag !== 58) {
1150
1468
  break;
1151
1469
  }
1152
- message.gender = reader.string();
1470
+ message.phoneNumber = reader.string();
1153
1471
  continue;
1154
1472
  }
1155
1473
  case 8: {
1156
1474
  if (tag !== 66) {
1157
1475
  break;
1158
1476
  }
1159
- message.dob = reader.string();
1477
+ message.gender = reader.string();
1160
1478
  continue;
1161
1479
  }
1162
1480
  case 9: {
1163
1481
  if (tag !== 74) {
1164
1482
  break;
1165
1483
  }
1166
- message.location = reader.string();
1484
+ message.dob = reader.string();
1167
1485
  continue;
1168
1486
  }
1169
1487
  case 10: {
1170
1488
  if (tag !== 82) {
1171
1489
  break;
1172
1490
  }
1173
- message.stateId = reader.string();
1491
+ message.location = reader.string();
1174
1492
  continue;
1175
1493
  }
1176
1494
  case 11: {
1177
1495
  if (tag !== 90) {
1178
1496
  break;
1179
1497
  }
1180
- message.localGovernmentId = reader.string();
1498
+ message.bio = reader.string();
1181
1499
  continue;
1182
1500
  }
1183
1501
  case 12: {
1184
1502
  if (tag !== 98) {
1185
1503
  break;
1186
1504
  }
1187
- message.accountTypeId = reader.string();
1505
+ message.website = reader.string();
1188
1506
  continue;
1189
1507
  }
1190
1508
  case 13: {
1191
1509
  if (tag !== 106) {
1192
1510
  break;
1193
1511
  }
1194
- message.pollingUnit = reader.string();
1512
+ message.state = lookup_1.State.decode(reader, reader.uint32());
1195
1513
  continue;
1196
1514
  }
1197
1515
  case 14: {
1198
- if (tag !== 112) {
1516
+ if (tag !== 114) {
1199
1517
  break;
1200
1518
  }
1201
- message.emailVerified = reader.bool();
1519
+ message.localGovernment = lookup_1.LocalGovernment.decode(reader, reader.uint32());
1202
1520
  continue;
1203
1521
  }
1204
1522
  case 15: {
1205
1523
  if (tag !== 122) {
1206
1524
  break;
1207
1525
  }
1208
- message.status = reader.string();
1526
+ message.constituency = lookup_1.Constituency.decode(reader, reader.uint32());
1209
1527
  continue;
1210
1528
  }
1211
1529
  case 16: {
1212
- if (tag !== 128) {
1530
+ if (tag !== 130) {
1213
1531
  break;
1214
1532
  }
1215
- message.kyced = reader.bool();
1533
+ message.district = lookup_1.District.decode(reader, reader.uint32());
1216
1534
  continue;
1217
1535
  }
1218
1536
  case 17: {
1219
1537
  if (tag !== 138) {
1220
1538
  break;
1221
1539
  }
1222
- message.createdAt = reader.string();
1540
+ message.accountType = lookup_1.AccountType.decode(reader, reader.uint32());
1223
1541
  continue;
1224
1542
  }
1225
1543
  case 18: {
1226
1544
  if (tag !== 146) {
1227
1545
  break;
1228
1546
  }
1229
- message.updatedAt = reader.string();
1547
+ message.pollingUnit = reader.string();
1230
1548
  continue;
1231
1549
  }
1232
- }
1233
- if ((tag & 7) === 4 || tag === 0) {
1234
- break;
1235
- }
1236
- reader.skip(tag & 7);
1237
- }
1238
- return message;
1239
- },
1240
- fromJSON(object) {
1241
- return {
1242
- id: isSet(object.id) ? globalThis.String(object.id) : "",
1243
- name: isSet(object.name) ? globalThis.String(object.name) : "",
1244
- email: isSet(object.email) ? globalThis.String(object.email) : "",
1245
- photoUrl: isSet(object.photoUrl) ? globalThis.String(object.photoUrl) : "",
1246
- coverPhotoUrl: isSet(object.coverPhotoUrl) ? globalThis.String(object.coverPhotoUrl) : "",
1247
- phoneNumber: isSet(object.phoneNumber) ? globalThis.String(object.phoneNumber) : "",
1248
- gender: isSet(object.gender) ? globalThis.String(object.gender) : "",
1249
- dob: isSet(object.dob) ? globalThis.String(object.dob) : "",
1550
+ case 19: {
1551
+ if (tag !== 152) {
1552
+ break;
1553
+ }
1554
+ message.emailVerified = reader.bool();
1555
+ continue;
1556
+ }
1557
+ case 20: {
1558
+ if (tag !== 160) {
1559
+ break;
1560
+ }
1561
+ message.verified = reader.bool();
1562
+ continue;
1563
+ }
1564
+ case 21: {
1565
+ if (tag !== 170) {
1566
+ break;
1567
+ }
1568
+ message.status = reader.string();
1569
+ continue;
1570
+ }
1571
+ case 22: {
1572
+ if (tag !== 176) {
1573
+ break;
1574
+ }
1575
+ message.kyced = reader.bool();
1576
+ continue;
1577
+ }
1578
+ case 23: {
1579
+ if (tag !== 186) {
1580
+ break;
1581
+ }
1582
+ message.createdAt = reader.string();
1583
+ continue;
1584
+ }
1585
+ case 24: {
1586
+ if (tag !== 194) {
1587
+ break;
1588
+ }
1589
+ message.updatedAt = reader.string();
1590
+ continue;
1591
+ }
1592
+ case 25: {
1593
+ if (tag !== 200) {
1594
+ break;
1595
+ }
1596
+ message.isFollowing = reader.bool();
1597
+ continue;
1598
+ }
1599
+ case 26: {
1600
+ if (tag !== 208) {
1601
+ break;
1602
+ }
1603
+ message.isFollowedBy = reader.bool();
1604
+ continue;
1605
+ }
1606
+ case 27: {
1607
+ if (tag !== 216) {
1608
+ break;
1609
+ }
1610
+ message.isOwnProfile = reader.bool();
1611
+ continue;
1612
+ }
1613
+ }
1614
+ if ((tag & 7) === 4 || tag === 0) {
1615
+ break;
1616
+ }
1617
+ reader.skip(tag & 7);
1618
+ }
1619
+ return message;
1620
+ },
1621
+ fromJSON(object) {
1622
+ return {
1623
+ id: isSet(object.id) ? globalThis.String(object.id) : "",
1624
+ name: isSet(object.name) ? globalThis.String(object.name) : "",
1625
+ username: isSet(object.username) ? globalThis.String(object.username) : "",
1626
+ email: isSet(object.email) ? globalThis.String(object.email) : "",
1627
+ photoUrl: isSet(object.photoUrl) ? globalThis.String(object.photoUrl) : "",
1628
+ coverPhotoUrl: isSet(object.coverPhotoUrl) ? globalThis.String(object.coverPhotoUrl) : "",
1629
+ phoneNumber: isSet(object.phoneNumber) ? globalThis.String(object.phoneNumber) : "",
1630
+ gender: isSet(object.gender) ? globalThis.String(object.gender) : "",
1631
+ dob: isSet(object.dob) ? globalThis.String(object.dob) : "",
1250
1632
  location: isSet(object.location) ? globalThis.String(object.location) : "",
1251
- stateId: isSet(object.stateId) ? globalThis.String(object.stateId) : "",
1252
- localGovernmentId: isSet(object.localGovernmentId) ? globalThis.String(object.localGovernmentId) : "",
1253
- accountTypeId: isSet(object.accountTypeId) ? globalThis.String(object.accountTypeId) : "",
1633
+ bio: isSet(object.bio) ? globalThis.String(object.bio) : "",
1634
+ website: isSet(object.website) ? globalThis.String(object.website) : "",
1635
+ state: isSet(object.state) ? lookup_1.State.fromJSON(object.state) : undefined,
1636
+ localGovernment: isSet(object.localGovernment) ? lookup_1.LocalGovernment.fromJSON(object.localGovernment) : undefined,
1637
+ constituency: isSet(object.constituency) ? lookup_1.Constituency.fromJSON(object.constituency) : undefined,
1638
+ district: isSet(object.district) ? lookup_1.District.fromJSON(object.district) : undefined,
1639
+ accountType: isSet(object.accountType) ? lookup_1.AccountType.fromJSON(object.accountType) : undefined,
1254
1640
  pollingUnit: isSet(object.pollingUnit) ? globalThis.String(object.pollingUnit) : "",
1255
1641
  emailVerified: isSet(object.emailVerified) ? globalThis.Boolean(object.emailVerified) : false,
1642
+ verified: isSet(object.verified) ? globalThis.Boolean(object.verified) : false,
1256
1643
  status: isSet(object.status) ? globalThis.String(object.status) : "",
1257
1644
  kyced: isSet(object.kyced) ? globalThis.Boolean(object.kyced) : false,
1258
1645
  createdAt: isSet(object.createdAt) ? globalThis.String(object.createdAt) : "",
1259
1646
  updatedAt: isSet(object.updatedAt) ? globalThis.String(object.updatedAt) : "",
1647
+ isFollowing: isSet(object.isFollowing) ? globalThis.Boolean(object.isFollowing) : false,
1648
+ isFollowedBy: isSet(object.isFollowedBy) ? globalThis.Boolean(object.isFollowedBy) : false,
1649
+ isOwnProfile: isSet(object.isOwnProfile) ? globalThis.Boolean(object.isOwnProfile) : false,
1260
1650
  };
1261
1651
  },
1262
1652
  toJSON(message) {
@@ -1267,6 +1657,9 @@ exports.Account = {
1267
1657
  if (message.name !== "") {
1268
1658
  obj.name = message.name;
1269
1659
  }
1660
+ if (message.username !== "") {
1661
+ obj.username = message.username;
1662
+ }
1270
1663
  if (message.email !== "") {
1271
1664
  obj.email = message.email;
1272
1665
  }
@@ -1288,14 +1681,26 @@ exports.Account = {
1288
1681
  if (message.location !== "") {
1289
1682
  obj.location = message.location;
1290
1683
  }
1291
- if (message.stateId !== "") {
1292
- obj.stateId = message.stateId;
1684
+ if (message.bio !== "") {
1685
+ obj.bio = message.bio;
1293
1686
  }
1294
- if (message.localGovernmentId !== "") {
1295
- obj.localGovernmentId = message.localGovernmentId;
1687
+ if (message.website !== "") {
1688
+ obj.website = message.website;
1689
+ }
1690
+ if (message.state !== undefined) {
1691
+ obj.state = lookup_1.State.toJSON(message.state);
1692
+ }
1693
+ if (message.localGovernment !== undefined) {
1694
+ obj.localGovernment = lookup_1.LocalGovernment.toJSON(message.localGovernment);
1695
+ }
1696
+ if (message.constituency !== undefined) {
1697
+ obj.constituency = lookup_1.Constituency.toJSON(message.constituency);
1296
1698
  }
1297
- if (message.accountTypeId !== "") {
1298
- obj.accountTypeId = message.accountTypeId;
1699
+ if (message.district !== undefined) {
1700
+ obj.district = lookup_1.District.toJSON(message.district);
1701
+ }
1702
+ if (message.accountType !== undefined) {
1703
+ obj.accountType = lookup_1.AccountType.toJSON(message.accountType);
1299
1704
  }
1300
1705
  if (message.pollingUnit !== "") {
1301
1706
  obj.pollingUnit = message.pollingUnit;
@@ -1303,6 +1708,9 @@ exports.Account = {
1303
1708
  if (message.emailVerified !== false) {
1304
1709
  obj.emailVerified = message.emailVerified;
1305
1710
  }
1711
+ if (message.verified !== false) {
1712
+ obj.verified = message.verified;
1713
+ }
1306
1714
  if (message.status !== "") {
1307
1715
  obj.status = message.status;
1308
1716
  }
@@ -1315,32 +1723,190 @@ exports.Account = {
1315
1723
  if (message.updatedAt !== "") {
1316
1724
  obj.updatedAt = message.updatedAt;
1317
1725
  }
1726
+ if (message.isFollowing !== false) {
1727
+ obj.isFollowing = message.isFollowing;
1728
+ }
1729
+ if (message.isFollowedBy !== false) {
1730
+ obj.isFollowedBy = message.isFollowedBy;
1731
+ }
1732
+ if (message.isOwnProfile !== false) {
1733
+ obj.isOwnProfile = message.isOwnProfile;
1734
+ }
1318
1735
  return obj;
1319
1736
  },
1320
1737
  create(base) {
1321
1738
  return exports.Account.fromPartial(base !== null && base !== void 0 ? base : {});
1322
1739
  },
1323
1740
  fromPartial(object) {
1324
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
1741
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;
1325
1742
  const message = createBaseAccount();
1326
1743
  message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
1327
1744
  message.name = (_b = object.name) !== null && _b !== void 0 ? _b : "";
1328
- message.email = (_c = object.email) !== null && _c !== void 0 ? _c : "";
1329
- message.photoUrl = (_d = object.photoUrl) !== null && _d !== void 0 ? _d : "";
1330
- message.coverPhotoUrl = (_e = object.coverPhotoUrl) !== null && _e !== void 0 ? _e : "";
1331
- message.phoneNumber = (_f = object.phoneNumber) !== null && _f !== void 0 ? _f : "";
1332
- message.gender = (_g = object.gender) !== null && _g !== void 0 ? _g : "";
1333
- message.dob = (_h = object.dob) !== null && _h !== void 0 ? _h : "";
1334
- message.location = (_j = object.location) !== null && _j !== void 0 ? _j : "";
1335
- message.stateId = (_k = object.stateId) !== null && _k !== void 0 ? _k : "";
1336
- message.localGovernmentId = (_l = object.localGovernmentId) !== null && _l !== void 0 ? _l : "";
1337
- message.accountTypeId = (_m = object.accountTypeId) !== null && _m !== void 0 ? _m : "";
1745
+ message.username = (_c = object.username) !== null && _c !== void 0 ? _c : "";
1746
+ message.email = (_d = object.email) !== null && _d !== void 0 ? _d : "";
1747
+ message.photoUrl = (_e = object.photoUrl) !== null && _e !== void 0 ? _e : "";
1748
+ message.coverPhotoUrl = (_f = object.coverPhotoUrl) !== null && _f !== void 0 ? _f : "";
1749
+ message.phoneNumber = (_g = object.phoneNumber) !== null && _g !== void 0 ? _g : "";
1750
+ message.gender = (_h = object.gender) !== null && _h !== void 0 ? _h : "";
1751
+ message.dob = (_j = object.dob) !== null && _j !== void 0 ? _j : "";
1752
+ message.location = (_k = object.location) !== null && _k !== void 0 ? _k : "";
1753
+ message.bio = (_l = object.bio) !== null && _l !== void 0 ? _l : "";
1754
+ message.website = (_m = object.website) !== null && _m !== void 0 ? _m : "";
1755
+ message.state = (object.state !== undefined && object.state !== null) ? lookup_1.State.fromPartial(object.state) : undefined;
1756
+ message.localGovernment = (object.localGovernment !== undefined && object.localGovernment !== null)
1757
+ ? lookup_1.LocalGovernment.fromPartial(object.localGovernment)
1758
+ : undefined;
1759
+ message.constituency = (object.constituency !== undefined && object.constituency !== null)
1760
+ ? lookup_1.Constituency.fromPartial(object.constituency)
1761
+ : undefined;
1762
+ message.district = (object.district !== undefined && object.district !== null)
1763
+ ? lookup_1.District.fromPartial(object.district)
1764
+ : undefined;
1765
+ message.accountType = (object.accountType !== undefined && object.accountType !== null)
1766
+ ? lookup_1.AccountType.fromPartial(object.accountType)
1767
+ : undefined;
1338
1768
  message.pollingUnit = (_o = object.pollingUnit) !== null && _o !== void 0 ? _o : "";
1339
1769
  message.emailVerified = (_p = object.emailVerified) !== null && _p !== void 0 ? _p : false;
1340
- message.status = (_q = object.status) !== null && _q !== void 0 ? _q : "";
1341
- message.kyced = (_r = object.kyced) !== null && _r !== void 0 ? _r : false;
1342
- message.createdAt = (_s = object.createdAt) !== null && _s !== void 0 ? _s : "";
1343
- message.updatedAt = (_t = object.updatedAt) !== null && _t !== void 0 ? _t : "";
1770
+ message.verified = (_q = object.verified) !== null && _q !== void 0 ? _q : false;
1771
+ message.status = (_r = object.status) !== null && _r !== void 0 ? _r : "";
1772
+ message.kyced = (_s = object.kyced) !== null && _s !== void 0 ? _s : false;
1773
+ message.createdAt = (_t = object.createdAt) !== null && _t !== void 0 ? _t : "";
1774
+ message.updatedAt = (_u = object.updatedAt) !== null && _u !== void 0 ? _u : "";
1775
+ message.isFollowing = (_v = object.isFollowing) !== null && _v !== void 0 ? _v : false;
1776
+ message.isFollowedBy = (_w = object.isFollowedBy) !== null && _w !== void 0 ? _w : false;
1777
+ message.isOwnProfile = (_x = object.isOwnProfile) !== null && _x !== void 0 ? _x : false;
1778
+ return message;
1779
+ },
1780
+ };
1781
+ function createBaseProfile() {
1782
+ return { user: undefined, stats: undefined, posts: [], replies: [], media: [], likes: [] };
1783
+ }
1784
+ exports.Profile = {
1785
+ encode(message, writer = new wire_1.BinaryWriter()) {
1786
+ if (message.user !== undefined) {
1787
+ exports.Account.encode(message.user, writer.uint32(10).fork()).join();
1788
+ }
1789
+ if (message.stats !== undefined) {
1790
+ exports.ProfileStats.encode(message.stats, writer.uint32(18).fork()).join();
1791
+ }
1792
+ for (const v of message.posts) {
1793
+ posts_1.Post.encode(v, writer.uint32(26).fork()).join();
1794
+ }
1795
+ for (const v of message.replies) {
1796
+ posts_1.Post.encode(v, writer.uint32(34).fork()).join();
1797
+ }
1798
+ for (const v of message.media) {
1799
+ posts_1.Post.encode(v, writer.uint32(42).fork()).join();
1800
+ }
1801
+ for (const v of message.likes) {
1802
+ posts_1.Post.encode(v, writer.uint32(50).fork()).join();
1803
+ }
1804
+ return writer;
1805
+ },
1806
+ decode(input, length) {
1807
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
1808
+ const end = length === undefined ? reader.len : reader.pos + length;
1809
+ const message = createBaseProfile();
1810
+ while (reader.pos < end) {
1811
+ const tag = reader.uint32();
1812
+ switch (tag >>> 3) {
1813
+ case 1: {
1814
+ if (tag !== 10) {
1815
+ break;
1816
+ }
1817
+ message.user = exports.Account.decode(reader, reader.uint32());
1818
+ continue;
1819
+ }
1820
+ case 2: {
1821
+ if (tag !== 18) {
1822
+ break;
1823
+ }
1824
+ message.stats = exports.ProfileStats.decode(reader, reader.uint32());
1825
+ continue;
1826
+ }
1827
+ case 3: {
1828
+ if (tag !== 26) {
1829
+ break;
1830
+ }
1831
+ message.posts.push(posts_1.Post.decode(reader, reader.uint32()));
1832
+ continue;
1833
+ }
1834
+ case 4: {
1835
+ if (tag !== 34) {
1836
+ break;
1837
+ }
1838
+ message.replies.push(posts_1.Post.decode(reader, reader.uint32()));
1839
+ continue;
1840
+ }
1841
+ case 5: {
1842
+ if (tag !== 42) {
1843
+ break;
1844
+ }
1845
+ message.media.push(posts_1.Post.decode(reader, reader.uint32()));
1846
+ continue;
1847
+ }
1848
+ case 6: {
1849
+ if (tag !== 50) {
1850
+ break;
1851
+ }
1852
+ message.likes.push(posts_1.Post.decode(reader, reader.uint32()));
1853
+ continue;
1854
+ }
1855
+ }
1856
+ if ((tag & 7) === 4 || tag === 0) {
1857
+ break;
1858
+ }
1859
+ reader.skip(tag & 7);
1860
+ }
1861
+ return message;
1862
+ },
1863
+ fromJSON(object) {
1864
+ return {
1865
+ user: isSet(object.user) ? exports.Account.fromJSON(object.user) : undefined,
1866
+ stats: isSet(object.stats) ? exports.ProfileStats.fromJSON(object.stats) : undefined,
1867
+ posts: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.posts) ? object.posts.map((e) => posts_1.Post.fromJSON(e)) : [],
1868
+ replies: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.replies) ? object.replies.map((e) => posts_1.Post.fromJSON(e)) : [],
1869
+ media: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.media) ? object.media.map((e) => posts_1.Post.fromJSON(e)) : [],
1870
+ likes: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.likes) ? object.likes.map((e) => posts_1.Post.fromJSON(e)) : [],
1871
+ };
1872
+ },
1873
+ toJSON(message) {
1874
+ var _a, _b, _c, _d;
1875
+ const obj = {};
1876
+ if (message.user !== undefined) {
1877
+ obj.user = exports.Account.toJSON(message.user);
1878
+ }
1879
+ if (message.stats !== undefined) {
1880
+ obj.stats = exports.ProfileStats.toJSON(message.stats);
1881
+ }
1882
+ if ((_a = message.posts) === null || _a === void 0 ? void 0 : _a.length) {
1883
+ obj.posts = message.posts.map((e) => posts_1.Post.toJSON(e));
1884
+ }
1885
+ if ((_b = message.replies) === null || _b === void 0 ? void 0 : _b.length) {
1886
+ obj.replies = message.replies.map((e) => posts_1.Post.toJSON(e));
1887
+ }
1888
+ if ((_c = message.media) === null || _c === void 0 ? void 0 : _c.length) {
1889
+ obj.media = message.media.map((e) => posts_1.Post.toJSON(e));
1890
+ }
1891
+ if ((_d = message.likes) === null || _d === void 0 ? void 0 : _d.length) {
1892
+ obj.likes = message.likes.map((e) => posts_1.Post.toJSON(e));
1893
+ }
1894
+ return obj;
1895
+ },
1896
+ create(base) {
1897
+ return exports.Profile.fromPartial(base !== null && base !== void 0 ? base : {});
1898
+ },
1899
+ fromPartial(object) {
1900
+ var _a, _b, _c, _d;
1901
+ const message = createBaseProfile();
1902
+ message.user = (object.user !== undefined && object.user !== null) ? exports.Account.fromPartial(object.user) : undefined;
1903
+ message.stats = (object.stats !== undefined && object.stats !== null)
1904
+ ? exports.ProfileStats.fromPartial(object.stats)
1905
+ : undefined;
1906
+ message.posts = ((_a = object.posts) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
1907
+ message.replies = ((_b = object.replies) === null || _b === void 0 ? void 0 : _b.map((e) => posts_1.Post.fromPartial(e))) || [];
1908
+ message.media = ((_c = object.media) === null || _c === void 0 ? void 0 : _c.map((e) => posts_1.Post.fromPartial(e))) || [];
1909
+ message.likes = ((_d = object.likes) === null || _d === void 0 ? void 0 : _d.map((e) => posts_1.Post.fromPartial(e))) || [];
1344
1910
  return message;
1345
1911
  },
1346
1912
  };
@@ -1902,100 +2468,1904 @@ exports.Representative = {
1902
2468
  return message;
1903
2469
  },
1904
2470
  };
1905
- exports.AccountServiceDefinition = {
1906
- name: "AccountService",
1907
- fullName: "pb.AccountService",
1908
- methods: {
1909
- getProfile: {
1910
- name: "GetProfile",
1911
- requestType: exports.GetProfileRequest,
1912
- requestStream: false,
1913
- responseType: exports.GetProfileResponse,
1914
- responseStream: false,
1915
- options: {
1916
- _unknownFields: {
1917
- 578365826: [
1918
- new Uint8Array([
1919
- 25,
1920
- 18,
1921
- 23,
1922
- 47,
1923
- 97,
1924
- 112,
1925
- 105,
1926
- 47,
1927
- 118,
1928
- 49,
1929
- 47,
1930
- 97,
1931
- 99,
1932
- 99,
1933
- 111,
1934
- 117,
1935
- 110,
1936
- 116,
1937
- 47,
1938
- 112,
1939
- 114,
1940
- 111,
1941
- 102,
1942
- 105,
1943
- 108,
1944
- 101,
1945
- ]),
1946
- ],
1947
- },
1948
- },
1949
- },
1950
- updateProfile: {
1951
- name: "UpdateProfile",
1952
- requestType: exports.UpdateProfileRequest,
1953
- requestStream: false,
1954
- responseType: exports.UpdateProfileResponse,
1955
- responseStream: false,
1956
- options: {
1957
- _unknownFields: {
1958
- 578365826: [
1959
- new Uint8Array([
1960
- 28,
1961
- 26,
1962
- 23,
1963
- 47,
1964
- 97,
1965
- 112,
1966
- 105,
1967
- 47,
1968
- 118,
1969
- 49,
1970
- 47,
1971
- 97,
1972
- 99,
1973
- 99,
1974
- 111,
1975
- 117,
1976
- 110,
1977
- 116,
1978
- 47,
1979
- 112,
1980
- 114,
1981
- 111,
1982
- 102,
1983
- 105,
1984
- 108,
1985
- 101,
1986
- 58,
1987
- 1,
1988
- 42,
1989
- ]),
1990
- ],
1991
- },
1992
- },
1993
- },
1994
- updatePassword: {
1995
- name: "UpdatePassword",
1996
- requestType: exports.UpdatePasswordRequest,
1997
- requestStream: false,
1998
- responseType: common_1.DeleteResponse,
2471
+ function createBaseFollowUserRequest() {
2472
+ return { userId: "" };
2473
+ }
2474
+ exports.FollowUserRequest = {
2475
+ encode(message, writer = new wire_1.BinaryWriter()) {
2476
+ if (message.userId !== "") {
2477
+ writer.uint32(10).string(message.userId);
2478
+ }
2479
+ return writer;
2480
+ },
2481
+ decode(input, length) {
2482
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2483
+ const end = length === undefined ? reader.len : reader.pos + length;
2484
+ const message = createBaseFollowUserRequest();
2485
+ while (reader.pos < end) {
2486
+ const tag = reader.uint32();
2487
+ switch (tag >>> 3) {
2488
+ case 1: {
2489
+ if (tag !== 10) {
2490
+ break;
2491
+ }
2492
+ message.userId = reader.string();
2493
+ continue;
2494
+ }
2495
+ }
2496
+ if ((tag & 7) === 4 || tag === 0) {
2497
+ break;
2498
+ }
2499
+ reader.skip(tag & 7);
2500
+ }
2501
+ return message;
2502
+ },
2503
+ fromJSON(object) {
2504
+ return { userId: isSet(object.userId) ? globalThis.String(object.userId) : "" };
2505
+ },
2506
+ toJSON(message) {
2507
+ const obj = {};
2508
+ if (message.userId !== "") {
2509
+ obj.userId = message.userId;
2510
+ }
2511
+ return obj;
2512
+ },
2513
+ create(base) {
2514
+ return exports.FollowUserRequest.fromPartial(base !== null && base !== void 0 ? base : {});
2515
+ },
2516
+ fromPartial(object) {
2517
+ var _a;
2518
+ const message = createBaseFollowUserRequest();
2519
+ message.userId = (_a = object.userId) !== null && _a !== void 0 ? _a : "";
2520
+ return message;
2521
+ },
2522
+ };
2523
+ function createBaseFollowUserResponse() {
2524
+ return { success: false, message: "", isFollowing: false };
2525
+ }
2526
+ exports.FollowUserResponse = {
2527
+ encode(message, writer = new wire_1.BinaryWriter()) {
2528
+ if (message.success !== false) {
2529
+ writer.uint32(8).bool(message.success);
2530
+ }
2531
+ if (message.message !== "") {
2532
+ writer.uint32(18).string(message.message);
2533
+ }
2534
+ if (message.isFollowing !== false) {
2535
+ writer.uint32(24).bool(message.isFollowing);
2536
+ }
2537
+ return writer;
2538
+ },
2539
+ decode(input, length) {
2540
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2541
+ const end = length === undefined ? reader.len : reader.pos + length;
2542
+ const message = createBaseFollowUserResponse();
2543
+ while (reader.pos < end) {
2544
+ const tag = reader.uint32();
2545
+ switch (tag >>> 3) {
2546
+ case 1: {
2547
+ if (tag !== 8) {
2548
+ break;
2549
+ }
2550
+ message.success = reader.bool();
2551
+ continue;
2552
+ }
2553
+ case 2: {
2554
+ if (tag !== 18) {
2555
+ break;
2556
+ }
2557
+ message.message = reader.string();
2558
+ continue;
2559
+ }
2560
+ case 3: {
2561
+ if (tag !== 24) {
2562
+ break;
2563
+ }
2564
+ message.isFollowing = reader.bool();
2565
+ continue;
2566
+ }
2567
+ }
2568
+ if ((tag & 7) === 4 || tag === 0) {
2569
+ break;
2570
+ }
2571
+ reader.skip(tag & 7);
2572
+ }
2573
+ return message;
2574
+ },
2575
+ fromJSON(object) {
2576
+ return {
2577
+ success: isSet(object.success) ? globalThis.Boolean(object.success) : false,
2578
+ message: isSet(object.message) ? globalThis.String(object.message) : "",
2579
+ isFollowing: isSet(object.isFollowing) ? globalThis.Boolean(object.isFollowing) : false,
2580
+ };
2581
+ },
2582
+ toJSON(message) {
2583
+ const obj = {};
2584
+ if (message.success !== false) {
2585
+ obj.success = message.success;
2586
+ }
2587
+ if (message.message !== "") {
2588
+ obj.message = message.message;
2589
+ }
2590
+ if (message.isFollowing !== false) {
2591
+ obj.isFollowing = message.isFollowing;
2592
+ }
2593
+ return obj;
2594
+ },
2595
+ create(base) {
2596
+ return exports.FollowUserResponse.fromPartial(base !== null && base !== void 0 ? base : {});
2597
+ },
2598
+ fromPartial(object) {
2599
+ var _a, _b, _c;
2600
+ const message = createBaseFollowUserResponse();
2601
+ message.success = (_a = object.success) !== null && _a !== void 0 ? _a : false;
2602
+ message.message = (_b = object.message) !== null && _b !== void 0 ? _b : "";
2603
+ message.isFollowing = (_c = object.isFollowing) !== null && _c !== void 0 ? _c : false;
2604
+ return message;
2605
+ },
2606
+ };
2607
+ function createBaseUnfollowUserRequest() {
2608
+ return { userId: "" };
2609
+ }
2610
+ exports.UnfollowUserRequest = {
2611
+ encode(message, writer = new wire_1.BinaryWriter()) {
2612
+ if (message.userId !== "") {
2613
+ writer.uint32(10).string(message.userId);
2614
+ }
2615
+ return writer;
2616
+ },
2617
+ decode(input, length) {
2618
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2619
+ const end = length === undefined ? reader.len : reader.pos + length;
2620
+ const message = createBaseUnfollowUserRequest();
2621
+ while (reader.pos < end) {
2622
+ const tag = reader.uint32();
2623
+ switch (tag >>> 3) {
2624
+ case 1: {
2625
+ if (tag !== 10) {
2626
+ break;
2627
+ }
2628
+ message.userId = reader.string();
2629
+ continue;
2630
+ }
2631
+ }
2632
+ if ((tag & 7) === 4 || tag === 0) {
2633
+ break;
2634
+ }
2635
+ reader.skip(tag & 7);
2636
+ }
2637
+ return message;
2638
+ },
2639
+ fromJSON(object) {
2640
+ return { userId: isSet(object.userId) ? globalThis.String(object.userId) : "" };
2641
+ },
2642
+ toJSON(message) {
2643
+ const obj = {};
2644
+ if (message.userId !== "") {
2645
+ obj.userId = message.userId;
2646
+ }
2647
+ return obj;
2648
+ },
2649
+ create(base) {
2650
+ return exports.UnfollowUserRequest.fromPartial(base !== null && base !== void 0 ? base : {});
2651
+ },
2652
+ fromPartial(object) {
2653
+ var _a;
2654
+ const message = createBaseUnfollowUserRequest();
2655
+ message.userId = (_a = object.userId) !== null && _a !== void 0 ? _a : "";
2656
+ return message;
2657
+ },
2658
+ };
2659
+ function createBaseUnfollowUserResponse() {
2660
+ return { success: false, message: "" };
2661
+ }
2662
+ exports.UnfollowUserResponse = {
2663
+ encode(message, writer = new wire_1.BinaryWriter()) {
2664
+ if (message.success !== false) {
2665
+ writer.uint32(8).bool(message.success);
2666
+ }
2667
+ if (message.message !== "") {
2668
+ writer.uint32(18).string(message.message);
2669
+ }
2670
+ return writer;
2671
+ },
2672
+ decode(input, length) {
2673
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2674
+ const end = length === undefined ? reader.len : reader.pos + length;
2675
+ const message = createBaseUnfollowUserResponse();
2676
+ while (reader.pos < end) {
2677
+ const tag = reader.uint32();
2678
+ switch (tag >>> 3) {
2679
+ case 1: {
2680
+ if (tag !== 8) {
2681
+ break;
2682
+ }
2683
+ message.success = reader.bool();
2684
+ continue;
2685
+ }
2686
+ case 2: {
2687
+ if (tag !== 18) {
2688
+ break;
2689
+ }
2690
+ message.message = reader.string();
2691
+ continue;
2692
+ }
2693
+ }
2694
+ if ((tag & 7) === 4 || tag === 0) {
2695
+ break;
2696
+ }
2697
+ reader.skip(tag & 7);
2698
+ }
2699
+ return message;
2700
+ },
2701
+ fromJSON(object) {
2702
+ return {
2703
+ success: isSet(object.success) ? globalThis.Boolean(object.success) : false,
2704
+ message: isSet(object.message) ? globalThis.String(object.message) : "",
2705
+ };
2706
+ },
2707
+ toJSON(message) {
2708
+ const obj = {};
2709
+ if (message.success !== false) {
2710
+ obj.success = message.success;
2711
+ }
2712
+ if (message.message !== "") {
2713
+ obj.message = message.message;
2714
+ }
2715
+ return obj;
2716
+ },
2717
+ create(base) {
2718
+ return exports.UnfollowUserResponse.fromPartial(base !== null && base !== void 0 ? base : {});
2719
+ },
2720
+ fromPartial(object) {
2721
+ var _a, _b;
2722
+ const message = createBaseUnfollowUserResponse();
2723
+ message.success = (_a = object.success) !== null && _a !== void 0 ? _a : false;
2724
+ message.message = (_b = object.message) !== null && _b !== void 0 ? _b : "";
2725
+ return message;
2726
+ },
2727
+ };
2728
+ function createBaseGetFollowersRequest() {
2729
+ return { limit: 0, offset: 0 };
2730
+ }
2731
+ exports.GetFollowersRequest = {
2732
+ encode(message, writer = new wire_1.BinaryWriter()) {
2733
+ if (message.limit !== 0) {
2734
+ writer.uint32(8).int32(message.limit);
2735
+ }
2736
+ if (message.offset !== 0) {
2737
+ writer.uint32(16).int32(message.offset);
2738
+ }
2739
+ return writer;
2740
+ },
2741
+ decode(input, length) {
2742
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2743
+ const end = length === undefined ? reader.len : reader.pos + length;
2744
+ const message = createBaseGetFollowersRequest();
2745
+ while (reader.pos < end) {
2746
+ const tag = reader.uint32();
2747
+ switch (tag >>> 3) {
2748
+ case 1: {
2749
+ if (tag !== 8) {
2750
+ break;
2751
+ }
2752
+ message.limit = reader.int32();
2753
+ continue;
2754
+ }
2755
+ case 2: {
2756
+ if (tag !== 16) {
2757
+ break;
2758
+ }
2759
+ message.offset = reader.int32();
2760
+ continue;
2761
+ }
2762
+ }
2763
+ if ((tag & 7) === 4 || tag === 0) {
2764
+ break;
2765
+ }
2766
+ reader.skip(tag & 7);
2767
+ }
2768
+ return message;
2769
+ },
2770
+ fromJSON(object) {
2771
+ return {
2772
+ limit: isSet(object.limit) ? globalThis.Number(object.limit) : 0,
2773
+ offset: isSet(object.offset) ? globalThis.Number(object.offset) : 0,
2774
+ };
2775
+ },
2776
+ toJSON(message) {
2777
+ const obj = {};
2778
+ if (message.limit !== 0) {
2779
+ obj.limit = Math.round(message.limit);
2780
+ }
2781
+ if (message.offset !== 0) {
2782
+ obj.offset = Math.round(message.offset);
2783
+ }
2784
+ return obj;
2785
+ },
2786
+ create(base) {
2787
+ return exports.GetFollowersRequest.fromPartial(base !== null && base !== void 0 ? base : {});
2788
+ },
2789
+ fromPartial(object) {
2790
+ var _a, _b;
2791
+ const message = createBaseGetFollowersRequest();
2792
+ message.limit = (_a = object.limit) !== null && _a !== void 0 ? _a : 0;
2793
+ message.offset = (_b = object.offset) !== null && _b !== void 0 ? _b : 0;
2794
+ return message;
2795
+ },
2796
+ };
2797
+ function createBaseGetFollowersResponse() {
2798
+ return { followers: [], totalCount: 0 };
2799
+ }
2800
+ exports.GetFollowersResponse = {
2801
+ encode(message, writer = new wire_1.BinaryWriter()) {
2802
+ for (const v of message.followers) {
2803
+ exports.Account.encode(v, writer.uint32(10).fork()).join();
2804
+ }
2805
+ if (message.totalCount !== 0) {
2806
+ writer.uint32(16).int64(message.totalCount);
2807
+ }
2808
+ return writer;
2809
+ },
2810
+ decode(input, length) {
2811
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2812
+ const end = length === undefined ? reader.len : reader.pos + length;
2813
+ const message = createBaseGetFollowersResponse();
2814
+ while (reader.pos < end) {
2815
+ const tag = reader.uint32();
2816
+ switch (tag >>> 3) {
2817
+ case 1: {
2818
+ if (tag !== 10) {
2819
+ break;
2820
+ }
2821
+ message.followers.push(exports.Account.decode(reader, reader.uint32()));
2822
+ continue;
2823
+ }
2824
+ case 2: {
2825
+ if (tag !== 16) {
2826
+ break;
2827
+ }
2828
+ message.totalCount = longToNumber(reader.int64());
2829
+ continue;
2830
+ }
2831
+ }
2832
+ if ((tag & 7) === 4 || tag === 0) {
2833
+ break;
2834
+ }
2835
+ reader.skip(tag & 7);
2836
+ }
2837
+ return message;
2838
+ },
2839
+ fromJSON(object) {
2840
+ return {
2841
+ followers: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.followers)
2842
+ ? object.followers.map((e) => exports.Account.fromJSON(e))
2843
+ : [],
2844
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
2845
+ };
2846
+ },
2847
+ toJSON(message) {
2848
+ var _a;
2849
+ const obj = {};
2850
+ if ((_a = message.followers) === null || _a === void 0 ? void 0 : _a.length) {
2851
+ obj.followers = message.followers.map((e) => exports.Account.toJSON(e));
2852
+ }
2853
+ if (message.totalCount !== 0) {
2854
+ obj.totalCount = Math.round(message.totalCount);
2855
+ }
2856
+ return obj;
2857
+ },
2858
+ create(base) {
2859
+ return exports.GetFollowersResponse.fromPartial(base !== null && base !== void 0 ? base : {});
2860
+ },
2861
+ fromPartial(object) {
2862
+ var _a, _b;
2863
+ const message = createBaseGetFollowersResponse();
2864
+ message.followers = ((_a = object.followers) === null || _a === void 0 ? void 0 : _a.map((e) => exports.Account.fromPartial(e))) || [];
2865
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
2866
+ return message;
2867
+ },
2868
+ };
2869
+ function createBaseGetFollowingRequest() {
2870
+ return { limit: 0, offset: 0 };
2871
+ }
2872
+ exports.GetFollowingRequest = {
2873
+ encode(message, writer = new wire_1.BinaryWriter()) {
2874
+ if (message.limit !== 0) {
2875
+ writer.uint32(8).int32(message.limit);
2876
+ }
2877
+ if (message.offset !== 0) {
2878
+ writer.uint32(16).int32(message.offset);
2879
+ }
2880
+ return writer;
2881
+ },
2882
+ decode(input, length) {
2883
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2884
+ const end = length === undefined ? reader.len : reader.pos + length;
2885
+ const message = createBaseGetFollowingRequest();
2886
+ while (reader.pos < end) {
2887
+ const tag = reader.uint32();
2888
+ switch (tag >>> 3) {
2889
+ case 1: {
2890
+ if (tag !== 8) {
2891
+ break;
2892
+ }
2893
+ message.limit = reader.int32();
2894
+ continue;
2895
+ }
2896
+ case 2: {
2897
+ if (tag !== 16) {
2898
+ break;
2899
+ }
2900
+ message.offset = reader.int32();
2901
+ continue;
2902
+ }
2903
+ }
2904
+ if ((tag & 7) === 4 || tag === 0) {
2905
+ break;
2906
+ }
2907
+ reader.skip(tag & 7);
2908
+ }
2909
+ return message;
2910
+ },
2911
+ fromJSON(object) {
2912
+ return {
2913
+ limit: isSet(object.limit) ? globalThis.Number(object.limit) : 0,
2914
+ offset: isSet(object.offset) ? globalThis.Number(object.offset) : 0,
2915
+ };
2916
+ },
2917
+ toJSON(message) {
2918
+ const obj = {};
2919
+ if (message.limit !== 0) {
2920
+ obj.limit = Math.round(message.limit);
2921
+ }
2922
+ if (message.offset !== 0) {
2923
+ obj.offset = Math.round(message.offset);
2924
+ }
2925
+ return obj;
2926
+ },
2927
+ create(base) {
2928
+ return exports.GetFollowingRequest.fromPartial(base !== null && base !== void 0 ? base : {});
2929
+ },
2930
+ fromPartial(object) {
2931
+ var _a, _b;
2932
+ const message = createBaseGetFollowingRequest();
2933
+ message.limit = (_a = object.limit) !== null && _a !== void 0 ? _a : 0;
2934
+ message.offset = (_b = object.offset) !== null && _b !== void 0 ? _b : 0;
2935
+ return message;
2936
+ },
2937
+ };
2938
+ function createBaseGetFollowingResponse() {
2939
+ return { following: [], totalCount: 0 };
2940
+ }
2941
+ exports.GetFollowingResponse = {
2942
+ encode(message, writer = new wire_1.BinaryWriter()) {
2943
+ for (const v of message.following) {
2944
+ exports.Account.encode(v, writer.uint32(10).fork()).join();
2945
+ }
2946
+ if (message.totalCount !== 0) {
2947
+ writer.uint32(16).int64(message.totalCount);
2948
+ }
2949
+ return writer;
2950
+ },
2951
+ decode(input, length) {
2952
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
2953
+ const end = length === undefined ? reader.len : reader.pos + length;
2954
+ const message = createBaseGetFollowingResponse();
2955
+ while (reader.pos < end) {
2956
+ const tag = reader.uint32();
2957
+ switch (tag >>> 3) {
2958
+ case 1: {
2959
+ if (tag !== 10) {
2960
+ break;
2961
+ }
2962
+ message.following.push(exports.Account.decode(reader, reader.uint32()));
2963
+ continue;
2964
+ }
2965
+ case 2: {
2966
+ if (tag !== 16) {
2967
+ break;
2968
+ }
2969
+ message.totalCount = longToNumber(reader.int64());
2970
+ continue;
2971
+ }
2972
+ }
2973
+ if ((tag & 7) === 4 || tag === 0) {
2974
+ break;
2975
+ }
2976
+ reader.skip(tag & 7);
2977
+ }
2978
+ return message;
2979
+ },
2980
+ fromJSON(object) {
2981
+ return {
2982
+ following: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.following)
2983
+ ? object.following.map((e) => exports.Account.fromJSON(e))
2984
+ : [],
2985
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
2986
+ };
2987
+ },
2988
+ toJSON(message) {
2989
+ var _a;
2990
+ const obj = {};
2991
+ if ((_a = message.following) === null || _a === void 0 ? void 0 : _a.length) {
2992
+ obj.following = message.following.map((e) => exports.Account.toJSON(e));
2993
+ }
2994
+ if (message.totalCount !== 0) {
2995
+ obj.totalCount = Math.round(message.totalCount);
2996
+ }
2997
+ return obj;
2998
+ },
2999
+ create(base) {
3000
+ return exports.GetFollowingResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3001
+ },
3002
+ fromPartial(object) {
3003
+ var _a, _b;
3004
+ const message = createBaseGetFollowingResponse();
3005
+ message.following = ((_a = object.following) === null || _a === void 0 ? void 0 : _a.map((e) => exports.Account.fromPartial(e))) || [];
3006
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3007
+ return message;
3008
+ },
3009
+ };
3010
+ function createBaseGetAccountPostsRequest() {
3011
+ return { accountId: "", page: 0, pageSize: 0 };
3012
+ }
3013
+ exports.GetAccountPostsRequest = {
3014
+ encode(message, writer = new wire_1.BinaryWriter()) {
3015
+ if (message.accountId !== "") {
3016
+ writer.uint32(10).string(message.accountId);
3017
+ }
3018
+ if (message.page !== 0) {
3019
+ writer.uint32(16).int32(message.page);
3020
+ }
3021
+ if (message.pageSize !== 0) {
3022
+ writer.uint32(24).int32(message.pageSize);
3023
+ }
3024
+ return writer;
3025
+ },
3026
+ decode(input, length) {
3027
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3028
+ const end = length === undefined ? reader.len : reader.pos + length;
3029
+ const message = createBaseGetAccountPostsRequest();
3030
+ while (reader.pos < end) {
3031
+ const tag = reader.uint32();
3032
+ switch (tag >>> 3) {
3033
+ case 1: {
3034
+ if (tag !== 10) {
3035
+ break;
3036
+ }
3037
+ message.accountId = reader.string();
3038
+ continue;
3039
+ }
3040
+ case 2: {
3041
+ if (tag !== 16) {
3042
+ break;
3043
+ }
3044
+ message.page = reader.int32();
3045
+ continue;
3046
+ }
3047
+ case 3: {
3048
+ if (tag !== 24) {
3049
+ break;
3050
+ }
3051
+ message.pageSize = reader.int32();
3052
+ continue;
3053
+ }
3054
+ }
3055
+ if ((tag & 7) === 4 || tag === 0) {
3056
+ break;
3057
+ }
3058
+ reader.skip(tag & 7);
3059
+ }
3060
+ return message;
3061
+ },
3062
+ fromJSON(object) {
3063
+ return {
3064
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
3065
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3066
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3067
+ };
3068
+ },
3069
+ toJSON(message) {
3070
+ const obj = {};
3071
+ if (message.accountId !== "") {
3072
+ obj.accountId = message.accountId;
3073
+ }
3074
+ if (message.page !== 0) {
3075
+ obj.page = Math.round(message.page);
3076
+ }
3077
+ if (message.pageSize !== 0) {
3078
+ obj.pageSize = Math.round(message.pageSize);
3079
+ }
3080
+ return obj;
3081
+ },
3082
+ create(base) {
3083
+ return exports.GetAccountPostsRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3084
+ },
3085
+ fromPartial(object) {
3086
+ var _a, _b, _c;
3087
+ const message = createBaseGetAccountPostsRequest();
3088
+ message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
3089
+ message.page = (_b = object.page) !== null && _b !== void 0 ? _b : 0;
3090
+ message.pageSize = (_c = object.pageSize) !== null && _c !== void 0 ? _c : 0;
3091
+ return message;
3092
+ },
3093
+ };
3094
+ function createBaseGetAccountPostsResponse() {
3095
+ return { posts: [], totalCount: 0, page: 0, pageSize: 0 };
3096
+ }
3097
+ exports.GetAccountPostsResponse = {
3098
+ encode(message, writer = new wire_1.BinaryWriter()) {
3099
+ for (const v of message.posts) {
3100
+ posts_1.Post.encode(v, writer.uint32(10).fork()).join();
3101
+ }
3102
+ if (message.totalCount !== 0) {
3103
+ writer.uint32(16).int64(message.totalCount);
3104
+ }
3105
+ if (message.page !== 0) {
3106
+ writer.uint32(24).int32(message.page);
3107
+ }
3108
+ if (message.pageSize !== 0) {
3109
+ writer.uint32(32).int32(message.pageSize);
3110
+ }
3111
+ return writer;
3112
+ },
3113
+ decode(input, length) {
3114
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3115
+ const end = length === undefined ? reader.len : reader.pos + length;
3116
+ const message = createBaseGetAccountPostsResponse();
3117
+ while (reader.pos < end) {
3118
+ const tag = reader.uint32();
3119
+ switch (tag >>> 3) {
3120
+ case 1: {
3121
+ if (tag !== 10) {
3122
+ break;
3123
+ }
3124
+ message.posts.push(posts_1.Post.decode(reader, reader.uint32()));
3125
+ continue;
3126
+ }
3127
+ case 2: {
3128
+ if (tag !== 16) {
3129
+ break;
3130
+ }
3131
+ message.totalCount = longToNumber(reader.int64());
3132
+ continue;
3133
+ }
3134
+ case 3: {
3135
+ if (tag !== 24) {
3136
+ break;
3137
+ }
3138
+ message.page = reader.int32();
3139
+ continue;
3140
+ }
3141
+ case 4: {
3142
+ if (tag !== 32) {
3143
+ break;
3144
+ }
3145
+ message.pageSize = reader.int32();
3146
+ continue;
3147
+ }
3148
+ }
3149
+ if ((tag & 7) === 4 || tag === 0) {
3150
+ break;
3151
+ }
3152
+ reader.skip(tag & 7);
3153
+ }
3154
+ return message;
3155
+ },
3156
+ fromJSON(object) {
3157
+ return {
3158
+ posts: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.posts) ? object.posts.map((e) => posts_1.Post.fromJSON(e)) : [],
3159
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
3160
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3161
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3162
+ };
3163
+ },
3164
+ toJSON(message) {
3165
+ var _a;
3166
+ const obj = {};
3167
+ if ((_a = message.posts) === null || _a === void 0 ? void 0 : _a.length) {
3168
+ obj.posts = message.posts.map((e) => posts_1.Post.toJSON(e));
3169
+ }
3170
+ if (message.totalCount !== 0) {
3171
+ obj.totalCount = Math.round(message.totalCount);
3172
+ }
3173
+ if (message.page !== 0) {
3174
+ obj.page = Math.round(message.page);
3175
+ }
3176
+ if (message.pageSize !== 0) {
3177
+ obj.pageSize = Math.round(message.pageSize);
3178
+ }
3179
+ return obj;
3180
+ },
3181
+ create(base) {
3182
+ return exports.GetAccountPostsResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3183
+ },
3184
+ fromPartial(object) {
3185
+ var _a, _b, _c, _d;
3186
+ const message = createBaseGetAccountPostsResponse();
3187
+ message.posts = ((_a = object.posts) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
3188
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3189
+ message.page = (_c = object.page) !== null && _c !== void 0 ? _c : 0;
3190
+ message.pageSize = (_d = object.pageSize) !== null && _d !== void 0 ? _d : 0;
3191
+ return message;
3192
+ },
3193
+ };
3194
+ function createBaseGetAccountRepliesRequest() {
3195
+ return { accountId: "", page: 0, pageSize: 0 };
3196
+ }
3197
+ exports.GetAccountRepliesRequest = {
3198
+ encode(message, writer = new wire_1.BinaryWriter()) {
3199
+ if (message.accountId !== "") {
3200
+ writer.uint32(10).string(message.accountId);
3201
+ }
3202
+ if (message.page !== 0) {
3203
+ writer.uint32(16).int32(message.page);
3204
+ }
3205
+ if (message.pageSize !== 0) {
3206
+ writer.uint32(24).int32(message.pageSize);
3207
+ }
3208
+ return writer;
3209
+ },
3210
+ decode(input, length) {
3211
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3212
+ const end = length === undefined ? reader.len : reader.pos + length;
3213
+ const message = createBaseGetAccountRepliesRequest();
3214
+ while (reader.pos < end) {
3215
+ const tag = reader.uint32();
3216
+ switch (tag >>> 3) {
3217
+ case 1: {
3218
+ if (tag !== 10) {
3219
+ break;
3220
+ }
3221
+ message.accountId = reader.string();
3222
+ continue;
3223
+ }
3224
+ case 2: {
3225
+ if (tag !== 16) {
3226
+ break;
3227
+ }
3228
+ message.page = reader.int32();
3229
+ continue;
3230
+ }
3231
+ case 3: {
3232
+ if (tag !== 24) {
3233
+ break;
3234
+ }
3235
+ message.pageSize = reader.int32();
3236
+ continue;
3237
+ }
3238
+ }
3239
+ if ((tag & 7) === 4 || tag === 0) {
3240
+ break;
3241
+ }
3242
+ reader.skip(tag & 7);
3243
+ }
3244
+ return message;
3245
+ },
3246
+ fromJSON(object) {
3247
+ return {
3248
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
3249
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3250
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3251
+ };
3252
+ },
3253
+ toJSON(message) {
3254
+ const obj = {};
3255
+ if (message.accountId !== "") {
3256
+ obj.accountId = message.accountId;
3257
+ }
3258
+ if (message.page !== 0) {
3259
+ obj.page = Math.round(message.page);
3260
+ }
3261
+ if (message.pageSize !== 0) {
3262
+ obj.pageSize = Math.round(message.pageSize);
3263
+ }
3264
+ return obj;
3265
+ },
3266
+ create(base) {
3267
+ return exports.GetAccountRepliesRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3268
+ },
3269
+ fromPartial(object) {
3270
+ var _a, _b, _c;
3271
+ const message = createBaseGetAccountRepliesRequest();
3272
+ message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
3273
+ message.page = (_b = object.page) !== null && _b !== void 0 ? _b : 0;
3274
+ message.pageSize = (_c = object.pageSize) !== null && _c !== void 0 ? _c : 0;
3275
+ return message;
3276
+ },
3277
+ };
3278
+ function createBaseGetAccountRepliesResponse() {
3279
+ return { replies: [], totalCount: 0, page: 0, pageSize: 0 };
3280
+ }
3281
+ exports.GetAccountRepliesResponse = {
3282
+ encode(message, writer = new wire_1.BinaryWriter()) {
3283
+ for (const v of message.replies) {
3284
+ posts_1.Post.encode(v, writer.uint32(10).fork()).join();
3285
+ }
3286
+ if (message.totalCount !== 0) {
3287
+ writer.uint32(16).int64(message.totalCount);
3288
+ }
3289
+ if (message.page !== 0) {
3290
+ writer.uint32(24).int32(message.page);
3291
+ }
3292
+ if (message.pageSize !== 0) {
3293
+ writer.uint32(32).int32(message.pageSize);
3294
+ }
3295
+ return writer;
3296
+ },
3297
+ decode(input, length) {
3298
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3299
+ const end = length === undefined ? reader.len : reader.pos + length;
3300
+ const message = createBaseGetAccountRepliesResponse();
3301
+ while (reader.pos < end) {
3302
+ const tag = reader.uint32();
3303
+ switch (tag >>> 3) {
3304
+ case 1: {
3305
+ if (tag !== 10) {
3306
+ break;
3307
+ }
3308
+ message.replies.push(posts_1.Post.decode(reader, reader.uint32()));
3309
+ continue;
3310
+ }
3311
+ case 2: {
3312
+ if (tag !== 16) {
3313
+ break;
3314
+ }
3315
+ message.totalCount = longToNumber(reader.int64());
3316
+ continue;
3317
+ }
3318
+ case 3: {
3319
+ if (tag !== 24) {
3320
+ break;
3321
+ }
3322
+ message.page = reader.int32();
3323
+ continue;
3324
+ }
3325
+ case 4: {
3326
+ if (tag !== 32) {
3327
+ break;
3328
+ }
3329
+ message.pageSize = reader.int32();
3330
+ continue;
3331
+ }
3332
+ }
3333
+ if ((tag & 7) === 4 || tag === 0) {
3334
+ break;
3335
+ }
3336
+ reader.skip(tag & 7);
3337
+ }
3338
+ return message;
3339
+ },
3340
+ fromJSON(object) {
3341
+ return {
3342
+ replies: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.replies) ? object.replies.map((e) => posts_1.Post.fromJSON(e)) : [],
3343
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
3344
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3345
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3346
+ };
3347
+ },
3348
+ toJSON(message) {
3349
+ var _a;
3350
+ const obj = {};
3351
+ if ((_a = message.replies) === null || _a === void 0 ? void 0 : _a.length) {
3352
+ obj.replies = message.replies.map((e) => posts_1.Post.toJSON(e));
3353
+ }
3354
+ if (message.totalCount !== 0) {
3355
+ obj.totalCount = Math.round(message.totalCount);
3356
+ }
3357
+ if (message.page !== 0) {
3358
+ obj.page = Math.round(message.page);
3359
+ }
3360
+ if (message.pageSize !== 0) {
3361
+ obj.pageSize = Math.round(message.pageSize);
3362
+ }
3363
+ return obj;
3364
+ },
3365
+ create(base) {
3366
+ return exports.GetAccountRepliesResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3367
+ },
3368
+ fromPartial(object) {
3369
+ var _a, _b, _c, _d;
3370
+ const message = createBaseGetAccountRepliesResponse();
3371
+ message.replies = ((_a = object.replies) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
3372
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3373
+ message.page = (_c = object.page) !== null && _c !== void 0 ? _c : 0;
3374
+ message.pageSize = (_d = object.pageSize) !== null && _d !== void 0 ? _d : 0;
3375
+ return message;
3376
+ },
3377
+ };
3378
+ function createBaseGetAccountMediaRequest() {
3379
+ return { accountId: "", page: 0, pageSize: 0 };
3380
+ }
3381
+ exports.GetAccountMediaRequest = {
3382
+ encode(message, writer = new wire_1.BinaryWriter()) {
3383
+ if (message.accountId !== "") {
3384
+ writer.uint32(10).string(message.accountId);
3385
+ }
3386
+ if (message.page !== 0) {
3387
+ writer.uint32(16).int32(message.page);
3388
+ }
3389
+ if (message.pageSize !== 0) {
3390
+ writer.uint32(24).int32(message.pageSize);
3391
+ }
3392
+ return writer;
3393
+ },
3394
+ decode(input, length) {
3395
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3396
+ const end = length === undefined ? reader.len : reader.pos + length;
3397
+ const message = createBaseGetAccountMediaRequest();
3398
+ while (reader.pos < end) {
3399
+ const tag = reader.uint32();
3400
+ switch (tag >>> 3) {
3401
+ case 1: {
3402
+ if (tag !== 10) {
3403
+ break;
3404
+ }
3405
+ message.accountId = reader.string();
3406
+ continue;
3407
+ }
3408
+ case 2: {
3409
+ if (tag !== 16) {
3410
+ break;
3411
+ }
3412
+ message.page = reader.int32();
3413
+ continue;
3414
+ }
3415
+ case 3: {
3416
+ if (tag !== 24) {
3417
+ break;
3418
+ }
3419
+ message.pageSize = reader.int32();
3420
+ continue;
3421
+ }
3422
+ }
3423
+ if ((tag & 7) === 4 || tag === 0) {
3424
+ break;
3425
+ }
3426
+ reader.skip(tag & 7);
3427
+ }
3428
+ return message;
3429
+ },
3430
+ fromJSON(object) {
3431
+ return {
3432
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
3433
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3434
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3435
+ };
3436
+ },
3437
+ toJSON(message) {
3438
+ const obj = {};
3439
+ if (message.accountId !== "") {
3440
+ obj.accountId = message.accountId;
3441
+ }
3442
+ if (message.page !== 0) {
3443
+ obj.page = Math.round(message.page);
3444
+ }
3445
+ if (message.pageSize !== 0) {
3446
+ obj.pageSize = Math.round(message.pageSize);
3447
+ }
3448
+ return obj;
3449
+ },
3450
+ create(base) {
3451
+ return exports.GetAccountMediaRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3452
+ },
3453
+ fromPartial(object) {
3454
+ var _a, _b, _c;
3455
+ const message = createBaseGetAccountMediaRequest();
3456
+ message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
3457
+ message.page = (_b = object.page) !== null && _b !== void 0 ? _b : 0;
3458
+ message.pageSize = (_c = object.pageSize) !== null && _c !== void 0 ? _c : 0;
3459
+ return message;
3460
+ },
3461
+ };
3462
+ function createBaseGetAccountMediaResponse() {
3463
+ return { media: [], totalCount: 0, page: 0, pageSize: 0 };
3464
+ }
3465
+ exports.GetAccountMediaResponse = {
3466
+ encode(message, writer = new wire_1.BinaryWriter()) {
3467
+ for (const v of message.media) {
3468
+ posts_1.Post.encode(v, writer.uint32(10).fork()).join();
3469
+ }
3470
+ if (message.totalCount !== 0) {
3471
+ writer.uint32(16).int64(message.totalCount);
3472
+ }
3473
+ if (message.page !== 0) {
3474
+ writer.uint32(24).int32(message.page);
3475
+ }
3476
+ if (message.pageSize !== 0) {
3477
+ writer.uint32(32).int32(message.pageSize);
3478
+ }
3479
+ return writer;
3480
+ },
3481
+ decode(input, length) {
3482
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3483
+ const end = length === undefined ? reader.len : reader.pos + length;
3484
+ const message = createBaseGetAccountMediaResponse();
3485
+ while (reader.pos < end) {
3486
+ const tag = reader.uint32();
3487
+ switch (tag >>> 3) {
3488
+ case 1: {
3489
+ if (tag !== 10) {
3490
+ break;
3491
+ }
3492
+ message.media.push(posts_1.Post.decode(reader, reader.uint32()));
3493
+ continue;
3494
+ }
3495
+ case 2: {
3496
+ if (tag !== 16) {
3497
+ break;
3498
+ }
3499
+ message.totalCount = longToNumber(reader.int64());
3500
+ continue;
3501
+ }
3502
+ case 3: {
3503
+ if (tag !== 24) {
3504
+ break;
3505
+ }
3506
+ message.page = reader.int32();
3507
+ continue;
3508
+ }
3509
+ case 4: {
3510
+ if (tag !== 32) {
3511
+ break;
3512
+ }
3513
+ message.pageSize = reader.int32();
3514
+ continue;
3515
+ }
3516
+ }
3517
+ if ((tag & 7) === 4 || tag === 0) {
3518
+ break;
3519
+ }
3520
+ reader.skip(tag & 7);
3521
+ }
3522
+ return message;
3523
+ },
3524
+ fromJSON(object) {
3525
+ return {
3526
+ media: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.media) ? object.media.map((e) => posts_1.Post.fromJSON(e)) : [],
3527
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
3528
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3529
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3530
+ };
3531
+ },
3532
+ toJSON(message) {
3533
+ var _a;
3534
+ const obj = {};
3535
+ if ((_a = message.media) === null || _a === void 0 ? void 0 : _a.length) {
3536
+ obj.media = message.media.map((e) => posts_1.Post.toJSON(e));
3537
+ }
3538
+ if (message.totalCount !== 0) {
3539
+ obj.totalCount = Math.round(message.totalCount);
3540
+ }
3541
+ if (message.page !== 0) {
3542
+ obj.page = Math.round(message.page);
3543
+ }
3544
+ if (message.pageSize !== 0) {
3545
+ obj.pageSize = Math.round(message.pageSize);
3546
+ }
3547
+ return obj;
3548
+ },
3549
+ create(base) {
3550
+ return exports.GetAccountMediaResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3551
+ },
3552
+ fromPartial(object) {
3553
+ var _a, _b, _c, _d;
3554
+ const message = createBaseGetAccountMediaResponse();
3555
+ message.media = ((_a = object.media) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
3556
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3557
+ message.page = (_c = object.page) !== null && _c !== void 0 ? _c : 0;
3558
+ message.pageSize = (_d = object.pageSize) !== null && _d !== void 0 ? _d : 0;
3559
+ return message;
3560
+ },
3561
+ };
3562
+ function createBaseGetAccountLikesRequest() {
3563
+ return { accountId: "", page: 0, pageSize: 0 };
3564
+ }
3565
+ exports.GetAccountLikesRequest = {
3566
+ encode(message, writer = new wire_1.BinaryWriter()) {
3567
+ if (message.accountId !== "") {
3568
+ writer.uint32(10).string(message.accountId);
3569
+ }
3570
+ if (message.page !== 0) {
3571
+ writer.uint32(16).int32(message.page);
3572
+ }
3573
+ if (message.pageSize !== 0) {
3574
+ writer.uint32(24).int32(message.pageSize);
3575
+ }
3576
+ return writer;
3577
+ },
3578
+ decode(input, length) {
3579
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3580
+ const end = length === undefined ? reader.len : reader.pos + length;
3581
+ const message = createBaseGetAccountLikesRequest();
3582
+ while (reader.pos < end) {
3583
+ const tag = reader.uint32();
3584
+ switch (tag >>> 3) {
3585
+ case 1: {
3586
+ if (tag !== 10) {
3587
+ break;
3588
+ }
3589
+ message.accountId = reader.string();
3590
+ continue;
3591
+ }
3592
+ case 2: {
3593
+ if (tag !== 16) {
3594
+ break;
3595
+ }
3596
+ message.page = reader.int32();
3597
+ continue;
3598
+ }
3599
+ case 3: {
3600
+ if (tag !== 24) {
3601
+ break;
3602
+ }
3603
+ message.pageSize = reader.int32();
3604
+ continue;
3605
+ }
3606
+ }
3607
+ if ((tag & 7) === 4 || tag === 0) {
3608
+ break;
3609
+ }
3610
+ reader.skip(tag & 7);
3611
+ }
3612
+ return message;
3613
+ },
3614
+ fromJSON(object) {
3615
+ return {
3616
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
3617
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3618
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3619
+ };
3620
+ },
3621
+ toJSON(message) {
3622
+ const obj = {};
3623
+ if (message.accountId !== "") {
3624
+ obj.accountId = message.accountId;
3625
+ }
3626
+ if (message.page !== 0) {
3627
+ obj.page = Math.round(message.page);
3628
+ }
3629
+ if (message.pageSize !== 0) {
3630
+ obj.pageSize = Math.round(message.pageSize);
3631
+ }
3632
+ return obj;
3633
+ },
3634
+ create(base) {
3635
+ return exports.GetAccountLikesRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3636
+ },
3637
+ fromPartial(object) {
3638
+ var _a, _b, _c;
3639
+ const message = createBaseGetAccountLikesRequest();
3640
+ message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
3641
+ message.page = (_b = object.page) !== null && _b !== void 0 ? _b : 0;
3642
+ message.pageSize = (_c = object.pageSize) !== null && _c !== void 0 ? _c : 0;
3643
+ return message;
3644
+ },
3645
+ };
3646
+ function createBaseGetAccountLikesResponse() {
3647
+ return { likes: [], totalCount: 0, page: 0, pageSize: 0 };
3648
+ }
3649
+ exports.GetAccountLikesResponse = {
3650
+ encode(message, writer = new wire_1.BinaryWriter()) {
3651
+ for (const v of message.likes) {
3652
+ posts_1.Post.encode(v, writer.uint32(10).fork()).join();
3653
+ }
3654
+ if (message.totalCount !== 0) {
3655
+ writer.uint32(16).int64(message.totalCount);
3656
+ }
3657
+ if (message.page !== 0) {
3658
+ writer.uint32(24).int32(message.page);
3659
+ }
3660
+ if (message.pageSize !== 0) {
3661
+ writer.uint32(32).int32(message.pageSize);
3662
+ }
3663
+ return writer;
3664
+ },
3665
+ decode(input, length) {
3666
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3667
+ const end = length === undefined ? reader.len : reader.pos + length;
3668
+ const message = createBaseGetAccountLikesResponse();
3669
+ while (reader.pos < end) {
3670
+ const tag = reader.uint32();
3671
+ switch (tag >>> 3) {
3672
+ case 1: {
3673
+ if (tag !== 10) {
3674
+ break;
3675
+ }
3676
+ message.likes.push(posts_1.Post.decode(reader, reader.uint32()));
3677
+ continue;
3678
+ }
3679
+ case 2: {
3680
+ if (tag !== 16) {
3681
+ break;
3682
+ }
3683
+ message.totalCount = longToNumber(reader.int64());
3684
+ continue;
3685
+ }
3686
+ case 3: {
3687
+ if (tag !== 24) {
3688
+ break;
3689
+ }
3690
+ message.page = reader.int32();
3691
+ continue;
3692
+ }
3693
+ case 4: {
3694
+ if (tag !== 32) {
3695
+ break;
3696
+ }
3697
+ message.pageSize = reader.int32();
3698
+ continue;
3699
+ }
3700
+ }
3701
+ if ((tag & 7) === 4 || tag === 0) {
3702
+ break;
3703
+ }
3704
+ reader.skip(tag & 7);
3705
+ }
3706
+ return message;
3707
+ },
3708
+ fromJSON(object) {
3709
+ return {
3710
+ likes: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.likes) ? object.likes.map((e) => posts_1.Post.fromJSON(e)) : [],
3711
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
3712
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3713
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3714
+ };
3715
+ },
3716
+ toJSON(message) {
3717
+ var _a;
3718
+ const obj = {};
3719
+ if ((_a = message.likes) === null || _a === void 0 ? void 0 : _a.length) {
3720
+ obj.likes = message.likes.map((e) => posts_1.Post.toJSON(e));
3721
+ }
3722
+ if (message.totalCount !== 0) {
3723
+ obj.totalCount = Math.round(message.totalCount);
3724
+ }
3725
+ if (message.page !== 0) {
3726
+ obj.page = Math.round(message.page);
3727
+ }
3728
+ if (message.pageSize !== 0) {
3729
+ obj.pageSize = Math.round(message.pageSize);
3730
+ }
3731
+ return obj;
3732
+ },
3733
+ create(base) {
3734
+ return exports.GetAccountLikesResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3735
+ },
3736
+ fromPartial(object) {
3737
+ var _a, _b, _c, _d;
3738
+ const message = createBaseGetAccountLikesResponse();
3739
+ message.likes = ((_a = object.likes) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
3740
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3741
+ message.page = (_c = object.page) !== null && _c !== void 0 ? _c : 0;
3742
+ message.pageSize = (_d = object.pageSize) !== null && _d !== void 0 ? _d : 0;
3743
+ return message;
3744
+ },
3745
+ };
3746
+ function createBaseGetAccountRepostsRequest() {
3747
+ return { accountId: "", page: 0, pageSize: 0 };
3748
+ }
3749
+ exports.GetAccountRepostsRequest = {
3750
+ encode(message, writer = new wire_1.BinaryWriter()) {
3751
+ if (message.accountId !== "") {
3752
+ writer.uint32(10).string(message.accountId);
3753
+ }
3754
+ if (message.page !== 0) {
3755
+ writer.uint32(16).int32(message.page);
3756
+ }
3757
+ if (message.pageSize !== 0) {
3758
+ writer.uint32(24).int32(message.pageSize);
3759
+ }
3760
+ return writer;
3761
+ },
3762
+ decode(input, length) {
3763
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3764
+ const end = length === undefined ? reader.len : reader.pos + length;
3765
+ const message = createBaseGetAccountRepostsRequest();
3766
+ while (reader.pos < end) {
3767
+ const tag = reader.uint32();
3768
+ switch (tag >>> 3) {
3769
+ case 1: {
3770
+ if (tag !== 10) {
3771
+ break;
3772
+ }
3773
+ message.accountId = reader.string();
3774
+ continue;
3775
+ }
3776
+ case 2: {
3777
+ if (tag !== 16) {
3778
+ break;
3779
+ }
3780
+ message.page = reader.int32();
3781
+ continue;
3782
+ }
3783
+ case 3: {
3784
+ if (tag !== 24) {
3785
+ break;
3786
+ }
3787
+ message.pageSize = reader.int32();
3788
+ continue;
3789
+ }
3790
+ }
3791
+ if ((tag & 7) === 4 || tag === 0) {
3792
+ break;
3793
+ }
3794
+ reader.skip(tag & 7);
3795
+ }
3796
+ return message;
3797
+ },
3798
+ fromJSON(object) {
3799
+ return {
3800
+ accountId: isSet(object.accountId) ? globalThis.String(object.accountId) : "",
3801
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3802
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3803
+ };
3804
+ },
3805
+ toJSON(message) {
3806
+ const obj = {};
3807
+ if (message.accountId !== "") {
3808
+ obj.accountId = message.accountId;
3809
+ }
3810
+ if (message.page !== 0) {
3811
+ obj.page = Math.round(message.page);
3812
+ }
3813
+ if (message.pageSize !== 0) {
3814
+ obj.pageSize = Math.round(message.pageSize);
3815
+ }
3816
+ return obj;
3817
+ },
3818
+ create(base) {
3819
+ return exports.GetAccountRepostsRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3820
+ },
3821
+ fromPartial(object) {
3822
+ var _a, _b, _c;
3823
+ const message = createBaseGetAccountRepostsRequest();
3824
+ message.accountId = (_a = object.accountId) !== null && _a !== void 0 ? _a : "";
3825
+ message.page = (_b = object.page) !== null && _b !== void 0 ? _b : 0;
3826
+ message.pageSize = (_c = object.pageSize) !== null && _c !== void 0 ? _c : 0;
3827
+ return message;
3828
+ },
3829
+ };
3830
+ function createBaseGetAccountRepostsResponse() {
3831
+ return { reposts: [], totalCount: 0, page: 0, pageSize: 0 };
3832
+ }
3833
+ exports.GetAccountRepostsResponse = {
3834
+ encode(message, writer = new wire_1.BinaryWriter()) {
3835
+ for (const v of message.reposts) {
3836
+ posts_1.Post.encode(v, writer.uint32(10).fork()).join();
3837
+ }
3838
+ if (message.totalCount !== 0) {
3839
+ writer.uint32(16).int64(message.totalCount);
3840
+ }
3841
+ if (message.page !== 0) {
3842
+ writer.uint32(24).int32(message.page);
3843
+ }
3844
+ if (message.pageSize !== 0) {
3845
+ writer.uint32(32).int32(message.pageSize);
3846
+ }
3847
+ return writer;
3848
+ },
3849
+ decode(input, length) {
3850
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3851
+ const end = length === undefined ? reader.len : reader.pos + length;
3852
+ const message = createBaseGetAccountRepostsResponse();
3853
+ while (reader.pos < end) {
3854
+ const tag = reader.uint32();
3855
+ switch (tag >>> 3) {
3856
+ case 1: {
3857
+ if (tag !== 10) {
3858
+ break;
3859
+ }
3860
+ message.reposts.push(posts_1.Post.decode(reader, reader.uint32()));
3861
+ continue;
3862
+ }
3863
+ case 2: {
3864
+ if (tag !== 16) {
3865
+ break;
3866
+ }
3867
+ message.totalCount = longToNumber(reader.int64());
3868
+ continue;
3869
+ }
3870
+ case 3: {
3871
+ if (tag !== 24) {
3872
+ break;
3873
+ }
3874
+ message.page = reader.int32();
3875
+ continue;
3876
+ }
3877
+ case 4: {
3878
+ if (tag !== 32) {
3879
+ break;
3880
+ }
3881
+ message.pageSize = reader.int32();
3882
+ continue;
3883
+ }
3884
+ }
3885
+ if ((tag & 7) === 4 || tag === 0) {
3886
+ break;
3887
+ }
3888
+ reader.skip(tag & 7);
3889
+ }
3890
+ return message;
3891
+ },
3892
+ fromJSON(object) {
3893
+ return {
3894
+ reposts: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.reposts) ? object.reposts.map((e) => posts_1.Post.fromJSON(e)) : [],
3895
+ totalCount: isSet(object.totalCount) ? globalThis.Number(object.totalCount) : 0,
3896
+ page: isSet(object.page) ? globalThis.Number(object.page) : 0,
3897
+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,
3898
+ };
3899
+ },
3900
+ toJSON(message) {
3901
+ var _a;
3902
+ const obj = {};
3903
+ if ((_a = message.reposts) === null || _a === void 0 ? void 0 : _a.length) {
3904
+ obj.reposts = message.reposts.map((e) => posts_1.Post.toJSON(e));
3905
+ }
3906
+ if (message.totalCount !== 0) {
3907
+ obj.totalCount = Math.round(message.totalCount);
3908
+ }
3909
+ if (message.page !== 0) {
3910
+ obj.page = Math.round(message.page);
3911
+ }
3912
+ if (message.pageSize !== 0) {
3913
+ obj.pageSize = Math.round(message.pageSize);
3914
+ }
3915
+ return obj;
3916
+ },
3917
+ create(base) {
3918
+ return exports.GetAccountRepostsResponse.fromPartial(base !== null && base !== void 0 ? base : {});
3919
+ },
3920
+ fromPartial(object) {
3921
+ var _a, _b, _c, _d;
3922
+ const message = createBaseGetAccountRepostsResponse();
3923
+ message.reposts = ((_a = object.reposts) === null || _a === void 0 ? void 0 : _a.map((e) => posts_1.Post.fromPartial(e))) || [];
3924
+ message.totalCount = (_b = object.totalCount) !== null && _b !== void 0 ? _b : 0;
3925
+ message.page = (_c = object.page) !== null && _c !== void 0 ? _c : 0;
3926
+ message.pageSize = (_d = object.pageSize) !== null && _d !== void 0 ? _d : 0;
3927
+ return message;
3928
+ },
3929
+ };
3930
+ function createBaseGetStatusRequest() {
3931
+ return {};
3932
+ }
3933
+ exports.GetStatusRequest = {
3934
+ encode(_, writer = new wire_1.BinaryWriter()) {
3935
+ return writer;
3936
+ },
3937
+ decode(input, length) {
3938
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3939
+ const end = length === undefined ? reader.len : reader.pos + length;
3940
+ const message = createBaseGetStatusRequest();
3941
+ while (reader.pos < end) {
3942
+ const tag = reader.uint32();
3943
+ switch (tag >>> 3) {
3944
+ }
3945
+ if ((tag & 7) === 4 || tag === 0) {
3946
+ break;
3947
+ }
3948
+ reader.skip(tag & 7);
3949
+ }
3950
+ return message;
3951
+ },
3952
+ fromJSON(_) {
3953
+ return {};
3954
+ },
3955
+ toJSON(_) {
3956
+ const obj = {};
3957
+ return obj;
3958
+ },
3959
+ create(base) {
3960
+ return exports.GetStatusRequest.fromPartial(base !== null && base !== void 0 ? base : {});
3961
+ },
3962
+ fromPartial(_) {
3963
+ const message = createBaseGetStatusRequest();
3964
+ return message;
3965
+ },
3966
+ };
3967
+ function createBaseGetStatusResponse() {
3968
+ return { status: "", service: "" };
3969
+ }
3970
+ exports.GetStatusResponse = {
3971
+ encode(message, writer = new wire_1.BinaryWriter()) {
3972
+ if (message.status !== "") {
3973
+ writer.uint32(10).string(message.status);
3974
+ }
3975
+ if (message.service !== "") {
3976
+ writer.uint32(18).string(message.service);
3977
+ }
3978
+ return writer;
3979
+ },
3980
+ decode(input, length) {
3981
+ const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
3982
+ const end = length === undefined ? reader.len : reader.pos + length;
3983
+ const message = createBaseGetStatusResponse();
3984
+ while (reader.pos < end) {
3985
+ const tag = reader.uint32();
3986
+ switch (tag >>> 3) {
3987
+ case 1: {
3988
+ if (tag !== 10) {
3989
+ break;
3990
+ }
3991
+ message.status = reader.string();
3992
+ continue;
3993
+ }
3994
+ case 2: {
3995
+ if (tag !== 18) {
3996
+ break;
3997
+ }
3998
+ message.service = reader.string();
3999
+ continue;
4000
+ }
4001
+ }
4002
+ if ((tag & 7) === 4 || tag === 0) {
4003
+ break;
4004
+ }
4005
+ reader.skip(tag & 7);
4006
+ }
4007
+ return message;
4008
+ },
4009
+ fromJSON(object) {
4010
+ return {
4011
+ status: isSet(object.status) ? globalThis.String(object.status) : "",
4012
+ service: isSet(object.service) ? globalThis.String(object.service) : "",
4013
+ };
4014
+ },
4015
+ toJSON(message) {
4016
+ const obj = {};
4017
+ if (message.status !== "") {
4018
+ obj.status = message.status;
4019
+ }
4020
+ if (message.service !== "") {
4021
+ obj.service = message.service;
4022
+ }
4023
+ return obj;
4024
+ },
4025
+ create(base) {
4026
+ return exports.GetStatusResponse.fromPartial(base !== null && base !== void 0 ? base : {});
4027
+ },
4028
+ fromPartial(object) {
4029
+ var _a, _b;
4030
+ const message = createBaseGetStatusResponse();
4031
+ message.status = (_a = object.status) !== null && _a !== void 0 ? _a : "";
4032
+ message.service = (_b = object.service) !== null && _b !== void 0 ? _b : "";
4033
+ return message;
4034
+ },
4035
+ };
4036
+ exports.AccountServiceDefinition = {
4037
+ name: "AccountService",
4038
+ fullName: "pb.AccountService",
4039
+ methods: {
4040
+ getStatus: {
4041
+ name: "GetStatus",
4042
+ requestType: exports.GetStatusRequest,
4043
+ requestStream: false,
4044
+ responseType: exports.GetStatusResponse,
4045
+ responseStream: false,
4046
+ options: {
4047
+ _unknownFields: {
4048
+ 578365826: [
4049
+ new Uint8Array([
4050
+ 24,
4051
+ 18,
4052
+ 22,
4053
+ 47,
4054
+ 97,
4055
+ 112,
4056
+ 105,
4057
+ 47,
4058
+ 118,
4059
+ 49,
4060
+ 47,
4061
+ 97,
4062
+ 99,
4063
+ 99,
4064
+ 111,
4065
+ 117,
4066
+ 110,
4067
+ 116,
4068
+ 47,
4069
+ 115,
4070
+ 116,
4071
+ 97,
4072
+ 116,
4073
+ 117,
4074
+ 115,
4075
+ ]),
4076
+ ],
4077
+ },
4078
+ },
4079
+ },
4080
+ getProfile: {
4081
+ name: "GetProfile",
4082
+ requestType: exports.GetProfileRequest,
4083
+ requestStream: false,
4084
+ responseType: exports.GetProfileResponse,
4085
+ responseStream: false,
4086
+ options: {
4087
+ _unknownFields: {
4088
+ 578365826: [
4089
+ new Uint8Array([
4090
+ 25,
4091
+ 18,
4092
+ 23,
4093
+ 47,
4094
+ 97,
4095
+ 112,
4096
+ 105,
4097
+ 47,
4098
+ 118,
4099
+ 49,
4100
+ 47,
4101
+ 97,
4102
+ 99,
4103
+ 99,
4104
+ 111,
4105
+ 117,
4106
+ 110,
4107
+ 116,
4108
+ 47,
4109
+ 112,
4110
+ 114,
4111
+ 111,
4112
+ 102,
4113
+ 105,
4114
+ 108,
4115
+ 101,
4116
+ ]),
4117
+ ],
4118
+ },
4119
+ },
4120
+ },
4121
+ getAccountPosts: {
4122
+ name: "GetAccountPosts",
4123
+ requestType: exports.GetAccountPostsRequest,
4124
+ requestStream: false,
4125
+ responseType: exports.GetAccountPostsResponse,
4126
+ responseStream: false,
4127
+ options: {
4128
+ _unknownFields: {
4129
+ 578365826: [
4130
+ new Uint8Array([
4131
+ 23,
4132
+ 18,
4133
+ 21,
4134
+ 47,
4135
+ 97,
4136
+ 112,
4137
+ 105,
4138
+ 47,
4139
+ 118,
4140
+ 49,
4141
+ 47,
4142
+ 97,
4143
+ 99,
4144
+ 99,
4145
+ 111,
4146
+ 117,
4147
+ 110,
4148
+ 116,
4149
+ 47,
4150
+ 112,
4151
+ 111,
4152
+ 115,
4153
+ 116,
4154
+ 115,
4155
+ ]),
4156
+ ],
4157
+ },
4158
+ },
4159
+ },
4160
+ getAccountReplies: {
4161
+ name: "GetAccountReplies",
4162
+ requestType: exports.GetAccountRepliesRequest,
4163
+ requestStream: false,
4164
+ responseType: exports.GetAccountRepliesResponse,
4165
+ responseStream: false,
4166
+ options: {
4167
+ _unknownFields: {
4168
+ 578365826: [
4169
+ new Uint8Array([
4170
+ 25,
4171
+ 18,
4172
+ 23,
4173
+ 47,
4174
+ 97,
4175
+ 112,
4176
+ 105,
4177
+ 47,
4178
+ 118,
4179
+ 49,
4180
+ 47,
4181
+ 97,
4182
+ 99,
4183
+ 99,
4184
+ 111,
4185
+ 117,
4186
+ 110,
4187
+ 116,
4188
+ 47,
4189
+ 114,
4190
+ 101,
4191
+ 112,
4192
+ 108,
4193
+ 105,
4194
+ 101,
4195
+ 115,
4196
+ ]),
4197
+ ],
4198
+ },
4199
+ },
4200
+ },
4201
+ getAccountMedia: {
4202
+ name: "GetAccountMedia",
4203
+ requestType: exports.GetAccountMediaRequest,
4204
+ requestStream: false,
4205
+ responseType: exports.GetAccountMediaResponse,
4206
+ responseStream: false,
4207
+ options: {
4208
+ _unknownFields: {
4209
+ 578365826: [
4210
+ new Uint8Array([
4211
+ 23,
4212
+ 18,
4213
+ 21,
4214
+ 47,
4215
+ 97,
4216
+ 112,
4217
+ 105,
4218
+ 47,
4219
+ 118,
4220
+ 49,
4221
+ 47,
4222
+ 97,
4223
+ 99,
4224
+ 99,
4225
+ 111,
4226
+ 117,
4227
+ 110,
4228
+ 116,
4229
+ 47,
4230
+ 109,
4231
+ 101,
4232
+ 100,
4233
+ 105,
4234
+ 97,
4235
+ ]),
4236
+ ],
4237
+ },
4238
+ },
4239
+ },
4240
+ getAccountLikes: {
4241
+ name: "GetAccountLikes",
4242
+ requestType: exports.GetAccountLikesRequest,
4243
+ requestStream: false,
4244
+ responseType: exports.GetAccountLikesResponse,
4245
+ responseStream: false,
4246
+ options: {
4247
+ _unknownFields: {
4248
+ 578365826: [
4249
+ new Uint8Array([
4250
+ 23,
4251
+ 18,
4252
+ 21,
4253
+ 47,
4254
+ 97,
4255
+ 112,
4256
+ 105,
4257
+ 47,
4258
+ 118,
4259
+ 49,
4260
+ 47,
4261
+ 97,
4262
+ 99,
4263
+ 99,
4264
+ 111,
4265
+ 117,
4266
+ 110,
4267
+ 116,
4268
+ 47,
4269
+ 108,
4270
+ 105,
4271
+ 107,
4272
+ 101,
4273
+ 115,
4274
+ ]),
4275
+ ],
4276
+ },
4277
+ },
4278
+ },
4279
+ getAccountReposts: {
4280
+ name: "GetAccountReposts",
4281
+ requestType: exports.GetAccountRepostsRequest,
4282
+ requestStream: false,
4283
+ responseType: exports.GetAccountRepostsResponse,
4284
+ responseStream: false,
4285
+ options: {
4286
+ _unknownFields: {
4287
+ 578365826: [
4288
+ new Uint8Array([
4289
+ 25,
4290
+ 18,
4291
+ 23,
4292
+ 47,
4293
+ 97,
4294
+ 112,
4295
+ 105,
4296
+ 47,
4297
+ 118,
4298
+ 49,
4299
+ 47,
4300
+ 97,
4301
+ 99,
4302
+ 99,
4303
+ 111,
4304
+ 117,
4305
+ 110,
4306
+ 116,
4307
+ 47,
4308
+ 114,
4309
+ 101,
4310
+ 112,
4311
+ 111,
4312
+ 115,
4313
+ 116,
4314
+ 115,
4315
+ ]),
4316
+ ],
4317
+ },
4318
+ },
4319
+ },
4320
+ updateProfile: {
4321
+ name: "UpdateProfile",
4322
+ requestType: exports.UpdateProfileRequest,
4323
+ requestStream: false,
4324
+ responseType: exports.UpdateProfileResponse,
4325
+ responseStream: false,
4326
+ options: {
4327
+ _unknownFields: {
4328
+ 578365826: [
4329
+ new Uint8Array([
4330
+ 28,
4331
+ 26,
4332
+ 23,
4333
+ 47,
4334
+ 97,
4335
+ 112,
4336
+ 105,
4337
+ 47,
4338
+ 118,
4339
+ 49,
4340
+ 47,
4341
+ 97,
4342
+ 99,
4343
+ 99,
4344
+ 111,
4345
+ 117,
4346
+ 110,
4347
+ 116,
4348
+ 47,
4349
+ 112,
4350
+ 114,
4351
+ 111,
4352
+ 102,
4353
+ 105,
4354
+ 108,
4355
+ 101,
4356
+ 58,
4357
+ 1,
4358
+ 42,
4359
+ ]),
4360
+ ],
4361
+ },
4362
+ },
4363
+ },
4364
+ updatePassword: {
4365
+ name: "UpdatePassword",
4366
+ requestType: exports.UpdatePasswordRequest,
4367
+ requestStream: false,
4368
+ responseType: common_1.DeleteResponse,
1999
4369
  responseStream: false,
2000
4370
  options: {
2001
4371
  _unknownFields: {
@@ -2179,6 +4549,193 @@ exports.AccountServiceDefinition = {
2179
4549
  },
2180
4550
  },
2181
4551
  },
4552
+ followUser: {
4553
+ name: "FollowUser",
4554
+ requestType: exports.FollowUserRequest,
4555
+ requestStream: false,
4556
+ responseType: exports.FollowUserResponse,
4557
+ responseStream: false,
4558
+ options: {
4559
+ _unknownFields: {
4560
+ 578365826: [
4561
+ new Uint8Array([
4562
+ 36,
4563
+ 34,
4564
+ 31,
4565
+ 47,
4566
+ 97,
4567
+ 112,
4568
+ 105,
4569
+ 47,
4570
+ 118,
4571
+ 49,
4572
+ 47,
4573
+ 97,
4574
+ 99,
4575
+ 99,
4576
+ 111,
4577
+ 117,
4578
+ 110,
4579
+ 116,
4580
+ 47,
4581
+ 102,
4582
+ 111,
4583
+ 108,
4584
+ 108,
4585
+ 111,
4586
+ 119,
4587
+ 47,
4588
+ 123,
4589
+ 117,
4590
+ 115,
4591
+ 101,
4592
+ 114,
4593
+ 73,
4594
+ 100,
4595
+ 125,
4596
+ 58,
4597
+ 1,
4598
+ 42,
4599
+ ]),
4600
+ ],
4601
+ },
4602
+ },
4603
+ },
4604
+ unfollowUser: {
4605
+ name: "UnfollowUser",
4606
+ requestType: exports.UnfollowUserRequest,
4607
+ requestStream: false,
4608
+ responseType: exports.UnfollowUserResponse,
4609
+ responseStream: false,
4610
+ options: {
4611
+ _unknownFields: {
4612
+ 578365826: [
4613
+ new Uint8Array([
4614
+ 33,
4615
+ 42,
4616
+ 31,
4617
+ 47,
4618
+ 97,
4619
+ 112,
4620
+ 105,
4621
+ 47,
4622
+ 118,
4623
+ 49,
4624
+ 47,
4625
+ 97,
4626
+ 99,
4627
+ 99,
4628
+ 111,
4629
+ 117,
4630
+ 110,
4631
+ 116,
4632
+ 47,
4633
+ 102,
4634
+ 111,
4635
+ 108,
4636
+ 108,
4637
+ 111,
4638
+ 119,
4639
+ 47,
4640
+ 123,
4641
+ 117,
4642
+ 115,
4643
+ 101,
4644
+ 114,
4645
+ 73,
4646
+ 100,
4647
+ 125,
4648
+ ]),
4649
+ ],
4650
+ },
4651
+ },
4652
+ },
4653
+ getFollowers: {
4654
+ name: "GetFollowers",
4655
+ requestType: exports.GetFollowersRequest,
4656
+ requestStream: false,
4657
+ responseType: exports.GetFollowersResponse,
4658
+ responseStream: false,
4659
+ options: {
4660
+ _unknownFields: {
4661
+ 578365826: [
4662
+ new Uint8Array([
4663
+ 27,
4664
+ 18,
4665
+ 25,
4666
+ 47,
4667
+ 97,
4668
+ 112,
4669
+ 105,
4670
+ 47,
4671
+ 118,
4672
+ 49,
4673
+ 47,
4674
+ 97,
4675
+ 99,
4676
+ 99,
4677
+ 111,
4678
+ 117,
4679
+ 110,
4680
+ 116,
4681
+ 47,
4682
+ 102,
4683
+ 111,
4684
+ 108,
4685
+ 108,
4686
+ 111,
4687
+ 119,
4688
+ 101,
4689
+ 114,
4690
+ 115,
4691
+ ]),
4692
+ ],
4693
+ },
4694
+ },
4695
+ },
4696
+ getFollowing: {
4697
+ name: "GetFollowing",
4698
+ requestType: exports.GetFollowingRequest,
4699
+ requestStream: false,
4700
+ responseType: exports.GetFollowingResponse,
4701
+ responseStream: false,
4702
+ options: {
4703
+ _unknownFields: {
4704
+ 578365826: [
4705
+ new Uint8Array([
4706
+ 27,
4707
+ 18,
4708
+ 25,
4709
+ 47,
4710
+ 97,
4711
+ 112,
4712
+ 105,
4713
+ 47,
4714
+ 118,
4715
+ 49,
4716
+ 47,
4717
+ 97,
4718
+ 99,
4719
+ 99,
4720
+ 111,
4721
+ 117,
4722
+ 110,
4723
+ 116,
4724
+ 47,
4725
+ 102,
4726
+ 111,
4727
+ 108,
4728
+ 108,
4729
+ 111,
4730
+ 119,
4731
+ 105,
4732
+ 110,
4733
+ 103,
4734
+ ]),
4735
+ ],
4736
+ },
4737
+ },
4738
+ },
2182
4739
  },
2183
4740
  };
2184
4741
  function bytesFromBase64(b64) {
@@ -2206,6 +4763,16 @@ function base64FromBytes(arr) {
2206
4763
  return globalThis.btoa(bin.join(""));
2207
4764
  }
2208
4765
  }
4766
+ function longToNumber(int64) {
4767
+ const num = globalThis.Number(int64.toString());
4768
+ if (num > globalThis.Number.MAX_SAFE_INTEGER) {
4769
+ throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
4770
+ }
4771
+ if (num < globalThis.Number.MIN_SAFE_INTEGER) {
4772
+ throw new globalThis.Error("Value is smaller than Number.MIN_SAFE_INTEGER");
4773
+ }
4774
+ return num;
4775
+ }
2209
4776
  function isSet(value) {
2210
4777
  return value !== null && value !== undefined;
2211
4778
  }