protobuf-platform 1.2.288 → 1.2.290

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.
@@ -158,6 +158,7 @@ message R2FileRequest {
158
158
  string type = 4;
159
159
  optional string name = 5;
160
160
  optional string folder = 6;
161
+ optional string object_key = 7;
161
162
  }
162
163
  message R2FileResponse {
163
164
  string key = 1;
@@ -5724,7 +5724,8 @@ proto.config.R2FileRequest.toObject = function(includeInstance, msg) {
5724
5724
  file: msg.getFile_asB64(),
5725
5725
  type: jspb.Message.getFieldWithDefault(msg, 4, ""),
5726
5726
  name: jspb.Message.getFieldWithDefault(msg, 5, ""),
5727
- folder: jspb.Message.getFieldWithDefault(msg, 6, "")
5727
+ folder: jspb.Message.getFieldWithDefault(msg, 6, ""),
5728
+ objectKey: jspb.Message.getFieldWithDefault(msg, 7, "")
5728
5729
  };
5729
5730
 
5730
5731
  if (includeInstance) {
@@ -5785,6 +5786,10 @@ proto.config.R2FileRequest.deserializeBinaryFromReader = function(msg, reader) {
5785
5786
  var value = /** @type {string} */ (reader.readString());
5786
5787
  msg.setFolder(value);
5787
5788
  break;
5789
+ case 7:
5790
+ var value = /** @type {string} */ (reader.readString());
5791
+ msg.setObjectKey(value);
5792
+ break;
5788
5793
  default:
5789
5794
  reader.skipField();
5790
5795
  break;
@@ -5856,6 +5861,13 @@ proto.config.R2FileRequest.serializeBinaryToWriter = function(message, writer) {
5856
5861
  f
5857
5862
  );
5858
5863
  }
5864
+ f = /** @type {string} */ (jspb.Message.getField(message, 7));
5865
+ if (f != null) {
5866
+ writer.writeString(
5867
+ 7,
5868
+ f
5869
+ );
5870
+ }
5859
5871
  };
5860
5872
 
5861
5873
 
@@ -6027,6 +6039,42 @@ proto.config.R2FileRequest.prototype.hasFolder = function() {
6027
6039
  };
6028
6040
 
6029
6041
 
6042
+ /**
6043
+ * optional string object_key = 7;
6044
+ * @return {string}
6045
+ */
6046
+ proto.config.R2FileRequest.prototype.getObjectKey = function() {
6047
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
6048
+ };
6049
+
6050
+
6051
+ /**
6052
+ * @param {string} value
6053
+ * @return {!proto.config.R2FileRequest} returns this
6054
+ */
6055
+ proto.config.R2FileRequest.prototype.setObjectKey = function(value) {
6056
+ return jspb.Message.setField(this, 7, value);
6057
+ };
6058
+
6059
+
6060
+ /**
6061
+ * Clears the field making it undefined.
6062
+ * @return {!proto.config.R2FileRequest} returns this
6063
+ */
6064
+ proto.config.R2FileRequest.prototype.clearObjectKey = function() {
6065
+ return jspb.Message.setField(this, 7, undefined);
6066
+ };
6067
+
6068
+
6069
+ /**
6070
+ * Returns whether this field is set.
6071
+ * @return {boolean}
6072
+ */
6073
+ proto.config.R2FileRequest.prototype.hasObjectKey = function() {
6074
+ return jspb.Message.getField(this, 7) != null;
6075
+ };
6076
+
6077
+
6030
6078
 
6031
6079
 
6032
6080
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "protobuf-platform",
3
- "version": "1.2.288",
3
+ "version": "1.2.290",
4
4
  "description": "Protobuf structures",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -43,6 +43,10 @@ service Payment {
43
43
  rpc getSegmentedUsers(SegmentedUserRequest) returns (SegmentedUserResponse);
44
44
  //Currency source-of-truth
45
45
  rpc getCurrencyMetadata(GetCurrencyMetadataRequest) returns (CurrencyMetadataResponse);
46
+ //Currency directory
47
+ rpc readSingleCurrency(GetCurrencyRequest) returns (CurrencyResponse);
48
+ rpc readListCurrencies(PaginationRequest) returns (CurrencyItemsResponse);
49
+ rpc syncCurrencies(SyncCurrenciesRequest) returns (PaymentStatusResponse);
46
50
  }
47
51
  //Technical
48
52
  message PingRequest { string ping = 1; }
@@ -444,4 +448,36 @@ message GetCurrencyMetadataRequest {
444
448
  message CurrencyMetadataResponse {
445
449
  string currency = 1;
446
450
  int32 currency_scale = 2;
451
+ }
452
+ message GetCurrencyRequest {
453
+ int32 id = 1;
454
+ }
455
+ message SyncCurrenciesRequest {
456
+ optional string source = 1;
457
+ }
458
+ message CurrencyItem {
459
+ optional int32 id = 1;
460
+ optional string code = 2;
461
+ optional string type = 3;
462
+ optional string name = 4;
463
+ optional string symbol = 5;
464
+ optional int32 scale = 6;
465
+ optional string external_source = 7;
466
+ optional string external_id = 8;
467
+ optional string source_payload = 9;
468
+ optional string price = 10;
469
+ optional string price_currency_code = 11;
470
+ optional string price_updated_at = 12;
471
+ optional int32 is_active = 13;
472
+ optional int32 is_system = 14;
473
+ optional string created_at = 15;
474
+ optional string updated_at = 16;
475
+ }
476
+ message CurrencyResponse {
477
+ CurrencyItem data = 1;
478
+ }
479
+ message CurrencyItemsResponse {
480
+ repeated CurrencyItem items = 1;
481
+ optional int32 total_pages = 2;
482
+ optional int32 total_items = 3;
447
483
  }
@@ -15,6 +15,17 @@ function deserialize_payment_AttemptDepositRequest(buffer_arg) {
15
15
  return payment_pb.AttemptDepositRequest.deserializeBinary(new Uint8Array(buffer_arg));
16
16
  }
17
17
 
18
+ function serialize_payment_CurrencyItemsResponse(arg) {
19
+ if (!(arg instanceof payment_pb.CurrencyItemsResponse)) {
20
+ throw new Error('Expected argument of type payment.CurrencyItemsResponse');
21
+ }
22
+ return Buffer.from(arg.serializeBinary());
23
+ }
24
+
25
+ function deserialize_payment_CurrencyItemsResponse(buffer_arg) {
26
+ return payment_pb.CurrencyItemsResponse.deserializeBinary(new Uint8Array(buffer_arg));
27
+ }
28
+
18
29
  function serialize_payment_CurrencyMetadataResponse(arg) {
19
30
  if (!(arg instanceof payment_pb.CurrencyMetadataResponse)) {
20
31
  throw new Error('Expected argument of type payment.CurrencyMetadataResponse');
@@ -26,6 +37,17 @@ function deserialize_payment_CurrencyMetadataResponse(buffer_arg) {
26
37
  return payment_pb.CurrencyMetadataResponse.deserializeBinary(new Uint8Array(buffer_arg));
27
38
  }
28
39
 
40
+ function serialize_payment_CurrencyResponse(arg) {
41
+ if (!(arg instanceof payment_pb.CurrencyResponse)) {
42
+ throw new Error('Expected argument of type payment.CurrencyResponse');
43
+ }
44
+ return Buffer.from(arg.serializeBinary());
45
+ }
46
+
47
+ function deserialize_payment_CurrencyResponse(buffer_arg) {
48
+ return payment_pb.CurrencyResponse.deserializeBinary(new Uint8Array(buffer_arg));
49
+ }
50
+
29
51
  function serialize_payment_DepositItemsResponse(arg) {
30
52
  if (!(arg instanceof payment_pb.DepositItemsResponse)) {
31
53
  throw new Error('Expected argument of type payment.DepositItemsResponse');
@@ -114,6 +136,17 @@ function deserialize_payment_GetCurrencyMetadataRequest(buffer_arg) {
114
136
  return payment_pb.GetCurrencyMetadataRequest.deserializeBinary(new Uint8Array(buffer_arg));
115
137
  }
116
138
 
139
+ function serialize_payment_GetCurrencyRequest(arg) {
140
+ if (!(arg instanceof payment_pb.GetCurrencyRequest)) {
141
+ throw new Error('Expected argument of type payment.GetCurrencyRequest');
142
+ }
143
+ return Buffer.from(arg.serializeBinary());
144
+ }
145
+
146
+ function deserialize_payment_GetCurrencyRequest(buffer_arg) {
147
+ return payment_pb.GetCurrencyRequest.deserializeBinary(new Uint8Array(buffer_arg));
148
+ }
149
+
117
150
  function serialize_payment_GetDepositRequest(arg) {
118
151
  if (!(arg instanceof payment_pb.GetDepositRequest)) {
119
152
  throw new Error('Expected argument of type payment.GetDepositRequest');
@@ -422,6 +455,17 @@ function deserialize_payment_SegmentedUserResponse(buffer_arg) {
422
455
  return payment_pb.SegmentedUserResponse.deserializeBinary(new Uint8Array(buffer_arg));
423
456
  }
424
457
 
458
+ function serialize_payment_SyncCurrenciesRequest(arg) {
459
+ if (!(arg instanceof payment_pb.SyncCurrenciesRequest)) {
460
+ throw new Error('Expected argument of type payment.SyncCurrenciesRequest');
461
+ }
462
+ return Buffer.from(arg.serializeBinary());
463
+ }
464
+
465
+ function deserialize_payment_SyncCurrenciesRequest(buffer_arg) {
466
+ return payment_pb.SyncCurrenciesRequest.deserializeBinary(new Uint8Array(buffer_arg));
467
+ }
468
+
425
469
  function serialize_payment_UserDepositItemsResponse(arg) {
426
470
  if (!(arg instanceof payment_pb.UserDepositItemsResponse)) {
427
471
  throw new Error('Expected argument of type payment.UserDepositItemsResponse');
@@ -817,6 +861,40 @@ getCurrencyMetadata: {
817
861
  responseSerialize: serialize_payment_CurrencyMetadataResponse,
818
862
  responseDeserialize: deserialize_payment_CurrencyMetadataResponse,
819
863
  },
864
+ // Currency directory
865
+ readSingleCurrency: {
866
+ path: '/payment.Payment/readSingleCurrency',
867
+ requestStream: false,
868
+ responseStream: false,
869
+ requestType: payment_pb.GetCurrencyRequest,
870
+ responseType: payment_pb.CurrencyResponse,
871
+ requestSerialize: serialize_payment_GetCurrencyRequest,
872
+ requestDeserialize: deserialize_payment_GetCurrencyRequest,
873
+ responseSerialize: serialize_payment_CurrencyResponse,
874
+ responseDeserialize: deserialize_payment_CurrencyResponse,
875
+ },
876
+ readListCurrencies: {
877
+ path: '/payment.Payment/readListCurrencies',
878
+ requestStream: false,
879
+ responseStream: false,
880
+ requestType: payment_pb.PaginationRequest,
881
+ responseType: payment_pb.CurrencyItemsResponse,
882
+ requestSerialize: serialize_payment_PaginationRequest,
883
+ requestDeserialize: deserialize_payment_PaginationRequest,
884
+ responseSerialize: serialize_payment_CurrencyItemsResponse,
885
+ responseDeserialize: deserialize_payment_CurrencyItemsResponse,
886
+ },
887
+ syncCurrencies: {
888
+ path: '/payment.Payment/syncCurrencies',
889
+ requestStream: false,
890
+ responseStream: false,
891
+ requestType: payment_pb.SyncCurrenciesRequest,
892
+ responseType: payment_pb.PaymentStatusResponse,
893
+ requestSerialize: serialize_payment_SyncCurrenciesRequest,
894
+ requestDeserialize: deserialize_payment_SyncCurrenciesRequest,
895
+ responseSerialize: serialize_payment_PaymentStatusResponse,
896
+ responseDeserialize: deserialize_payment_PaymentStatusResponse,
897
+ },
820
898
  };
821
899
 
822
900
  exports.PaymentClient = grpc.makeGenericClientConstructor(PaymentService, 'Payment');