protobuf-platform 1.2.192 → 1.2.194

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.
@@ -110,6 +110,11 @@ message CashbackActions {
110
110
  bool can_reactivate = 2;
111
111
  bool can_calculate = 3;
112
112
  }
113
+ message CashbackGamePreview {
114
+ string game_slug = 1;
115
+ string provider_slug = 2;
116
+ optional string image = 3;
117
+ }
113
118
  //User
114
119
  message UserCashbackItem {
115
120
  int32 cashback_id = 1;
@@ -133,6 +138,7 @@ message UserCashbackItem {
133
138
  optional int64 remaining_ms = 15;
134
139
  optional float remaining_to_min = 16;
135
140
  optional int32 cashback_user_id = 17;
141
+ repeated CashbackGamePreview games = 18;
136
142
  }
137
143
  message CashbackUserRequest {
138
144
  int32 user_id = 1;
@@ -24,6 +24,7 @@ var global = (function() {
24
24
  goog.exportSymbol('proto.cashback.CashbackActions', null, global);
25
25
  goog.exportSymbol('proto.cashback.CashbackConfigItem', null, global);
26
26
  goog.exportSymbol('proto.cashback.CashbackConfigRequest', null, global);
27
+ goog.exportSymbol('proto.cashback.CashbackGamePreview', null, global);
27
28
  goog.exportSymbol('proto.cashback.CashbackItem', null, global);
28
29
  goog.exportSymbol('proto.cashback.CashbackItemRequest', null, global);
29
30
  goog.exportSymbol('proto.cashback.CashbackItemsResponse', null, global);
@@ -433,9 +434,30 @@ if (goog.DEBUG && !COMPILED) {
433
434
  * @extends {jspb.Message}
434
435
  * @constructor
435
436
  */
436
- proto.cashback.UserCashbackItem = function(opt_data) {
437
+ proto.cashback.CashbackGamePreview = function(opt_data) {
437
438
  jspb.Message.initialize(this, opt_data, 0, -1, null, null);
438
439
  };
440
+ goog.inherits(proto.cashback.CashbackGamePreview, jspb.Message);
441
+ if (goog.DEBUG && !COMPILED) {
442
+ /**
443
+ * @public
444
+ * @override
445
+ */
446
+ proto.cashback.CashbackGamePreview.displayName = 'proto.cashback.CashbackGamePreview';
447
+ }
448
+ /**
449
+ * Generated by JsPbCodeGenerator.
450
+ * @param {Array=} opt_data Optional initial data array, typically from a
451
+ * server response, or constructed directly in Javascript. The array is used
452
+ * in place and becomes part of the constructed object. It is not cloned.
453
+ * If no data is provided, the constructed object will be empty, but still
454
+ * valid.
455
+ * @extends {jspb.Message}
456
+ * @constructor
457
+ */
458
+ proto.cashback.UserCashbackItem = function(opt_data) {
459
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cashback.UserCashbackItem.repeatedFields_, null);
460
+ };
439
461
  goog.inherits(proto.cashback.UserCashbackItem, jspb.Message);
440
462
  if (goog.DEBUG && !COMPILED) {
441
463
  /**
@@ -5018,6 +5040,221 @@ proto.cashback.CashbackActions.prototype.setCanCalculate = function(value) {
5018
5040
 
5019
5041
 
5020
5042
 
5043
+ if (jspb.Message.GENERATE_TO_OBJECT) {
5044
+ /**
5045
+ * Creates an object representation of this proto.
5046
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
5047
+ * Optional fields that are not set will be set to undefined.
5048
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
5049
+ * For the list of reserved names please see:
5050
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
5051
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
5052
+ * JSPB instance for transitional soy proto support:
5053
+ * http://goto/soy-param-migration
5054
+ * @return {!Object}
5055
+ */
5056
+ proto.cashback.CashbackGamePreview.prototype.toObject = function(opt_includeInstance) {
5057
+ return proto.cashback.CashbackGamePreview.toObject(opt_includeInstance, this);
5058
+ };
5059
+
5060
+
5061
+ /**
5062
+ * Static version of the {@see toObject} method.
5063
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
5064
+ * the JSPB instance for transitional soy proto support:
5065
+ * http://goto/soy-param-migration
5066
+ * @param {!proto.cashback.CashbackGamePreview} msg The msg instance to transform.
5067
+ * @return {!Object}
5068
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5069
+ */
5070
+ proto.cashback.CashbackGamePreview.toObject = function(includeInstance, msg) {
5071
+ var f, obj = {
5072
+ gameSlug: jspb.Message.getFieldWithDefault(msg, 1, ""),
5073
+ providerSlug: jspb.Message.getFieldWithDefault(msg, 2, ""),
5074
+ image: jspb.Message.getFieldWithDefault(msg, 3, "")
5075
+ };
5076
+
5077
+ if (includeInstance) {
5078
+ obj.$jspbMessageInstance = msg;
5079
+ }
5080
+ return obj;
5081
+ };
5082
+ }
5083
+
5084
+
5085
+ /**
5086
+ * Deserializes binary data (in protobuf wire format).
5087
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
5088
+ * @return {!proto.cashback.CashbackGamePreview}
5089
+ */
5090
+ proto.cashback.CashbackGamePreview.deserializeBinary = function(bytes) {
5091
+ var reader = new jspb.BinaryReader(bytes);
5092
+ var msg = new proto.cashback.CashbackGamePreview;
5093
+ return proto.cashback.CashbackGamePreview.deserializeBinaryFromReader(msg, reader);
5094
+ };
5095
+
5096
+
5097
+ /**
5098
+ * Deserializes binary data (in protobuf wire format) from the
5099
+ * given reader into the given message object.
5100
+ * @param {!proto.cashback.CashbackGamePreview} msg The message object to deserialize into.
5101
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
5102
+ * @return {!proto.cashback.CashbackGamePreview}
5103
+ */
5104
+ proto.cashback.CashbackGamePreview.deserializeBinaryFromReader = function(msg, reader) {
5105
+ while (reader.nextField()) {
5106
+ if (reader.isEndGroup()) {
5107
+ break;
5108
+ }
5109
+ var field = reader.getFieldNumber();
5110
+ switch (field) {
5111
+ case 1:
5112
+ var value = /** @type {string} */ (reader.readString());
5113
+ msg.setGameSlug(value);
5114
+ break;
5115
+ case 2:
5116
+ var value = /** @type {string} */ (reader.readString());
5117
+ msg.setProviderSlug(value);
5118
+ break;
5119
+ case 3:
5120
+ var value = /** @type {string} */ (reader.readString());
5121
+ msg.setImage(value);
5122
+ break;
5123
+ default:
5124
+ reader.skipField();
5125
+ break;
5126
+ }
5127
+ }
5128
+ return msg;
5129
+ };
5130
+
5131
+
5132
+ /**
5133
+ * Serializes the message to binary data (in protobuf wire format).
5134
+ * @return {!Uint8Array}
5135
+ */
5136
+ proto.cashback.CashbackGamePreview.prototype.serializeBinary = function() {
5137
+ var writer = new jspb.BinaryWriter();
5138
+ proto.cashback.CashbackGamePreview.serializeBinaryToWriter(this, writer);
5139
+ return writer.getResultBuffer();
5140
+ };
5141
+
5142
+
5143
+ /**
5144
+ * Serializes the given message to binary data (in protobuf wire
5145
+ * format), writing to the given BinaryWriter.
5146
+ * @param {!proto.cashback.CashbackGamePreview} message
5147
+ * @param {!jspb.BinaryWriter} writer
5148
+ * @suppress {unusedLocalVariables} f is only used for nested messages
5149
+ */
5150
+ proto.cashback.CashbackGamePreview.serializeBinaryToWriter = function(message, writer) {
5151
+ var f = undefined;
5152
+ f = message.getGameSlug();
5153
+ if (f.length > 0) {
5154
+ writer.writeString(
5155
+ 1,
5156
+ f
5157
+ );
5158
+ }
5159
+ f = message.getProviderSlug();
5160
+ if (f.length > 0) {
5161
+ writer.writeString(
5162
+ 2,
5163
+ f
5164
+ );
5165
+ }
5166
+ f = /** @type {string} */ (jspb.Message.getField(message, 3));
5167
+ if (f != null) {
5168
+ writer.writeString(
5169
+ 3,
5170
+ f
5171
+ );
5172
+ }
5173
+ };
5174
+
5175
+
5176
+ /**
5177
+ * optional string game_slug = 1;
5178
+ * @return {string}
5179
+ */
5180
+ proto.cashback.CashbackGamePreview.prototype.getGameSlug = function() {
5181
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
5182
+ };
5183
+
5184
+
5185
+ /**
5186
+ * @param {string} value
5187
+ * @return {!proto.cashback.CashbackGamePreview} returns this
5188
+ */
5189
+ proto.cashback.CashbackGamePreview.prototype.setGameSlug = function(value) {
5190
+ return jspb.Message.setProto3StringField(this, 1, value);
5191
+ };
5192
+
5193
+
5194
+ /**
5195
+ * optional string provider_slug = 2;
5196
+ * @return {string}
5197
+ */
5198
+ proto.cashback.CashbackGamePreview.prototype.getProviderSlug = function() {
5199
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
5200
+ };
5201
+
5202
+
5203
+ /**
5204
+ * @param {string} value
5205
+ * @return {!proto.cashback.CashbackGamePreview} returns this
5206
+ */
5207
+ proto.cashback.CashbackGamePreview.prototype.setProviderSlug = function(value) {
5208
+ return jspb.Message.setProto3StringField(this, 2, value);
5209
+ };
5210
+
5211
+
5212
+ /**
5213
+ * optional string image = 3;
5214
+ * @return {string}
5215
+ */
5216
+ proto.cashback.CashbackGamePreview.prototype.getImage = function() {
5217
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
5218
+ };
5219
+
5220
+
5221
+ /**
5222
+ * @param {string} value
5223
+ * @return {!proto.cashback.CashbackGamePreview} returns this
5224
+ */
5225
+ proto.cashback.CashbackGamePreview.prototype.setImage = function(value) {
5226
+ return jspb.Message.setField(this, 3, value);
5227
+ };
5228
+
5229
+
5230
+ /**
5231
+ * Clears the field making it undefined.
5232
+ * @return {!proto.cashback.CashbackGamePreview} returns this
5233
+ */
5234
+ proto.cashback.CashbackGamePreview.prototype.clearImage = function() {
5235
+ return jspb.Message.setField(this, 3, undefined);
5236
+ };
5237
+
5238
+
5239
+ /**
5240
+ * Returns whether this field is set.
5241
+ * @return {boolean}
5242
+ */
5243
+ proto.cashback.CashbackGamePreview.prototype.hasImage = function() {
5244
+ return jspb.Message.getField(this, 3) != null;
5245
+ };
5246
+
5247
+
5248
+
5249
+ /**
5250
+ * List of repeated fields within this message type.
5251
+ * @private {!Array<number>}
5252
+ * @const
5253
+ */
5254
+ proto.cashback.UserCashbackItem.repeatedFields_ = [18];
5255
+
5256
+
5257
+
5021
5258
  if (jspb.Message.GENERATE_TO_OBJECT) {
5022
5259
  /**
5023
5260
  * Creates an object representation of this proto.
@@ -5063,7 +5300,9 @@ proto.cashback.UserCashbackItem.toObject = function(includeInstance, msg) {
5063
5300
  actions: (f = msg.getActions()) && proto.cashback.CashbackActions.toObject(includeInstance, f),
5064
5301
  remainingMs: jspb.Message.getFieldWithDefault(msg, 15, 0),
5065
5302
  remainingToMin: jspb.Message.getFloatingPointFieldWithDefault(msg, 16, 0.0),
5066
- cashbackUserId: jspb.Message.getFieldWithDefault(msg, 17, 0)
5303
+ cashbackUserId: jspb.Message.getFieldWithDefault(msg, 17, 0),
5304
+ gamesList: jspb.Message.toObjectList(msg.getGamesList(),
5305
+ proto.cashback.CashbackGamePreview.toObject, includeInstance)
5067
5306
  };
5068
5307
 
5069
5308
  if (includeInstance) {
@@ -5169,6 +5408,11 @@ proto.cashback.UserCashbackItem.deserializeBinaryFromReader = function(msg, read
5169
5408
  var value = /** @type {number} */ (reader.readInt32());
5170
5409
  msg.setCashbackUserId(value);
5171
5410
  break;
5411
+ case 18:
5412
+ var value = new proto.cashback.CashbackGamePreview;
5413
+ reader.readMessage(value,proto.cashback.CashbackGamePreview.deserializeBinaryFromReader);
5414
+ msg.addGames(value);
5415
+ break;
5172
5416
  default:
5173
5417
  reader.skipField();
5174
5418
  break;
@@ -5318,6 +5562,14 @@ proto.cashback.UserCashbackItem.serializeBinaryToWriter = function(message, writ
5318
5562
  f
5319
5563
  );
5320
5564
  }
5565
+ f = message.getGamesList();
5566
+ if (f.length > 0) {
5567
+ writer.writeRepeatedMessage(
5568
+ 18,
5569
+ f,
5570
+ proto.cashback.CashbackGamePreview.serializeBinaryToWriter
5571
+ );
5572
+ }
5321
5573
  };
5322
5574
 
5323
5575
 
@@ -5826,6 +6078,44 @@ proto.cashback.UserCashbackItem.prototype.hasCashbackUserId = function() {
5826
6078
  };
5827
6079
 
5828
6080
 
6081
+ /**
6082
+ * repeated CashbackGamePreview games = 18;
6083
+ * @return {!Array<!proto.cashback.CashbackGamePreview>}
6084
+ */
6085
+ proto.cashback.UserCashbackItem.prototype.getGamesList = function() {
6086
+ return /** @type{!Array<!proto.cashback.CashbackGamePreview>} */ (
6087
+ jspb.Message.getRepeatedWrapperField(this, proto.cashback.CashbackGamePreview, 18));
6088
+ };
6089
+
6090
+
6091
+ /**
6092
+ * @param {!Array<!proto.cashback.CashbackGamePreview>} value
6093
+ * @return {!proto.cashback.UserCashbackItem} returns this
6094
+ */
6095
+ proto.cashback.UserCashbackItem.prototype.setGamesList = function(value) {
6096
+ return jspb.Message.setRepeatedWrapperField(this, 18, value);
6097
+ };
6098
+
6099
+
6100
+ /**
6101
+ * @param {!proto.cashback.CashbackGamePreview=} opt_value
6102
+ * @param {number=} opt_index
6103
+ * @return {!proto.cashback.CashbackGamePreview}
6104
+ */
6105
+ proto.cashback.UserCashbackItem.prototype.addGames = function(opt_value, opt_index) {
6106
+ return jspb.Message.addToRepeatedWrapperField(this, 18, opt_value, proto.cashback.CashbackGamePreview, opt_index);
6107
+ };
6108
+
6109
+
6110
+ /**
6111
+ * Clears the list making it empty but non-null.
6112
+ * @return {!proto.cashback.UserCashbackItem} returns this
6113
+ */
6114
+ proto.cashback.UserCashbackItem.prototype.clearGamesList = function() {
6115
+ return this.setGamesList([]);
6116
+ };
6117
+
6118
+
5829
6119
 
5830
6120
 
5831
6121
 
package/game/game.proto CHANGED
@@ -101,6 +101,8 @@ service Game {
101
101
  rpc addGamesIntoCashBackList(CashBackListGamesRequest) returns (GameStatusResponse);
102
102
  rpc removeGamesFromCashBackList(CashBackListGamesRequest) returns (GameStatusResponse);
103
103
  rpc fetchGamesFromCashBackList(PaginationRequest) returns (GameItemsResponse);
104
+ rpc fetchGamesFromCashBackLists(CashBackListsGamesRequest) returns (CashBackListsGamesResponse);
105
+ rpc fetchGamesFromCashBackTypes(CashBackTypesGamesRequest) returns (CashBackTypesGamesResponse);
104
106
  rpc notProcessedGamesInCashBackList(PaginationRequest) returns (GameItemsResponse);
105
107
  rpc updateCashBackListInBunch(ItemsBunchRequest) returns (GameStatusResponse);
106
108
  //Dashboard
@@ -701,6 +703,36 @@ message CashBackListItemsResponse {
701
703
  optional int32 total_pages = 2;
702
704
  optional int32 total_items = 3;
703
705
  }
706
+ message CashBackListsGamesRequest {
707
+ repeated int32 cashback_list_ids = 1;
708
+ optional int32 limit = 2;
709
+ optional int32 offset = 3;
710
+ }
711
+ message CashbackGamePreview {
712
+ string game_slug = 1;
713
+ string provider_slug = 2;
714
+ string image = 3;
715
+ optional int32 game_id = 4;
716
+ }
717
+ message CashBackListGamesItem {
718
+ int32 cashback_list_id = 1;
719
+ repeated CashbackGamePreview games = 2;
720
+ }
721
+ message CashBackListsGamesResponse {
722
+ repeated CashBackListGamesItem items = 1;
723
+ }
724
+ message CashBackTypesGamesRequest {
725
+ repeated string cashback_types = 1;
726
+ optional int32 limit = 2;
727
+ optional int32 offset = 3;
728
+ }
729
+ message CashBackTypeGamesItem {
730
+ string cashback_type = 1;
731
+ repeated CashbackGamePreview games = 2;
732
+ }
733
+ message CashBackTypesGamesResponse {
734
+ repeated CashBackTypeGamesItem items = 1;
735
+ }
704
736
  //Dashboard
705
737
  message DashboardRequest {
706
738
  string start_date = 1;
@@ -48,6 +48,50 @@ function deserialize_game_CashBackListResponse(buffer_arg) {
48
48
  return game_pb.CashBackListResponse.deserializeBinary(new Uint8Array(buffer_arg));
49
49
  }
50
50
 
51
+ function serialize_game_CashBackListsGamesRequest(arg) {
52
+ if (!(arg instanceof game_pb.CashBackListsGamesRequest)) {
53
+ throw new Error('Expected argument of type game.CashBackListsGamesRequest');
54
+ }
55
+ return Buffer.from(arg.serializeBinary());
56
+ }
57
+
58
+ function deserialize_game_CashBackListsGamesRequest(buffer_arg) {
59
+ return game_pb.CashBackListsGamesRequest.deserializeBinary(new Uint8Array(buffer_arg));
60
+ }
61
+
62
+ function serialize_game_CashBackListsGamesResponse(arg) {
63
+ if (!(arg instanceof game_pb.CashBackListsGamesResponse)) {
64
+ throw new Error('Expected argument of type game.CashBackListsGamesResponse');
65
+ }
66
+ return Buffer.from(arg.serializeBinary());
67
+ }
68
+
69
+ function deserialize_game_CashBackListsGamesResponse(buffer_arg) {
70
+ return game_pb.CashBackListsGamesResponse.deserializeBinary(new Uint8Array(buffer_arg));
71
+ }
72
+
73
+ function serialize_game_CashBackTypesGamesRequest(arg) {
74
+ if (!(arg instanceof game_pb.CashBackTypesGamesRequest)) {
75
+ throw new Error('Expected argument of type game.CashBackTypesGamesRequest');
76
+ }
77
+ return Buffer.from(arg.serializeBinary());
78
+ }
79
+
80
+ function deserialize_game_CashBackTypesGamesRequest(buffer_arg) {
81
+ return game_pb.CashBackTypesGamesRequest.deserializeBinary(new Uint8Array(buffer_arg));
82
+ }
83
+
84
+ function serialize_game_CashBackTypesGamesResponse(arg) {
85
+ if (!(arg instanceof game_pb.CashBackTypesGamesResponse)) {
86
+ throw new Error('Expected argument of type game.CashBackTypesGamesResponse');
87
+ }
88
+ return Buffer.from(arg.serializeBinary());
89
+ }
90
+
91
+ function deserialize_game_CashBackTypesGamesResponse(buffer_arg) {
92
+ return game_pb.CashBackTypesGamesResponse.deserializeBinary(new Uint8Array(buffer_arg));
93
+ }
94
+
51
95
  function serialize_game_CategoryItemsResponse(arg) {
52
96
  if (!(arg instanceof game_pb.CategoryItemsResponse)) {
53
97
  throw new Error('Expected argument of type game.CategoryItemsResponse');
@@ -1932,6 +1976,28 @@ readSingleCashBackList: {
1932
1976
  responseSerialize: serialize_game_GameItemsResponse,
1933
1977
  responseDeserialize: deserialize_game_GameItemsResponse,
1934
1978
  },
1979
+ fetchGamesFromCashBackLists: {
1980
+ path: '/game.Game/fetchGamesFromCashBackLists',
1981
+ requestStream: false,
1982
+ responseStream: false,
1983
+ requestType: game_pb.CashBackListsGamesRequest,
1984
+ responseType: game_pb.CashBackListsGamesResponse,
1985
+ requestSerialize: serialize_game_CashBackListsGamesRequest,
1986
+ requestDeserialize: deserialize_game_CashBackListsGamesRequest,
1987
+ responseSerialize: serialize_game_CashBackListsGamesResponse,
1988
+ responseDeserialize: deserialize_game_CashBackListsGamesResponse,
1989
+ },
1990
+ fetchGamesFromCashBackTypes: {
1991
+ path: '/game.Game/fetchGamesFromCashBackTypes',
1992
+ requestStream: false,
1993
+ responseStream: false,
1994
+ requestType: game_pb.CashBackTypesGamesRequest,
1995
+ responseType: game_pb.CashBackTypesGamesResponse,
1996
+ requestSerialize: serialize_game_CashBackTypesGamesRequest,
1997
+ requestDeserialize: deserialize_game_CashBackTypesGamesRequest,
1998
+ responseSerialize: serialize_game_CashBackTypesGamesResponse,
1999
+ responseDeserialize: deserialize_game_CashBackTypesGamesResponse,
2000
+ },
1935
2001
  notProcessedGamesInCashBackList: {
1936
2002
  path: '/game.Game/notProcessedGamesInCashBackList',
1937
2003
  requestStream: false,