@tripsam/main 2.0.11 → 2.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -34,6 +34,7 @@ __export(index_exports, {
34
34
  Location: () => location_exports,
35
35
  ResetPassword: () => reset_password_exports,
36
36
  Safari: () => safari_exports,
37
+ SafariBooking: () => safariBooking_exports,
37
38
  Signup: () => signup_exports,
38
39
  User: () => user_exports
39
40
  });
@@ -221,7 +222,7 @@ var pickupPoint = import_zod6.default.object({
221
222
  var safariDetails = import_zod6.default.object({
222
223
  id: import_zod6.default.string(),
223
224
  safariCode: import_zod6.default.string(),
224
- vehilces: import_zod6.default.array(safariVehicle),
225
+ vehicles: import_zod6.default.array(safariVehicle),
225
226
  slots: import_zod6.default.array(safariSlot),
226
227
  rate: decimalish,
227
228
  discount: decimalish,
@@ -233,12 +234,40 @@ var safariDetails = import_zod6.default.object({
233
234
  safariType: import_zod6.default.array(import_zod6.default.string()),
234
235
  description: import_zod6.default.string().optional()
235
236
  });
237
+
238
+ // src/safariBooking.ts
239
+ var safariBooking_exports = {};
240
+ __export(safariBooking_exports, {
241
+ createBooking: () => createBooking,
242
+ safariType: () => safariType
243
+ });
244
+ var import_zod7 = __toESM(require("zod"), 1);
245
+ var safariType = import_zod7.default.enum([
246
+ "LEOPARD_SAFARI",
247
+ "TIGER_SAFARI",
248
+ "LION_SAFARI",
249
+ "BIRD_WATCHING_SAFARI",
250
+ "JUNGLE_SAFARI",
251
+ "VILLAGE_SAFARI"
252
+ ]);
253
+ var createBooking = import_zod7.default.object({
254
+ safariId: import_zod7.default.string().min(1),
255
+ slotId: import_zod7.default.string().min(1),
256
+ bookingDate: import_zod7.default.string().refine((s) => !Number.isNaN(Date.parse(s)), "invalid ISO date"),
257
+ numberOfAdults: import_zod7.default.coerce.number().int().min(1),
258
+ numberOfKids: import_zod7.default.coerce.number().int().min(0).default(0),
259
+ numberOfInfants: import_zod7.default.coerce.number().int().min(0).default(0),
260
+ totalPrice: import_zod7.default.coerce.number().int().min(0),
261
+ commission: import_zod7.default.coerce.number().int().min(0),
262
+ safariType: safariType.default("LEOPARD_SAFARI")
263
+ });
236
264
  // Annotate the CommonJS export names for ESM import in node:
237
265
  0 && (module.exports = {
238
266
  Auth,
239
267
  Location,
240
268
  ResetPassword,
241
269
  Safari,
270
+ SafariBooking,
242
271
  Signup,
243
272
  User
244
273
  });
package/dist/index.d.cts CHANGED
@@ -208,7 +208,7 @@ declare const pickupPoint: z$1.ZodObject<{
208
208
  declare const safariDetails: z$1.ZodObject<{
209
209
  id: z$1.ZodString;
210
210
  safariCode: z$1.ZodString;
211
- vehilces: z$1.ZodArray<z$1.ZodObject<{
211
+ vehicles: z$1.ZodArray<z$1.ZodObject<{
212
212
  name: z$1.ZodString;
213
213
  rcNumber: z$1.ZodString;
214
214
  capacity: z$1.ZodNumber;
@@ -287,4 +287,39 @@ declare namespace safari {
287
287
  export { type safari_SafariDetails as SafariDetails, type safari_SafariSearch as SafariSearch, safari_location as location, safari_pickupPoint as pickupPoint, safari_safariDetails as safariDetails, safari_safariSearchSchema as safariSearchSchema, safari_safariSlot as safariSlot, safari_safariVehicle as safariVehicle };
288
288
  }
289
289
 
290
- export { auth as Auth, location$2 as Location, resetPassword as ResetPassword, safari as Safari, signup as Signup, user as User };
290
+ declare const safariType: z$1.ZodEnum<{
291
+ LEOPARD_SAFARI: "LEOPARD_SAFARI";
292
+ TIGER_SAFARI: "TIGER_SAFARI";
293
+ LION_SAFARI: "LION_SAFARI";
294
+ BIRD_WATCHING_SAFARI: "BIRD_WATCHING_SAFARI";
295
+ JUNGLE_SAFARI: "JUNGLE_SAFARI";
296
+ VILLAGE_SAFARI: "VILLAGE_SAFARI";
297
+ }>;
298
+ declare const createBooking: z$1.ZodObject<{
299
+ safariId: z$1.ZodString;
300
+ slotId: z$1.ZodString;
301
+ bookingDate: z$1.ZodString;
302
+ numberOfAdults: z$1.ZodCoercedNumber<unknown>;
303
+ numberOfKids: z$1.ZodDefault<z$1.ZodCoercedNumber<unknown>>;
304
+ numberOfInfants: z$1.ZodDefault<z$1.ZodCoercedNumber<unknown>>;
305
+ totalPrice: z$1.ZodCoercedNumber<unknown>;
306
+ commission: z$1.ZodCoercedNumber<unknown>;
307
+ safariType: z$1.ZodDefault<z$1.ZodEnum<{
308
+ LEOPARD_SAFARI: "LEOPARD_SAFARI";
309
+ TIGER_SAFARI: "TIGER_SAFARI";
310
+ LION_SAFARI: "LION_SAFARI";
311
+ BIRD_WATCHING_SAFARI: "BIRD_WATCHING_SAFARI";
312
+ JUNGLE_SAFARI: "JUNGLE_SAFARI";
313
+ VILLAGE_SAFARI: "VILLAGE_SAFARI";
314
+ }>>;
315
+ }, z$1.core.$strip>;
316
+ type SafeCreateBooking = z$1.output<typeof createBooking>;
317
+
318
+ type safariBooking_SafeCreateBooking = SafeCreateBooking;
319
+ declare const safariBooking_createBooking: typeof createBooking;
320
+ declare const safariBooking_safariType: typeof safariType;
321
+ declare namespace safariBooking {
322
+ export { type safariBooking_SafeCreateBooking as SafeCreateBooking, safariBooking_createBooking as createBooking, safariBooking_safariType as safariType };
323
+ }
324
+
325
+ export { auth as Auth, location$2 as Location, resetPassword as ResetPassword, safari as Safari, safariBooking as SafariBooking, signup as Signup, user as User };
package/dist/index.d.ts CHANGED
@@ -208,7 +208,7 @@ declare const pickupPoint: z$1.ZodObject<{
208
208
  declare const safariDetails: z$1.ZodObject<{
209
209
  id: z$1.ZodString;
210
210
  safariCode: z$1.ZodString;
211
- vehilces: z$1.ZodArray<z$1.ZodObject<{
211
+ vehicles: z$1.ZodArray<z$1.ZodObject<{
212
212
  name: z$1.ZodString;
213
213
  rcNumber: z$1.ZodString;
214
214
  capacity: z$1.ZodNumber;
@@ -287,4 +287,39 @@ declare namespace safari {
287
287
  export { type safari_SafariDetails as SafariDetails, type safari_SafariSearch as SafariSearch, safari_location as location, safari_pickupPoint as pickupPoint, safari_safariDetails as safariDetails, safari_safariSearchSchema as safariSearchSchema, safari_safariSlot as safariSlot, safari_safariVehicle as safariVehicle };
288
288
  }
289
289
 
290
- export { auth as Auth, location$2 as Location, resetPassword as ResetPassword, safari as Safari, signup as Signup, user as User };
290
+ declare const safariType: z$1.ZodEnum<{
291
+ LEOPARD_SAFARI: "LEOPARD_SAFARI";
292
+ TIGER_SAFARI: "TIGER_SAFARI";
293
+ LION_SAFARI: "LION_SAFARI";
294
+ BIRD_WATCHING_SAFARI: "BIRD_WATCHING_SAFARI";
295
+ JUNGLE_SAFARI: "JUNGLE_SAFARI";
296
+ VILLAGE_SAFARI: "VILLAGE_SAFARI";
297
+ }>;
298
+ declare const createBooking: z$1.ZodObject<{
299
+ safariId: z$1.ZodString;
300
+ slotId: z$1.ZodString;
301
+ bookingDate: z$1.ZodString;
302
+ numberOfAdults: z$1.ZodCoercedNumber<unknown>;
303
+ numberOfKids: z$1.ZodDefault<z$1.ZodCoercedNumber<unknown>>;
304
+ numberOfInfants: z$1.ZodDefault<z$1.ZodCoercedNumber<unknown>>;
305
+ totalPrice: z$1.ZodCoercedNumber<unknown>;
306
+ commission: z$1.ZodCoercedNumber<unknown>;
307
+ safariType: z$1.ZodDefault<z$1.ZodEnum<{
308
+ LEOPARD_SAFARI: "LEOPARD_SAFARI";
309
+ TIGER_SAFARI: "TIGER_SAFARI";
310
+ LION_SAFARI: "LION_SAFARI";
311
+ BIRD_WATCHING_SAFARI: "BIRD_WATCHING_SAFARI";
312
+ JUNGLE_SAFARI: "JUNGLE_SAFARI";
313
+ VILLAGE_SAFARI: "VILLAGE_SAFARI";
314
+ }>>;
315
+ }, z$1.core.$strip>;
316
+ type SafeCreateBooking = z$1.output<typeof createBooking>;
317
+
318
+ type safariBooking_SafeCreateBooking = SafeCreateBooking;
319
+ declare const safariBooking_createBooking: typeof createBooking;
320
+ declare const safariBooking_safariType: typeof safariType;
321
+ declare namespace safariBooking {
322
+ export { type safariBooking_SafeCreateBooking as SafeCreateBooking, safariBooking_createBooking as createBooking, safariBooking_safariType as safariType };
323
+ }
324
+
325
+ export { auth as Auth, location$2 as Location, resetPassword as ResetPassword, safari as Safari, safariBooking as SafariBooking, signup as Signup, user as User };
package/dist/index.js CHANGED
@@ -186,7 +186,7 @@ var pickupPoint = z6.object({
186
186
  var safariDetails = z6.object({
187
187
  id: z6.string(),
188
188
  safariCode: z6.string(),
189
- vehilces: z6.array(safariVehicle),
189
+ vehicles: z6.array(safariVehicle),
190
190
  slots: z6.array(safariSlot),
191
191
  rate: decimalish,
192
192
  discount: decimalish,
@@ -198,11 +198,39 @@ var safariDetails = z6.object({
198
198
  safariType: z6.array(z6.string()),
199
199
  description: z6.string().optional()
200
200
  });
201
+
202
+ // src/safariBooking.ts
203
+ var safariBooking_exports = {};
204
+ __export(safariBooking_exports, {
205
+ createBooking: () => createBooking,
206
+ safariType: () => safariType
207
+ });
208
+ import z7 from "zod";
209
+ var safariType = z7.enum([
210
+ "LEOPARD_SAFARI",
211
+ "TIGER_SAFARI",
212
+ "LION_SAFARI",
213
+ "BIRD_WATCHING_SAFARI",
214
+ "JUNGLE_SAFARI",
215
+ "VILLAGE_SAFARI"
216
+ ]);
217
+ var createBooking = z7.object({
218
+ safariId: z7.string().min(1),
219
+ slotId: z7.string().min(1),
220
+ bookingDate: z7.string().refine((s) => !Number.isNaN(Date.parse(s)), "invalid ISO date"),
221
+ numberOfAdults: z7.coerce.number().int().min(1),
222
+ numberOfKids: z7.coerce.number().int().min(0).default(0),
223
+ numberOfInfants: z7.coerce.number().int().min(0).default(0),
224
+ totalPrice: z7.coerce.number().int().min(0),
225
+ commission: z7.coerce.number().int().min(0),
226
+ safariType: safariType.default("LEOPARD_SAFARI")
227
+ });
201
228
  export {
202
229
  auth_exports as Auth,
203
230
  location_exports as Location,
204
231
  reset_password_exports as ResetPassword,
205
232
  safari_exports as Safari,
233
+ safariBooking_exports as SafariBooking,
206
234
  signup_exports as Signup,
207
235
  user_exports as User
208
236
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tripsam/main",
3
- "version": "2.0.11",
3
+ "version": "2.0.13",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",
@@ -32,4 +32,4 @@
32
32
  "publishConfig": {
33
33
  "access": "public"
34
34
  }
35
- }
35
+ }