@sellout/models 0.0.231 → 0.0.234

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.
Files changed (64) hide show
  1. package/.dist/graphql/fragments/event.fragment.js +2 -0
  2. package/.dist/graphql/fragments/event.fragment.js.map +1 -1
  3. package/.dist/graphql/fragments/order.fragment.d.ts +1 -0
  4. package/.dist/graphql/fragments/order.fragment.js +23 -0
  5. package/.dist/graphql/fragments/order.fragment.js.map +1 -1
  6. package/.dist/graphql/mutations/createOrder.mutation.js +1 -0
  7. package/.dist/graphql/mutations/createOrder.mutation.js.map +1 -1
  8. package/.dist/graphql/queries/discountCodeVerify.query.d.ts +2 -0
  9. package/.dist/graphql/queries/discountCodeVerify.query.js +34 -0
  10. package/.dist/graphql/queries/discountCodeVerify.query.js.map +1 -0
  11. package/.dist/graphql/queries/order.query.js +4 -0
  12. package/.dist/graphql/queries/order.query.js.map +1 -1
  13. package/.dist/interfaces/IAnalytics.d.ts +3 -0
  14. package/.dist/interfaces/IAnalytics.js +3 -0
  15. package/.dist/interfaces/IAnalytics.js.map +1 -1
  16. package/.dist/interfaces/ICreateOrderParams.d.ts +3 -0
  17. package/.dist/interfaces/IEventPromotion.d.ts +5 -0
  18. package/.dist/interfaces/IEventPromotion.js +6 -1
  19. package/.dist/interfaces/IEventPromotion.js.map +1 -1
  20. package/.dist/interfaces/IFee.d.ts +3 -8
  21. package/.dist/interfaces/IFee.js +4 -10
  22. package/.dist/interfaces/IFee.js.map +1 -1
  23. package/.dist/interfaces/IOrder.d.ts +2 -0
  24. package/.dist/interfaces/IOrder.js.map +1 -1
  25. package/.dist/interfaces/IOrderSummary.d.ts +1 -0
  26. package/.dist/interfaces/IOrderTicket.d.ts +1 -0
  27. package/.dist/interfaces/IPayment.d.ts +2 -0
  28. package/.dist/schemas/Event.d.ts +4 -0
  29. package/.dist/schemas/Event.js +4 -0
  30. package/.dist/schemas/Event.js.map +1 -1
  31. package/.dist/schemas/Order.d.ts +21 -0
  32. package/.dist/schemas/Order.js +21 -0
  33. package/.dist/schemas/Order.js.map +1 -1
  34. package/.dist/sellout-proto.js +705 -6
  35. package/.dist/utils/AnalyticsUtil.d.ts +2 -0
  36. package/.dist/utils/AnalyticsUtil.js +72 -0
  37. package/.dist/utils/AnalyticsUtil.js.map +1 -1
  38. package/.dist/utils/OrderUtil.js +1 -1
  39. package/.dist/utils/OrderUtil.js.map +1 -1
  40. package/.dist/utils/PaymentUtil.d.ts +2 -0
  41. package/.dist/utils/PaymentUtil.js +382 -33
  42. package/.dist/utils/PaymentUtil.js.map +1 -1
  43. package/package.json +3 -3
  44. package/src/graphql/fragments/event.fragment.ts +2 -0
  45. package/src/graphql/fragments/order.fragment.ts +24 -0
  46. package/src/graphql/mutations/createOrder.mutation.ts +1 -0
  47. package/src/graphql/queries/discountCodeVerify.query.ts +30 -0
  48. package/src/graphql/queries/order.query.ts +4 -0
  49. package/src/interfaces/IAnalytics.ts +3 -0
  50. package/src/interfaces/ICreateOrderParams.ts +4 -0
  51. package/src/interfaces/IEventPromotion.ts +7 -0
  52. package/src/interfaces/IFee.ts +3 -10
  53. package/src/interfaces/IOrder.ts +2 -0
  54. package/src/interfaces/IOrderSummary.ts +1 -0
  55. package/src/interfaces/IOrderTicket.ts +1 -0
  56. package/src/interfaces/IPayment.ts +3 -1
  57. package/src/proto/email.proto +1 -0
  58. package/src/proto/event.proto +18 -1
  59. package/src/proto/order.proto +15 -0
  60. package/src/schemas/Event.ts +4 -0
  61. package/src/schemas/Order.ts +21 -0
  62. package/src/utils/AnalyticsUtil.ts +123 -2
  63. package/src/utils/OrderUtil.ts +2 -1
  64. package/src/utils/PaymentUtil.ts +595 -96
@@ -13049,6 +13049,8 @@ $root.Order = (function() {
13049
13049
  * @property {Array.<IorderFees>|null} [fees] Order fees
13050
13050
  * @property {IProcessingFees|null} [promoterFee] Order promoterFee
13051
13051
  * @property {string|null} [email] Order email
13052
+ * @property {string|null} [discountCode] Order discountCode
13053
+ * @property {number|null} [discountAmount] Order discountAmount
13052
13054
  */
13053
13055
 
13054
13056
  /**
@@ -13347,6 +13349,22 @@ $root.Order = (function() {
13347
13349
  */
13348
13350
  Order.prototype.email = "";
13349
13351
 
13352
+ /**
13353
+ * Order discountCode.
13354
+ * @member {string} discountCode
13355
+ * @memberof Order
13356
+ * @instance
13357
+ */
13358
+ Order.prototype.discountCode = "";
13359
+
13360
+ /**
13361
+ * Order discountAmount.
13362
+ * @member {number} discountAmount
13363
+ * @memberof Order
13364
+ * @instance
13365
+ */
13366
+ Order.prototype.discountAmount = 0;
13367
+
13350
13368
  /**
13351
13369
  * Creates a new Order instance using the specified properties.
13352
13370
  * @function create
@@ -13448,6 +13466,10 @@ $root.Order = (function() {
13448
13466
  $root.ProcessingFees.encode(message.promoterFee, writer.uint32(/* id 32, wireType 2 =*/258).fork()).ldelim();
13449
13467
  if (message.email != null && Object.hasOwnProperty.call(message, "email"))
13450
13468
  writer.uint32(/* id 33, wireType 2 =*/266).string(message.email);
13469
+ if (message.discountCode != null && Object.hasOwnProperty.call(message, "discountCode"))
13470
+ writer.uint32(/* id 34, wireType 2 =*/274).string(message.discountCode);
13471
+ if (message.discountAmount != null && Object.hasOwnProperty.call(message, "discountAmount"))
13472
+ writer.uint32(/* id 35, wireType 0 =*/280).int32(message.discountAmount);
13451
13473
  return writer;
13452
13474
  };
13453
13475
 
@@ -13602,6 +13624,12 @@ $root.Order = (function() {
13602
13624
  case 33:
13603
13625
  message.email = reader.string();
13604
13626
  break;
13627
+ case 34:
13628
+ message.discountCode = reader.string();
13629
+ break;
13630
+ case 35:
13631
+ message.discountAmount = reader.int32();
13632
+ break;
13605
13633
  default:
13606
13634
  reader.skipType(tag & 7);
13607
13635
  break;
@@ -13791,6 +13819,12 @@ $root.Order = (function() {
13791
13819
  if (message.email != null && message.hasOwnProperty("email"))
13792
13820
  if (!$util.isString(message.email))
13793
13821
  return "email: string expected";
13822
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
13823
+ if (!$util.isString(message.discountCode))
13824
+ return "discountCode: string expected";
13825
+ if (message.discountAmount != null && message.hasOwnProperty("discountAmount"))
13826
+ if (!$util.isInteger(message.discountAmount))
13827
+ return "discountAmount: integer expected";
13794
13828
  return null;
13795
13829
  };
13796
13830
 
@@ -13943,6 +13977,10 @@ $root.Order = (function() {
13943
13977
  }
13944
13978
  if (object.email != null)
13945
13979
  message.email = String(object.email);
13980
+ if (object.discountCode != null)
13981
+ message.discountCode = String(object.discountCode);
13982
+ if (object.discountAmount != null)
13983
+ message.discountAmount = object.discountAmount | 0;
13946
13984
  return message;
13947
13985
  };
13948
13986
 
@@ -13996,6 +14034,8 @@ $root.Order = (function() {
13996
14034
  object.parentSeasonOrderId = "";
13997
14035
  object.promoterFee = null;
13998
14036
  object.email = "";
14037
+ object.discountCode = "";
14038
+ object.discountAmount = 0;
13999
14039
  }
14000
14040
  if (message._id != null && message.hasOwnProperty("_id"))
14001
14041
  object._id = message._id;
@@ -14092,6 +14132,10 @@ $root.Order = (function() {
14092
14132
  object.promoterFee = $root.ProcessingFees.toObject(message.promoterFee, options);
14093
14133
  if (message.email != null && message.hasOwnProperty("email"))
14094
14134
  object.email = message.email;
14135
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
14136
+ object.discountCode = message.discountCode;
14137
+ if (message.discountAmount != null && message.hasOwnProperty("discountAmount"))
14138
+ object.discountAmount = message.discountAmount;
14095
14139
  return object;
14096
14140
  };
14097
14141
 
@@ -14349,6 +14393,7 @@ $root.OrderTicket = (function() {
14349
14393
  * @property {boolean|null} [isMemberIdValid] OrderTicket isMemberIdValid
14350
14394
  * @property {ITeiMemberInfoParams|null} [teiMemberInfo] OrderTicket teiMemberInfo
14351
14395
  * @property {boolean|null} [guestTicket] OrderTicket guestTicket
14396
+ * @property {number|null} [origionalPrice] OrderTicket origionalPrice
14352
14397
  */
14353
14398
 
14354
14399
  /**
@@ -14520,6 +14565,14 @@ $root.OrderTicket = (function() {
14520
14565
  */
14521
14566
  OrderTicket.prototype.guestTicket = false;
14522
14567
 
14568
+ /**
14569
+ * OrderTicket origionalPrice.
14570
+ * @member {number} origionalPrice
14571
+ * @memberof OrderTicket
14572
+ * @instance
14573
+ */
14574
+ OrderTicket.prototype.origionalPrice = 0;
14575
+
14523
14576
  /**
14524
14577
  * Creates a new OrderTicket instance using the specified properties.
14525
14578
  * @function create
@@ -14584,6 +14637,8 @@ $root.OrderTicket = (function() {
14584
14637
  $root.TeiMemberInfoParams.encode(message.teiMemberInfo, writer.uint32(/* id 17, wireType 2 =*/138).fork()).ldelim();
14585
14638
  if (message.guestTicket != null && Object.hasOwnProperty.call(message, "guestTicket"))
14586
14639
  writer.uint32(/* id 18, wireType 0 =*/144).bool(message.guestTicket);
14640
+ if (message.origionalPrice != null && Object.hasOwnProperty.call(message, "origionalPrice"))
14641
+ writer.uint32(/* id 19, wireType 0 =*/152).int32(message.origionalPrice);
14587
14642
  return writer;
14588
14643
  };
14589
14644
 
@@ -14679,6 +14734,9 @@ $root.OrderTicket = (function() {
14679
14734
  case 18:
14680
14735
  message.guestTicket = reader.bool();
14681
14736
  break;
14737
+ case 19:
14738
+ message.origionalPrice = reader.int32();
14739
+ break;
14682
14740
  default:
14683
14741
  reader.skipType(tag & 7);
14684
14742
  break;
@@ -14785,6 +14843,9 @@ $root.OrderTicket = (function() {
14785
14843
  if (message.guestTicket != null && message.hasOwnProperty("guestTicket"))
14786
14844
  if (typeof message.guestTicket !== "boolean")
14787
14845
  return "guestTicket: boolean expected";
14846
+ if (message.origionalPrice != null && message.hasOwnProperty("origionalPrice"))
14847
+ if (!$util.isInteger(message.origionalPrice))
14848
+ return "origionalPrice: integer expected";
14788
14849
  return null;
14789
14850
  };
14790
14851
 
@@ -14857,6 +14918,8 @@ $root.OrderTicket = (function() {
14857
14918
  }
14858
14919
  if (object.guestTicket != null)
14859
14920
  message.guestTicket = Boolean(object.guestTicket);
14921
+ if (object.origionalPrice != null)
14922
+ message.origionalPrice = object.origionalPrice | 0;
14860
14923
  return message;
14861
14924
  };
14862
14925
 
@@ -14895,6 +14958,7 @@ $root.OrderTicket = (function() {
14895
14958
  object.isMemberIdValid = false;
14896
14959
  object.teiMemberInfo = null;
14897
14960
  object.guestTicket = false;
14961
+ object.origionalPrice = 0;
14898
14962
  }
14899
14963
  if (message._id != null && message.hasOwnProperty("_id"))
14900
14964
  object._id = message._id;
@@ -14940,6 +15004,8 @@ $root.OrderTicket = (function() {
14940
15004
  object.teiMemberInfo = $root.TeiMemberInfoParams.toObject(message.teiMemberInfo, options);
14941
15005
  if (message.guestTicket != null && message.hasOwnProperty("guestTicket"))
14942
15006
  object.guestTicket = message.guestTicket;
15007
+ if (message.origionalPrice != null && message.hasOwnProperty("origionalPrice"))
15008
+ object.origionalPrice = message.origionalPrice;
14943
15009
  return object;
14944
15010
  };
14945
15011
 
@@ -17031,6 +17097,8 @@ $root.Payment = (function() {
17031
17097
  * @property {string|null} [promotionCode] Payment promotionCode
17032
17098
  * @property {string|null} [paymentMethodType] Payment paymentMethodType
17033
17099
  * @property {number|null} [tax] Payment tax
17100
+ * @property {string|null} [discountCode] Payment discountCode
17101
+ * @property {number|null} [discount] Payment discount
17034
17102
  */
17035
17103
 
17036
17104
  /**
@@ -17137,6 +17205,22 @@ $root.Payment = (function() {
17137
17205
  */
17138
17206
  Payment.prototype.tax = 0;
17139
17207
 
17208
+ /**
17209
+ * Payment discountCode.
17210
+ * @member {string} discountCode
17211
+ * @memberof Payment
17212
+ * @instance
17213
+ */
17214
+ Payment.prototype.discountCode = "";
17215
+
17216
+ /**
17217
+ * Payment discount.
17218
+ * @member {number} discount
17219
+ * @memberof Payment
17220
+ * @instance
17221
+ */
17222
+ Payment.prototype.discount = 0;
17223
+
17140
17224
  /**
17141
17225
  * Creates a new Payment instance using the specified properties.
17142
17226
  * @function create
@@ -17184,6 +17268,10 @@ $root.Payment = (function() {
17184
17268
  writer.uint32(/* id 9, wireType 2 =*/74).string(message.paymentMethodType);
17185
17269
  if (message.tax != null && Object.hasOwnProperty.call(message, "tax"))
17186
17270
  writer.uint32(/* id 10, wireType 0 =*/80).int32(message.tax);
17271
+ if (message.discountCode != null && Object.hasOwnProperty.call(message, "discountCode"))
17272
+ writer.uint32(/* id 11, wireType 2 =*/90).string(message.discountCode);
17273
+ if (message.discount != null && Object.hasOwnProperty.call(message, "discount"))
17274
+ writer.uint32(/* id 12, wireType 0 =*/96).int32(message.discount);
17187
17275
  return writer;
17188
17276
  };
17189
17277
 
@@ -17253,6 +17341,12 @@ $root.Payment = (function() {
17253
17341
  case 10:
17254
17342
  message.tax = reader.int32();
17255
17343
  break;
17344
+ case 11:
17345
+ message.discountCode = reader.string();
17346
+ break;
17347
+ case 12:
17348
+ message.discount = reader.int32();
17349
+ break;
17256
17350
  default:
17257
17351
  reader.skipType(tag & 7);
17258
17352
  break;
@@ -17325,6 +17419,12 @@ $root.Payment = (function() {
17325
17419
  if (message.tax != null && message.hasOwnProperty("tax"))
17326
17420
  if (!$util.isInteger(message.tax))
17327
17421
  return "tax: integer expected";
17422
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
17423
+ if (!$util.isString(message.discountCode))
17424
+ return "discountCode: string expected";
17425
+ if (message.discount != null && message.hasOwnProperty("discount"))
17426
+ if (!$util.isInteger(message.discount))
17427
+ return "discount: integer expected";
17328
17428
  return null;
17329
17429
  };
17330
17430
 
@@ -17367,6 +17467,10 @@ $root.Payment = (function() {
17367
17467
  message.paymentMethodType = String(object.paymentMethodType);
17368
17468
  if (object.tax != null)
17369
17469
  message.tax = object.tax | 0;
17470
+ if (object.discountCode != null)
17471
+ message.discountCode = String(object.discountCode);
17472
+ if (object.discount != null)
17473
+ message.discount = object.discount | 0;
17370
17474
  return message;
17371
17475
  };
17372
17476
 
@@ -17396,6 +17500,8 @@ $root.Payment = (function() {
17396
17500
  object.promotionCode = "";
17397
17501
  object.paymentMethodType = "";
17398
17502
  object.tax = 0;
17503
+ object.discountCode = "";
17504
+ object.discount = 0;
17399
17505
  }
17400
17506
  if (message._id != null && message.hasOwnProperty("_id"))
17401
17507
  object._id = message._id;
@@ -17422,6 +17528,10 @@ $root.Payment = (function() {
17422
17528
  object.paymentMethodType = message.paymentMethodType;
17423
17529
  if (message.tax != null && message.hasOwnProperty("tax"))
17424
17530
  object.tax = message.tax;
17531
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
17532
+ object.discountCode = message.discountCode;
17533
+ if (message.discount != null && message.hasOwnProperty("discount"))
17534
+ object.discount = message.discount;
17425
17535
  return object;
17426
17536
  };
17427
17537
 
@@ -17460,6 +17570,8 @@ $root.CreateOrderParams = (function() {
17460
17570
  * @property {string|null} [ipAddress] CreateOrderParams ipAddress
17461
17571
  * @property {boolean|null} [hidden] CreateOrderParams hidden
17462
17572
  * @property {string|null} [parentSeasonOrderId] CreateOrderParams parentSeasonOrderId
17573
+ * @property {string|null} [discountCode] CreateOrderParams discountCode
17574
+ * @property {number|null} [discountAmount] CreateOrderParams discountAmount
17463
17575
  */
17464
17576
 
17465
17577
  /**
@@ -17600,6 +17712,22 @@ $root.CreateOrderParams = (function() {
17600
17712
  */
17601
17713
  CreateOrderParams.prototype.parentSeasonOrderId = "";
17602
17714
 
17715
+ /**
17716
+ * CreateOrderParams discountCode.
17717
+ * @member {string} discountCode
17718
+ * @memberof CreateOrderParams
17719
+ * @instance
17720
+ */
17721
+ CreateOrderParams.prototype.discountCode = "";
17722
+
17723
+ /**
17724
+ * CreateOrderParams discountAmount.
17725
+ * @member {number} discountAmount
17726
+ * @memberof CreateOrderParams
17727
+ * @instance
17728
+ */
17729
+ CreateOrderParams.prototype.discountAmount = 0;
17730
+
17603
17731
  /**
17604
17732
  * Creates a new CreateOrderParams instance using the specified properties.
17605
17733
  * @function create
@@ -17657,6 +17785,10 @@ $root.CreateOrderParams = (function() {
17657
17785
  writer.uint32(/* id 13, wireType 0 =*/104).bool(message.hidden);
17658
17786
  if (message.parentSeasonOrderId != null && Object.hasOwnProperty.call(message, "parentSeasonOrderId"))
17659
17787
  writer.uint32(/* id 14, wireType 2 =*/114).string(message.parentSeasonOrderId);
17788
+ if (message.discountCode != null && Object.hasOwnProperty.call(message, "discountCode"))
17789
+ writer.uint32(/* id 15, wireType 2 =*/122).string(message.discountCode);
17790
+ if (message.discountAmount != null && Object.hasOwnProperty.call(message, "discountAmount"))
17791
+ writer.uint32(/* id 16, wireType 0 =*/128).int32(message.discountAmount);
17660
17792
  return writer;
17661
17793
  };
17662
17794
 
@@ -17742,6 +17874,12 @@ $root.CreateOrderParams = (function() {
17742
17874
  case 14:
17743
17875
  message.parentSeasonOrderId = reader.string();
17744
17876
  break;
17877
+ case 15:
17878
+ message.discountCode = reader.string();
17879
+ break;
17880
+ case 16:
17881
+ message.discountAmount = reader.int32();
17882
+ break;
17745
17883
  default:
17746
17884
  reader.skipType(tag & 7);
17747
17885
  break;
@@ -17840,6 +17978,12 @@ $root.CreateOrderParams = (function() {
17840
17978
  if (message.parentSeasonOrderId != null && message.hasOwnProperty("parentSeasonOrderId"))
17841
17979
  if (!$util.isString(message.parentSeasonOrderId))
17842
17980
  return "parentSeasonOrderId: string expected";
17981
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
17982
+ if (!$util.isString(message.discountCode))
17983
+ return "discountCode: string expected";
17984
+ if (message.discountAmount != null && message.hasOwnProperty("discountAmount"))
17985
+ if (!$util.isInteger(message.discountAmount))
17986
+ return "discountAmount: integer expected";
17843
17987
  return null;
17844
17988
  };
17845
17989
 
@@ -17909,6 +18053,10 @@ $root.CreateOrderParams = (function() {
17909
18053
  message.hidden = Boolean(object.hidden);
17910
18054
  if (object.parentSeasonOrderId != null)
17911
18055
  message.parentSeasonOrderId = String(object.parentSeasonOrderId);
18056
+ if (object.discountCode != null)
18057
+ message.discountCode = String(object.discountCode);
18058
+ if (object.discountAmount != null)
18059
+ message.discountAmount = object.discountAmount | 0;
17912
18060
  return message;
17913
18061
  };
17914
18062
 
@@ -17943,6 +18091,8 @@ $root.CreateOrderParams = (function() {
17943
18091
  object.ipAddress = "";
17944
18092
  object.hidden = false;
17945
18093
  object.parentSeasonOrderId = "";
18094
+ object.discountCode = "";
18095
+ object.discountAmount = 0;
17946
18096
  }
17947
18097
  if (message.userId != null && message.hasOwnProperty("userId"))
17948
18098
  object.userId = message.userId;
@@ -17983,6 +18133,10 @@ $root.CreateOrderParams = (function() {
17983
18133
  object.hidden = message.hidden;
17984
18134
  if (message.parentSeasonOrderId != null && message.hasOwnProperty("parentSeasonOrderId"))
17985
18135
  object.parentSeasonOrderId = message.parentSeasonOrderId;
18136
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
18137
+ object.discountCode = message.discountCode;
18138
+ if (message.discountAmount != null && message.hasOwnProperty("discountAmount"))
18139
+ object.discountAmount = message.discountAmount;
17986
18140
  return object;
17987
18141
  };
17988
18142
 
@@ -18537,6 +18691,7 @@ $root.CreateOrderTicketParams = (function() {
18537
18691
  * @property {boolean|null} [isMemberIdValid] CreateOrderTicketParams isMemberIdValid
18538
18692
  * @property {ITeiMemberInfoParams|null} [teiMemberInfo] CreateOrderTicketParams teiMemberInfo
18539
18693
  * @property {boolean|null} [guestTicket] CreateOrderTicketParams guestTicket
18694
+ * @property {number|null} [origionalPrice] CreateOrderTicketParams origionalPrice
18540
18695
  */
18541
18696
 
18542
18697
  /**
@@ -18667,6 +18822,14 @@ $root.CreateOrderTicketParams = (function() {
18667
18822
  */
18668
18823
  CreateOrderTicketParams.prototype.guestTicket = false;
18669
18824
 
18825
+ /**
18826
+ * CreateOrderTicketParams origionalPrice.
18827
+ * @member {number} origionalPrice
18828
+ * @memberof CreateOrderTicketParams
18829
+ * @instance
18830
+ */
18831
+ CreateOrderTicketParams.prototype.origionalPrice = 0;
18832
+
18670
18833
  /**
18671
18834
  * Creates a new CreateOrderTicketParams instance using the specified properties.
18672
18835
  * @function create
@@ -18720,6 +18883,8 @@ $root.CreateOrderTicketParams = (function() {
18720
18883
  $root.TeiMemberInfoParams.encode(message.teiMemberInfo, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim();
18721
18884
  if (message.guestTicket != null && Object.hasOwnProperty.call(message, "guestTicket"))
18722
18885
  writer.uint32(/* id 13, wireType 0 =*/104).bool(message.guestTicket);
18886
+ if (message.origionalPrice != null && Object.hasOwnProperty.call(message, "origionalPrice"))
18887
+ writer.uint32(/* id 14, wireType 0 =*/112).int32(message.origionalPrice);
18723
18888
  return writer;
18724
18889
  };
18725
18890
 
@@ -18798,6 +18963,9 @@ $root.CreateOrderTicketParams = (function() {
18798
18963
  case 13:
18799
18964
  message.guestTicket = reader.bool();
18800
18965
  break;
18966
+ case 14:
18967
+ message.origionalPrice = reader.int32();
18968
+ break;
18801
18969
  default:
18802
18970
  reader.skipType(tag & 7);
18803
18971
  break;
@@ -18881,6 +19049,9 @@ $root.CreateOrderTicketParams = (function() {
18881
19049
  if (message.guestTicket != null && message.hasOwnProperty("guestTicket"))
18882
19050
  if (typeof message.guestTicket !== "boolean")
18883
19051
  return "guestTicket: boolean expected";
19052
+ if (message.origionalPrice != null && message.hasOwnProperty("origionalPrice"))
19053
+ if (!$util.isInteger(message.origionalPrice))
19054
+ return "origionalPrice: integer expected";
18884
19055
  return null;
18885
19056
  };
18886
19057
 
@@ -18932,6 +19103,8 @@ $root.CreateOrderTicketParams = (function() {
18932
19103
  }
18933
19104
  if (object.guestTicket != null)
18934
19105
  message.guestTicket = Boolean(object.guestTicket);
19106
+ if (object.origionalPrice != null)
19107
+ message.origionalPrice = object.origionalPrice | 0;
18935
19108
  return message;
18936
19109
  };
18937
19110
 
@@ -18964,6 +19137,7 @@ $root.CreateOrderTicketParams = (function() {
18964
19137
  object.isMemberIdValid = false;
18965
19138
  object.teiMemberInfo = null;
18966
19139
  object.guestTicket = false;
19140
+ object.origionalPrice = 0;
18967
19141
  }
18968
19142
  if (message.name != null && message.hasOwnProperty("name"))
18969
19143
  object.name = message.name;
@@ -18996,6 +19170,8 @@ $root.CreateOrderTicketParams = (function() {
18996
19170
  object.teiMemberInfo = $root.TeiMemberInfoParams.toObject(message.teiMemberInfo, options);
18997
19171
  if (message.guestTicket != null && message.hasOwnProperty("guestTicket"))
18998
19172
  object.guestTicket = message.guestTicket;
19173
+ if (message.origionalPrice != null && message.hasOwnProperty("origionalPrice"))
19174
+ object.origionalPrice = message.origionalPrice;
18999
19175
  return object;
19000
19176
  };
19001
19177
 
@@ -20371,6 +20547,8 @@ $root.CreateOrderPaymentIntentParams = (function() {
20371
20547
  * @property {string|null} [paymentMethodId] CreateOrderPaymentIntentParams paymentMethodId
20372
20548
  * @property {string|null} [stalePaymentIntentId] CreateOrderPaymentIntentParams stalePaymentIntentId
20373
20549
  * @property {string|null} [channel] CreateOrderPaymentIntentParams channel
20550
+ * @property {string|null} [discountCode] CreateOrderPaymentIntentParams discountCode
20551
+ * @property {number|null} [discount] CreateOrderPaymentIntentParams discount
20374
20552
  */
20375
20553
 
20376
20554
  /**
@@ -20470,6 +20648,22 @@ $root.CreateOrderPaymentIntentParams = (function() {
20470
20648
  */
20471
20649
  CreateOrderPaymentIntentParams.prototype.channel = "";
20472
20650
 
20651
+ /**
20652
+ * CreateOrderPaymentIntentParams discountCode.
20653
+ * @member {string} discountCode
20654
+ * @memberof CreateOrderPaymentIntentParams
20655
+ * @instance
20656
+ */
20657
+ CreateOrderPaymentIntentParams.prototype.discountCode = "";
20658
+
20659
+ /**
20660
+ * CreateOrderPaymentIntentParams discount.
20661
+ * @member {number} discount
20662
+ * @memberof CreateOrderPaymentIntentParams
20663
+ * @instance
20664
+ */
20665
+ CreateOrderPaymentIntentParams.prototype.discount = 0;
20666
+
20473
20667
  /**
20474
20668
  * Creates a new CreateOrderPaymentIntentParams instance using the specified properties.
20475
20669
  * @function create
@@ -20516,6 +20710,10 @@ $root.CreateOrderPaymentIntentParams = (function() {
20516
20710
  writer.uint32(/* id 8, wireType 2 =*/66).string(message.stalePaymentIntentId);
20517
20711
  if (message.channel != null && Object.hasOwnProperty.call(message, "channel"))
20518
20712
  writer.uint32(/* id 9, wireType 2 =*/74).string(message.channel);
20713
+ if (message.discountCode != null && Object.hasOwnProperty.call(message, "discountCode"))
20714
+ writer.uint32(/* id 10, wireType 2 =*/82).string(message.discountCode);
20715
+ if (message.discount != null && Object.hasOwnProperty.call(message, "discount"))
20716
+ writer.uint32(/* id 11, wireType 0 =*/88).int32(message.discount);
20519
20717
  return writer;
20520
20718
  };
20521
20719
 
@@ -20584,6 +20782,12 @@ $root.CreateOrderPaymentIntentParams = (function() {
20584
20782
  case 9:
20585
20783
  message.channel = reader.string();
20586
20784
  break;
20785
+ case 10:
20786
+ message.discountCode = reader.string();
20787
+ break;
20788
+ case 11:
20789
+ message.discount = reader.int32();
20790
+ break;
20587
20791
  default:
20588
20792
  reader.skipType(tag & 7);
20589
20793
  break;
@@ -20661,6 +20865,12 @@ $root.CreateOrderPaymentIntentParams = (function() {
20661
20865
  if (message.channel != null && message.hasOwnProperty("channel"))
20662
20866
  if (!$util.isString(message.channel))
20663
20867
  return "channel: string expected";
20868
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
20869
+ if (!$util.isString(message.discountCode))
20870
+ return "discountCode: string expected";
20871
+ if (message.discount != null && message.hasOwnProperty("discount"))
20872
+ if (!$util.isInteger(message.discount))
20873
+ return "discount: integer expected";
20664
20874
  return null;
20665
20875
  };
20666
20876
 
@@ -20712,6 +20922,10 @@ $root.CreateOrderPaymentIntentParams = (function() {
20712
20922
  message.stalePaymentIntentId = String(object.stalePaymentIntentId);
20713
20923
  if (object.channel != null)
20714
20924
  message.channel = String(object.channel);
20925
+ if (object.discountCode != null)
20926
+ message.discountCode = String(object.discountCode);
20927
+ if (object.discount != null)
20928
+ message.discount = object.discount | 0;
20715
20929
  return message;
20716
20930
  };
20717
20931
 
@@ -20741,6 +20955,8 @@ $root.CreateOrderPaymentIntentParams = (function() {
20741
20955
  object.paymentMethodId = "";
20742
20956
  object.stalePaymentIntentId = "";
20743
20957
  object.channel = "";
20958
+ object.discountCode = "";
20959
+ object.discount = 0;
20744
20960
  }
20745
20961
  if (message.userId != null && message.hasOwnProperty("userId"))
20746
20962
  object.userId = message.userId;
@@ -20768,6 +20984,10 @@ $root.CreateOrderPaymentIntentParams = (function() {
20768
20984
  object.stalePaymentIntentId = message.stalePaymentIntentId;
20769
20985
  if (message.channel != null && message.hasOwnProperty("channel"))
20770
20986
  object.channel = message.channel;
20987
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
20988
+ object.discountCode = message.discountCode;
20989
+ if (message.discount != null && message.hasOwnProperty("discount"))
20990
+ object.discount = message.discount;
20771
20991
  return object;
20772
20992
  };
20773
20993
 
@@ -28825,6 +29045,7 @@ $root.QueryOrdersRequest = (function() {
28825
29045
  * @property {string|null} [orgId] QueryOrdersRequest orgId
28826
29046
  * @property {IOrderQuery|null} [query] QueryOrdersRequest query
28827
29047
  * @property {IPagination|null} [pagination] QueryOrdersRequest pagination
29048
+ * @property {string|null} [userId] QueryOrdersRequest userId
28828
29049
  */
28829
29050
 
28830
29051
  /**
@@ -28874,6 +29095,14 @@ $root.QueryOrdersRequest = (function() {
28874
29095
  */
28875
29096
  QueryOrdersRequest.prototype.pagination = null;
28876
29097
 
29098
+ /**
29099
+ * QueryOrdersRequest userId.
29100
+ * @member {string} userId
29101
+ * @memberof QueryOrdersRequest
29102
+ * @instance
29103
+ */
29104
+ QueryOrdersRequest.prototype.userId = "";
29105
+
28877
29106
  /**
28878
29107
  * Creates a new QueryOrdersRequest instance using the specified properties.
28879
29108
  * @function create
@@ -28906,6 +29135,8 @@ $root.QueryOrdersRequest = (function() {
28906
29135
  $root.OrderQuery.encode(message.query, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
28907
29136
  if (message.pagination != null && Object.hasOwnProperty.call(message, "pagination"))
28908
29137
  $root.Pagination.encode(message.pagination, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
29138
+ if (message.userId != null && Object.hasOwnProperty.call(message, "userId"))
29139
+ writer.uint32(/* id 4, wireType 2 =*/34).string(message.userId);
28909
29140
  return writer;
28910
29141
  };
28911
29142
 
@@ -28952,6 +29183,9 @@ $root.QueryOrdersRequest = (function() {
28952
29183
  case 3:
28953
29184
  message.pagination = $root.Pagination.decode(reader, reader.uint32());
28954
29185
  break;
29186
+ case 4:
29187
+ message.userId = reader.string();
29188
+ break;
28955
29189
  default:
28956
29190
  reader.skipType(tag & 7);
28957
29191
  break;
@@ -29003,6 +29237,9 @@ $root.QueryOrdersRequest = (function() {
29003
29237
  if (error)
29004
29238
  return "pagination." + error;
29005
29239
  }
29240
+ if (message.userId != null && message.hasOwnProperty("userId"))
29241
+ if (!$util.isString(message.userId))
29242
+ return "userId: string expected";
29006
29243
  return null;
29007
29244
  };
29008
29245
 
@@ -29032,6 +29269,8 @@ $root.QueryOrdersRequest = (function() {
29032
29269
  throw TypeError(".QueryOrdersRequest.pagination: object expected");
29033
29270
  message.pagination = $root.Pagination.fromObject(object.pagination);
29034
29271
  }
29272
+ if (object.userId != null)
29273
+ message.userId = String(object.userId);
29035
29274
  return message;
29036
29275
  };
29037
29276
 
@@ -29053,6 +29292,7 @@ $root.QueryOrdersRequest = (function() {
29053
29292
  object.orgId = "";
29054
29293
  object.query = null;
29055
29294
  object.pagination = null;
29295
+ object.userId = "";
29056
29296
  }
29057
29297
  if (message.spanContext != null && message.hasOwnProperty("spanContext"))
29058
29298
  object.spanContext = message.spanContext;
@@ -29062,6 +29302,8 @@ $root.QueryOrdersRequest = (function() {
29062
29302
  object.query = $root.OrderQuery.toObject(message.query, options);
29063
29303
  if (message.pagination != null && message.hasOwnProperty("pagination"))
29064
29304
  object.pagination = $root.Pagination.toObject(message.pagination, options);
29305
+ if (message.userId != null && message.hasOwnProperty("userId"))
29306
+ object.userId = message.userId;
29065
29307
  return object;
29066
29308
  };
29067
29309
 
@@ -40667,6 +40909,7 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
40667
40909
  * @property {string|null} [physicalDeliveryInstructions] QueueOrderQRCodeEmailRequest physicalDeliveryInstructions
40668
40910
  * @property {string|null} [promoterFee] QueueOrderQRCodeEmailRequest promoterFee
40669
40911
  * @property {string|null} [processingFee] QueueOrderQRCodeEmailRequest processingFee
40912
+ * @property {string|null} [discount] QueueOrderQRCodeEmailRequest discount
40670
40913
  */
40671
40914
 
40672
40915
  /**
@@ -40991,6 +41234,14 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
40991
41234
  */
40992
41235
  QueueOrderQRCodeEmailRequest.prototype.processingFee = "";
40993
41236
 
41237
+ /**
41238
+ * QueueOrderQRCodeEmailRequest discount.
41239
+ * @member {string} discount
41240
+ * @memberof QueueOrderQRCodeEmailRequest
41241
+ * @instance
41242
+ */
41243
+ QueueOrderQRCodeEmailRequest.prototype.discount = "";
41244
+
40994
41245
  /**
40995
41246
  * Creates a new QueueOrderQRCodeEmailRequest instance using the specified properties.
40996
41247
  * @function create
@@ -41094,6 +41345,8 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41094
41345
  writer.uint32(/* id 36, wireType 2 =*/290).string(message.promoterFee);
41095
41346
  if (message.processingFee != null && Object.hasOwnProperty.call(message, "processingFee"))
41096
41347
  writer.uint32(/* id 37, wireType 2 =*/298).string(message.processingFee);
41348
+ if (message.discount != null && Object.hasOwnProperty.call(message, "discount"))
41349
+ writer.uint32(/* id 38, wireType 2 =*/306).string(message.discount);
41097
41350
  return writer;
41098
41351
  };
41099
41352
 
@@ -41248,6 +41501,9 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41248
41501
  case 37:
41249
41502
  message.processingFee = reader.string();
41250
41503
  break;
41504
+ case 38:
41505
+ message.discount = reader.string();
41506
+ break;
41251
41507
  default:
41252
41508
  reader.skipType(tag & 7);
41253
41509
  break;
@@ -41415,6 +41671,9 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41415
41671
  if (message.processingFee != null && message.hasOwnProperty("processingFee"))
41416
41672
  if (!$util.isString(message.processingFee))
41417
41673
  return "processingFee: string expected";
41674
+ if (message.discount != null && message.hasOwnProperty("discount"))
41675
+ if (!$util.isString(message.discount))
41676
+ return "discount: string expected";
41418
41677
  return null;
41419
41678
  };
41420
41679
 
@@ -41530,6 +41789,8 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41530
41789
  message.promoterFee = String(object.promoterFee);
41531
41790
  if (object.processingFee != null)
41532
41791
  message.processingFee = String(object.processingFee);
41792
+ if (object.discount != null)
41793
+ message.discount = String(object.discount);
41533
41794
  return message;
41534
41795
  };
41535
41796
 
@@ -41587,6 +41848,7 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41587
41848
  object.physicalDeliveryInstructions = "";
41588
41849
  object.promoterFee = "";
41589
41850
  object.processingFee = "";
41851
+ object.discount = "";
41590
41852
  }
41591
41853
  if (message.spanContext != null && message.hasOwnProperty("spanContext"))
41592
41854
  object.spanContext = message.spanContext;
@@ -41673,6 +41935,8 @@ $root.QueueOrderQRCodeEmailRequest = (function() {
41673
41935
  object.promoterFee = message.promoterFee;
41674
41936
  if (message.processingFee != null && message.hasOwnProperty("processingFee"))
41675
41937
  object.processingFee = message.processingFee;
41938
+ if (message.discount != null && message.hasOwnProperty("discount"))
41939
+ object.discount = message.discount;
41676
41940
  return object;
41677
41941
  };
41678
41942
 
@@ -51445,6 +51709,7 @@ $root.EventPromotion = (function() {
51445
51709
  * @property {number|null} [discountValue] EventPromotion discountValue
51446
51710
  * @property {number|null} [overRideMax] EventPromotion overRideMax
51447
51711
  * @property {number|null} [overRideMaxUpg] EventPromotion overRideMaxUpg
51712
+ * @property {string|null} [appliesTo] EventPromotion appliesTo
51448
51713
  */
51449
51714
 
51450
51715
  /**
@@ -51584,6 +51849,14 @@ $root.EventPromotion = (function() {
51584
51849
  */
51585
51850
  EventPromotion.prototype.overRideMaxUpg = 0;
51586
51851
 
51852
+ /**
51853
+ * EventPromotion appliesTo.
51854
+ * @member {string} appliesTo
51855
+ * @memberof EventPromotion
51856
+ * @instance
51857
+ */
51858
+ EventPromotion.prototype.appliesTo = "";
51859
+
51587
51860
  /**
51588
51861
  * Creates a new EventPromotion instance using the specified properties.
51589
51862
  * @function create
@@ -51635,11 +51908,13 @@ $root.EventPromotion = (function() {
51635
51908
  if (message.discountType != null && Object.hasOwnProperty.call(message, "discountType"))
51636
51909
  writer.uint32(/* id 11, wireType 2 =*/90).string(message.discountType);
51637
51910
  if (message.discountValue != null && Object.hasOwnProperty.call(message, "discountValue"))
51638
- writer.uint32(/* id 12, wireType 0 =*/96).int32(message.discountValue);
51911
+ writer.uint32(/* id 12, wireType 1 =*/97).double(message.discountValue);
51639
51912
  if (message.overRideMax != null && Object.hasOwnProperty.call(message, "overRideMax"))
51640
51913
  writer.uint32(/* id 13, wireType 0 =*/104).int32(message.overRideMax);
51641
51914
  if (message.overRideMaxUpg != null && Object.hasOwnProperty.call(message, "overRideMaxUpg"))
51642
51915
  writer.uint32(/* id 14, wireType 0 =*/112).int32(message.overRideMaxUpg);
51916
+ if (message.appliesTo != null && Object.hasOwnProperty.call(message, "appliesTo"))
51917
+ writer.uint32(/* id 15, wireType 2 =*/122).string(message.appliesTo);
51643
51918
  return writer;
51644
51919
  };
51645
51920
 
@@ -51715,7 +51990,7 @@ $root.EventPromotion = (function() {
51715
51990
  message.discountType = reader.string();
51716
51991
  break;
51717
51992
  case 12:
51718
- message.discountValue = reader.int32();
51993
+ message.discountValue = reader.double();
51719
51994
  break;
51720
51995
  case 13:
51721
51996
  message.overRideMax = reader.int32();
@@ -51723,6 +51998,9 @@ $root.EventPromotion = (function() {
51723
51998
  case 14:
51724
51999
  message.overRideMaxUpg = reader.int32();
51725
52000
  break;
52001
+ case 15:
52002
+ message.appliesTo = reader.string();
52003
+ break;
51726
52004
  default:
51727
52005
  reader.skipType(tag & 7);
51728
52006
  break;
@@ -51803,14 +52081,17 @@ $root.EventPromotion = (function() {
51803
52081
  if (!$util.isString(message.discountType))
51804
52082
  return "discountType: string expected";
51805
52083
  if (message.discountValue != null && message.hasOwnProperty("discountValue"))
51806
- if (!$util.isInteger(message.discountValue))
51807
- return "discountValue: integer expected";
52084
+ if (typeof message.discountValue !== "number")
52085
+ return "discountValue: number expected";
51808
52086
  if (message.overRideMax != null && message.hasOwnProperty("overRideMax"))
51809
52087
  if (!$util.isInteger(message.overRideMax))
51810
52088
  return "overRideMax: integer expected";
51811
52089
  if (message.overRideMaxUpg != null && message.hasOwnProperty("overRideMaxUpg"))
51812
52090
  if (!$util.isInteger(message.overRideMaxUpg))
51813
52091
  return "overRideMaxUpg: integer expected";
52092
+ if (message.appliesTo != null && message.hasOwnProperty("appliesTo"))
52093
+ if (!$util.isString(message.appliesTo))
52094
+ return "appliesTo: string expected";
51814
52095
  return null;
51815
52096
  };
51816
52097
 
@@ -51861,11 +52142,13 @@ $root.EventPromotion = (function() {
51861
52142
  if (object.discountType != null)
51862
52143
  message.discountType = String(object.discountType);
51863
52144
  if (object.discountValue != null)
51864
- message.discountValue = object.discountValue | 0;
52145
+ message.discountValue = Number(object.discountValue);
51865
52146
  if (object.overRideMax != null)
51866
52147
  message.overRideMax = object.overRideMax | 0;
51867
52148
  if (object.overRideMaxUpg != null)
51868
52149
  message.overRideMaxUpg = object.overRideMaxUpg | 0;
52150
+ if (object.appliesTo != null)
52151
+ message.appliesTo = String(object.appliesTo);
51869
52152
  return message;
51870
52153
  };
51871
52154
 
@@ -51900,6 +52183,7 @@ $root.EventPromotion = (function() {
51900
52183
  object.discountValue = 0;
51901
52184
  object.overRideMax = 0;
51902
52185
  object.overRideMaxUpg = 0;
52186
+ object.appliesTo = "";
51903
52187
  }
51904
52188
  if (message._id != null && message.hasOwnProperty("_id"))
51905
52189
  object._id = message._id;
@@ -51932,11 +52216,13 @@ $root.EventPromotion = (function() {
51932
52216
  if (message.discountType != null && message.hasOwnProperty("discountType"))
51933
52217
  object.discountType = message.discountType;
51934
52218
  if (message.discountValue != null && message.hasOwnProperty("discountValue"))
51935
- object.discountValue = message.discountValue;
52219
+ object.discountValue = options.json && !isFinite(message.discountValue) ? String(message.discountValue) : message.discountValue;
51936
52220
  if (message.overRideMax != null && message.hasOwnProperty("overRideMax"))
51937
52221
  object.overRideMax = message.overRideMax;
51938
52222
  if (message.overRideMaxUpg != null && message.hasOwnProperty("overRideMaxUpg"))
51939
52223
  object.overRideMaxUpg = message.overRideMaxUpg;
52224
+ if (message.appliesTo != null && message.hasOwnProperty("appliesTo"))
52225
+ object.appliesTo = message.appliesTo;
51940
52226
  return object;
51941
52227
  };
51942
52228
 
@@ -56228,6 +56514,282 @@ $root.EventTicketsRequest = (function() {
56228
56514
  return EventTicketsRequest;
56229
56515
  })();
56230
56516
 
56517
+ $root.EventDiscountRequest = (function() {
56518
+
56519
+ /**
56520
+ * Properties of an EventDiscountRequest.
56521
+ * @exports IEventDiscountRequest
56522
+ * @interface IEventDiscountRequest
56523
+ * @property {string|null} [spanContext] EventDiscountRequest spanContext
56524
+ * @property {string|null} [eventId] EventDiscountRequest eventId
56525
+ * @property {string|null} [discountCode] EventDiscountRequest discountCode
56526
+ * @property {string|null} [seasonId] EventDiscountRequest seasonId
56527
+ * @property {string|null} [userId] EventDiscountRequest userId
56528
+ */
56529
+
56530
+ /**
56531
+ * Constructs a new EventDiscountRequest.
56532
+ * @exports EventDiscountRequest
56533
+ * @classdesc Represents an EventDiscountRequest.
56534
+ * @implements IEventDiscountRequest
56535
+ * @constructor
56536
+ * @param {IEventDiscountRequest=} [properties] Properties to set
56537
+ */
56538
+ function EventDiscountRequest(properties) {
56539
+ if (properties)
56540
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
56541
+ if (properties[keys[i]] != null)
56542
+ this[keys[i]] = properties[keys[i]];
56543
+ }
56544
+
56545
+ /**
56546
+ * EventDiscountRequest spanContext.
56547
+ * @member {string} spanContext
56548
+ * @memberof EventDiscountRequest
56549
+ * @instance
56550
+ */
56551
+ EventDiscountRequest.prototype.spanContext = "";
56552
+
56553
+ /**
56554
+ * EventDiscountRequest eventId.
56555
+ * @member {string} eventId
56556
+ * @memberof EventDiscountRequest
56557
+ * @instance
56558
+ */
56559
+ EventDiscountRequest.prototype.eventId = "";
56560
+
56561
+ /**
56562
+ * EventDiscountRequest discountCode.
56563
+ * @member {string} discountCode
56564
+ * @memberof EventDiscountRequest
56565
+ * @instance
56566
+ */
56567
+ EventDiscountRequest.prototype.discountCode = "";
56568
+
56569
+ /**
56570
+ * EventDiscountRequest seasonId.
56571
+ * @member {string} seasonId
56572
+ * @memberof EventDiscountRequest
56573
+ * @instance
56574
+ */
56575
+ EventDiscountRequest.prototype.seasonId = "";
56576
+
56577
+ /**
56578
+ * EventDiscountRequest userId.
56579
+ * @member {string} userId
56580
+ * @memberof EventDiscountRequest
56581
+ * @instance
56582
+ */
56583
+ EventDiscountRequest.prototype.userId = "";
56584
+
56585
+ /**
56586
+ * Creates a new EventDiscountRequest instance using the specified properties.
56587
+ * @function create
56588
+ * @memberof EventDiscountRequest
56589
+ * @static
56590
+ * @param {IEventDiscountRequest=} [properties] Properties to set
56591
+ * @returns {EventDiscountRequest} EventDiscountRequest instance
56592
+ */
56593
+ EventDiscountRequest.create = function create(properties) {
56594
+ return new EventDiscountRequest(properties);
56595
+ };
56596
+
56597
+ /**
56598
+ * Encodes the specified EventDiscountRequest message. Does not implicitly {@link EventDiscountRequest.verify|verify} messages.
56599
+ * @function encode
56600
+ * @memberof EventDiscountRequest
56601
+ * @static
56602
+ * @param {IEventDiscountRequest} message EventDiscountRequest message or plain object to encode
56603
+ * @param {$protobuf.Writer} [writer] Writer to encode to
56604
+ * @returns {$protobuf.Writer} Writer
56605
+ */
56606
+ EventDiscountRequest.encode = function encode(message, writer) {
56607
+ if (!writer)
56608
+ writer = $Writer.create();
56609
+ if (message.spanContext != null && Object.hasOwnProperty.call(message, "spanContext"))
56610
+ writer.uint32(/* id 0, wireType 2 =*/2).string(message.spanContext);
56611
+ if (message.eventId != null && Object.hasOwnProperty.call(message, "eventId"))
56612
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.eventId);
56613
+ if (message.discountCode != null && Object.hasOwnProperty.call(message, "discountCode"))
56614
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.discountCode);
56615
+ if (message.seasonId != null && Object.hasOwnProperty.call(message, "seasonId"))
56616
+ writer.uint32(/* id 3, wireType 2 =*/26).string(message.seasonId);
56617
+ if (message.userId != null && Object.hasOwnProperty.call(message, "userId"))
56618
+ writer.uint32(/* id 4, wireType 2 =*/34).string(message.userId);
56619
+ return writer;
56620
+ };
56621
+
56622
+ /**
56623
+ * Encodes the specified EventDiscountRequest message, length delimited. Does not implicitly {@link EventDiscountRequest.verify|verify} messages.
56624
+ * @function encodeDelimited
56625
+ * @memberof EventDiscountRequest
56626
+ * @static
56627
+ * @param {IEventDiscountRequest} message EventDiscountRequest message or plain object to encode
56628
+ * @param {$protobuf.Writer} [writer] Writer to encode to
56629
+ * @returns {$protobuf.Writer} Writer
56630
+ */
56631
+ EventDiscountRequest.encodeDelimited = function encodeDelimited(message, writer) {
56632
+ return this.encode(message, writer).ldelim();
56633
+ };
56634
+
56635
+ /**
56636
+ * Decodes an EventDiscountRequest message from the specified reader or buffer.
56637
+ * @function decode
56638
+ * @memberof EventDiscountRequest
56639
+ * @static
56640
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
56641
+ * @param {number} [length] Message length if known beforehand
56642
+ * @returns {EventDiscountRequest} EventDiscountRequest
56643
+ * @throws {Error} If the payload is not a reader or valid buffer
56644
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
56645
+ */
56646
+ EventDiscountRequest.decode = function decode(reader, length) {
56647
+ if (!(reader instanceof $Reader))
56648
+ reader = $Reader.create(reader);
56649
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.EventDiscountRequest();
56650
+ while (reader.pos < end) {
56651
+ var tag = reader.uint32();
56652
+ switch (tag >>> 3) {
56653
+ case 0:
56654
+ message.spanContext = reader.string();
56655
+ break;
56656
+ case 1:
56657
+ message.eventId = reader.string();
56658
+ break;
56659
+ case 2:
56660
+ message.discountCode = reader.string();
56661
+ break;
56662
+ case 3:
56663
+ message.seasonId = reader.string();
56664
+ break;
56665
+ case 4:
56666
+ message.userId = reader.string();
56667
+ break;
56668
+ default:
56669
+ reader.skipType(tag & 7);
56670
+ break;
56671
+ }
56672
+ }
56673
+ return message;
56674
+ };
56675
+
56676
+ /**
56677
+ * Decodes an EventDiscountRequest message from the specified reader or buffer, length delimited.
56678
+ * @function decodeDelimited
56679
+ * @memberof EventDiscountRequest
56680
+ * @static
56681
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
56682
+ * @returns {EventDiscountRequest} EventDiscountRequest
56683
+ * @throws {Error} If the payload is not a reader or valid buffer
56684
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
56685
+ */
56686
+ EventDiscountRequest.decodeDelimited = function decodeDelimited(reader) {
56687
+ if (!(reader instanceof $Reader))
56688
+ reader = new $Reader(reader);
56689
+ return this.decode(reader, reader.uint32());
56690
+ };
56691
+
56692
+ /**
56693
+ * Verifies an EventDiscountRequest message.
56694
+ * @function verify
56695
+ * @memberof EventDiscountRequest
56696
+ * @static
56697
+ * @param {Object.<string,*>} message Plain object to verify
56698
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
56699
+ */
56700
+ EventDiscountRequest.verify = function verify(message) {
56701
+ if (typeof message !== "object" || message === null)
56702
+ return "object expected";
56703
+ if (message.spanContext != null && message.hasOwnProperty("spanContext"))
56704
+ if (!$util.isString(message.spanContext))
56705
+ return "spanContext: string expected";
56706
+ if (message.eventId != null && message.hasOwnProperty("eventId"))
56707
+ if (!$util.isString(message.eventId))
56708
+ return "eventId: string expected";
56709
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
56710
+ if (!$util.isString(message.discountCode))
56711
+ return "discountCode: string expected";
56712
+ if (message.seasonId != null && message.hasOwnProperty("seasonId"))
56713
+ if (!$util.isString(message.seasonId))
56714
+ return "seasonId: string expected";
56715
+ if (message.userId != null && message.hasOwnProperty("userId"))
56716
+ if (!$util.isString(message.userId))
56717
+ return "userId: string expected";
56718
+ return null;
56719
+ };
56720
+
56721
+ /**
56722
+ * Creates an EventDiscountRequest message from a plain object. Also converts values to their respective internal types.
56723
+ * @function fromObject
56724
+ * @memberof EventDiscountRequest
56725
+ * @static
56726
+ * @param {Object.<string,*>} object Plain object
56727
+ * @returns {EventDiscountRequest} EventDiscountRequest
56728
+ */
56729
+ EventDiscountRequest.fromObject = function fromObject(object) {
56730
+ if (object instanceof $root.EventDiscountRequest)
56731
+ return object;
56732
+ var message = new $root.EventDiscountRequest();
56733
+ if (object.spanContext != null)
56734
+ message.spanContext = String(object.spanContext);
56735
+ if (object.eventId != null)
56736
+ message.eventId = String(object.eventId);
56737
+ if (object.discountCode != null)
56738
+ message.discountCode = String(object.discountCode);
56739
+ if (object.seasonId != null)
56740
+ message.seasonId = String(object.seasonId);
56741
+ if (object.userId != null)
56742
+ message.userId = String(object.userId);
56743
+ return message;
56744
+ };
56745
+
56746
+ /**
56747
+ * Creates a plain object from an EventDiscountRequest message. Also converts values to other types if specified.
56748
+ * @function toObject
56749
+ * @memberof EventDiscountRequest
56750
+ * @static
56751
+ * @param {EventDiscountRequest} message EventDiscountRequest
56752
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
56753
+ * @returns {Object.<string,*>} Plain object
56754
+ */
56755
+ EventDiscountRequest.toObject = function toObject(message, options) {
56756
+ if (!options)
56757
+ options = {};
56758
+ var object = {};
56759
+ if (options.defaults) {
56760
+ object.spanContext = "";
56761
+ object.eventId = "";
56762
+ object.discountCode = "";
56763
+ object.seasonId = "";
56764
+ object.userId = "";
56765
+ }
56766
+ if (message.spanContext != null && message.hasOwnProperty("spanContext"))
56767
+ object.spanContext = message.spanContext;
56768
+ if (message.eventId != null && message.hasOwnProperty("eventId"))
56769
+ object.eventId = message.eventId;
56770
+ if (message.discountCode != null && message.hasOwnProperty("discountCode"))
56771
+ object.discountCode = message.discountCode;
56772
+ if (message.seasonId != null && message.hasOwnProperty("seasonId"))
56773
+ object.seasonId = message.seasonId;
56774
+ if (message.userId != null && message.hasOwnProperty("userId"))
56775
+ object.userId = message.userId;
56776
+ return object;
56777
+ };
56778
+
56779
+ /**
56780
+ * Converts this EventDiscountRequest to JSON.
56781
+ * @function toJSON
56782
+ * @memberof EventDiscountRequest
56783
+ * @instance
56784
+ * @returns {Object.<string,*>} JSON object
56785
+ */
56786
+ EventDiscountRequest.prototype.toJSON = function toJSON() {
56787
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
56788
+ };
56789
+
56790
+ return EventDiscountRequest;
56791
+ })();
56792
+
56231
56793
  $root.EventTickets = (function() {
56232
56794
 
56233
56795
  /**
@@ -56243,6 +56805,10 @@ $root.EventTickets = (function() {
56243
56805
  * @property {Array.<IEventUpgrade>|null} [eventUpgrades] EventTickets eventUpgrades
56244
56806
  * @property {number|null} [overRideMax] EventTickets overRideMax
56245
56807
  * @property {number|null} [overRideMaxUpg] EventTickets overRideMaxUpg
56808
+ * @property {string|null} [discountType] EventTickets discountType
56809
+ * @property {number|null} [discountValue] EventTickets discountValue
56810
+ * @property {string|null} [appliesTo] EventTickets appliesTo
56811
+ * @property {Array.<string>|null} [ticketTypeIds] EventTickets ticketTypeIds
56246
56812
  */
56247
56813
 
56248
56814
  /**
@@ -56256,6 +56822,7 @@ $root.EventTickets = (function() {
56256
56822
  function EventTickets(properties) {
56257
56823
  this.eventTickets = [];
56258
56824
  this.eventUpgrades = [];
56825
+ this.ticketTypeIds = [];
56259
56826
  if (properties)
56260
56827
  for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
56261
56828
  if (properties[keys[i]] != null)
@@ -56334,6 +56901,38 @@ $root.EventTickets = (function() {
56334
56901
  */
56335
56902
  EventTickets.prototype.overRideMaxUpg = 0;
56336
56903
 
56904
+ /**
56905
+ * EventTickets discountType.
56906
+ * @member {string} discountType
56907
+ * @memberof EventTickets
56908
+ * @instance
56909
+ */
56910
+ EventTickets.prototype.discountType = "";
56911
+
56912
+ /**
56913
+ * EventTickets discountValue.
56914
+ * @member {number} discountValue
56915
+ * @memberof EventTickets
56916
+ * @instance
56917
+ */
56918
+ EventTickets.prototype.discountValue = 0;
56919
+
56920
+ /**
56921
+ * EventTickets appliesTo.
56922
+ * @member {string} appliesTo
56923
+ * @memberof EventTickets
56924
+ * @instance
56925
+ */
56926
+ EventTickets.prototype.appliesTo = "";
56927
+
56928
+ /**
56929
+ * EventTickets ticketTypeIds.
56930
+ * @member {Array.<string>} ticketTypeIds
56931
+ * @memberof EventTickets
56932
+ * @instance
56933
+ */
56934
+ EventTickets.prototype.ticketTypeIds = $util.emptyArray;
56935
+
56337
56936
  /**
56338
56937
  * Creates a new EventTickets instance using the specified properties.
56339
56938
  * @function create
@@ -56378,6 +56977,15 @@ $root.EventTickets = (function() {
56378
56977
  writer.uint32(/* id 7, wireType 0 =*/56).int32(message.overRideMax);
56379
56978
  if (message.overRideMaxUpg != null && Object.hasOwnProperty.call(message, "overRideMaxUpg"))
56380
56979
  writer.uint32(/* id 8, wireType 0 =*/64).int32(message.overRideMaxUpg);
56980
+ if (message.discountType != null && Object.hasOwnProperty.call(message, "discountType"))
56981
+ writer.uint32(/* id 9, wireType 2 =*/74).string(message.discountType);
56982
+ if (message.discountValue != null && Object.hasOwnProperty.call(message, "discountValue"))
56983
+ writer.uint32(/* id 10, wireType 1 =*/81).double(message.discountValue);
56984
+ if (message.appliesTo != null && Object.hasOwnProperty.call(message, "appliesTo"))
56985
+ writer.uint32(/* id 11, wireType 2 =*/90).string(message.appliesTo);
56986
+ if (message.ticketTypeIds != null && message.ticketTypeIds.length)
56987
+ for (var i = 0; i < message.ticketTypeIds.length; ++i)
56988
+ writer.uint32(/* id 12, wireType 2 =*/98).string(message.ticketTypeIds[i]);
56381
56989
  return writer;
56382
56990
  };
56383
56991
 
@@ -56443,6 +57051,20 @@ $root.EventTickets = (function() {
56443
57051
  case 8:
56444
57052
  message.overRideMaxUpg = reader.int32();
56445
57053
  break;
57054
+ case 9:
57055
+ message.discountType = reader.string();
57056
+ break;
57057
+ case 10:
57058
+ message.discountValue = reader.double();
57059
+ break;
57060
+ case 11:
57061
+ message.appliesTo = reader.string();
57062
+ break;
57063
+ case 12:
57064
+ if (!(message.ticketTypeIds && message.ticketTypeIds.length))
57065
+ message.ticketTypeIds = [];
57066
+ message.ticketTypeIds.push(reader.string());
57067
+ break;
56446
57068
  default:
56447
57069
  reader.skipType(tag & 7);
56448
57070
  break;
@@ -56517,6 +57139,22 @@ $root.EventTickets = (function() {
56517
57139
  if (message.overRideMaxUpg != null && message.hasOwnProperty("overRideMaxUpg"))
56518
57140
  if (!$util.isInteger(message.overRideMaxUpg))
56519
57141
  return "overRideMaxUpg: integer expected";
57142
+ if (message.discountType != null && message.hasOwnProperty("discountType"))
57143
+ if (!$util.isString(message.discountType))
57144
+ return "discountType: string expected";
57145
+ if (message.discountValue != null && message.hasOwnProperty("discountValue"))
57146
+ if (typeof message.discountValue !== "number")
57147
+ return "discountValue: number expected";
57148
+ if (message.appliesTo != null && message.hasOwnProperty("appliesTo"))
57149
+ if (!$util.isString(message.appliesTo))
57150
+ return "appliesTo: string expected";
57151
+ if (message.ticketTypeIds != null && message.hasOwnProperty("ticketTypeIds")) {
57152
+ if (!Array.isArray(message.ticketTypeIds))
57153
+ return "ticketTypeIds: array expected";
57154
+ for (var i = 0; i < message.ticketTypeIds.length; ++i)
57155
+ if (!$util.isString(message.ticketTypeIds[i]))
57156
+ return "ticketTypeIds: string[] expected";
57157
+ }
56520
57158
  return null;
56521
57159
  };
56522
57160
 
@@ -56566,6 +57204,19 @@ $root.EventTickets = (function() {
56566
57204
  message.overRideMax = object.overRideMax | 0;
56567
57205
  if (object.overRideMaxUpg != null)
56568
57206
  message.overRideMaxUpg = object.overRideMaxUpg | 0;
57207
+ if (object.discountType != null)
57208
+ message.discountType = String(object.discountType);
57209
+ if (object.discountValue != null)
57210
+ message.discountValue = Number(object.discountValue);
57211
+ if (object.appliesTo != null)
57212
+ message.appliesTo = String(object.appliesTo);
57213
+ if (object.ticketTypeIds) {
57214
+ if (!Array.isArray(object.ticketTypeIds))
57215
+ throw TypeError(".EventTickets.ticketTypeIds: array expected");
57216
+ message.ticketTypeIds = [];
57217
+ for (var i = 0; i < object.ticketTypeIds.length; ++i)
57218
+ message.ticketTypeIds[i] = String(object.ticketTypeIds[i]);
57219
+ }
56569
57220
  return message;
56570
57221
  };
56571
57222
 
@@ -56585,6 +57236,7 @@ $root.EventTickets = (function() {
56585
57236
  if (options.arrays || options.defaults) {
56586
57237
  object.eventTickets = [];
56587
57238
  object.eventUpgrades = [];
57239
+ object.ticketTypeIds = [];
56588
57240
  }
56589
57241
  if (options.defaults) {
56590
57242
  object.promoType = "";
@@ -56594,6 +57246,9 @@ $root.EventTickets = (function() {
56594
57246
  object.endsAt = 0;
56595
57247
  object.overRideMax = 0;
56596
57248
  object.overRideMaxUpg = 0;
57249
+ object.discountType = "";
57250
+ object.discountValue = 0;
57251
+ object.appliesTo = "";
56597
57252
  }
56598
57253
  if (message.promoType != null && message.hasOwnProperty("promoType"))
56599
57254
  object.promoType = message.promoType;
@@ -56619,6 +57274,17 @@ $root.EventTickets = (function() {
56619
57274
  object.overRideMax = message.overRideMax;
56620
57275
  if (message.overRideMaxUpg != null && message.hasOwnProperty("overRideMaxUpg"))
56621
57276
  object.overRideMaxUpg = message.overRideMaxUpg;
57277
+ if (message.discountType != null && message.hasOwnProperty("discountType"))
57278
+ object.discountType = message.discountType;
57279
+ if (message.discountValue != null && message.hasOwnProperty("discountValue"))
57280
+ object.discountValue = options.json && !isFinite(message.discountValue) ? String(message.discountValue) : message.discountValue;
57281
+ if (message.appliesTo != null && message.hasOwnProperty("appliesTo"))
57282
+ object.appliesTo = message.appliesTo;
57283
+ if (message.ticketTypeIds && message.ticketTypeIds.length) {
57284
+ object.ticketTypeIds = [];
57285
+ for (var j = 0; j < message.ticketTypeIds.length; ++j)
57286
+ object.ticketTypeIds[j] = message.ticketTypeIds[j];
57287
+ }
56622
57288
  return object;
56623
57289
  };
56624
57290
 
@@ -62816,6 +63482,39 @@ $root.EventService = (function() {
62816
63482
  * @variation 2
62817
63483
  */
62818
63484
 
63485
+ /**
63486
+ * Callback as used by {@link EventService#eventDiscounts}.
63487
+ * @memberof EventService
63488
+ * @typedef eventDiscountsCallback
63489
+ * @type {function}
63490
+ * @param {Error|null} error Error, if any
63491
+ * @param {EventTicketsResponse} [response] EventTicketsResponse
63492
+ */
63493
+
63494
+ /**
63495
+ * Calls eventDiscounts.
63496
+ * @function eventDiscounts
63497
+ * @memberof EventService
63498
+ * @instance
63499
+ * @param {IEventDiscountRequest} request EventDiscountRequest message or plain object
63500
+ * @param {EventService.eventDiscountsCallback} callback Node-style callback called with the error, if any, and EventTicketsResponse
63501
+ * @returns {undefined}
63502
+ * @variation 1
63503
+ */
63504
+ Object.defineProperty(EventService.prototype.eventDiscounts = function eventDiscounts(request, callback) {
63505
+ return this.rpcCall(eventDiscounts, $root.EventDiscountRequest, $root.EventTicketsResponse, request, callback);
63506
+ }, "name", { value: "eventDiscounts" });
63507
+
63508
+ /**
63509
+ * Calls eventDiscounts.
63510
+ * @function eventDiscounts
63511
+ * @memberof EventService
63512
+ * @instance
63513
+ * @param {IEventDiscountRequest} request EventDiscountRequest message or plain object
63514
+ * @returns {Promise<EventTicketsResponse>} Promise
63515
+ * @variation 2
63516
+ */
63517
+
62819
63518
  /**
62820
63519
  * Callback as used by {@link EventService#findEventById}.
62821
63520
  * @memberof EventService