protobuf-platform 1.2.500 → 1.2.502

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.500",
3
+ "version": "1.2.502",
4
4
  "description": "Protobuf structures",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -51,6 +51,7 @@ service Payment {
51
51
  rpc getPaymentMethodsForUser(GetUserPaymentsInfoRequest) returns (UserPaymentMethodsResponse);
52
52
  rpc checkFastDeposit(CheckFastDepositRequest) returns (CheckFastDepositResponse);
53
53
  rpc getWithdrawalWagerSnapshot(GetWithdrawalWagerSnapshotRequest) returns (GetWithdrawalWagerSnapshotResponse);
54
+ rpc checkWithdrawalEligibility(CheckWithdrawalEligibilityRequest) returns (CheckWithdrawalEligibilityResponse);
54
55
  rpc getWithdrawalWagerBucketHistory(GetWithdrawalWagerBucketHistoryRequest) returns (GetWithdrawalWagerBucketHistoryResponse);
55
56
  rpc getUserKycFinancialSnapshot(GetUserKycFinancialSnapshotRequest) returns (GetUserKycFinancialSnapshotResponse);
56
57
  //Segmentation
@@ -685,6 +686,18 @@ message CheckFastDepositRequest {
685
686
  message CheckFastDepositResponse {
686
687
  UserPaymentMethodItem method = 1;
687
688
  }
689
+ message CheckWithdrawalEligibilityRequest {
690
+ int32 user_id = 1;
691
+ string currency = 2;
692
+ string amount = 3;
693
+ }
694
+ message CheckWithdrawalEligibilityResponse {
695
+ bool allowed = 1;
696
+ optional string reason = 2;
697
+ optional int64 available_real_minor = 3;
698
+ optional string currency = 4;
699
+ optional int32 currency_scale = 5;
700
+ }
688
701
  message GetWithdrawalWagerSnapshotRequest {
689
702
  int32 user_id = 1;
690
703
  optional string currency = 2;
@@ -70,6 +70,28 @@ function deserialize_payment_CheckFastDepositResponse(buffer_arg) {
70
70
  return payment_pb.CheckFastDepositResponse.deserializeBinary(new Uint8Array(buffer_arg));
71
71
  }
72
72
 
73
+ function serialize_payment_CheckWithdrawalEligibilityRequest(arg) {
74
+ if (!(arg instanceof payment_pb.CheckWithdrawalEligibilityRequest)) {
75
+ throw new Error('Expected argument of type payment.CheckWithdrawalEligibilityRequest');
76
+ }
77
+ return Buffer.from(arg.serializeBinary());
78
+ }
79
+
80
+ function deserialize_payment_CheckWithdrawalEligibilityRequest(buffer_arg) {
81
+ return payment_pb.CheckWithdrawalEligibilityRequest.deserializeBinary(new Uint8Array(buffer_arg));
82
+ }
83
+
84
+ function serialize_payment_CheckWithdrawalEligibilityResponse(arg) {
85
+ if (!(arg instanceof payment_pb.CheckWithdrawalEligibilityResponse)) {
86
+ throw new Error('Expected argument of type payment.CheckWithdrawalEligibilityResponse');
87
+ }
88
+ return Buffer.from(arg.serializeBinary());
89
+ }
90
+
91
+ function deserialize_payment_CheckWithdrawalEligibilityResponse(buffer_arg) {
92
+ return payment_pb.CheckWithdrawalEligibilityResponse.deserializeBinary(new Uint8Array(buffer_arg));
93
+ }
94
+
73
95
  function serialize_payment_CompensationRequest(arg) {
74
96
  if (!(arg instanceof payment_pb.CompensationRequest)) {
75
97
  throw new Error('Expected argument of type payment.CompensationRequest');
@@ -1256,6 +1278,17 @@ userPaymentsInfo: {
1256
1278
  responseSerialize: serialize_payment_GetWithdrawalWagerSnapshotResponse,
1257
1279
  responseDeserialize: deserialize_payment_GetWithdrawalWagerSnapshotResponse,
1258
1280
  },
1281
+ checkWithdrawalEligibility: {
1282
+ path: '/payment.Payment/checkWithdrawalEligibility',
1283
+ requestStream: false,
1284
+ responseStream: false,
1285
+ requestType: payment_pb.CheckWithdrawalEligibilityRequest,
1286
+ responseType: payment_pb.CheckWithdrawalEligibilityResponse,
1287
+ requestSerialize: serialize_payment_CheckWithdrawalEligibilityRequest,
1288
+ requestDeserialize: deserialize_payment_CheckWithdrawalEligibilityRequest,
1289
+ responseSerialize: serialize_payment_CheckWithdrawalEligibilityResponse,
1290
+ responseDeserialize: deserialize_payment_CheckWithdrawalEligibilityResponse,
1291
+ },
1259
1292
  getWithdrawalWagerBucketHistory: {
1260
1293
  path: '/payment.Payment/getWithdrawalWagerBucketHistory',
1261
1294
  requestStream: false,
@@ -28,6 +28,8 @@ goog.exportSymbol('proto.payment.CashierFieldItemsResponse', null, global);
28
28
  goog.exportSymbol('proto.payment.CashierFieldsRequest', null, global);
29
29
  goog.exportSymbol('proto.payment.CheckFastDepositRequest', null, global);
30
30
  goog.exportSymbol('proto.payment.CheckFastDepositResponse', null, global);
31
+ goog.exportSymbol('proto.payment.CheckWithdrawalEligibilityRequest', null, global);
32
+ goog.exportSymbol('proto.payment.CheckWithdrawalEligibilityResponse', null, global);
31
33
  goog.exportSymbol('proto.payment.CompensationRequest', null, global);
32
34
  goog.exportSymbol('proto.payment.ConfiscationRequest', null, global);
33
35
  goog.exportSymbol('proto.payment.CryptoDepositInstructions', null, global);
@@ -1566,6 +1568,48 @@ if (goog.DEBUG && !COMPILED) {
1566
1568
  */
1567
1569
  proto.payment.CheckFastDepositResponse.displayName = 'proto.payment.CheckFastDepositResponse';
1568
1570
  }
1571
+ /**
1572
+ * Generated by JsPbCodeGenerator.
1573
+ * @param {Array=} opt_data Optional initial data array, typically from a
1574
+ * server response, or constructed directly in Javascript. The array is used
1575
+ * in place and becomes part of the constructed object. It is not cloned.
1576
+ * If no data is provided, the constructed object will be empty, but still
1577
+ * valid.
1578
+ * @extends {jspb.Message}
1579
+ * @constructor
1580
+ */
1581
+ proto.payment.CheckWithdrawalEligibilityRequest = function(opt_data) {
1582
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
1583
+ };
1584
+ goog.inherits(proto.payment.CheckWithdrawalEligibilityRequest, jspb.Message);
1585
+ if (goog.DEBUG && !COMPILED) {
1586
+ /**
1587
+ * @public
1588
+ * @override
1589
+ */
1590
+ proto.payment.CheckWithdrawalEligibilityRequest.displayName = 'proto.payment.CheckWithdrawalEligibilityRequest';
1591
+ }
1592
+ /**
1593
+ * Generated by JsPbCodeGenerator.
1594
+ * @param {Array=} opt_data Optional initial data array, typically from a
1595
+ * server response, or constructed directly in Javascript. The array is used
1596
+ * in place and becomes part of the constructed object. It is not cloned.
1597
+ * If no data is provided, the constructed object will be empty, but still
1598
+ * valid.
1599
+ * @extends {jspb.Message}
1600
+ * @constructor
1601
+ */
1602
+ proto.payment.CheckWithdrawalEligibilityResponse = function(opt_data) {
1603
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
1604
+ };
1605
+ goog.inherits(proto.payment.CheckWithdrawalEligibilityResponse, jspb.Message);
1606
+ if (goog.DEBUG && !COMPILED) {
1607
+ /**
1608
+ * @public
1609
+ * @override
1610
+ */
1611
+ proto.payment.CheckWithdrawalEligibilityResponse.displayName = 'proto.payment.CheckWithdrawalEligibilityResponse';
1612
+ }
1569
1613
  /**
1570
1614
  * Generated by JsPbCodeGenerator.
1571
1615
  * @param {Array=} opt_data Optional initial data array, typically from a
@@ -29792,6 +29836,518 @@ proto.payment.CheckFastDepositResponse.prototype.hasMethod = function() {
29792
29836
 
29793
29837
 
29794
29838
 
29839
+ if (jspb.Message.GENERATE_TO_OBJECT) {
29840
+ /**
29841
+ * Creates an object representation of this proto.
29842
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
29843
+ * Optional fields that are not set will be set to undefined.
29844
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
29845
+ * For the list of reserved names please see:
29846
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
29847
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
29848
+ * JSPB instance for transitional soy proto support:
29849
+ * http://goto/soy-param-migration
29850
+ * @return {!Object}
29851
+ */
29852
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.toObject = function(opt_includeInstance) {
29853
+ return proto.payment.CheckWithdrawalEligibilityRequest.toObject(opt_includeInstance, this);
29854
+ };
29855
+
29856
+
29857
+ /**
29858
+ * Static version of the {@see toObject} method.
29859
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
29860
+ * the JSPB instance for transitional soy proto support:
29861
+ * http://goto/soy-param-migration
29862
+ * @param {!proto.payment.CheckWithdrawalEligibilityRequest} msg The msg instance to transform.
29863
+ * @return {!Object}
29864
+ * @suppress {unusedLocalVariables} f is only used for nested messages
29865
+ */
29866
+ proto.payment.CheckWithdrawalEligibilityRequest.toObject = function(includeInstance, msg) {
29867
+ var f, obj = {
29868
+ userId: jspb.Message.getFieldWithDefault(msg, 1, 0),
29869
+ currency: jspb.Message.getFieldWithDefault(msg, 2, ""),
29870
+ amount: jspb.Message.getFieldWithDefault(msg, 3, "")
29871
+ };
29872
+
29873
+ if (includeInstance) {
29874
+ obj.$jspbMessageInstance = msg;
29875
+ }
29876
+ return obj;
29877
+ };
29878
+ }
29879
+
29880
+
29881
+ /**
29882
+ * Deserializes binary data (in protobuf wire format).
29883
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
29884
+ * @return {!proto.payment.CheckWithdrawalEligibilityRequest}
29885
+ */
29886
+ proto.payment.CheckWithdrawalEligibilityRequest.deserializeBinary = function(bytes) {
29887
+ var reader = new jspb.BinaryReader(bytes);
29888
+ var msg = new proto.payment.CheckWithdrawalEligibilityRequest;
29889
+ return proto.payment.CheckWithdrawalEligibilityRequest.deserializeBinaryFromReader(msg, reader);
29890
+ };
29891
+
29892
+
29893
+ /**
29894
+ * Deserializes binary data (in protobuf wire format) from the
29895
+ * given reader into the given message object.
29896
+ * @param {!proto.payment.CheckWithdrawalEligibilityRequest} msg The message object to deserialize into.
29897
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
29898
+ * @return {!proto.payment.CheckWithdrawalEligibilityRequest}
29899
+ */
29900
+ proto.payment.CheckWithdrawalEligibilityRequest.deserializeBinaryFromReader = function(msg, reader) {
29901
+ while (reader.nextField()) {
29902
+ if (reader.isEndGroup()) {
29903
+ break;
29904
+ }
29905
+ var field = reader.getFieldNumber();
29906
+ switch (field) {
29907
+ case 1:
29908
+ var value = /** @type {number} */ (reader.readInt32());
29909
+ msg.setUserId(value);
29910
+ break;
29911
+ case 2:
29912
+ var value = /** @type {string} */ (reader.readString());
29913
+ msg.setCurrency(value);
29914
+ break;
29915
+ case 3:
29916
+ var value = /** @type {string} */ (reader.readString());
29917
+ msg.setAmount(value);
29918
+ break;
29919
+ default:
29920
+ reader.skipField();
29921
+ break;
29922
+ }
29923
+ }
29924
+ return msg;
29925
+ };
29926
+
29927
+
29928
+ /**
29929
+ * Serializes the message to binary data (in protobuf wire format).
29930
+ * @return {!Uint8Array}
29931
+ */
29932
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.serializeBinary = function() {
29933
+ var writer = new jspb.BinaryWriter();
29934
+ proto.payment.CheckWithdrawalEligibilityRequest.serializeBinaryToWriter(this, writer);
29935
+ return writer.getResultBuffer();
29936
+ };
29937
+
29938
+
29939
+ /**
29940
+ * Serializes the given message to binary data (in protobuf wire
29941
+ * format), writing to the given BinaryWriter.
29942
+ * @param {!proto.payment.CheckWithdrawalEligibilityRequest} message
29943
+ * @param {!jspb.BinaryWriter} writer
29944
+ * @suppress {unusedLocalVariables} f is only used for nested messages
29945
+ */
29946
+ proto.payment.CheckWithdrawalEligibilityRequest.serializeBinaryToWriter = function(message, writer) {
29947
+ var f = undefined;
29948
+ f = message.getUserId();
29949
+ if (f !== 0) {
29950
+ writer.writeInt32(
29951
+ 1,
29952
+ f
29953
+ );
29954
+ }
29955
+ f = message.getCurrency();
29956
+ if (f.length > 0) {
29957
+ writer.writeString(
29958
+ 2,
29959
+ f
29960
+ );
29961
+ }
29962
+ f = message.getAmount();
29963
+ if (f.length > 0) {
29964
+ writer.writeString(
29965
+ 3,
29966
+ f
29967
+ );
29968
+ }
29969
+ };
29970
+
29971
+
29972
+ /**
29973
+ * optional int32 user_id = 1;
29974
+ * @return {number}
29975
+ */
29976
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.getUserId = function() {
29977
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
29978
+ };
29979
+
29980
+
29981
+ /**
29982
+ * @param {number} value
29983
+ * @return {!proto.payment.CheckWithdrawalEligibilityRequest} returns this
29984
+ */
29985
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.setUserId = function(value) {
29986
+ return jspb.Message.setProto3IntField(this, 1, value);
29987
+ };
29988
+
29989
+
29990
+ /**
29991
+ * optional string currency = 2;
29992
+ * @return {string}
29993
+ */
29994
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.getCurrency = function() {
29995
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
29996
+ };
29997
+
29998
+
29999
+ /**
30000
+ * @param {string} value
30001
+ * @return {!proto.payment.CheckWithdrawalEligibilityRequest} returns this
30002
+ */
30003
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.setCurrency = function(value) {
30004
+ return jspb.Message.setProto3StringField(this, 2, value);
30005
+ };
30006
+
30007
+
30008
+ /**
30009
+ * optional string amount = 3;
30010
+ * @return {string}
30011
+ */
30012
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.getAmount = function() {
30013
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
30014
+ };
30015
+
30016
+
30017
+ /**
30018
+ * @param {string} value
30019
+ * @return {!proto.payment.CheckWithdrawalEligibilityRequest} returns this
30020
+ */
30021
+ proto.payment.CheckWithdrawalEligibilityRequest.prototype.setAmount = function(value) {
30022
+ return jspb.Message.setProto3StringField(this, 3, value);
30023
+ };
30024
+
30025
+
30026
+
30027
+
30028
+
30029
+ if (jspb.Message.GENERATE_TO_OBJECT) {
30030
+ /**
30031
+ * Creates an object representation of this proto.
30032
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
30033
+ * Optional fields that are not set will be set to undefined.
30034
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
30035
+ * For the list of reserved names please see:
30036
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
30037
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
30038
+ * JSPB instance for transitional soy proto support:
30039
+ * http://goto/soy-param-migration
30040
+ * @return {!Object}
30041
+ */
30042
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.toObject = function(opt_includeInstance) {
30043
+ return proto.payment.CheckWithdrawalEligibilityResponse.toObject(opt_includeInstance, this);
30044
+ };
30045
+
30046
+
30047
+ /**
30048
+ * Static version of the {@see toObject} method.
30049
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
30050
+ * the JSPB instance for transitional soy proto support:
30051
+ * http://goto/soy-param-migration
30052
+ * @param {!proto.payment.CheckWithdrawalEligibilityResponse} msg The msg instance to transform.
30053
+ * @return {!Object}
30054
+ * @suppress {unusedLocalVariables} f is only used for nested messages
30055
+ */
30056
+ proto.payment.CheckWithdrawalEligibilityResponse.toObject = function(includeInstance, msg) {
30057
+ var f, obj = {
30058
+ allowed: jspb.Message.getBooleanFieldWithDefault(msg, 1, false),
30059
+ reason: jspb.Message.getFieldWithDefault(msg, 2, ""),
30060
+ availableRealMinor: jspb.Message.getFieldWithDefault(msg, 3, 0),
30061
+ currency: jspb.Message.getFieldWithDefault(msg, 4, ""),
30062
+ currencyScale: jspb.Message.getFieldWithDefault(msg, 5, 0)
30063
+ };
30064
+
30065
+ if (includeInstance) {
30066
+ obj.$jspbMessageInstance = msg;
30067
+ }
30068
+ return obj;
30069
+ };
30070
+ }
30071
+
30072
+
30073
+ /**
30074
+ * Deserializes binary data (in protobuf wire format).
30075
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
30076
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse}
30077
+ */
30078
+ proto.payment.CheckWithdrawalEligibilityResponse.deserializeBinary = function(bytes) {
30079
+ var reader = new jspb.BinaryReader(bytes);
30080
+ var msg = new proto.payment.CheckWithdrawalEligibilityResponse;
30081
+ return proto.payment.CheckWithdrawalEligibilityResponse.deserializeBinaryFromReader(msg, reader);
30082
+ };
30083
+
30084
+
30085
+ /**
30086
+ * Deserializes binary data (in protobuf wire format) from the
30087
+ * given reader into the given message object.
30088
+ * @param {!proto.payment.CheckWithdrawalEligibilityResponse} msg The message object to deserialize into.
30089
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
30090
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse}
30091
+ */
30092
+ proto.payment.CheckWithdrawalEligibilityResponse.deserializeBinaryFromReader = function(msg, reader) {
30093
+ while (reader.nextField()) {
30094
+ if (reader.isEndGroup()) {
30095
+ break;
30096
+ }
30097
+ var field = reader.getFieldNumber();
30098
+ switch (field) {
30099
+ case 1:
30100
+ var value = /** @type {boolean} */ (reader.readBool());
30101
+ msg.setAllowed(value);
30102
+ break;
30103
+ case 2:
30104
+ var value = /** @type {string} */ (reader.readString());
30105
+ msg.setReason(value);
30106
+ break;
30107
+ case 3:
30108
+ var value = /** @type {number} */ (reader.readInt64());
30109
+ msg.setAvailableRealMinor(value);
30110
+ break;
30111
+ case 4:
30112
+ var value = /** @type {string} */ (reader.readString());
30113
+ msg.setCurrency(value);
30114
+ break;
30115
+ case 5:
30116
+ var value = /** @type {number} */ (reader.readInt32());
30117
+ msg.setCurrencyScale(value);
30118
+ break;
30119
+ default:
30120
+ reader.skipField();
30121
+ break;
30122
+ }
30123
+ }
30124
+ return msg;
30125
+ };
30126
+
30127
+
30128
+ /**
30129
+ * Serializes the message to binary data (in protobuf wire format).
30130
+ * @return {!Uint8Array}
30131
+ */
30132
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.serializeBinary = function() {
30133
+ var writer = new jspb.BinaryWriter();
30134
+ proto.payment.CheckWithdrawalEligibilityResponse.serializeBinaryToWriter(this, writer);
30135
+ return writer.getResultBuffer();
30136
+ };
30137
+
30138
+
30139
+ /**
30140
+ * Serializes the given message to binary data (in protobuf wire
30141
+ * format), writing to the given BinaryWriter.
30142
+ * @param {!proto.payment.CheckWithdrawalEligibilityResponse} message
30143
+ * @param {!jspb.BinaryWriter} writer
30144
+ * @suppress {unusedLocalVariables} f is only used for nested messages
30145
+ */
30146
+ proto.payment.CheckWithdrawalEligibilityResponse.serializeBinaryToWriter = function(message, writer) {
30147
+ var f = undefined;
30148
+ f = message.getAllowed();
30149
+ if (f) {
30150
+ writer.writeBool(
30151
+ 1,
30152
+ f
30153
+ );
30154
+ }
30155
+ f = /** @type {string} */ (jspb.Message.getField(message, 2));
30156
+ if (f != null) {
30157
+ writer.writeString(
30158
+ 2,
30159
+ f
30160
+ );
30161
+ }
30162
+ f = /** @type {number} */ (jspb.Message.getField(message, 3));
30163
+ if (f != null) {
30164
+ writer.writeInt64(
30165
+ 3,
30166
+ f
30167
+ );
30168
+ }
30169
+ f = /** @type {string} */ (jspb.Message.getField(message, 4));
30170
+ if (f != null) {
30171
+ writer.writeString(
30172
+ 4,
30173
+ f
30174
+ );
30175
+ }
30176
+ f = /** @type {number} */ (jspb.Message.getField(message, 5));
30177
+ if (f != null) {
30178
+ writer.writeInt32(
30179
+ 5,
30180
+ f
30181
+ );
30182
+ }
30183
+ };
30184
+
30185
+
30186
+ /**
30187
+ * optional bool allowed = 1;
30188
+ * @return {boolean}
30189
+ */
30190
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.getAllowed = function() {
30191
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false));
30192
+ };
30193
+
30194
+
30195
+ /**
30196
+ * @param {boolean} value
30197
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30198
+ */
30199
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.setAllowed = function(value) {
30200
+ return jspb.Message.setProto3BooleanField(this, 1, value);
30201
+ };
30202
+
30203
+
30204
+ /**
30205
+ * optional string reason = 2;
30206
+ * @return {string}
30207
+ */
30208
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.getReason = function() {
30209
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
30210
+ };
30211
+
30212
+
30213
+ /**
30214
+ * @param {string} value
30215
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30216
+ */
30217
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.setReason = function(value) {
30218
+ return jspb.Message.setField(this, 2, value);
30219
+ };
30220
+
30221
+
30222
+ /**
30223
+ * Clears the field making it undefined.
30224
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30225
+ */
30226
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.clearReason = function() {
30227
+ return jspb.Message.setField(this, 2, undefined);
30228
+ };
30229
+
30230
+
30231
+ /**
30232
+ * Returns whether this field is set.
30233
+ * @return {boolean}
30234
+ */
30235
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.hasReason = function() {
30236
+ return jspb.Message.getField(this, 2) != null;
30237
+ };
30238
+
30239
+
30240
+ /**
30241
+ * optional int64 available_real_minor = 3;
30242
+ * @return {number}
30243
+ */
30244
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.getAvailableRealMinor = function() {
30245
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
30246
+ };
30247
+
30248
+
30249
+ /**
30250
+ * @param {number} value
30251
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30252
+ */
30253
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.setAvailableRealMinor = function(value) {
30254
+ return jspb.Message.setField(this, 3, value);
30255
+ };
30256
+
30257
+
30258
+ /**
30259
+ * Clears the field making it undefined.
30260
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30261
+ */
30262
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.clearAvailableRealMinor = function() {
30263
+ return jspb.Message.setField(this, 3, undefined);
30264
+ };
30265
+
30266
+
30267
+ /**
30268
+ * Returns whether this field is set.
30269
+ * @return {boolean}
30270
+ */
30271
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.hasAvailableRealMinor = function() {
30272
+ return jspb.Message.getField(this, 3) != null;
30273
+ };
30274
+
30275
+
30276
+ /**
30277
+ * optional string currency = 4;
30278
+ * @return {string}
30279
+ */
30280
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.getCurrency = function() {
30281
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
30282
+ };
30283
+
30284
+
30285
+ /**
30286
+ * @param {string} value
30287
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30288
+ */
30289
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.setCurrency = function(value) {
30290
+ return jspb.Message.setField(this, 4, value);
30291
+ };
30292
+
30293
+
30294
+ /**
30295
+ * Clears the field making it undefined.
30296
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30297
+ */
30298
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.clearCurrency = function() {
30299
+ return jspb.Message.setField(this, 4, undefined);
30300
+ };
30301
+
30302
+
30303
+ /**
30304
+ * Returns whether this field is set.
30305
+ * @return {boolean}
30306
+ */
30307
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.hasCurrency = function() {
30308
+ return jspb.Message.getField(this, 4) != null;
30309
+ };
30310
+
30311
+
30312
+ /**
30313
+ * optional int32 currency_scale = 5;
30314
+ * @return {number}
30315
+ */
30316
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.getCurrencyScale = function() {
30317
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
30318
+ };
30319
+
30320
+
30321
+ /**
30322
+ * @param {number} value
30323
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30324
+ */
30325
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.setCurrencyScale = function(value) {
30326
+ return jspb.Message.setField(this, 5, value);
30327
+ };
30328
+
30329
+
30330
+ /**
30331
+ * Clears the field making it undefined.
30332
+ * @return {!proto.payment.CheckWithdrawalEligibilityResponse} returns this
30333
+ */
30334
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.clearCurrencyScale = function() {
30335
+ return jspb.Message.setField(this, 5, undefined);
30336
+ };
30337
+
30338
+
30339
+ /**
30340
+ * Returns whether this field is set.
30341
+ * @return {boolean}
30342
+ */
30343
+ proto.payment.CheckWithdrawalEligibilityResponse.prototype.hasCurrencyScale = function() {
30344
+ return jspb.Message.getField(this, 5) != null;
30345
+ };
30346
+
30347
+
30348
+
30349
+
30350
+
29795
30351
  if (jspb.Message.GENERATE_TO_OBJECT) {
29796
30352
  /**
29797
30353
  * Creates an object representation of this proto.
package/user/user.proto CHANGED
@@ -476,7 +476,8 @@ message UserBalanceRequest {
476
476
  message CheckWithdrawalEligibilityRequest {
477
477
  int32 user_id = 1;
478
478
  string currency = 2;
479
- int64 amount_minor = 3;
479
+ optional int64 amount_minor = 3;
480
+ optional string amount = 4;
480
481
  }
481
482
  message CheckWithdrawalEligibilityResponse {
482
483
  bool allowed = 1;
package/user/user_pb.js CHANGED
@@ -18255,7 +18255,8 @@ proto.user.CheckWithdrawalEligibilityRequest.toObject = function(includeInstance
18255
18255
  var f, obj = {
18256
18256
  userId: jspb.Message.getFieldWithDefault(msg, 1, 0),
18257
18257
  currency: jspb.Message.getFieldWithDefault(msg, 2, ""),
18258
- amountMinor: jspb.Message.getFieldWithDefault(msg, 3, 0)
18258
+ amountMinor: jspb.Message.getFieldWithDefault(msg, 3, 0),
18259
+ amount: jspb.Message.getFieldWithDefault(msg, 4, "")
18259
18260
  };
18260
18261
 
18261
18262
  if (includeInstance) {
@@ -18304,6 +18305,10 @@ proto.user.CheckWithdrawalEligibilityRequest.deserializeBinaryFromReader = funct
18304
18305
  var value = /** @type {number} */ (reader.readInt64());
18305
18306
  msg.setAmountMinor(value);
18306
18307
  break;
18308
+ case 4:
18309
+ var value = /** @type {string} */ (reader.readString());
18310
+ msg.setAmount(value);
18311
+ break;
18307
18312
  default:
18308
18313
  reader.skipField();
18309
18314
  break;
@@ -18347,13 +18352,20 @@ proto.user.CheckWithdrawalEligibilityRequest.serializeBinaryToWriter = function(
18347
18352
  f
18348
18353
  );
18349
18354
  }
18350
- f = message.getAmountMinor();
18351
- if (f !== 0) {
18355
+ f = /** @type {number} */ (jspb.Message.getField(message, 3));
18356
+ if (f != null) {
18352
18357
  writer.writeInt64(
18353
18358
  3,
18354
18359
  f
18355
18360
  );
18356
18361
  }
18362
+ f = /** @type {string} */ (jspb.Message.getField(message, 4));
18363
+ if (f != null) {
18364
+ writer.writeString(
18365
+ 4,
18366
+ f
18367
+ );
18368
+ }
18357
18369
  };
18358
18370
 
18359
18371
 
@@ -18407,7 +18419,61 @@ proto.user.CheckWithdrawalEligibilityRequest.prototype.getAmountMinor = function
18407
18419
  * @return {!proto.user.CheckWithdrawalEligibilityRequest} returns this
18408
18420
  */
18409
18421
  proto.user.CheckWithdrawalEligibilityRequest.prototype.setAmountMinor = function(value) {
18410
- return jspb.Message.setProto3IntField(this, 3, value);
18422
+ return jspb.Message.setField(this, 3, value);
18423
+ };
18424
+
18425
+
18426
+ /**
18427
+ * Clears the field making it undefined.
18428
+ * @return {!proto.user.CheckWithdrawalEligibilityRequest} returns this
18429
+ */
18430
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.clearAmountMinor = function() {
18431
+ return jspb.Message.setField(this, 3, undefined);
18432
+ };
18433
+
18434
+
18435
+ /**
18436
+ * Returns whether this field is set.
18437
+ * @return {boolean}
18438
+ */
18439
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.hasAmountMinor = function() {
18440
+ return jspb.Message.getField(this, 3) != null;
18441
+ };
18442
+
18443
+
18444
+ /**
18445
+ * optional string amount = 4;
18446
+ * @return {string}
18447
+ */
18448
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.getAmount = function() {
18449
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
18450
+ };
18451
+
18452
+
18453
+ /**
18454
+ * @param {string} value
18455
+ * @return {!proto.user.CheckWithdrawalEligibilityRequest} returns this
18456
+ */
18457
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.setAmount = function(value) {
18458
+ return jspb.Message.setField(this, 4, value);
18459
+ };
18460
+
18461
+
18462
+ /**
18463
+ * Clears the field making it undefined.
18464
+ * @return {!proto.user.CheckWithdrawalEligibilityRequest} returns this
18465
+ */
18466
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.clearAmount = function() {
18467
+ return jspb.Message.setField(this, 4, undefined);
18468
+ };
18469
+
18470
+
18471
+ /**
18472
+ * Returns whether this field is set.
18473
+ * @return {boolean}
18474
+ */
18475
+ proto.user.CheckWithdrawalEligibilityRequest.prototype.hasAmount = function() {
18476
+ return jspb.Message.getField(this, 4) != null;
18411
18477
  };
18412
18478
 
18413
18479