protobuf-platform 1.2.120 → 1.2.122

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "protobuf-platform",
3
- "version": "1.2.120",
3
+ "version": "1.2.122",
4
4
  "description": "Protobuf structures",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -21,7 +21,10 @@
21
21
  },
22
22
  "homepage": "https://gitlab.com/platform5334443/backend/protobuf#readme",
23
23
  "dependencies": {
24
- "@grpc/grpc-js": "^1.12.2",
25
24
  "google-protobuf": "^3.21.4"
25
+ },
26
+ "devDependencies": {
27
+ "@grpc/grpc-js": "^1.14.1",
28
+ "grpc-tools": "^1.13.0"
26
29
  }
27
30
  }
package/sport/sport.proto CHANGED
@@ -6,6 +6,8 @@ service Sport {
6
6
  rpc checkConnection(PingRequest) returns (PongResponse);
7
7
  // Launch Betby sportsbook widget for user or guest.
8
8
  rpc launchBetby(LaunchBetbyRequest) returns (LaunchBetbyResponse);
9
+ //Vendor
10
+ rpc processedVendorActionCallback(VendorActionRequest) returns (VendorActionResponse);
9
11
  }
10
12
  message PingRequest { string ping = 1; }
11
13
  message PongResponse { string pong = 1; }
@@ -42,4 +44,11 @@ message LaunchBetbyResponse {
42
44
 
43
45
  // Launch mode: "guest" or "player".
44
46
  optional string mode = 2;
47
+ }
48
+ //Vendor
49
+ message VendorActionRequest {
50
+ string data = 1;
51
+ }
52
+ message VendorActionResponse {
53
+ string data = 1;
45
54
  }
@@ -48,6 +48,28 @@ function deserialize_sport_PongResponse(buffer_arg) {
48
48
  return sport_pb.PongResponse.deserializeBinary(new Uint8Array(buffer_arg));
49
49
  }
50
50
 
51
+ function serialize_sport_VendorActionRequest(arg) {
52
+ if (!(arg instanceof sport_pb.VendorActionRequest)) {
53
+ throw new Error('Expected argument of type sport.VendorActionRequest');
54
+ }
55
+ return Buffer.from(arg.serializeBinary());
56
+ }
57
+
58
+ function deserialize_sport_VendorActionRequest(buffer_arg) {
59
+ return sport_pb.VendorActionRequest.deserializeBinary(new Uint8Array(buffer_arg));
60
+ }
61
+
62
+ function serialize_sport_VendorActionResponse(arg) {
63
+ if (!(arg instanceof sport_pb.VendorActionResponse)) {
64
+ throw new Error('Expected argument of type sport.VendorActionResponse');
65
+ }
66
+ return Buffer.from(arg.serializeBinary());
67
+ }
68
+
69
+ function deserialize_sport_VendorActionResponse(buffer_arg) {
70
+ return sport_pb.VendorActionResponse.deserializeBinary(new Uint8Array(buffer_arg));
71
+ }
72
+
51
73
 
52
74
  var SportService = exports.SportService = {
53
75
  checkConnection: {
@@ -73,6 +95,18 @@ launchBetby: {
73
95
  responseSerialize: serialize_sport_LaunchBetbyResponse,
74
96
  responseDeserialize: deserialize_sport_LaunchBetbyResponse,
75
97
  },
98
+ // Vendor
99
+ processedVendorActionCallback: {
100
+ path: '/sport.Sport/processedVendorActionCallback',
101
+ requestStream: false,
102
+ responseStream: false,
103
+ requestType: sport_pb.VendorActionRequest,
104
+ responseType: sport_pb.VendorActionResponse,
105
+ requestSerialize: serialize_sport_VendorActionRequest,
106
+ requestDeserialize: deserialize_sport_VendorActionRequest,
107
+ responseSerialize: serialize_sport_VendorActionResponse,
108
+ responseDeserialize: deserialize_sport_VendorActionResponse,
109
+ },
76
110
  };
77
111
 
78
112
  exports.SportClient = grpc.makeGenericClientConstructor(SportService, 'Sport');
package/sport/sport_pb.js CHANGED
@@ -26,6 +26,8 @@ goog.exportSymbol('proto.sport.LaunchBetbyResponse', null, global);
26
26
  goog.exportSymbol('proto.sport.PaginationRequest', null, global);
27
27
  goog.exportSymbol('proto.sport.PingRequest', null, global);
28
28
  goog.exportSymbol('proto.sport.PongResponse', null, global);
29
+ goog.exportSymbol('proto.sport.VendorActionRequest', null, global);
30
+ goog.exportSymbol('proto.sport.VendorActionResponse', null, global);
29
31
  /**
30
32
  * Generated by JsPbCodeGenerator.
31
33
  * @param {Array=} opt_data Optional initial data array, typically from a
@@ -131,6 +133,48 @@ if (goog.DEBUG && !COMPILED) {
131
133
  */
132
134
  proto.sport.LaunchBetbyResponse.displayName = 'proto.sport.LaunchBetbyResponse';
133
135
  }
136
+ /**
137
+ * Generated by JsPbCodeGenerator.
138
+ * @param {Array=} opt_data Optional initial data array, typically from a
139
+ * server response, or constructed directly in Javascript. The array is used
140
+ * in place and becomes part of the constructed object. It is not cloned.
141
+ * If no data is provided, the constructed object will be empty, but still
142
+ * valid.
143
+ * @extends {jspb.Message}
144
+ * @constructor
145
+ */
146
+ proto.sport.VendorActionRequest = function(opt_data) {
147
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
148
+ };
149
+ goog.inherits(proto.sport.VendorActionRequest, jspb.Message);
150
+ if (goog.DEBUG && !COMPILED) {
151
+ /**
152
+ * @public
153
+ * @override
154
+ */
155
+ proto.sport.VendorActionRequest.displayName = 'proto.sport.VendorActionRequest';
156
+ }
157
+ /**
158
+ * Generated by JsPbCodeGenerator.
159
+ * @param {Array=} opt_data Optional initial data array, typically from a
160
+ * server response, or constructed directly in Javascript. The array is used
161
+ * in place and becomes part of the constructed object. It is not cloned.
162
+ * If no data is provided, the constructed object will be empty, but still
163
+ * valid.
164
+ * @extends {jspb.Message}
165
+ * @constructor
166
+ */
167
+ proto.sport.VendorActionResponse = function(opt_data) {
168
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
169
+ };
170
+ goog.inherits(proto.sport.VendorActionResponse, jspb.Message);
171
+ if (goog.DEBUG && !COMPILED) {
172
+ /**
173
+ * @public
174
+ * @override
175
+ */
176
+ proto.sport.VendorActionResponse.displayName = 'proto.sport.VendorActionResponse';
177
+ }
134
178
 
135
179
 
136
180
 
@@ -1213,4 +1257,264 @@ proto.sport.LaunchBetbyResponse.prototype.hasMode = function() {
1213
1257
  };
1214
1258
 
1215
1259
 
1260
+
1261
+
1262
+
1263
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1264
+ /**
1265
+ * Creates an object representation of this proto.
1266
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1267
+ * Optional fields that are not set will be set to undefined.
1268
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1269
+ * For the list of reserved names please see:
1270
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1271
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1272
+ * JSPB instance for transitional soy proto support:
1273
+ * http://goto/soy-param-migration
1274
+ * @return {!Object}
1275
+ */
1276
+ proto.sport.VendorActionRequest.prototype.toObject = function(opt_includeInstance) {
1277
+ return proto.sport.VendorActionRequest.toObject(opt_includeInstance, this);
1278
+ };
1279
+
1280
+
1281
+ /**
1282
+ * Static version of the {@see toObject} method.
1283
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1284
+ * the JSPB instance for transitional soy proto support:
1285
+ * http://goto/soy-param-migration
1286
+ * @param {!proto.sport.VendorActionRequest} msg The msg instance to transform.
1287
+ * @return {!Object}
1288
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1289
+ */
1290
+ proto.sport.VendorActionRequest.toObject = function(includeInstance, msg) {
1291
+ var f, obj = {
1292
+ data: jspb.Message.getFieldWithDefault(msg, 1, "")
1293
+ };
1294
+
1295
+ if (includeInstance) {
1296
+ obj.$jspbMessageInstance = msg;
1297
+ }
1298
+ return obj;
1299
+ };
1300
+ }
1301
+
1302
+
1303
+ /**
1304
+ * Deserializes binary data (in protobuf wire format).
1305
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1306
+ * @return {!proto.sport.VendorActionRequest}
1307
+ */
1308
+ proto.sport.VendorActionRequest.deserializeBinary = function(bytes) {
1309
+ var reader = new jspb.BinaryReader(bytes);
1310
+ var msg = new proto.sport.VendorActionRequest;
1311
+ return proto.sport.VendorActionRequest.deserializeBinaryFromReader(msg, reader);
1312
+ };
1313
+
1314
+
1315
+ /**
1316
+ * Deserializes binary data (in protobuf wire format) from the
1317
+ * given reader into the given message object.
1318
+ * @param {!proto.sport.VendorActionRequest} msg The message object to deserialize into.
1319
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1320
+ * @return {!proto.sport.VendorActionRequest}
1321
+ */
1322
+ proto.sport.VendorActionRequest.deserializeBinaryFromReader = function(msg, reader) {
1323
+ while (reader.nextField()) {
1324
+ if (reader.isEndGroup()) {
1325
+ break;
1326
+ }
1327
+ var field = reader.getFieldNumber();
1328
+ switch (field) {
1329
+ case 1:
1330
+ var value = /** @type {string} */ (reader.readString());
1331
+ msg.setData(value);
1332
+ break;
1333
+ default:
1334
+ reader.skipField();
1335
+ break;
1336
+ }
1337
+ }
1338
+ return msg;
1339
+ };
1340
+
1341
+
1342
+ /**
1343
+ * Serializes the message to binary data (in protobuf wire format).
1344
+ * @return {!Uint8Array}
1345
+ */
1346
+ proto.sport.VendorActionRequest.prototype.serializeBinary = function() {
1347
+ var writer = new jspb.BinaryWriter();
1348
+ proto.sport.VendorActionRequest.serializeBinaryToWriter(this, writer);
1349
+ return writer.getResultBuffer();
1350
+ };
1351
+
1352
+
1353
+ /**
1354
+ * Serializes the given message to binary data (in protobuf wire
1355
+ * format), writing to the given BinaryWriter.
1356
+ * @param {!proto.sport.VendorActionRequest} message
1357
+ * @param {!jspb.BinaryWriter} writer
1358
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1359
+ */
1360
+ proto.sport.VendorActionRequest.serializeBinaryToWriter = function(message, writer) {
1361
+ var f = undefined;
1362
+ f = message.getData();
1363
+ if (f.length > 0) {
1364
+ writer.writeString(
1365
+ 1,
1366
+ f
1367
+ );
1368
+ }
1369
+ };
1370
+
1371
+
1372
+ /**
1373
+ * optional string data = 1;
1374
+ * @return {string}
1375
+ */
1376
+ proto.sport.VendorActionRequest.prototype.getData = function() {
1377
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1378
+ };
1379
+
1380
+
1381
+ /**
1382
+ * @param {string} value
1383
+ * @return {!proto.sport.VendorActionRequest} returns this
1384
+ */
1385
+ proto.sport.VendorActionRequest.prototype.setData = function(value) {
1386
+ return jspb.Message.setProto3StringField(this, 1, value);
1387
+ };
1388
+
1389
+
1390
+
1391
+
1392
+
1393
+ if (jspb.Message.GENERATE_TO_OBJECT) {
1394
+ /**
1395
+ * Creates an object representation of this proto.
1396
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
1397
+ * Optional fields that are not set will be set to undefined.
1398
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
1399
+ * For the list of reserved names please see:
1400
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
1401
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
1402
+ * JSPB instance for transitional soy proto support:
1403
+ * http://goto/soy-param-migration
1404
+ * @return {!Object}
1405
+ */
1406
+ proto.sport.VendorActionResponse.prototype.toObject = function(opt_includeInstance) {
1407
+ return proto.sport.VendorActionResponse.toObject(opt_includeInstance, this);
1408
+ };
1409
+
1410
+
1411
+ /**
1412
+ * Static version of the {@see toObject} method.
1413
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
1414
+ * the JSPB instance for transitional soy proto support:
1415
+ * http://goto/soy-param-migration
1416
+ * @param {!proto.sport.VendorActionResponse} msg The msg instance to transform.
1417
+ * @return {!Object}
1418
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1419
+ */
1420
+ proto.sport.VendorActionResponse.toObject = function(includeInstance, msg) {
1421
+ var f, obj = {
1422
+ data: jspb.Message.getFieldWithDefault(msg, 1, "")
1423
+ };
1424
+
1425
+ if (includeInstance) {
1426
+ obj.$jspbMessageInstance = msg;
1427
+ }
1428
+ return obj;
1429
+ };
1430
+ }
1431
+
1432
+
1433
+ /**
1434
+ * Deserializes binary data (in protobuf wire format).
1435
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
1436
+ * @return {!proto.sport.VendorActionResponse}
1437
+ */
1438
+ proto.sport.VendorActionResponse.deserializeBinary = function(bytes) {
1439
+ var reader = new jspb.BinaryReader(bytes);
1440
+ var msg = new proto.sport.VendorActionResponse;
1441
+ return proto.sport.VendorActionResponse.deserializeBinaryFromReader(msg, reader);
1442
+ };
1443
+
1444
+
1445
+ /**
1446
+ * Deserializes binary data (in protobuf wire format) from the
1447
+ * given reader into the given message object.
1448
+ * @param {!proto.sport.VendorActionResponse} msg The message object to deserialize into.
1449
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
1450
+ * @return {!proto.sport.VendorActionResponse}
1451
+ */
1452
+ proto.sport.VendorActionResponse.deserializeBinaryFromReader = function(msg, reader) {
1453
+ while (reader.nextField()) {
1454
+ if (reader.isEndGroup()) {
1455
+ break;
1456
+ }
1457
+ var field = reader.getFieldNumber();
1458
+ switch (field) {
1459
+ case 1:
1460
+ var value = /** @type {string} */ (reader.readString());
1461
+ msg.setData(value);
1462
+ break;
1463
+ default:
1464
+ reader.skipField();
1465
+ break;
1466
+ }
1467
+ }
1468
+ return msg;
1469
+ };
1470
+
1471
+
1472
+ /**
1473
+ * Serializes the message to binary data (in protobuf wire format).
1474
+ * @return {!Uint8Array}
1475
+ */
1476
+ proto.sport.VendorActionResponse.prototype.serializeBinary = function() {
1477
+ var writer = new jspb.BinaryWriter();
1478
+ proto.sport.VendorActionResponse.serializeBinaryToWriter(this, writer);
1479
+ return writer.getResultBuffer();
1480
+ };
1481
+
1482
+
1483
+ /**
1484
+ * Serializes the given message to binary data (in protobuf wire
1485
+ * format), writing to the given BinaryWriter.
1486
+ * @param {!proto.sport.VendorActionResponse} message
1487
+ * @param {!jspb.BinaryWriter} writer
1488
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1489
+ */
1490
+ proto.sport.VendorActionResponse.serializeBinaryToWriter = function(message, writer) {
1491
+ var f = undefined;
1492
+ f = message.getData();
1493
+ if (f.length > 0) {
1494
+ writer.writeString(
1495
+ 1,
1496
+ f
1497
+ );
1498
+ }
1499
+ };
1500
+
1501
+
1502
+ /**
1503
+ * optional string data = 1;
1504
+ * @return {string}
1505
+ */
1506
+ proto.sport.VendorActionResponse.prototype.getData = function() {
1507
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1508
+ };
1509
+
1510
+
1511
+ /**
1512
+ * @param {string} value
1513
+ * @return {!proto.sport.VendorActionResponse} returns this
1514
+ */
1515
+ proto.sport.VendorActionResponse.prototype.setData = function(value) {
1516
+ return jspb.Message.setProto3StringField(this, 1, value);
1517
+ };
1518
+
1519
+
1216
1520
  goog.object.extend(exports, proto.sport);
package/user/user.proto CHANGED
@@ -8,6 +8,7 @@ service User {
8
8
  rpc signUp(RegistrationRequest) returns (LoggedInResponse);
9
9
  rpc signIn(LoginRequest) returns (LoggedInResponse);
10
10
  rpc getUserData(UserDataRequest) returns (UserDataResponse);
11
+ rpc getUserBalance(UserDataRequest) returns (UserDataResponse);
11
12
  //Role and Permissions
12
13
  rpc addPermissionToUserRole(RolePermissionRequest) returns (RolePermissionStatusResponse);
13
14
  rpc rolesList(PaginationRequest) returns (RolesItemsResponse);
@@ -150,8 +151,9 @@ message LoginRequest {
150
151
  optional string city = 7;
151
152
  }
152
153
  message UserDataRequest {
153
- int32 id = 1;
154
+ optional int32 id = 1;
154
155
  optional string requested_area = 2;
156
+ optional string public_id = 3;
155
157
  }
156
158
  message UserPasswordRequest {
157
159
  int32 id = 1;
@@ -623,6 +623,17 @@ signUp: {
623
623
  responseSerialize: serialize_user_UserDataResponse,
624
624
  responseDeserialize: deserialize_user_UserDataResponse,
625
625
  },
626
+ getUserBalance: {
627
+ path: '/user.User/getUserBalance',
628
+ requestStream: false,
629
+ responseStream: false,
630
+ requestType: user_pb.UserDataRequest,
631
+ responseType: user_pb.UserDataResponse,
632
+ requestSerialize: serialize_user_UserDataRequest,
633
+ requestDeserialize: deserialize_user_UserDataRequest,
634
+ responseSerialize: serialize_user_UserDataResponse,
635
+ responseDeserialize: deserialize_user_UserDataResponse,
636
+ },
626
637
  // Role and Permissions
627
638
  addPermissionToUserRole: {
628
639
  path: '/user.User/addPermissionToUserRole',
package/user/user_pb.js CHANGED
@@ -5726,7 +5726,8 @@ proto.user.UserDataRequest.prototype.toObject = function(opt_includeInstance) {
5726
5726
  proto.user.UserDataRequest.toObject = function(includeInstance, msg) {
5727
5727
  var f, obj = {
5728
5728
  id: jspb.Message.getFieldWithDefault(msg, 1, 0),
5729
- requestedArea: jspb.Message.getFieldWithDefault(msg, 2, "")
5729
+ requestedArea: jspb.Message.getFieldWithDefault(msg, 2, ""),
5730
+ publicId: jspb.Message.getFieldWithDefault(msg, 3, "")
5730
5731
  };
5731
5732
 
5732
5733
  if (includeInstance) {
@@ -5771,6 +5772,10 @@ proto.user.UserDataRequest.deserializeBinaryFromReader = function(msg, reader) {
5771
5772
  var value = /** @type {string} */ (reader.readString());
5772
5773
  msg.setRequestedArea(value);
5773
5774
  break;
5775
+ case 3:
5776
+ var value = /** @type {string} */ (reader.readString());
5777
+ msg.setPublicId(value);
5778
+ break;
5774
5779
  default:
5775
5780
  reader.skipField();
5776
5781
  break;
@@ -5800,8 +5805,8 @@ proto.user.UserDataRequest.prototype.serializeBinary = function() {
5800
5805
  */
5801
5806
  proto.user.UserDataRequest.serializeBinaryToWriter = function(message, writer) {
5802
5807
  var f = undefined;
5803
- f = message.getId();
5804
- if (f !== 0) {
5808
+ f = /** @type {number} */ (jspb.Message.getField(message, 1));
5809
+ if (f != null) {
5805
5810
  writer.writeInt32(
5806
5811
  1,
5807
5812
  f
@@ -5814,6 +5819,13 @@ proto.user.UserDataRequest.serializeBinaryToWriter = function(message, writer) {
5814
5819
  f
5815
5820
  );
5816
5821
  }
5822
+ f = /** @type {string} */ (jspb.Message.getField(message, 3));
5823
+ if (f != null) {
5824
+ writer.writeString(
5825
+ 3,
5826
+ f
5827
+ );
5828
+ }
5817
5829
  };
5818
5830
 
5819
5831
 
@@ -5831,7 +5843,25 @@ proto.user.UserDataRequest.prototype.getId = function() {
5831
5843
  * @return {!proto.user.UserDataRequest} returns this
5832
5844
  */
5833
5845
  proto.user.UserDataRequest.prototype.setId = function(value) {
5834
- return jspb.Message.setProto3IntField(this, 1, value);
5846
+ return jspb.Message.setField(this, 1, value);
5847
+ };
5848
+
5849
+
5850
+ /**
5851
+ * Clears the field making it undefined.
5852
+ * @return {!proto.user.UserDataRequest} returns this
5853
+ */
5854
+ proto.user.UserDataRequest.prototype.clearId = function() {
5855
+ return jspb.Message.setField(this, 1, undefined);
5856
+ };
5857
+
5858
+
5859
+ /**
5860
+ * Returns whether this field is set.
5861
+ * @return {boolean}
5862
+ */
5863
+ proto.user.UserDataRequest.prototype.hasId = function() {
5864
+ return jspb.Message.getField(this, 1) != null;
5835
5865
  };
5836
5866
 
5837
5867
 
@@ -5871,6 +5901,42 @@ proto.user.UserDataRequest.prototype.hasRequestedArea = function() {
5871
5901
  };
5872
5902
 
5873
5903
 
5904
+ /**
5905
+ * optional string public_id = 3;
5906
+ * @return {string}
5907
+ */
5908
+ proto.user.UserDataRequest.prototype.getPublicId = function() {
5909
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
5910
+ };
5911
+
5912
+
5913
+ /**
5914
+ * @param {string} value
5915
+ * @return {!proto.user.UserDataRequest} returns this
5916
+ */
5917
+ proto.user.UserDataRequest.prototype.setPublicId = function(value) {
5918
+ return jspb.Message.setField(this, 3, value);
5919
+ };
5920
+
5921
+
5922
+ /**
5923
+ * Clears the field making it undefined.
5924
+ * @return {!proto.user.UserDataRequest} returns this
5925
+ */
5926
+ proto.user.UserDataRequest.prototype.clearPublicId = function() {
5927
+ return jspb.Message.setField(this, 3, undefined);
5928
+ };
5929
+
5930
+
5931
+ /**
5932
+ * Returns whether this field is set.
5933
+ * @return {boolean}
5934
+ */
5935
+ proto.user.UserDataRequest.prototype.hasPublicId = function() {
5936
+ return jspb.Message.getField(this, 3) != null;
5937
+ };
5938
+
5939
+
5874
5940
 
5875
5941
 
5876
5942