@51eat/sdk 0.0.32 → 0.0.34

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 (122) hide show
  1. package/README.md +12 -16
  2. package/dist/cjs/BaseClient.js +2 -2
  3. package/dist/cjs/Client.d.ts +0 -3
  4. package/dist/cjs/Client.js +6 -11
  5. package/dist/cjs/api/resources/customer/resources/auth/client/Client.d.ts +1 -2
  6. package/dist/cjs/api/resources/customer/resources/auth/client/Client.js +5 -9
  7. package/dist/cjs/api/resources/customer/resources/auth/client/requests/UploadAvatarRequest.d.ts +2 -3
  8. package/dist/cjs/api/resources/customer/resources/events/resources/index.d.ts +1 -0
  9. package/dist/cjs/api/resources/customer/resources/events/resources/index.js +1 -0
  10. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/Client.d.ts +55 -14
  11. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/Client.js +171 -53
  12. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/ReleaseHoldTicketingRequest.d.ts +2 -2
  13. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/index.d.ts +4 -4
  14. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/index.d.ts +1 -0
  15. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/index.js +1 -0
  16. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/types/CalculatePriceTicketingResponse.d.ts +11 -0
  17. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/types/ConfirmOrderTicketingResponse.d.ts +4 -0
  18. package/dist/cjs/api/resources/{customerEvents/types/CreatePaymentIntentResponse.d.ts → customer/resources/events/resources/ticketing/types/CreatePaymentIntentTicketingResponse.d.ts} +3 -3
  19. package/dist/{esm/api/resources/customerEvents/types/HoldTicketsResponse.d.mts → cjs/api/resources/customer/resources/events/resources/ticketing/types/HoldTicketsTicketingResponse.d.ts} +3 -3
  20. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/types/index.d.ts +4 -0
  21. package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/types/index.js +4 -4
  22. package/dist/cjs/api/resources/index.d.ts +0 -3
  23. package/dist/cjs/api/resources/index.js +1 -4
  24. package/dist/cjs/version.d.ts +1 -1
  25. package/dist/cjs/version.js +1 -1
  26. package/dist/esm/BaseClient.mjs +2 -2
  27. package/dist/esm/Client.d.mts +0 -3
  28. package/dist/esm/Client.mjs +0 -5
  29. package/dist/esm/api/resources/customer/resources/auth/client/Client.d.mts +1 -2
  30. package/dist/esm/api/resources/customer/resources/auth/client/Client.mjs +6 -10
  31. package/dist/esm/api/resources/customer/resources/auth/client/requests/UploadAvatarRequest.d.mts +2 -3
  32. package/dist/esm/api/resources/customer/resources/events/resources/index.d.mts +1 -0
  33. package/dist/esm/api/resources/customer/resources/events/resources/index.mjs +1 -0
  34. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/Client.d.mts +55 -14
  35. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/Client.mjs +171 -53
  36. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/ReleaseHoldTicketingRequest.d.mts +2 -2
  37. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/index.d.mts +4 -4
  38. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/index.d.mts +1 -0
  39. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/index.mjs +1 -0
  40. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/types/CalculatePriceTicketingResponse.d.mts +11 -0
  41. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/types/ConfirmOrderTicketingResponse.d.mts +4 -0
  42. package/dist/esm/api/resources/{customerEvents/types/CreatePaymentIntentResponse.d.mts → customer/resources/events/resources/ticketing/types/CreatePaymentIntentTicketingResponse.d.mts} +3 -3
  43. package/dist/{cjs/api/resources/customerEvents/types/HoldTicketsResponse.d.ts → esm/api/resources/customer/resources/events/resources/ticketing/types/HoldTicketsTicketingResponse.d.mts} +3 -3
  44. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/types/index.d.mts +4 -0
  45. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/types/index.mjs +4 -0
  46. package/dist/esm/api/resources/index.d.mts +0 -3
  47. package/dist/esm/api/resources/index.mjs +0 -3
  48. package/dist/esm/version.d.mts +1 -1
  49. package/dist/esm/version.mjs +1 -1
  50. package/package.json +1 -12
  51. package/reference.md +97 -354
  52. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/CalculatePriceTicketingRequest.d.ts +0 -9
  53. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/ConfirmOrderTicketingRequest.d.ts +0 -9
  54. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/CreatePaymentIntentTicketingRequest.d.ts +0 -9
  55. package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/client/requests/HoldTicketsTicketingRequest.d.ts +0 -9
  56. package/dist/cjs/api/resources/customerEvents/client/Client.d.ts +0 -110
  57. package/dist/cjs/api/resources/customerEvents/client/Client.js +0 -384
  58. package/dist/cjs/api/resources/customerEvents/client/index.d.ts +0 -1
  59. package/dist/cjs/api/resources/customerEvents/client/index.js +0 -17
  60. package/dist/cjs/api/resources/customerEvents/client/requests/ReleaseTicketHoldRequest.d.ts +0 -11
  61. package/dist/cjs/api/resources/customerEvents/client/requests/ReleaseTicketHoldRequest.js +0 -3
  62. package/dist/cjs/api/resources/customerEvents/client/requests/index.d.ts +0 -5
  63. package/dist/cjs/api/resources/customerEvents/client/requests/index.js +0 -2
  64. package/dist/cjs/api/resources/customerEvents/exports.d.ts +0 -2
  65. package/dist/cjs/api/resources/customerEvents/exports.js +0 -21
  66. package/dist/cjs/api/resources/customerEvents/index.d.ts +0 -2
  67. package/dist/cjs/api/resources/customerEvents/index.js +0 -18
  68. package/dist/cjs/api/resources/customerEvents/types/CalculateTicketPriceResponse.d.ts +0 -11
  69. package/dist/cjs/api/resources/customerEvents/types/CalculateTicketPriceResponse.js +0 -3
  70. package/dist/cjs/api/resources/customerEvents/types/ConfirmTicketOrderResponse.d.ts +0 -4
  71. package/dist/cjs/api/resources/customerEvents/types/ConfirmTicketOrderResponse.js +0 -3
  72. package/dist/cjs/api/resources/customerEvents/types/CreatePaymentIntentResponse.js +0 -3
  73. package/dist/cjs/api/resources/customerEvents/types/HoldTicketsResponse.js +0 -3
  74. package/dist/cjs/api/resources/customerEvents/types/index.d.ts +0 -4
  75. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/CalculatePriceTicketingRequest.d.mts +0 -9
  76. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/ConfirmOrderTicketingRequest.d.mts +0 -9
  77. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/CreatePaymentIntentTicketingRequest.d.mts +0 -9
  78. package/dist/esm/api/resources/customer/resources/events/resources/ticketing/client/requests/HoldTicketsTicketingRequest.d.mts +0 -9
  79. package/dist/esm/api/resources/customerEvents/client/Client.d.mts +0 -110
  80. package/dist/esm/api/resources/customerEvents/client/Client.mjs +0 -347
  81. package/dist/esm/api/resources/customerEvents/client/index.d.mts +0 -1
  82. package/dist/esm/api/resources/customerEvents/client/index.mjs +0 -1
  83. package/dist/esm/api/resources/customerEvents/client/requests/ReleaseTicketHoldRequest.d.mts +0 -11
  84. package/dist/esm/api/resources/customerEvents/client/requests/ReleaseTicketHoldRequest.mjs +0 -2
  85. package/dist/esm/api/resources/customerEvents/client/requests/index.d.mts +0 -5
  86. package/dist/esm/api/resources/customerEvents/client/requests/index.mjs +0 -1
  87. package/dist/esm/api/resources/customerEvents/exports.d.mts +0 -2
  88. package/dist/esm/api/resources/customerEvents/exports.mjs +0 -3
  89. package/dist/esm/api/resources/customerEvents/index.d.mts +0 -2
  90. package/dist/esm/api/resources/customerEvents/index.mjs +0 -2
  91. package/dist/esm/api/resources/customerEvents/types/CalculateTicketPriceResponse.d.mts +0 -11
  92. package/dist/esm/api/resources/customerEvents/types/CalculateTicketPriceResponse.mjs +0 -2
  93. package/dist/esm/api/resources/customerEvents/types/ConfirmTicketOrderResponse.d.mts +0 -4
  94. package/dist/esm/api/resources/customerEvents/types/ConfirmTicketOrderResponse.mjs +0 -2
  95. package/dist/esm/api/resources/customerEvents/types/CreatePaymentIntentResponse.mjs +0 -2
  96. package/dist/esm/api/resources/customerEvents/types/HoldTicketsResponse.mjs +0 -2
  97. package/dist/esm/api/resources/customerEvents/types/index.d.mts +0 -4
  98. package/dist/esm/api/resources/customerEvents/types/index.mjs +0 -4
  99. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CalculatePriceRequest.d.ts +0 -0
  100. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CalculatePriceRequest.js +0 -0
  101. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CreatePaymentIntentRequest.d.ts +0 -0
  102. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CreatePaymentIntentRequest.js +0 -0
  103. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketHoldRequest.d.ts +0 -0
  104. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketHoldRequest.js +0 -0
  105. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketOrderRequest.d.ts +0 -0
  106. /package/dist/cjs/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketOrderRequest.js +0 -0
  107. /package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/{client/requests/CalculatePriceTicketingRequest.js → types/CalculatePriceTicketingResponse.js} +0 -0
  108. /package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/{client/requests/ConfirmOrderTicketingRequest.js → types/ConfirmOrderTicketingResponse.js} +0 -0
  109. /package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/{client/requests/CreatePaymentIntentTicketingRequest.js → types/CreatePaymentIntentTicketingResponse.js} +0 -0
  110. /package/dist/cjs/api/resources/customer/resources/events/resources/ticketing/{client/requests/HoldTicketsTicketingRequest.js → types/HoldTicketsTicketingResponse.js} +0 -0
  111. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CalculatePriceRequest.d.mts +0 -0
  112. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CalculatePriceRequest.mjs +0 -0
  113. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CreatePaymentIntentRequest.d.mts +0 -0
  114. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/CreatePaymentIntentRequest.mjs +0 -0
  115. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketHoldRequest.d.mts +0 -0
  116. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketHoldRequest.mjs +0 -0
  117. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketOrderRequest.d.mts +0 -0
  118. /package/dist/esm/api/resources/{customerEvents → customer/resources/events/resources/ticketing}/client/requests/StoreTicketOrderRequest.mjs +0 -0
  119. /package/dist/esm/api/resources/customer/resources/events/resources/ticketing/{client/requests/CalculatePriceTicketingRequest.mjs → types/CalculatePriceTicketingResponse.mjs} +0 -0
  120. /package/dist/esm/api/resources/customer/resources/events/resources/ticketing/{client/requests/ConfirmOrderTicketingRequest.mjs → types/ConfirmOrderTicketingResponse.mjs} +0 -0
  121. /package/dist/esm/api/resources/customer/resources/events/resources/ticketing/{client/requests/CreatePaymentIntentTicketingRequest.mjs → types/CreatePaymentIntentTicketingResponse.mjs} +0 -0
  122. /package/dist/esm/api/resources/customer/resources/events/resources/ticketing/{client/requests/HoldTicketsTicketingRequest.mjs → types/HoldTicketsTicketingResponse.mjs} +0 -0
@@ -42,6 +42,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
42
42
  step((generator = generator.apply(thisArg, _arguments || [])).next());
43
43
  });
44
44
  };
45
+ var __rest = (this && this.__rest) || function (s, e) {
46
+ var t = {};
47
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
48
+ t[p] = s[p];
49
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
50
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
51
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
52
+ t[p[i]] = s[p[i]];
53
+ }
54
+ return t;
55
+ };
45
56
  Object.defineProperty(exports, "__esModule", { value: true });
46
57
  exports.TicketingClient = void 0;
47
58
  const BaseClient_js_1 = require("../../../../../../../../BaseClient.js");
@@ -50,17 +61,28 @@ const core = __importStar(require("../../../../../../../../core/index.js"));
50
61
  const environments = __importStar(require("../../../../../../../../environments.js"));
51
62
  const handleNonStatusCodeError_js_1 = require("../../../../../../../../errors/handleNonStatusCodeError.js");
52
63
  const errors = __importStar(require("../../../../../../../../errors/index.js"));
64
+ const FiveOneEat = __importStar(require("../../../../../../../index.js"));
53
65
  class TicketingClient {
54
66
  constructor(options = {}) {
55
67
  this._options = (0, BaseClient_js_1.normalizeClientOptionsWithAuth)(options);
56
68
  }
57
69
  /**
58
- * @param {FiveOneEat.customer.events.HoldTicketsTicketingRequest} request
70
+ * Place a temporary hold on tickets for the specified event. Holds expire after 10 minutes.
71
+ *
72
+ * @param {FiveOneEat.customer.events.StoreTicketHoldRequest} request
59
73
  * @param {TicketingClient.RequestOptions} requestOptions - Request-specific configuration.
60
74
  *
75
+ * @throws {@link FiveOneEat.UnauthorizedError}
76
+ * @throws {@link FiveOneEat.NotFoundError}
77
+ * @throws {@link FiveOneEat.UnprocessableEntityError}
78
+ *
61
79
  * @example
62
80
  * await client.customer.events.ticketing.holdTickets({
63
- * event: "event"
81
+ * eventId: "eventId",
82
+ * tickets: [{
83
+ * ticket_type_id: "ticket_type_id",
84
+ * quantity: 1
85
+ * }]
64
86
  * })
65
87
  */
66
88
  holdTickets(request, requestOptions) {
@@ -69,14 +91,17 @@ class TicketingClient {
69
91
  __holdTickets(request, requestOptions) {
70
92
  return __awaiter(this, void 0, void 0, function* () {
71
93
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
72
- const { event } = request;
94
+ const { eventId } = request, _body = __rest(request, ["eventId"]);
73
95
  const _authRequest = yield this._options.authProvider.getAuthRequest();
74
96
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
75
97
  const _response = yield core.fetcher({
76
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(event)}/ticket-holds`),
98
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(eventId)}/ticket-holds`),
77
99
  method: "POST",
78
100
  headers: _headers,
101
+ contentType: "application/json",
79
102
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
103
+ requestType: "json",
104
+ body: _body,
80
105
  timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
81
106
  maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
82
107
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -84,25 +109,42 @@ class TicketingClient {
84
109
  logging: this._options.logging,
85
110
  });
86
111
  if (_response.ok) {
87
- return { data: undefined, rawResponse: _response.rawResponse };
112
+ return {
113
+ data: _response.body,
114
+ rawResponse: _response.rawResponse,
115
+ };
88
116
  }
89
117
  if (_response.error.reason === "status-code") {
90
- throw new errors.FiveOneEatError({
91
- statusCode: _response.error.statusCode,
92
- body: _response.error.body,
93
- rawResponse: _response.rawResponse,
94
- });
118
+ switch (_response.error.statusCode) {
119
+ case 401:
120
+ throw new FiveOneEat.UnauthorizedError(_response.error.body, _response.rawResponse);
121
+ case 404:
122
+ throw new FiveOneEat.NotFoundError(_response.error.body, _response.rawResponse);
123
+ case 422:
124
+ throw new FiveOneEat.UnprocessableEntityError(_response.error.body, _response.rawResponse);
125
+ default:
126
+ throw new errors.FiveOneEatError({
127
+ statusCode: _response.error.statusCode,
128
+ body: _response.error.body,
129
+ rawResponse: _response.rawResponse,
130
+ });
131
+ }
95
132
  }
96
- return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{event}/ticket-holds");
133
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{eventId}/ticket-holds");
97
134
  });
98
135
  }
99
136
  /**
137
+ * Release all active holds for the given session, freeing the tickets for others.
138
+ *
100
139
  * @param {FiveOneEat.customer.events.ReleaseHoldTicketingRequest} request
101
140
  * @param {TicketingClient.RequestOptions} requestOptions - Request-specific configuration.
102
141
  *
142
+ * @throws {@link FiveOneEat.UnauthorizedError}
143
+ * @throws {@link FiveOneEat.NotFoundError}
144
+ *
103
145
  * @example
104
146
  * await client.customer.events.ticketing.releaseHold({
105
- * event: "event",
147
+ * eventId: "eventId",
106
148
  * sessionId: "sessionId"
107
149
  * })
108
150
  */
@@ -112,11 +154,11 @@ class TicketingClient {
112
154
  __releaseHold(request, requestOptions) {
113
155
  return __awaiter(this, void 0, void 0, function* () {
114
156
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
115
- const { event, sessionId } = request;
157
+ const { eventId, sessionId } = request;
116
158
  const _authRequest = yield this._options.authProvider.getAuthRequest();
117
159
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
118
160
  const _response = yield core.fetcher({
119
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(event)}/ticket-holds/${core.url.encodePathParam(sessionId)}`),
161
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(eventId)}/ticket-holds/${core.url.encodePathParam(sessionId)}`),
120
162
  method: "DELETE",
121
163
  headers: _headers,
122
164
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -130,22 +172,39 @@ class TicketingClient {
130
172
  return { data: undefined, rawResponse: _response.rawResponse };
131
173
  }
132
174
  if (_response.error.reason === "status-code") {
133
- throw new errors.FiveOneEatError({
134
- statusCode: _response.error.statusCode,
135
- body: _response.error.body,
136
- rawResponse: _response.rawResponse,
137
- });
175
+ switch (_response.error.statusCode) {
176
+ case 401:
177
+ throw new FiveOneEat.UnauthorizedError(_response.error.body, _response.rawResponse);
178
+ case 404:
179
+ throw new FiveOneEat.NotFoundError(_response.error.body, _response.rawResponse);
180
+ default:
181
+ throw new errors.FiveOneEatError({
182
+ statusCode: _response.error.statusCode,
183
+ body: _response.error.body,
184
+ rawResponse: _response.rawResponse,
185
+ });
186
+ }
138
187
  }
139
- return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/customer/events/{event}/ticket-holds/{sessionId}");
188
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/customer/events/{eventId}/ticket-holds/{sessionId}");
140
189
  });
141
190
  }
142
191
  /**
143
- * @param {FiveOneEat.customer.events.CalculatePriceTicketingRequest} request
192
+ * Preview the subtotal, platform fee, and total for a given ticket selection.
193
+ *
194
+ * @param {FiveOneEat.customer.events.CalculatePriceRequest} request
144
195
  * @param {TicketingClient.RequestOptions} requestOptions - Request-specific configuration.
145
196
  *
197
+ * @throws {@link FiveOneEat.UnauthorizedError}
198
+ * @throws {@link FiveOneEat.NotFoundError}
199
+ * @throws {@link FiveOneEat.UnprocessableEntityError}
200
+ *
146
201
  * @example
147
202
  * await client.customer.events.ticketing.calculatePrice({
148
- * event: "event"
203
+ * eventId: "eventId",
204
+ * tickets: [{
205
+ * ticket_type_id: "ticket_type_id",
206
+ * quantity: 1
207
+ * }]
149
208
  * })
150
209
  */
151
210
  calculatePrice(request, requestOptions) {
@@ -154,14 +213,17 @@ class TicketingClient {
154
213
  __calculatePrice(request, requestOptions) {
155
214
  return __awaiter(this, void 0, void 0, function* () {
156
215
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
157
- const { event } = request;
216
+ const { eventId } = request, _body = __rest(request, ["eventId"]);
158
217
  const _authRequest = yield this._options.authProvider.getAuthRequest();
159
218
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
160
219
  const _response = yield core.fetcher({
161
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(event)}/calculate-price`),
220
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(eventId)}/calculate-price`),
162
221
  method: "POST",
163
222
  headers: _headers,
223
+ contentType: "application/json",
164
224
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
225
+ requestType: "json",
226
+ body: _body,
165
227
  timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
166
228
  maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
167
229
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -169,25 +231,45 @@ class TicketingClient {
169
231
  logging: this._options.logging,
170
232
  });
171
233
  if (_response.ok) {
172
- return { data: undefined, rawResponse: _response.rawResponse };
234
+ return {
235
+ data: _response.body,
236
+ rawResponse: _response.rawResponse,
237
+ };
173
238
  }
174
239
  if (_response.error.reason === "status-code") {
175
- throw new errors.FiveOneEatError({
176
- statusCode: _response.error.statusCode,
177
- body: _response.error.body,
178
- rawResponse: _response.rawResponse,
179
- });
240
+ switch (_response.error.statusCode) {
241
+ case 401:
242
+ throw new FiveOneEat.UnauthorizedError(_response.error.body, _response.rawResponse);
243
+ case 404:
244
+ throw new FiveOneEat.NotFoundError(_response.error.body, _response.rawResponse);
245
+ case 422:
246
+ throw new FiveOneEat.UnprocessableEntityError(_response.error.body, _response.rawResponse);
247
+ default:
248
+ throw new errors.FiveOneEatError({
249
+ statusCode: _response.error.statusCode,
250
+ body: _response.error.body,
251
+ rawResponse: _response.rawResponse,
252
+ });
253
+ }
180
254
  }
181
- return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{event}/calculate-price");
255
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{eventId}/calculate-price");
182
256
  });
183
257
  }
184
258
  /**
185
- * @param {FiveOneEat.customer.events.CreatePaymentIntentTicketingRequest} request
259
+ * Create a Stripe payment intent for the tickets held in the given session.
260
+ * Returns a client_secret for the mobile app to confirm payment with Stripe.
261
+ *
262
+ * @param {FiveOneEat.customer.events.CreatePaymentIntentRequest} request
186
263
  * @param {TicketingClient.RequestOptions} requestOptions - Request-specific configuration.
187
264
  *
265
+ * @throws {@link FiveOneEat.UnauthorizedError}
266
+ * @throws {@link FiveOneEat.NotFoundError}
267
+ * @throws {@link FiveOneEat.UnprocessableEntityError}
268
+ *
188
269
  * @example
189
270
  * await client.customer.events.ticketing.createPaymentIntent({
190
- * event: "event"
271
+ * eventId: "eventId",
272
+ * session_id: "session_id"
191
273
  * })
192
274
  */
193
275
  createPaymentIntent(request, requestOptions) {
@@ -196,14 +278,17 @@ class TicketingClient {
196
278
  __createPaymentIntent(request, requestOptions) {
197
279
  return __awaiter(this, void 0, void 0, function* () {
198
280
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
199
- const { event } = request;
281
+ const { eventId } = request, _body = __rest(request, ["eventId"]);
200
282
  const _authRequest = yield this._options.authProvider.getAuthRequest();
201
283
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
202
284
  const _response = yield core.fetcher({
203
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(event)}/payment-intent`),
285
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(eventId)}/payment-intent`),
204
286
  method: "POST",
205
287
  headers: _headers,
288
+ contentType: "application/json",
206
289
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
290
+ requestType: "json",
291
+ body: _body,
207
292
  timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
208
293
  maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
209
294
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -211,25 +296,45 @@ class TicketingClient {
211
296
  logging: this._options.logging,
212
297
  });
213
298
  if (_response.ok) {
214
- return { data: undefined, rawResponse: _response.rawResponse };
299
+ return {
300
+ data: _response.body,
301
+ rawResponse: _response.rawResponse,
302
+ };
215
303
  }
216
304
  if (_response.error.reason === "status-code") {
217
- throw new errors.FiveOneEatError({
218
- statusCode: _response.error.statusCode,
219
- body: _response.error.body,
220
- rawResponse: _response.rawResponse,
221
- });
305
+ switch (_response.error.statusCode) {
306
+ case 401:
307
+ throw new FiveOneEat.UnauthorizedError(_response.error.body, _response.rawResponse);
308
+ case 404:
309
+ throw new FiveOneEat.NotFoundError(_response.error.body, _response.rawResponse);
310
+ case 422:
311
+ throw new FiveOneEat.UnprocessableEntityError(_response.error.body, _response.rawResponse);
312
+ default:
313
+ throw new errors.FiveOneEatError({
314
+ statusCode: _response.error.statusCode,
315
+ body: _response.error.body,
316
+ rawResponse: _response.rawResponse,
317
+ });
318
+ }
222
319
  }
223
- return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{event}/payment-intent");
320
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{eventId}/payment-intent");
224
321
  });
225
322
  }
226
323
  /**
227
- * @param {FiveOneEat.customer.events.ConfirmOrderTicketingRequest} request
324
+ * Confirm a completed Stripe payment and create the ticket order.
325
+ * The payment must have succeeded before calling this endpoint.
326
+ *
327
+ * @param {FiveOneEat.customer.events.StoreTicketOrderRequest} request
228
328
  * @param {TicketingClient.RequestOptions} requestOptions - Request-specific configuration.
229
329
  *
330
+ * @throws {@link FiveOneEat.UnauthorizedError}
331
+ * @throws {@link FiveOneEat.UnprocessableEntityError}
332
+ *
230
333
  * @example
231
334
  * await client.customer.events.ticketing.confirmOrder({
232
- * event: "event"
335
+ * eventId: "eventId",
336
+ * payment_intent_id: "payment_intent_id",
337
+ * session_id: "session_id"
233
338
  * })
234
339
  */
235
340
  confirmOrder(request, requestOptions) {
@@ -238,14 +343,17 @@ class TicketingClient {
238
343
  __confirmOrder(request, requestOptions) {
239
344
  return __awaiter(this, void 0, void 0, function* () {
240
345
  var _a, _b, _c, _d, _e, _f, _g, _h, _j;
241
- const { event } = request;
346
+ const { eventId } = request, _body = __rest(request, ["eventId"]);
242
347
  const _authRequest = yield this._options.authProvider.getAuthRequest();
243
348
  const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
244
349
  const _response = yield core.fetcher({
245
- url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(event)}/ticket-orders`),
350
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FiveOneEatEnvironment.Production, `customer/events/${core.url.encodePathParam(eventId)}/ticket-orders`),
246
351
  method: "POST",
247
352
  headers: _headers,
353
+ contentType: "application/json",
248
354
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
355
+ requestType: "json",
356
+ body: _body,
249
357
  timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
250
358
  maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
251
359
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -253,16 +361,26 @@ class TicketingClient {
253
361
  logging: this._options.logging,
254
362
  });
255
363
  if (_response.ok) {
256
- return { data: undefined, rawResponse: _response.rawResponse };
364
+ return {
365
+ data: _response.body,
366
+ rawResponse: _response.rawResponse,
367
+ };
257
368
  }
258
369
  if (_response.error.reason === "status-code") {
259
- throw new errors.FiveOneEatError({
260
- statusCode: _response.error.statusCode,
261
- body: _response.error.body,
262
- rawResponse: _response.rawResponse,
263
- });
370
+ switch (_response.error.statusCode) {
371
+ case 401:
372
+ throw new FiveOneEat.UnauthorizedError(_response.error.body, _response.rawResponse);
373
+ case 422:
374
+ throw new FiveOneEat.UnprocessableEntityError(_response.error.body, _response.rawResponse);
375
+ default:
376
+ throw new errors.FiveOneEatError({
377
+ statusCode: _response.error.statusCode,
378
+ body: _response.error.body,
379
+ rawResponse: _response.rawResponse,
380
+ });
381
+ }
264
382
  }
265
- return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{event}/ticket-orders");
383
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/customer/events/{eventId}/ticket-orders");
266
384
  });
267
385
  }
268
386
  }
@@ -1,11 +1,11 @@
1
1
  /**
2
2
  * @example
3
3
  * {
4
- * event: "event",
4
+ * eventId: "eventId",
5
5
  * sessionId: "sessionId"
6
6
  * }
7
7
  */
8
8
  export interface ReleaseHoldTicketingRequest {
9
- event: string;
9
+ eventId: string;
10
10
  sessionId: string;
11
11
  }
@@ -1,5 +1,5 @@
1
- export type { CalculatePriceTicketingRequest } from "./CalculatePriceTicketingRequest.js";
2
- export type { ConfirmOrderTicketingRequest } from "./ConfirmOrderTicketingRequest.js";
3
- export type { CreatePaymentIntentTicketingRequest } from "./CreatePaymentIntentTicketingRequest.js";
4
- export type { HoldTicketsTicketingRequest } from "./HoldTicketsTicketingRequest.js";
1
+ export type { CalculatePriceRequest } from "./CalculatePriceRequest.js";
2
+ export type { CreatePaymentIntentRequest } from "./CreatePaymentIntentRequest.js";
5
3
  export type { ReleaseHoldTicketingRequest } from "./ReleaseHoldTicketingRequest.js";
4
+ export type { StoreTicketHoldRequest } from "./StoreTicketHoldRequest.js";
5
+ export type { StoreTicketOrderRequest } from "./StoreTicketOrderRequest.js";
@@ -1 +1,2 @@
1
1
  export * from "./client/index.js";
2
+ export * from "./types/index.js";
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./client/index.js"), exports);
18
+ __exportStar(require("./types/index.js"), exports);
@@ -0,0 +1,11 @@
1
+ export interface CalculatePriceTicketingResponse {
2
+ data: CalculatePriceTicketingResponse.Data;
3
+ }
4
+ export declare namespace CalculatePriceTicketingResponse {
5
+ interface Data {
6
+ subtotal: string;
7
+ platform_fee: string;
8
+ total: string;
9
+ line_items: string;
10
+ }
11
+ }
@@ -0,0 +1,4 @@
1
+ import type * as FiveOneEat from "../../../../../../../index.js";
2
+ export type ConfirmOrderTicketingResponse = {
3
+ data: FiveOneEat.JsonResource;
4
+ } | Record<string, unknown>;
@@ -1,7 +1,7 @@
1
- export interface CreatePaymentIntentResponse {
2
- data: CreatePaymentIntentResponse.Data;
1
+ export interface CreatePaymentIntentTicketingResponse {
2
+ data: CreatePaymentIntentTicketingResponse.Data;
3
3
  }
4
- export declare namespace CreatePaymentIntentResponse {
4
+ export declare namespace CreatePaymentIntentTicketingResponse {
5
5
  interface Data {
6
6
  payment_intent_id: string;
7
7
  client_secret: string;
@@ -1,7 +1,7 @@
1
- export interface HoldTicketsResponse {
2
- data: HoldTicketsResponse.Data;
1
+ export interface HoldTicketsTicketingResponse {
2
+ data: HoldTicketsTicketingResponse.Data;
3
3
  }
4
- export declare namespace HoldTicketsResponse {
4
+ export declare namespace HoldTicketsTicketingResponse {
5
5
  interface Data {
6
6
  session_id: string | null;
7
7
  expires_at: string;
@@ -0,0 +1,4 @@
1
+ export * from "./CalculatePriceTicketingResponse.js";
2
+ export * from "./ConfirmOrderTicketingResponse.js";
3
+ export * from "./CreatePaymentIntentTicketingResponse.js";
4
+ export * from "./HoldTicketsTicketingResponse.js";
@@ -14,7 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./CalculateTicketPriceResponse.js"), exports);
18
- __exportStar(require("./ConfirmTicketOrderResponse.js"), exports);
19
- __exportStar(require("./CreatePaymentIntentResponse.js"), exports);
20
- __exportStar(require("./HoldTicketsResponse.js"), exports);
17
+ __exportStar(require("./CalculatePriceTicketingResponse.js"), exports);
18
+ __exportStar(require("./ConfirmOrderTicketingResponse.js"), exports);
19
+ __exportStar(require("./CreatePaymentIntentTicketingResponse.js"), exports);
20
+ __exportStar(require("./HoldTicketsTicketingResponse.js"), exports);
@@ -2,9 +2,6 @@ export * as business from "./business/index.js";
2
2
  export * from "./customer/client/requests/index.js";
3
3
  export * as customer from "./customer/index.js";
4
4
  export * from "./customer/types/index.js";
5
- export * from "./customerEvents/client/requests/index.js";
6
- export * as customerEvents from "./customerEvents/index.js";
7
- export * from "./customerEvents/types/index.js";
8
5
  export * from "./customerMyAccount/client/requests/index.js";
9
6
  export * as customerMyAccount from "./customerMyAccount/index.js";
10
7
  export * from "./customerMyAccount/types/index.js";
@@ -36,14 +36,11 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
36
36
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
37
37
  };
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.serveAd = exports.recordClick = exports.customerMyAccount = exports.customerEvents = exports.customer = exports.business = void 0;
39
+ exports.serveAd = exports.recordClick = exports.customerMyAccount = exports.customer = exports.business = void 0;
40
40
  exports.business = __importStar(require("./business/index.js"));
41
41
  __exportStar(require("./customer/client/requests/index.js"), exports);
42
42
  exports.customer = __importStar(require("./customer/index.js"));
43
43
  __exportStar(require("./customer/types/index.js"), exports);
44
- __exportStar(require("./customerEvents/client/requests/index.js"), exports);
45
- exports.customerEvents = __importStar(require("./customerEvents/index.js"));
46
- __exportStar(require("./customerEvents/types/index.js"), exports);
47
44
  __exportStar(require("./customerMyAccount/client/requests/index.js"), exports);
48
45
  exports.customerMyAccount = __importStar(require("./customerMyAccount/index.js"));
49
46
  __exportStar(require("./customerMyAccount/types/index.js"), exports);
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.0.32";
1
+ export declare const SDK_VERSION = "0.0.34";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "0.0.32";
4
+ exports.SDK_VERSION = "0.0.34";
@@ -6,8 +6,8 @@ export function normalizeClientOptions(options) {
6
6
  const headers = mergeHeaders({
7
7
  "X-Fern-Language": "JavaScript",
8
8
  "X-Fern-SDK-Name": "@51eat/sdk",
9
- "X-Fern-SDK-Version": "0.0.32",
10
- "User-Agent": "@51eat/sdk/0.0.32",
9
+ "X-Fern-SDK-Version": "0.0.34",
10
+ "User-Agent": "@51eat/sdk/0.0.34",
11
11
  "X-Fern-Runtime": core.RUNTIME.type,
12
12
  "X-Fern-Runtime-Version": core.RUNTIME.version,
13
13
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -1,6 +1,5 @@
1
1
  import { BusinessClient } from "./api/resources/business/client/Client.mjs";
2
2
  import { CustomerClient } from "./api/resources/customer/client/Client.mjs";
3
- import { CustomerEventsClient } from "./api/resources/customerEvents/client/Client.mjs";
4
3
  import { CustomerMyAccountClient } from "./api/resources/customerMyAccount/client/Client.mjs";
5
4
  import { RecordClickClient } from "./api/resources/recordClick/client/Client.mjs";
6
5
  import { ServeAdClient } from "./api/resources/serveAd/client/Client.mjs";
@@ -14,14 +13,12 @@ export declare namespace FiveOneEatClient {
14
13
  }
15
14
  export declare class FiveOneEatClient {
16
15
  protected readonly _options: NormalizedClientOptionsWithAuth<FiveOneEatClient.Options>;
17
- protected _customerEvents: CustomerEventsClient | undefined;
18
16
  protected _customerMyAccount: CustomerMyAccountClient | undefined;
19
17
  protected _customer: CustomerClient | undefined;
20
18
  protected _recordClick: RecordClickClient | undefined;
21
19
  protected _serveAd: ServeAdClient | undefined;
22
20
  protected _business: BusinessClient | undefined;
23
21
  constructor(options?: FiveOneEatClient.Options);
24
- get customerEvents(): CustomerEventsClient;
25
22
  get customerMyAccount(): CustomerMyAccountClient;
26
23
  get customer(): CustomerClient;
27
24
  get recordClick(): RecordClickClient;
@@ -10,7 +10,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  };
11
11
  import { BusinessClient } from "./api/resources/business/client/Client.mjs";
12
12
  import { CustomerClient } from "./api/resources/customer/client/Client.mjs";
13
- import { CustomerEventsClient } from "./api/resources/customerEvents/client/Client.mjs";
14
13
  import { CustomerMyAccountClient } from "./api/resources/customerMyAccount/client/Client.mjs";
15
14
  import { RecordClickClient } from "./api/resources/recordClick/client/Client.mjs";
16
15
  import { ServeAdClient } from "./api/resources/serveAd/client/Client.mjs";
@@ -20,10 +19,6 @@ export class FiveOneEatClient {
20
19
  constructor(options = {}) {
21
20
  this._options = normalizeClientOptionsWithAuth(options);
22
21
  }
23
- get customerEvents() {
24
- var _a;
25
- return ((_a = this._customerEvents) !== null && _a !== void 0 ? _a : (this._customerEvents = new CustomerEventsClient(this._options)));
26
- }
27
22
  get customerMyAccount() {
28
23
  var _a;
29
24
  return ((_a = this._customerMyAccount) !== null && _a !== void 0 ? _a : (this._customerMyAccount = new CustomerMyAccountClient(this._options)));
@@ -121,9 +121,8 @@ export declare class AuthClient {
121
121
  * @throws {@link FiveOneEat.UnprocessableEntityError}
122
122
  *
123
123
  * @example
124
- * import { createReadStream } from "fs";
125
124
  * await client.customer.auth.uploadAvatar({
126
- * avatar: fs.createReadStream("/path/to/your/file")
125
+ * avatar: "avatar"
127
126
  * })
128
127
  */
129
128
  uploadAvatar(request: FiveOneEat.customer.UploadAvatarRequest, requestOptions?: AuthClient.RequestOptions): core.HttpResponsePromise<FiveOneEat.customer.UploadAvatarAuthResponse>;