@stashfin/grpc 1.2.247 → 1.2.248

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": "@stashfin/grpc",
3
- "version": "1.2.247",
3
+ "version": "1.2.248",
4
4
  "description": "Grpc proto manger",
5
5
  "scripts": {
6
6
  "prebuild": "rimraf src/ts && mkdirp src/ts && mkdirp dist",
@@ -23,6 +23,7 @@ export interface response_Fee_data {
23
23
  amount: number;
24
24
  other_fees: number;
25
25
  total_amount: number;
26
+ modes: string[];
26
27
  }
27
28
  export interface response_Data {
28
29
  fee_data: response_Fee_data[];
@@ -283,7 +283,7 @@ exports.response_Fees = {
283
283
  },
284
284
  };
285
285
  function createBaseresponse_Fee_data() {
286
- return { gateway: "", fees: undefined, amount: 0, other_fees: 0, total_amount: 0 };
286
+ return { gateway: "", fees: undefined, amount: 0, other_fees: 0, total_amount: 0, modes: [] };
287
287
  }
288
288
  exports.response_Fee_data = {
289
289
  encode(message, writer = minimal_1.default.Writer.create()) {
@@ -302,6 +302,9 @@ exports.response_Fee_data = {
302
302
  if (message.total_amount !== 0) {
303
303
  writer.uint32(41).double(message.total_amount);
304
304
  }
305
+ for (const v of message.modes) {
306
+ writer.uint32(50).string(v);
307
+ }
305
308
  return writer;
306
309
  },
307
310
  decode(input, length) {
@@ -341,6 +344,12 @@ exports.response_Fee_data = {
341
344
  }
342
345
  message.total_amount = reader.double();
343
346
  continue;
347
+ case 6:
348
+ if (tag !== 50) {
349
+ break;
350
+ }
351
+ message.modes.push(reader.string());
352
+ continue;
344
353
  }
345
354
  if ((tag & 7) === 4 || tag === 0) {
346
355
  break;
@@ -356,6 +365,7 @@ exports.response_Fee_data = {
356
365
  amount: isSet(object.amount) ? globalThis.Number(object.amount) : 0,
357
366
  other_fees: isSet(object.other_fees) ? globalThis.Number(object.other_fees) : 0,
358
367
  total_amount: isSet(object.total_amount) ? globalThis.Number(object.total_amount) : 0,
368
+ modes: globalThis.Array.isArray(object?.modes) ? object.modes.map((e) => globalThis.String(e)) : [],
359
369
  };
360
370
  },
361
371
  toJSON(message) {
@@ -375,6 +385,9 @@ exports.response_Fee_data = {
375
385
  if (message.total_amount !== 0) {
376
386
  obj.total_amount = message.total_amount;
377
387
  }
388
+ if (message.modes?.length) {
389
+ obj.modes = message.modes;
390
+ }
378
391
  return obj;
379
392
  },
380
393
  create(base) {
@@ -389,6 +402,7 @@ exports.response_Fee_data = {
389
402
  message.amount = object.amount ?? 0;
390
403
  message.other_fees = object.other_fees ?? 0;
391
404
  message.total_amount = object.total_amount ?? 0;
405
+ message.modes = object.modes?.map((e) => e) || [];
392
406
  return message;
393
407
  },
394
408
  };