@matchi/api 0.20250130.2 → 0.20250206.1

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.
@@ -1007,6 +1007,27 @@ type payment = {
1007
1007
  description: string;
1008
1008
  };
1009
1009
 
1010
+ type paymentMethodPaymentDetail = {
1011
+ name: string;
1012
+ amount: string;
1013
+ method: string;
1014
+ status: string;
1015
+ type: string;
1016
+ lastUpdated: timeStamp;
1017
+ };
1018
+
1019
+ type paymentMethodPaymentRefund = {
1020
+ amount: string;
1021
+ note: string;
1022
+ lastUpdated: timeStamp;
1023
+ };
1024
+
1025
+ type paymentMethodPromoCodeOutcome = {
1026
+ promoCode: string;
1027
+ discountAmount?: string;
1028
+ discountPercent?: string;
1029
+ };
1030
+
1010
1031
  type paymentDetails = {
1011
1032
  id: number;
1012
1033
  /**
@@ -1075,6 +1096,15 @@ type paymentDetails = {
1075
1096
  subscriptionId?: number;
1076
1097
  skipCheckout: boolean;
1077
1098
  orderSplitPayments?: OrderSplitPayments;
1099
+ standardFee?: string;
1100
+ standardAmountWithFee?: string;
1101
+ standardFeeVat?: string;
1102
+ feeVatValue?: string;
1103
+ minimumFee?: string;
1104
+ maximumFee?: string;
1105
+ refunds?: Array<paymentMethodPaymentRefund>;
1106
+ promoCodeOutcome?: paymentMethodPromoCodeOutcome;
1107
+ payments?: Array<paymentMethodPaymentDetail>;
1078
1108
  };
1079
1109
 
1080
1110
  type paymentInfo = {
@@ -2732,4 +2762,4 @@ declare class UserServiceV1Service {
2732
2762
  static listUserOfferValueCards(offset?: number, limit?: number): CancelablePromise<userOfferValueCardsResponse>;
2733
2763
  }
2734
2764
 
2735
- export { type ActivityEvent, ActivityServiceV1Service, type AdminOccasionDetails, AnonymousService, ApiClientServiceV1Service, ApiError, AuthorizedService, BookingServiceV1Service, CancelError, CancelablePromise, CheckoutServiceV1Service, CompetitionServiceV1Service, CorsService, type Error$1 as Error, type ExternalServiceProperty, LoyaltyServiceV1Service, MembershipServiceV1Service, type OccasionCourt, OpenAPI, type OpenAPIConfig, type OrderSplitPayments, type OrderSplitPaymentsRow, type OrderSplitPrice, PlaySessionServiceV1Service, UserServiceV1Service, access, type activitiesResponse, type activity, type activityOccasion, type activityType, type actor, type address, type adyenGiftCardOutcome, type apiClient, type apiClientInput, type apiClientListResponse, type article, type articleMetadata, type availability, type booking, type bookingGroup, bookingRestriction, type bookingRestrictions, bookingSubType, bookingSubscription, type bookingSubscriptionPayment, type bookingUser, bookingUserStatus, type bookingUsersResponse, type bookingsResponse, type camera, cancellationPolicy, chat, chatTarget, type checkoutResponse, clientType, type competitionAdminAccount, type config, type configuration, type configurationEntry, type configurationMap, type configurationResource, type coupon, type createBookingEventExternal, createChatResponse, type createPromoCode, type dailyQuota, type days, type deleteBookingEventExternal, directionParam, type endTimePriceDetail, type endTimesWithRestrictions, type exposeOccasions, type facilitiesResponse, type facility, type facilityConfiguration, type facilityDetails, type friendRelationResponse, type friendRelationsResponse, type getChatAuthResponse, type getChatResponse, type giftCard, type hideFullyBooked, type hours, type internalPaymentMethod, type levelRange, type limitParam, type listChatsResponse, type membershipRequest, type membershipRequestItem, type monthlyUsage, months, type occasionBooking, type occasionParticipant, type offsetParam, type openingHours, type order, type orderSplitBaseResponse, type participants, type payment, type paymentDetails, type paymentInfo, type paymentInterval, type paymentMethods, type paymentType, type paymentsResponse, pendingPayment, type playSession, type playSessionBooking, type playSessionBookingPayment, type playSessionResponse, playSessionSettings, playSessionUser, type playerLevels, playerStatusParam, playingUserResponse, type playingUsersResponse, type playsessionUserDetails, type position, type price, type priceDetails, type priceDetailsActivity, type profile, type promoCode, type promoCodeOutcome, type pspSession, type resource, type resultSet, type serviceFee, type timeOfDay, type timeStamp, type usagePlan, userChatStatusParam, type userFacility, type userId, type userInfo, type userMembership, type userOfferPunchCardsResponse, type userOfferValueCardsResponse, type userPublicProfile, userPunchCard, type userValueCard, type valueCardOutcome };
2765
+ export { type ActivityEvent, ActivityServiceV1Service, type AdminOccasionDetails, AnonymousService, ApiClientServiceV1Service, ApiError, AuthorizedService, BookingServiceV1Service, CancelError, CancelablePromise, CheckoutServiceV1Service, CompetitionServiceV1Service, CorsService, type Error$1 as Error, type ExternalServiceProperty, LoyaltyServiceV1Service, MembershipServiceV1Service, type OccasionCourt, OpenAPI, type OpenAPIConfig, type OrderSplitPayments, type OrderSplitPaymentsRow, type OrderSplitPrice, PlaySessionServiceV1Service, UserServiceV1Service, access, type activitiesResponse, type activity, type activityOccasion, type activityType, type actor, type address, type adyenGiftCardOutcome, type apiClient, type apiClientInput, type apiClientListResponse, type article, type articleMetadata, type availability, type booking, type bookingGroup, bookingRestriction, type bookingRestrictions, bookingSubType, bookingSubscription, type bookingSubscriptionPayment, type bookingUser, bookingUserStatus, type bookingUsersResponse, type bookingsResponse, type camera, cancellationPolicy, chat, chatTarget, type checkoutResponse, clientType, type competitionAdminAccount, type config, type configuration, type configurationEntry, type configurationMap, type configurationResource, type coupon, type createBookingEventExternal, createChatResponse, type createPromoCode, type dailyQuota, type days, type deleteBookingEventExternal, directionParam, type endTimePriceDetail, type endTimesWithRestrictions, type exposeOccasions, type facilitiesResponse, type facility, type facilityConfiguration, type facilityDetails, type friendRelationResponse, type friendRelationsResponse, type getChatAuthResponse, type getChatResponse, type giftCard, type hideFullyBooked, type hours, type internalPaymentMethod, type levelRange, type limitParam, type listChatsResponse, type membershipRequest, type membershipRequestItem, type monthlyUsage, months, type occasionBooking, type occasionParticipant, type offsetParam, type openingHours, type order, type orderSplitBaseResponse, type participants, type payment, type paymentDetails, type paymentInfo, type paymentInterval, type paymentMethodPaymentDetail, type paymentMethodPaymentRefund, type paymentMethodPromoCodeOutcome, type paymentMethods, type paymentType, type paymentsResponse, pendingPayment, type playSession, type playSessionBooking, type playSessionBookingPayment, type playSessionResponse, playSessionSettings, playSessionUser, type playerLevels, playerStatusParam, playingUserResponse, type playingUsersResponse, type playsessionUserDetails, type position, type price, type priceDetails, type priceDetailsActivity, type profile, type promoCode, type promoCodeOutcome, type pspSession, type resource, type resultSet, type serviceFee, type timeOfDay, type timeStamp, type usagePlan, userChatStatusParam, type userFacility, type userId, type userInfo, type userMembership, type userOfferPunchCardsResponse, type userOfferValueCardsResponse, type userPublicProfile, userPunchCard, type userValueCard, type valueCardOutcome };
@@ -1007,6 +1007,27 @@ type payment = {
1007
1007
  description: string;
1008
1008
  };
1009
1009
 
1010
+ type paymentMethodPaymentDetail = {
1011
+ name: string;
1012
+ amount: string;
1013
+ method: string;
1014
+ status: string;
1015
+ type: string;
1016
+ lastUpdated: timeStamp;
1017
+ };
1018
+
1019
+ type paymentMethodPaymentRefund = {
1020
+ amount: string;
1021
+ note: string;
1022
+ lastUpdated: timeStamp;
1023
+ };
1024
+
1025
+ type paymentMethodPromoCodeOutcome = {
1026
+ promoCode: string;
1027
+ discountAmount?: string;
1028
+ discountPercent?: string;
1029
+ };
1030
+
1010
1031
  type paymentDetails = {
1011
1032
  id: number;
1012
1033
  /**
@@ -1075,6 +1096,15 @@ type paymentDetails = {
1075
1096
  subscriptionId?: number;
1076
1097
  skipCheckout: boolean;
1077
1098
  orderSplitPayments?: OrderSplitPayments;
1099
+ standardFee?: string;
1100
+ standardAmountWithFee?: string;
1101
+ standardFeeVat?: string;
1102
+ feeVatValue?: string;
1103
+ minimumFee?: string;
1104
+ maximumFee?: string;
1105
+ refunds?: Array<paymentMethodPaymentRefund>;
1106
+ promoCodeOutcome?: paymentMethodPromoCodeOutcome;
1107
+ payments?: Array<paymentMethodPaymentDetail>;
1078
1108
  };
1079
1109
 
1080
1110
  type paymentInfo = {
@@ -2732,4 +2762,4 @@ declare class UserServiceV1Service {
2732
2762
  static listUserOfferValueCards(offset?: number, limit?: number): CancelablePromise<userOfferValueCardsResponse>;
2733
2763
  }
2734
2764
 
2735
- export { type ActivityEvent, ActivityServiceV1Service, type AdminOccasionDetails, AnonymousService, ApiClientServiceV1Service, ApiError, AuthorizedService, BookingServiceV1Service, CancelError, CancelablePromise, CheckoutServiceV1Service, CompetitionServiceV1Service, CorsService, type Error$1 as Error, type ExternalServiceProperty, LoyaltyServiceV1Service, MembershipServiceV1Service, type OccasionCourt, OpenAPI, type OpenAPIConfig, type OrderSplitPayments, type OrderSplitPaymentsRow, type OrderSplitPrice, PlaySessionServiceV1Service, UserServiceV1Service, access, type activitiesResponse, type activity, type activityOccasion, type activityType, type actor, type address, type adyenGiftCardOutcome, type apiClient, type apiClientInput, type apiClientListResponse, type article, type articleMetadata, type availability, type booking, type bookingGroup, bookingRestriction, type bookingRestrictions, bookingSubType, bookingSubscription, type bookingSubscriptionPayment, type bookingUser, bookingUserStatus, type bookingUsersResponse, type bookingsResponse, type camera, cancellationPolicy, chat, chatTarget, type checkoutResponse, clientType, type competitionAdminAccount, type config, type configuration, type configurationEntry, type configurationMap, type configurationResource, type coupon, type createBookingEventExternal, createChatResponse, type createPromoCode, type dailyQuota, type days, type deleteBookingEventExternal, directionParam, type endTimePriceDetail, type endTimesWithRestrictions, type exposeOccasions, type facilitiesResponse, type facility, type facilityConfiguration, type facilityDetails, type friendRelationResponse, type friendRelationsResponse, type getChatAuthResponse, type getChatResponse, type giftCard, type hideFullyBooked, type hours, type internalPaymentMethod, type levelRange, type limitParam, type listChatsResponse, type membershipRequest, type membershipRequestItem, type monthlyUsage, months, type occasionBooking, type occasionParticipant, type offsetParam, type openingHours, type order, type orderSplitBaseResponse, type participants, type payment, type paymentDetails, type paymentInfo, type paymentInterval, type paymentMethods, type paymentType, type paymentsResponse, pendingPayment, type playSession, type playSessionBooking, type playSessionBookingPayment, type playSessionResponse, playSessionSettings, playSessionUser, type playerLevels, playerStatusParam, playingUserResponse, type playingUsersResponse, type playsessionUserDetails, type position, type price, type priceDetails, type priceDetailsActivity, type profile, type promoCode, type promoCodeOutcome, type pspSession, type resource, type resultSet, type serviceFee, type timeOfDay, type timeStamp, type usagePlan, userChatStatusParam, type userFacility, type userId, type userInfo, type userMembership, type userOfferPunchCardsResponse, type userOfferValueCardsResponse, type userPublicProfile, userPunchCard, type userValueCard, type valueCardOutcome };
2765
+ export { type ActivityEvent, ActivityServiceV1Service, type AdminOccasionDetails, AnonymousService, ApiClientServiceV1Service, ApiError, AuthorizedService, BookingServiceV1Service, CancelError, CancelablePromise, CheckoutServiceV1Service, CompetitionServiceV1Service, CorsService, type Error$1 as Error, type ExternalServiceProperty, LoyaltyServiceV1Service, MembershipServiceV1Service, type OccasionCourt, OpenAPI, type OpenAPIConfig, type OrderSplitPayments, type OrderSplitPaymentsRow, type OrderSplitPrice, PlaySessionServiceV1Service, UserServiceV1Service, access, type activitiesResponse, type activity, type activityOccasion, type activityType, type actor, type address, type adyenGiftCardOutcome, type apiClient, type apiClientInput, type apiClientListResponse, type article, type articleMetadata, type availability, type booking, type bookingGroup, bookingRestriction, type bookingRestrictions, bookingSubType, bookingSubscription, type bookingSubscriptionPayment, type bookingUser, bookingUserStatus, type bookingUsersResponse, type bookingsResponse, type camera, cancellationPolicy, chat, chatTarget, type checkoutResponse, clientType, type competitionAdminAccount, type config, type configuration, type configurationEntry, type configurationMap, type configurationResource, type coupon, type createBookingEventExternal, createChatResponse, type createPromoCode, type dailyQuota, type days, type deleteBookingEventExternal, directionParam, type endTimePriceDetail, type endTimesWithRestrictions, type exposeOccasions, type facilitiesResponse, type facility, type facilityConfiguration, type facilityDetails, type friendRelationResponse, type friendRelationsResponse, type getChatAuthResponse, type getChatResponse, type giftCard, type hideFullyBooked, type hours, type internalPaymentMethod, type levelRange, type limitParam, type listChatsResponse, type membershipRequest, type membershipRequestItem, type monthlyUsage, months, type occasionBooking, type occasionParticipant, type offsetParam, type openingHours, type order, type orderSplitBaseResponse, type participants, type payment, type paymentDetails, type paymentInfo, type paymentInterval, type paymentMethodPaymentDetail, type paymentMethodPaymentRefund, type paymentMethodPromoCodeOutcome, type paymentMethods, type paymentType, type paymentsResponse, pendingPayment, type playSession, type playSessionBooking, type playSessionBookingPayment, type playSessionResponse, playSessionSettings, playSessionUser, type playerLevels, playerStatusParam, playingUserResponse, type playingUsersResponse, type playsessionUserDetails, type position, type price, type priceDetails, type priceDetailsActivity, type profile, type promoCode, type promoCodeOutcome, type pspSession, type resource, type resultSet, type serviceFee, type timeOfDay, type timeStamp, type usagePlan, userChatStatusParam, type userFacility, type userId, type userInfo, type userMembership, type userOfferPunchCardsResponse, type userOfferValueCardsResponse, type userPublicProfile, userPunchCard, type userValueCard, type valueCardOutcome };
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_query_core_build_legacy_hydration_ClXcjjG9 from '@tanstack/query-core/build/legacy/hydration-ClXcjjG9';
2
2
  import * as _tanstack_react_query_build_legacy_types from '@tanstack/react-query/build/legacy/types';
3
- import { FindBookingsData, Booking, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedProblemDetails, AddBookingData, DeleteBookingData, FindBookingByIdData, UpdateBookingData } from '../types.gen.mjs';
3
+ import { FindBookingsData, Booking, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedProblemDetails, AddBookingData, DeleteBookingData, FindBookingByIdData, UpdateBookingData, ListFacilityOffersData, FacilityOfferList, CreateFacilityOfferOrderData, FacilityOfferOrder } from '../types.gen.mjs';
4
4
  import { Options } from '@hey-api/client-fetch';
5
5
  import { InfiniteData, UseMutationOptions } from '@tanstack/react-query';
6
6
 
@@ -124,5 +124,66 @@ declare const findBookingByIdOptions: (options: Options<FindBookingByIdData>) =>
124
124
  };
125
125
  };
126
126
  declare const updateBookingMutation: (options?: Partial<Options<UpdateBookingData>>) => UseMutationOptions<Booking, PkgOpenapiSharedProblemDetails, Options<UpdateBookingData>, unknown>;
127
+ declare const listFacilityOffersQueryKey: (options: Options<ListFacilityOffersData>) => (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
128
+ _id: string;
129
+ _infinite?: boolean | undefined;
130
+ })[];
131
+ declare const listFacilityOffersOptions: (options: Options<ListFacilityOffersData>) => _tanstack_query_core_build_legacy_hydration_ClXcjjG9.O<_tanstack_react_query_build_legacy_types.UseQueryOptions<FacilityOfferList, Error, FacilityOfferList, (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
132
+ _id: string;
133
+ _infinite?: boolean | undefined;
134
+ })[]>, "queryFn"> & {
135
+ queryFn?: _tanstack_query_core_build_legacy_hydration_ClXcjjG9.K<FacilityOfferList, (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
136
+ _id: string;
137
+ _infinite?: boolean | undefined;
138
+ })[], never> | undefined;
139
+ } & {
140
+ queryKey: (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
141
+ _id: string;
142
+ _infinite?: boolean | undefined;
143
+ })[] & {
144
+ [dataTagSymbol]: FacilityOfferList;
145
+ [dataTagErrorSymbol]: Error;
146
+ };
147
+ };
148
+ declare const listFacilityOffersInfiniteQueryKey: (options: Options<ListFacilityOffersData>) => QueryKey<Options<ListFacilityOffersData>>;
149
+ declare const listFacilityOffersInfiniteOptions: (options: Options<ListFacilityOffersData>) => _tanstack_react_query_build_legacy_types.UseInfiniteQueryOptions<FacilityOfferList, PkgOpenapiSharedProblemDetails, InfiniteData<FacilityOfferList, unknown>, FacilityOfferList, QueryKey<Options<ListFacilityOffersData>>, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
150
+ _id: string;
151
+ _infinite?: boolean | undefined;
152
+ }, "body" | "path" | "query" | "headers">> & {
153
+ initialData: InfiniteData<FacilityOfferList, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
154
+ _id: string;
155
+ _infinite?: boolean | undefined;
156
+ }, "body" | "path" | "query" | "headers">> | (() => InfiniteData<FacilityOfferList, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
157
+ _id: string;
158
+ _infinite?: boolean | undefined;
159
+ }, "body" | "path" | "query" | "headers">>) | undefined;
160
+ } & {
161
+ queryKey: QueryKey<Options<ListFacilityOffersData>> & {
162
+ [dataTagSymbol]: InfiniteData<FacilityOfferList, unknown>;
163
+ [dataTagErrorSymbol]: PkgOpenapiSharedProblemDetails;
164
+ };
165
+ };
166
+ declare const createFacilityOfferOrderQueryKey: (options: Options<CreateFacilityOfferOrderData>) => (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
167
+ _id: string;
168
+ _infinite?: boolean | undefined;
169
+ })[];
170
+ declare const createFacilityOfferOrderOptions: (options: Options<CreateFacilityOfferOrderData>) => _tanstack_query_core_build_legacy_hydration_ClXcjjG9.O<_tanstack_react_query_build_legacy_types.UseQueryOptions<FacilityOfferOrder, Error, FacilityOfferOrder, (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
171
+ _id: string;
172
+ _infinite?: boolean | undefined;
173
+ })[]>, "queryFn"> & {
174
+ queryFn?: _tanstack_query_core_build_legacy_hydration_ClXcjjG9.K<FacilityOfferOrder, (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
175
+ _id: string;
176
+ _infinite?: boolean | undefined;
177
+ })[], never> | undefined;
178
+ } & {
179
+ queryKey: (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
180
+ _id: string;
181
+ _infinite?: boolean | undefined;
182
+ })[] & {
183
+ [dataTagSymbol]: FacilityOfferOrder;
184
+ [dataTagErrorSymbol]: Error;
185
+ };
186
+ };
187
+ declare const createFacilityOfferOrderMutation: (options?: Partial<Options<CreateFacilityOfferOrderData>>) => UseMutationOptions<FacilityOfferOrder, PkgOpenapiSharedProblemDetails, Options<CreateFacilityOfferOrderData>, unknown>;
127
188
 
128
- export { addBookingMutation, addBookingOptions, addBookingQueryKey, deleteBookingMutation, findBookingByIdOptions, findBookingByIdQueryKey, findBookingsInfiniteOptions, findBookingsInfiniteQueryKey, findBookingsOptions, findBookingsQueryKey, updateBookingMutation };
189
+ export { addBookingMutation, addBookingOptions, addBookingQueryKey, createFacilityOfferOrderMutation, createFacilityOfferOrderOptions, createFacilityOfferOrderQueryKey, deleteBookingMutation, findBookingByIdOptions, findBookingByIdQueryKey, findBookingsInfiniteOptions, findBookingsInfiniteQueryKey, findBookingsOptions, findBookingsQueryKey, listFacilityOffersInfiniteOptions, listFacilityOffersInfiniteQueryKey, listFacilityOffersOptions, listFacilityOffersQueryKey, updateBookingMutation };
@@ -1,6 +1,6 @@
1
1
  import * as _tanstack_query_core_build_legacy_hydration_ClXcjjG9 from '@tanstack/query-core/build/legacy/hydration-ClXcjjG9';
2
2
  import * as _tanstack_react_query_build_legacy_types from '@tanstack/react-query/build/legacy/types';
3
- import { FindBookingsData, Booking, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedProblemDetails, AddBookingData, DeleteBookingData, FindBookingByIdData, UpdateBookingData } from '../types.gen.js';
3
+ import { FindBookingsData, Booking, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedProblemDetails, AddBookingData, DeleteBookingData, FindBookingByIdData, UpdateBookingData, ListFacilityOffersData, FacilityOfferList, CreateFacilityOfferOrderData, FacilityOfferOrder } from '../types.gen.js';
4
4
  import { Options } from '@hey-api/client-fetch';
5
5
  import { InfiniteData, UseMutationOptions } from '@tanstack/react-query';
6
6
 
@@ -124,5 +124,66 @@ declare const findBookingByIdOptions: (options: Options<FindBookingByIdData>) =>
124
124
  };
125
125
  };
126
126
  declare const updateBookingMutation: (options?: Partial<Options<UpdateBookingData>>) => UseMutationOptions<Booking, PkgOpenapiSharedProblemDetails, Options<UpdateBookingData>, unknown>;
127
+ declare const listFacilityOffersQueryKey: (options: Options<ListFacilityOffersData>) => (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
128
+ _id: string;
129
+ _infinite?: boolean | undefined;
130
+ })[];
131
+ declare const listFacilityOffersOptions: (options: Options<ListFacilityOffersData>) => _tanstack_query_core_build_legacy_hydration_ClXcjjG9.O<_tanstack_react_query_build_legacy_types.UseQueryOptions<FacilityOfferList, Error, FacilityOfferList, (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
132
+ _id: string;
133
+ _infinite?: boolean | undefined;
134
+ })[]>, "queryFn"> & {
135
+ queryFn?: _tanstack_query_core_build_legacy_hydration_ClXcjjG9.K<FacilityOfferList, (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
136
+ _id: string;
137
+ _infinite?: boolean | undefined;
138
+ })[], never> | undefined;
139
+ } & {
140
+ queryKey: (Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
141
+ _id: string;
142
+ _infinite?: boolean | undefined;
143
+ })[] & {
144
+ [dataTagSymbol]: FacilityOfferList;
145
+ [dataTagErrorSymbol]: Error;
146
+ };
147
+ };
148
+ declare const listFacilityOffersInfiniteQueryKey: (options: Options<ListFacilityOffersData>) => QueryKey<Options<ListFacilityOffersData>>;
149
+ declare const listFacilityOffersInfiniteOptions: (options: Options<ListFacilityOffersData>) => _tanstack_react_query_build_legacy_types.UseInfiniteQueryOptions<FacilityOfferList, PkgOpenapiSharedProblemDetails, InfiniteData<FacilityOfferList, unknown>, FacilityOfferList, QueryKey<Options<ListFacilityOffersData>>, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
150
+ _id: string;
151
+ _infinite?: boolean | undefined;
152
+ }, "body" | "path" | "query" | "headers">> & {
153
+ initialData: InfiniteData<FacilityOfferList, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
154
+ _id: string;
155
+ _infinite?: boolean | undefined;
156
+ }, "body" | "path" | "query" | "headers">> | (() => InfiniteData<FacilityOfferList, string | Pick<Pick<Options<ListFacilityOffersData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
157
+ _id: string;
158
+ _infinite?: boolean | undefined;
159
+ }, "body" | "path" | "query" | "headers">>) | undefined;
160
+ } & {
161
+ queryKey: QueryKey<Options<ListFacilityOffersData>> & {
162
+ [dataTagSymbol]: InfiniteData<FacilityOfferList, unknown>;
163
+ [dataTagErrorSymbol]: PkgOpenapiSharedProblemDetails;
164
+ };
165
+ };
166
+ declare const createFacilityOfferOrderQueryKey: (options: Options<CreateFacilityOfferOrderData>) => (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
167
+ _id: string;
168
+ _infinite?: boolean | undefined;
169
+ })[];
170
+ declare const createFacilityOfferOrderOptions: (options: Options<CreateFacilityOfferOrderData>) => _tanstack_query_core_build_legacy_hydration_ClXcjjG9.O<_tanstack_react_query_build_legacy_types.UseQueryOptions<FacilityOfferOrder, Error, FacilityOfferOrder, (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
171
+ _id: string;
172
+ _infinite?: boolean | undefined;
173
+ })[]>, "queryFn"> & {
174
+ queryFn?: _tanstack_query_core_build_legacy_hydration_ClXcjjG9.K<FacilityOfferOrder, (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
175
+ _id: string;
176
+ _infinite?: boolean | undefined;
177
+ })[], never> | undefined;
178
+ } & {
179
+ queryKey: (Pick<Options<CreateFacilityOfferOrderData>, "body" | "path" | "query" | "headers" | "baseUrl"> & {
180
+ _id: string;
181
+ _infinite?: boolean | undefined;
182
+ })[] & {
183
+ [dataTagSymbol]: FacilityOfferOrder;
184
+ [dataTagErrorSymbol]: Error;
185
+ };
186
+ };
187
+ declare const createFacilityOfferOrderMutation: (options?: Partial<Options<CreateFacilityOfferOrderData>>) => UseMutationOptions<FacilityOfferOrder, PkgOpenapiSharedProblemDetails, Options<CreateFacilityOfferOrderData>, unknown>;
127
188
 
128
- export { addBookingMutation, addBookingOptions, addBookingQueryKey, deleteBookingMutation, findBookingByIdOptions, findBookingByIdQueryKey, findBookingsInfiniteOptions, findBookingsInfiniteQueryKey, findBookingsOptions, findBookingsQueryKey, updateBookingMutation };
189
+ export { addBookingMutation, addBookingOptions, addBookingQueryKey, createFacilityOfferOrderMutation, createFacilityOfferOrderOptions, createFacilityOfferOrderQueryKey, deleteBookingMutation, findBookingByIdOptions, findBookingByIdQueryKey, findBookingsInfiniteOptions, findBookingsInfiniteQueryKey, findBookingsOptions, findBookingsQueryKey, listFacilityOffersInfiniteOptions, listFacilityOffersInfiniteQueryKey, listFacilityOffersOptions, listFacilityOffersQueryKey, updateBookingMutation };
@@ -1 +1 @@
1
- "use strict";var b=Object.defineProperty;var K=Object.getOwnPropertyDescriptor;var Q=Object.getOwnPropertyNames;var P=Object.prototype.hasOwnProperty;var W=(e,t)=>{for(var r in t)b(e,r,{get:t[r],enumerable:!0})},N=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Q(t))!P.call(e,i)&&i!==r&&b(e,i,{get:()=>t[i],enumerable:!(n=K(t,i))||n.enumerable});return e};var M=e=>N(b({},"__esModule",{value:!0}),e);var ce={};W(ce,{addBookingMutation:()=>le,addBookingOptions:()=>de,addBookingQueryKey:()=>$,deleteBookingMutation:()=>ue,findBookingByIdOptions:()=>pe,findBookingByIdQueryKey:()=>_,findBookingsInfiniteOptions:()=>se,findBookingsInfiniteQueryKey:()=>C,findBookingsOptions:()=>ae,findBookingsQueryKey:()=>v,updateBookingMutation:()=>ye});module.exports=M(ce);var H=/\{[^{}]+\}/g,k=({allowReserved:e,name:t,value:r})=>{if(r==null)return"";if(typeof r=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${t}=${e?r:encodeURIComponent(r)}`},J=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},L=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},V=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},R=({allowReserved:e,explode:t,name:r,style:n,value:i})=>{if(!t){let a=(e?i:i.map(d=>encodeURIComponent(d))).join(L(n));switch(n){case"label":return`.${a}`;case"matrix":return`;${r}=${a}`;case"simple":return a;default:return`${r}=${a}`}}let s=J(n),o=i.map(a=>n==="label"||n==="simple"?e?a:encodeURIComponent(a):k({allowReserved:e,name:r,value:a})).join(s);return n==="label"||n==="matrix"?s+o:o},q=({allowReserved:e,explode:t,name:r,style:n,value:i})=>{if(i instanceof Date)return`${r}=${i.toISOString()}`;if(n!=="deepObject"&&!t){let a=[];Object.entries(i).forEach(([c,u])=>{a=[...a,c,e?u:encodeURIComponent(u)]});let d=a.join(",");switch(n){case"form":return`${r}=${d}`;case"label":return`.${d}`;case"matrix":return`;${r}=${d}`;default:return d}}let s=V(n),o=Object.entries(i).map(([a,d])=>k({allowReserved:e,name:n==="deepObject"?`${r}[${a}]`:a,value:d})).join(s);return n==="label"||n==="matrix"?s+o:o},G=({path:e,url:t})=>{let r=t,n=t.match(H);if(n)for(let i of n){let s=!1,o=i.substring(1,i.length-1),a="simple";o.endsWith("*")&&(s=!0,o=o.substring(0,o.length-1)),o.startsWith(".")?(o=o.substring(1),a="label"):o.startsWith(";")&&(o=o.substring(1),a="matrix");let d=e[o];if(d==null)continue;if(Array.isArray(d)){r=r.replace(i,R({explode:s,name:o,style:a,value:d}));continue}if(typeof d=="object"){r=r.replace(i,q({explode:s,name:o,style:a,value:d}));continue}if(a==="matrix"){r=r.replace(i,`;${k({name:o,value:d})}`);continue}let c=encodeURIComponent(a==="label"?`.${d}`:d);r=r.replace(i,c)}return r},F=({allowReserved:e,array:t,object:r}={})=>n=>{let i=[];if(n&&typeof n=="object")for(let s in n){let o=n[s];if(o!=null){if(Array.isArray(o)){i=[...i,R({allowReserved:e,explode:!0,name:s,style:"form",value:o,...t})];continue}if(typeof o=="object"){i=[...i,q({allowReserved:e,explode:!0,name:s,style:"deepObject",value:o,...r})];continue}i=[...i,k({allowReserved:e,name:s,value:o})]}}return i.join("&")},X=e=>{if(!e)return"stream";let t=e.split(";")[0]?.trim();if(t){if(t.startsWith("application/json")||t.endsWith("+json"))return"json";if(t==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(r=>t.startsWith(r)))return"blob";if(t.startsWith("text/"))return"text"}},Y=async(e,t)=>{let r=typeof t=="function"?await t(e):t;if(r)return e.scheme==="bearer"?`Bearer ${r}`:e.scheme==="basic"?`Basic ${btoa(r)}`:r},Z=async({security:e,...t})=>{for(let r of e){let n=await Y(r,t.auth);if(!n)continue;let i=r.name??"Authorization";switch(r.in){case"query":t.query||(t.query={}),t.query[i]=n;break;case"header":default:t.headers.set(i,n);break}return}},x=e=>ee({baseUrl:e.baseUrl??"",path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:F(e.querySerializer),url:e.url}),ee=({baseUrl:e,path:t,query:r,querySerializer:n,url:i})=>{let s=i.startsWith("/")?i:`/${i}`,o=e+s;t&&(o=G({path:t,url:o}));let a=r?n(r):"";return a.startsWith("?")&&(a=a.substring(1)),a&&(o+=`?${a}`),o},T=(e,t)=>{let r={...e,...t};return r.baseUrl?.endsWith("/")&&(r.baseUrl=r.baseUrl.substring(0,r.baseUrl.length-1)),r.headers=U(e.headers,t.headers),r},U=(...e)=>{let t=new Headers;for(let r of e){if(!r||typeof r!="object")continue;let n=r instanceof Headers?r.entries():Object.entries(r);for(let[i,s]of n)if(s===null)t.delete(i);else if(Array.isArray(s))for(let o of s)t.append(i,o);else s!==void 0&&t.set(i,typeof s=="object"?JSON.stringify(s):s)}return t},m=class{_fns;constructor(){this._fns=[]}clear(){this._fns=[]}exists(e){return this._fns.indexOf(e)!==-1}eject(e){let t=this._fns.indexOf(e);t!==-1&&(this._fns=[...this._fns.slice(0,t),...this._fns.slice(t+1)])}use(e){this._fns=[...this._fns,e]}},te=()=>({error:new m,request:new m,response:new m});var re={bodySerializer:e=>JSON.stringify(e)};var oe=F({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),ne={"Content-Type":"application/json"},w=(e={})=>({...re,baseUrl:"",headers:ne,parseAs:"auto",querySerializer:oe,...e}),j=(e={})=>{let t=T(w(),e),r=()=>({...t}),n=o=>(t=T(t,o),r()),i=te(),s=async o=>{let a={...t,...o,fetch:o.fetch??t.fetch??globalThis.fetch,headers:U(t.headers,o.headers)};a.security&&await Z({...a,security:a.security}),a.body&&a.bodySerializer&&(a.body=a.bodySerializer(a.body)),a.body||a.headers.delete("Content-Type");let d=x(a),c={redirect:"follow",...a},u=new Request(d,c);for(let p of i.request._fns)u=await p(u,a);let z=a.fetch,l=await z(u);for(let p of i.response._fns)l=await p(l,u,a);let g={request:u,response:l};if(l.ok){if(l.status===204||l.headers.get("Content-Length")==="0")return{data:{},...g};let p=(a.parseAs==="auto"?X(l.headers.get("Content-Type")):a.parseAs)??"json";if(p==="stream")return{data:l.body,...g};let B=await l[p]();return p==="json"&&(a.responseValidator&&await a.responseValidator(B),a.responseTransformer&&(B=await a.responseTransformer(B))),{data:B,...g}}let h=await l.text();try{h=JSON.parse(h)}catch{}let f=h;for(let p of i.error._fns)f=await p(h,l,u,a);if(f=f||{},a.throwOnError)throw f;return{error:f,...g}};return{buildUrl:x,connect:o=>s({...o,method:"CONNECT"}),delete:o=>s({...o,method:"DELETE"}),get:o=>s({...o,method:"GET"}),getConfig:r,head:o=>s({...o,method:"HEAD"}),interceptors:i,options:o=>s({...o,method:"OPTIONS"}),patch:o=>s({...o,method:"PATCH"}),post:o=>s({...o,method:"POST"}),put:o=>s({...o,method:"PUT"}),request:s,setConfig:n,trace:o=>s({...o,method:"TRACE"})}};var y=j(w()),D=e=>(e?.client??y).get({...e,url:"/bookings"}),E=e=>(e?.client??y).post({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings"}),A=e=>(e?.client??y).delete({...e,url:"/bookings/{bookingId}"}),I=e=>(e?.client??y).get({...e,url:"/bookings/{bookingId}"}),S=e=>(e?.client??y).put({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings/{bookingId}"});var O=(e,t,r)=>{let n={_id:e,baseUrl:(t?.client??y).getConfig().baseUrl};return r&&(n._infinite=r),t?.body&&(n.body=t.body),t?.headers&&(n.headers=t.headers),t?.path&&(n.path=t.path),t?.query&&(n.query=t.query),n},v=e=>[O("findBookings",e)],ae=e=>({queryFn:async({queryKey:t,signal:r})=>{let{data:n}=await D({...e,...t[0],signal:r,throwOnError:!0});return n},queryKey:v(e)}),ie=(e,t)=>{let r=e[0];return t.body&&(r.body={...e[0].body,...t.body}),t.headers&&(r.headers={...e[0].headers,...t.headers}),t.path&&(r.path={...e[0].path,...t.path}),t.query&&(r.query={...e[0].query,...t.query}),r},C=e=>[O("findBookings",e,!0)],se=e=>({queryFn:async({pageParam:t,queryKey:r,signal:n})=>{let s=ie(r,typeof t=="object"?t:{query:{offset:t}}),{data:o}=await D({...e,...s,signal:n,throwOnError:!0});return o},queryKey:C(e)}),$=e=>[O("addBooking",e)],de=e=>({queryFn:async({queryKey:t,signal:r})=>{let{data:n}=await E({...e,...t[0],signal:r,throwOnError:!0});return n},queryKey:$(e)}),le=e=>({mutationFn:async r=>{let{data:n}=await E({...e,...r,throwOnError:!0});return n}}),ue=e=>({mutationFn:async r=>{let{data:n}=await A({...e,...r,throwOnError:!0});return n}}),_=e=>[O("findBookingById",e)],pe=e=>({queryFn:async({queryKey:t,signal:r})=>{let{data:n}=await I({...e,...t[0],signal:r,throwOnError:!0});return n},queryKey:_(e)}),ye=e=>({mutationFn:async r=>{let{data:n}=await S({...e,...r,throwOnError:!0});return n}});0&&(module.exports={addBookingMutation,addBookingOptions,addBookingQueryKey,deleteBookingMutation,findBookingByIdOptions,findBookingByIdQueryKey,findBookingsInfiniteOptions,findBookingsInfiniteQueryKey,findBookingsOptions,findBookingsQueryKey,updateBookingMutation});
1
+ "use strict";var b=Object.defineProperty;var N=Object.getOwnPropertyDescriptor;var H=Object.getOwnPropertyNames;var J=Object.prototype.hasOwnProperty;var V=(e,r)=>{for(var t in r)b(e,t,{get:r[t],enumerable:!0})},G=(e,r,t,o)=>{if(r&&typeof r=="object"||typeof r=="function")for(let a of H(r))!J.call(e,a)&&a!==t&&b(e,a,{get:()=>r[a],enumerable:!(o=N(r,a))||o.enumerable});return e};var X=e=>G(b({},"__esModule",{value:!0}),e);var Fe={};V(Fe,{addBookingMutation:()=>pe,addBookingOptions:()=>ce,addBookingQueryKey:()=>$,createFacilityOfferOrderMutation:()=>me,createFacilityOfferOrderOptions:()=>be,createFacilityOfferOrderQueryKey:()=>W,deleteBookingMutation:()=>Oe,findBookingByIdOptions:()=>he,findBookingByIdQueryKey:()=>_,findBookingsInfiniteOptions:()=>ye,findBookingsInfiniteQueryKey:()=>L,findBookingsOptions:()=>ue,findBookingsQueryKey:()=>v,listFacilityOffersInfiniteOptions:()=>ke,listFacilityOffersInfiniteQueryKey:()=>P,listFacilityOffersOptions:()=>Be,listFacilityOffersQueryKey:()=>z,updateBookingMutation:()=>ge});module.exports=X(Fe);var Y=/\{[^{}]+\}/g,k=({allowReserved:e,name:r,value:t})=>{if(t==null)return"";if(typeof t=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${r}=${e?t:encodeURIComponent(t)}`},Z=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},ee=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},re=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},T=({allowReserved:e,explode:r,name:t,style:o,value:a})=>{if(!r){let i=(e?a:a.map(l=>encodeURIComponent(l))).join(ee(o));switch(o){case"label":return`.${i}`;case"matrix":return`;${t}=${i}`;case"simple":return i;default:return`${t}=${i}`}}let s=Z(o),n=a.map(i=>o==="label"||o==="simple"?e?i:encodeURIComponent(i):k({allowReserved:e,name:t,value:i})).join(s);return o==="label"||o==="matrix"?s+n:n},C=({allowReserved:e,explode:r,name:t,style:o,value:a})=>{if(a instanceof Date)return`${t}=${a.toISOString()}`;if(o!=="deepObject"&&!r){let i=[];Object.entries(a).forEach(([p,f])=>{i=[...i,p,e?f:encodeURIComponent(f)]});let l=i.join(",");switch(o){case"form":return`${t}=${l}`;case"label":return`.${l}`;case"matrix":return`;${t}=${l}`;default:return l}}let s=re(o),n=Object.entries(a).map(([i,l])=>k({allowReserved:e,name:o==="deepObject"?`${t}[${i}]`:i,value:l})).join(s);return o==="label"||o==="matrix"?s+n:n},te=({path:e,url:r})=>{let t=r,o=r.match(Y);if(o)for(let a of o){let s=!1,n=a.substring(1,a.length-1),i="simple";n.endsWith("*")&&(s=!0,n=n.substring(0,n.length-1)),n.startsWith(".")?(n=n.substring(1),i="label"):n.startsWith(";")&&(n=n.substring(1),i="matrix");let l=e[n];if(l==null)continue;if(Array.isArray(l)){t=t.replace(a,T({explode:s,name:n,style:i,value:l}));continue}if(typeof l=="object"){t=t.replace(a,C({explode:s,name:n,style:i,value:l}));continue}if(i==="matrix"){t=t.replace(a,`;${k({name:n,value:l})}`);continue}let p=encodeURIComponent(i==="label"?`.${l}`:l);t=t.replace(a,p)}return t},U=({allowReserved:e,array:r,object:t}={})=>o=>{let a=[];if(o&&typeof o=="object")for(let s in o){let n=o[s];if(n!=null){if(Array.isArray(n)){a=[...a,T({allowReserved:e,explode:!0,name:s,style:"form",value:n,...r})];continue}if(typeof n=="object"){a=[...a,C({allowReserved:e,explode:!0,name:s,style:"deepObject",value:n,...t})];continue}a=[...a,k({allowReserved:e,name:s,value:n})]}}return a.join("&")},oe=e=>{if(!e)return"stream";let r=e.split(";")[0]?.trim();if(r){if(r.startsWith("application/json")||r.endsWith("+json"))return"json";if(r==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(t=>r.startsWith(t)))return"blob";if(r.startsWith("text/"))return"text"}},ne=async(e,r)=>{let t=typeof r=="function"?await r(e):r;if(t)return e.scheme==="bearer"?`Bearer ${t}`:e.scheme==="basic"?`Basic ${btoa(t)}`:t},ie=async({security:e,...r})=>{for(let t of e){let o=await ne(t,r.auth);if(!o)continue;let a=t.name??"Authorization";switch(t.in){case"query":r.query||(r.query={}),r.query[a]=o;break;case"header":default:r.headers.set(a,o);break}return}},R=e=>ae({baseUrl:e.baseUrl??"",path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:U(e.querySerializer),url:e.url}),ae=({baseUrl:e,path:r,query:t,querySerializer:o,url:a})=>{let s=a.startsWith("/")?a:`/${a}`,n=e+s;r&&(n=te({path:r,url:n}));let i=t?o(t):"";return i.startsWith("?")&&(i=i.substring(1)),i&&(n+=`?${i}`),n},q=(e,r)=>{let t={...e,...r};return t.baseUrl?.endsWith("/")&&(t.baseUrl=t.baseUrl.substring(0,t.baseUrl.length-1)),t.headers=j(e.headers,r.headers),t},j=(...e)=>{let r=new Headers;for(let t of e){if(!t||typeof t!="object")continue;let o=t instanceof Headers?t.entries():Object.entries(t);for(let[a,s]of o)if(s===null)r.delete(a);else if(Array.isArray(s))for(let n of s)r.append(a,n);else s!==void 0&&r.set(a,typeof s=="object"?JSON.stringify(s):s)}return r},m=class{_fns;constructor(){this._fns=[]}clear(){this._fns=[]}exists(e){return this._fns.indexOf(e)!==-1}eject(e){let r=this._fns.indexOf(e);r!==-1&&(this._fns=[...this._fns.slice(0,r),...this._fns.slice(r+1)])}use(e){this._fns=[...this._fns,e]}},se=()=>({error:new m,request:new m,response:new m});var le={bodySerializer:e=>JSON.stringify(e)};var de=U({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),fe={"Content-Type":"application/json"},F=(e={})=>({...le,baseUrl:"",headers:fe,parseAs:"auto",querySerializer:de,...e}),A=(e={})=>{let r=q(F(),e),t=()=>({...r}),o=n=>(r=q(r,n),t()),a=se(),s=async n=>{let i={...r,...n,fetch:n.fetch??r.fetch??globalThis.fetch,headers:j(r.headers,n.headers)};i.security&&await ie({...i,security:i.security}),i.body&&i.bodySerializer&&(i.body=i.bodySerializer(i.body)),i.body||i.headers.delete("Content-Type");let l=R(i),p={redirect:"follow",...i},f=new Request(l,p);for(let u of a.request._fns)f=await u(f,i);let M=i.fetch,d=await M(f);for(let u of a.response._fns)d=await u(d,f,i);let h={request:f,response:d};if(d.ok){if(d.status===204||d.headers.get("Content-Length")==="0")return{data:{},...h};let u=(i.parseAs==="auto"?oe(d.headers.get("Content-Type")):i.parseAs)??"json";if(u==="stream")return{data:d.body,...h};let B=await d[u]();return u==="json"&&(i.responseValidator&&await i.responseValidator(B),i.responseTransformer&&(B=await i.responseTransformer(B))),{data:B,...h}}let g=await d.text();try{g=JSON.parse(g)}catch{}let O=g;for(let u of a.error._fns)O=await u(g,d,f,i);if(O=O||{},i.throwOnError)throw O;return{error:O,...h}};return{buildUrl:R,connect:n=>s({...n,method:"CONNECT"}),delete:n=>s({...n,method:"DELETE"}),get:n=>s({...n,method:"GET"}),getConfig:t,head:n=>s({...n,method:"HEAD"}),interceptors:a,options:n=>s({...n,method:"OPTIONS"}),patch:n=>s({...n,method:"PATCH"}),post:n=>s({...n,method:"POST"}),put:n=>s({...n,method:"PUT"}),request:s,setConfig:o,trace:n=>s({...n,method:"TRACE"})}};var y=A(F()),w=e=>(e?.client??y).get({...e,url:"/bookings"}),D=e=>(e?.client??y).post({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings"}),I=e=>(e?.client??y).delete({...e,url:"/bookings/{bookingId}"}),K=e=>(e?.client??y).get({...e,url:"/bookings/{bookingId}"}),S=e=>(e?.client??y).put({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings/{bookingId}"}),E=e=>(e?.client??y).get({...e,url:"/facilities/{facility_id}/offers"}),x=e=>(e?.client??y).post({...e,url:"/facilities/{facility_id}/offers/{offer_id}"});var c=(e,r,t)=>{let o={_id:e,baseUrl:(r?.client??y).getConfig().baseUrl};return t&&(o._infinite=t),r?.body&&(o.body=r.body),r?.headers&&(o.headers=r.headers),r?.path&&(o.path=r.path),r?.query&&(o.query=r.query),o},v=e=>[c("findBookings",e)],ue=e=>({queryFn:async({queryKey:r,signal:t})=>{let{data:o}=await w({...e,...r[0],signal:t,throwOnError:!0});return o},queryKey:v(e)}),Q=(e,r)=>{let t=e[0];return r.body&&(t.body={...e[0].body,...r.body}),r.headers&&(t.headers={...e[0].headers,...r.headers}),r.path&&(t.path={...e[0].path,...r.path}),r.query&&(t.query={...e[0].query,...r.query}),t},L=e=>[c("findBookings",e,!0)],ye=e=>({queryFn:async({pageParam:r,queryKey:t,signal:o})=>{let s=Q(t,typeof r=="object"?r:{query:{offset:r}}),{data:n}=await w({...e,...s,signal:o,throwOnError:!0});return n},queryKey:L(e)}),$=e=>[c("addBooking",e)],ce=e=>({queryFn:async({queryKey:r,signal:t})=>{let{data:o}=await D({...e,...r[0],signal:t,throwOnError:!0});return o},queryKey:$(e)}),pe=e=>({mutationFn:async t=>{let{data:o}=await D({...e,...t,throwOnError:!0});return o}}),Oe=e=>({mutationFn:async t=>{let{data:o}=await I({...e,...t,throwOnError:!0});return o}}),_=e=>[c("findBookingById",e)],he=e=>({queryFn:async({queryKey:r,signal:t})=>{let{data:o}=await K({...e,...r[0],signal:t,throwOnError:!0});return o},queryKey:_(e)}),ge=e=>({mutationFn:async t=>{let{data:o}=await S({...e,...t,throwOnError:!0});return o}}),z=e=>[c("listFacilityOffers",e)],Be=e=>({queryFn:async({queryKey:r,signal:t})=>{let{data:o}=await E({...e,...r[0],signal:t,throwOnError:!0});return o},queryKey:z(e)}),P=e=>[c("listFacilityOffers",e,!0)],ke=e=>({queryFn:async({pageParam:r,queryKey:t,signal:o})=>{let s=Q(t,typeof r=="object"?r:{query:{cursor:r}}),{data:n}=await E({...e,...s,signal:o,throwOnError:!0});return n},queryKey:P(e)}),W=e=>[c("createFacilityOfferOrder",e)],be=e=>({queryFn:async({queryKey:r,signal:t})=>{let{data:o}=await x({...e,...r[0],signal:t,throwOnError:!0});return o},queryKey:W(e)}),me=e=>({mutationFn:async t=>{let{data:o}=await x({...e,...t,throwOnError:!0});return o}});0&&(module.exports={addBookingMutation,addBookingOptions,addBookingQueryKey,createFacilityOfferOrderMutation,createFacilityOfferOrderOptions,createFacilityOfferOrderQueryKey,deleteBookingMutation,findBookingByIdOptions,findBookingByIdQueryKey,findBookingsInfiniteOptions,findBookingsInfiniteQueryKey,findBookingsOptions,findBookingsQueryKey,listFacilityOffersInfiniteOptions,listFacilityOffersInfiniteQueryKey,listFacilityOffersOptions,listFacilityOffersQueryKey,updateBookingMutation});
@@ -1 +1 @@
1
- import{a as s,b as r,c as a,d,e as y,f as p}from"../chunk-SNGJPP3Q.mjs";var i=(o,n,t)=>{let e={_id:o,baseUrl:(n?.client??s).getConfig().baseUrl};return t&&(e._infinite=t),n?.body&&(e.body=n.body),n?.headers&&(e.headers=n.headers),n?.path&&(e.path=n.path),n?.query&&(e.query=n.query),e},k=o=>[i("findBookings",o)],F=o=>({queryFn:async({queryKey:n,signal:t})=>{let{data:e}=await r({...o,...n[0],signal:t,throwOnError:!0});return e},queryKey:k(o)}),g=(o,n)=>{let t=o[0];return n.body&&(t.body={...o[0].body,...n.body}),n.headers&&(t.headers={...o[0].headers,...n.headers}),n.path&&(t.path={...o[0].path,...n.path}),n.query&&(t.query={...o[0].query,...n.query}),t},O=o=>[i("findBookings",o,!0)],l=o=>({queryFn:async({pageParam:n,queryKey:t,signal:e})=>{let u=g(t,typeof n=="object"?n:{query:{offset:n}}),{data:B}=await r({...o,...u,signal:e,throwOnError:!0});return B},queryKey:O(o)}),c=o=>[i("addBooking",o)],m=o=>({queryFn:async({queryKey:n,signal:t})=>{let{data:e}=await a({...o,...n[0],signal:t,throwOnError:!0});return e},queryKey:c(o)}),b=o=>({mutationFn:async t=>{let{data:e}=await a({...o,...t,throwOnError:!0});return e}}),q=o=>({mutationFn:async t=>{let{data:e}=await d({...o,...t,throwOnError:!0});return e}}),f=o=>[i("findBookingById",o)],K=o=>({queryFn:async({queryKey:n,signal:t})=>{let{data:e}=await y({...o,...n[0],signal:t,throwOnError:!0});return e},queryKey:f(o)}),Q=o=>({mutationFn:async t=>{let{data:e}=await p({...o,...t,throwOnError:!0});return e}});export{b as addBookingMutation,m as addBookingOptions,c as addBookingQueryKey,q as deleteBookingMutation,K as findBookingByIdOptions,f as findBookingByIdQueryKey,l as findBookingsInfiniteOptions,O as findBookingsInfiniteQueryKey,F as findBookingsOptions,k as findBookingsQueryKey,Q as updateBookingMutation};
1
+ import{a as p,b as s,c as y,d as u,e as f,f as c,g as d,h as O}from"../chunk-M5A265XW.mjs";var i=(t,e,r)=>{let o={_id:t,baseUrl:(e?.client??p).getConfig().baseUrl};return r&&(o._infinite=r),e?.body&&(o.body=e.body),e?.headers&&(o.headers=e.headers),e?.path&&(o.path=e.path),e?.query&&(o.query=e.query),o},l=t=>[i("findBookings",t)],E=t=>({queryFn:async({queryKey:e,signal:r})=>{let{data:o}=await s({...t,...e[0],signal:r,throwOnError:!0});return o},queryKey:l(t)}),k=(t,e)=>{let r=t[0];return e.body&&(r.body={...t[0].body,...e.body}),e.headers&&(r.headers={...t[0].headers,...e.headers}),e.path&&(r.path={...t[0].path,...e.path}),e.query&&(r.query={...t[0].query,...e.query}),r},F=t=>[i("findBookings",t,!0)],Q=t=>({queryFn:async({pageParam:e,queryKey:r,signal:o})=>{let n=k(r,typeof e=="object"?e:{query:{offset:e}}),{data:a}=await s({...t,...n,signal:o,throwOnError:!0});return a},queryKey:F(t)}),g=t=>[i("addBooking",t)],m=t=>({queryFn:async({queryKey:e,signal:r})=>{let{data:o}=await y({...t,...e[0],signal:r,throwOnError:!0});return o},queryKey:g(t)}),b=t=>({mutationFn:async r=>{let{data:o}=await y({...t,...r,throwOnError:!0});return o}}),x=t=>({mutationFn:async r=>{let{data:o}=await u({...t,...r,throwOnError:!0});return o}}),D=t=>[i("findBookingById",t)],I=t=>({queryFn:async({queryKey:e,signal:r})=>{let{data:o}=await f({...t,...e[0],signal:r,throwOnError:!0});return o},queryKey:D(t)}),U=t=>({mutationFn:async r=>{let{data:o}=await c({...t,...r,throwOnError:!0});return o}}),h=t=>[i("listFacilityOffers",t)],L=t=>({queryFn:async({queryKey:e,signal:r})=>{let{data:o}=await d({...t,...e[0],signal:r,throwOnError:!0});return o},queryKey:h(t)}),K=t=>[i("listFacilityOffers",t,!0)],R=t=>({queryFn:async({pageParam:e,queryKey:r,signal:o})=>{let n=k(r,typeof e=="object"?e:{query:{cursor:e}}),{data:a}=await d({...t,...n,signal:o,throwOnError:!0});return a},queryKey:K(t)}),q=t=>[i("createFacilityOfferOrder",t)],C=t=>({queryFn:async({queryKey:e,signal:r})=>{let{data:o}=await O({...t,...e[0],signal:r,throwOnError:!0});return o},queryKey:q(t)}),A=t=>({mutationFn:async r=>{let{data:o}=await O({...t,...r,throwOnError:!0});return o}});export{b as addBookingMutation,m as addBookingOptions,g as addBookingQueryKey,A as createFacilityOfferOrderMutation,C as createFacilityOfferOrderOptions,q as createFacilityOfferOrderQueryKey,x as deleteBookingMutation,I as findBookingByIdOptions,D as findBookingByIdQueryKey,Q as findBookingsInfiniteOptions,F as findBookingsInfiniteQueryKey,E as findBookingsOptions,l as findBookingsQueryKey,R as listFacilityOffersInfiniteOptions,K as listFacilityOffersInfiniteQueryKey,L as listFacilityOffersOptions,h as listFacilityOffersQueryKey,U as updateBookingMutation};
@@ -0,0 +1 @@
1
+ var C=/\{[^{}]+\}/g,O=({allowReserved:e,name:n,value:t})=>{if(t==null)return"";if(typeof t=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${n}=${e?t:encodeURIComponent(t)}`},F=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},S=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},v=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},k=({allowReserved:e,explode:n,name:t,style:s,value:a})=>{if(!n){let o=(e?a:a.map(l=>encodeURIComponent(l))).join(S(s));switch(s){case"label":return`.${o}`;case"matrix":return`;${t}=${o}`;case"simple":return o;default:return`${t}=${o}`}}let i=F(s),r=a.map(o=>s==="label"||s==="simple"?e?o:encodeURIComponent(o):O({allowReserved:e,name:t,value:o})).join(i);return s==="label"||s==="matrix"?i+r:r},x=({allowReserved:e,explode:n,name:t,style:s,value:a})=>{if(a instanceof Date)return`${t}=${a.toISOString()}`;if(s!=="deepObject"&&!n){let o=[];Object.entries(a).forEach(([p,f])=>{o=[...o,p,e?f:encodeURIComponent(f)]});let l=o.join(",");switch(s){case"form":return`${t}=${l}`;case"label":return`.${l}`;case"matrix":return`;${t}=${l}`;default:return l}}let i=v(s),r=Object.entries(a).map(([o,l])=>O({allowReserved:e,name:s==="deepObject"?`${t}[${o}]`:o,value:l})).join(i);return s==="label"||s==="matrix"?i+r:r},A=({path:e,url:n})=>{let t=n,s=n.match(C);if(s)for(let a of s){let i=!1,r=a.substring(1,a.length-1),o="simple";r.endsWith("*")&&(i=!0,r=r.substring(0,r.length-1)),r.startsWith(".")?(r=r.substring(1),o="label"):r.startsWith(";")&&(r=r.substring(1),o="matrix");let l=e[r];if(l==null)continue;if(Array.isArray(l)){t=t.replace(a,k({explode:i,name:r,style:o,value:l}));continue}if(typeof l=="object"){t=t.replace(a,x({explode:i,name:r,style:o,value:l}));continue}if(o==="matrix"){t=t.replace(a,`;${O({name:r,value:l})}`);continue}let p=encodeURIComponent(o==="label"?`.${l}`:l);t=t.replace(a,p)}return t},T=({allowReserved:e,array:n,object:t}={})=>s=>{let a=[];if(s&&typeof s=="object")for(let i in s){let r=s[i];if(r!=null){if(Array.isArray(r)){a=[...a,k({allowReserved:e,explode:!0,name:i,style:"form",value:r,...n})];continue}if(typeof r=="object"){a=[...a,x({allowReserved:e,explode:!0,name:i,style:"deepObject",value:r,...t})];continue}a=[...a,O({allowReserved:e,name:i,value:r})]}}return a.join("&")},U=e=>{if(!e)return"stream";let n=e.split(";")[0]?.trim();if(n){if(n.startsWith("application/json")||n.endsWith("+json"))return"json";if(n==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(t=>n.startsWith(t)))return"blob";if(n.startsWith("text/"))return"text"}},$=async(e,n)=>{let t=typeof n=="function"?await n(e):n;if(t)return e.scheme==="bearer"?`Bearer ${t}`:e.scheme==="basic"?`Basic ${btoa(t)}`:t},q=async({security:e,...n})=>{for(let t of e){let s=await $(t,n.auth);if(!s)continue;let a=t.name??"Authorization";switch(t.in){case"query":n.query||(n.query={}),n.query[a]=s;break;case"header":default:n.headers.set(a,s);break}return}},E=e=>I({baseUrl:e.baseUrl??"",path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:T(e.querySerializer),url:e.url}),I=({baseUrl:e,path:n,query:t,querySerializer:s,url:a})=>{let i=a.startsWith("/")?a:`/${a}`,r=e+i;n&&(r=A({path:n,url:r}));let o=t?s(t):"";return o.startsWith("?")&&(o=o.substring(1)),o&&(r+=`?${o}`),r},B=(e,n)=>{let t={...e,...n};return t.baseUrl?.endsWith("/")&&(t.baseUrl=t.baseUrl.substring(0,t.baseUrl.length-1)),t.headers=j(e.headers,n.headers),t},j=(...e)=>{let n=new Headers;for(let t of e){if(!t||typeof t!="object")continue;let s=t instanceof Headers?t.entries():Object.entries(t);for(let[a,i]of s)if(i===null)n.delete(a);else if(Array.isArray(i))for(let r of i)n.append(a,r);else i!==void 0&&n.set(a,typeof i=="object"?JSON.stringify(i):i)}return n},m=class{_fns;constructor(){this._fns=[]}clear(){this._fns=[]}exists(e){return this._fns.indexOf(e)!==-1}eject(e){let n=this._fns.indexOf(e);n!==-1&&(this._fns=[...this._fns.slice(0,n),...this._fns.slice(n+1)])}use(e){this._fns=[...this._fns,e]}},z=()=>({error:new m,request:new m,response:new m});var _={bodySerializer:e=>JSON.stringify(e)};var W=T({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),L={"Content-Type":"application/json"},w=(e={})=>({..._,baseUrl:"",headers:L,parseAs:"auto",querySerializer:W,...e}),R=(e={})=>{let n=B(w(),e),t=()=>({...n}),s=r=>(n=B(n,r),t()),a=z(),i=async r=>{let o={...n,...r,fetch:r.fetch??n.fetch??globalThis.fetch,headers:j(n.headers,r.headers)};o.security&&await q({...o,security:o.security}),o.body&&o.bodySerializer&&(o.body=o.bodySerializer(o.body)),o.body||o.headers.delete("Content-Type");let l=E(o),p={redirect:"follow",...o},f=new Request(l,p);for(let u of a.request._fns)f=await u(f,o);let D=o.fetch,d=await D(f);for(let u of a.response._fns)d=await u(d,f,o);let y={request:f,response:d};if(d.ok){if(d.status===204||d.headers.get("Content-Length")==="0")return{data:{},...y};let u=(o.parseAs==="auto"?U(d.headers.get("Content-Type")):o.parseAs)??"json";if(u==="stream")return{data:d.body,...y};let g=await d[u]();return u==="json"&&(o.responseValidator&&await o.responseValidator(g),o.responseTransformer&&(g=await o.responseTransformer(g))),{data:g,...y}}let b=await d.text();try{b=JSON.parse(b)}catch{}let h=b;for(let u of a.error._fns)h=await u(b,d,f,o);if(h=h||{},o.throwOnError)throw h;return{error:h,...y}};return{buildUrl:E,connect:r=>i({...r,method:"CONNECT"}),delete:r=>i({...r,method:"DELETE"}),get:r=>i({...r,method:"GET"}),getConfig:t,head:r=>i({...r,method:"HEAD"}),interceptors:a,options:r=>i({...r,method:"OPTIONS"}),patch:r=>i({...r,method:"PATCH"}),post:r=>i({...r,method:"POST"}),put:r=>i({...r,method:"PUT"}),request:i,setConfig:s,trace:r=>i({...r,method:"TRACE"})}};var c=R(w()),J=e=>(e?.client??c).get({...e,url:"/bookings"}),V=e=>(e?.client??c).post({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings"}),G=e=>(e?.client??c).delete({...e,url:"/bookings/{bookingId}"}),M=e=>(e?.client??c).get({...e,url:"/bookings/{bookingId}"}),Q=e=>(e?.client??c).put({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings/{bookingId}"}),K=e=>(e?.client??c).get({...e,url:"/facilities/{facility_id}/offers"}),X=e=>(e?.client??c).post({...e,url:"/facilities/{facility_id}/offers/{offer_id}"});export{c as a,J as b,V as c,G as d,M as e,Q as f,K as g,X as h};
@@ -1,3 +1,3 @@
1
- export { AddBookingData, AddBookingError, AddBookingErrors, AddBookingResponse, AddBookingResponses, Booking, CreateBooking, DeleteBookingData, DeleteBookingError, DeleteBookingErrors, DeleteBookingResponse, DeleteBookingResponses, FindBookingByIdData, FindBookingByIdError, FindBookingByIdErrors, FindBookingByIdResponse, FindBookingByIdResponses, FindBookingsData, FindBookingsError, FindBookingsErrors, FindBookingsResponse, FindBookingsResponses, Guest, PkgOpenapiSharedError, PkgOpenapiSharedErrors, PkgOpenapiSharedOffsetLimitParam, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedOffsetParam, PkgOpenapiSharedProblemDetails, Player, UpdateBooking, UpdateBookingData, UpdateBookingError, UpdateBookingErrors, UpdateBookingResponse, UpdateBookingResponses } from './types.gen.mjs';
2
- export { addBooking, client, deleteBooking, findBookingById, findBookings, updateBooking } from './sdk.gen.mjs';
1
+ export { AddBookingData, AddBookingError, AddBookingErrors, AddBookingResponse, AddBookingResponses, Booking, CreateBooking, CreateFacilityOfferOrderData, CreateFacilityOfferOrderError, CreateFacilityOfferOrderErrors, CreateFacilityOfferOrderResponse, CreateFacilityOfferOrderResponses, DeleteBookingData, DeleteBookingError, DeleteBookingErrors, DeleteBookingResponse, DeleteBookingResponses, FacilityIdPath, FacilityOffer, FacilityOfferCondition, FacilityOfferConditionActivities, FacilityOfferConditionCourts, FacilityOfferConditionDate, FacilityOfferConditionHoursinadvance, FacilityOfferConditionNotImplemented, FacilityOfferConditionTime, FacilityOfferConditionWeekdays, FacilityOfferList, FacilityOfferOrder, FacilityPunchCardData, FacilityValueCardData, FindBookingByIdData, FindBookingByIdError, FindBookingByIdErrors, FindBookingByIdResponse, FindBookingByIdResponses, FindBookingsData, FindBookingsError, FindBookingsErrors, FindBookingsResponse, FindBookingsResponses, Guest, ListFacilityOffersData, ListFacilityOffersError, ListFacilityOffersErrors, ListFacilityOffersResponse, ListFacilityOffersResponses, OfferIdPath, PkgOpenapiSharedCursorLimitParam, PkgOpenapiSharedCursorPaginatedResultSet, PkgOpenapiSharedCursorParam, PkgOpenapiSharedError, PkgOpenapiSharedErrors, PkgOpenapiSharedOffsetLimitParam, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedOffsetParam, PkgOpenapiSharedProblemDetails, Player, UpdateBooking, UpdateBookingData, UpdateBookingError, UpdateBookingErrors, UpdateBookingResponse, UpdateBookingResponses } from './types.gen.mjs';
2
+ export { addBooking, client, createFacilityOfferOrder, deleteBooking, findBookingById, findBookings, listFacilityOffers, updateBooking } from './sdk.gen.mjs';
3
3
  import '@hey-api/client-fetch';
@@ -1,3 +1,3 @@
1
- export { AddBookingData, AddBookingError, AddBookingErrors, AddBookingResponse, AddBookingResponses, Booking, CreateBooking, DeleteBookingData, DeleteBookingError, DeleteBookingErrors, DeleteBookingResponse, DeleteBookingResponses, FindBookingByIdData, FindBookingByIdError, FindBookingByIdErrors, FindBookingByIdResponse, FindBookingByIdResponses, FindBookingsData, FindBookingsError, FindBookingsErrors, FindBookingsResponse, FindBookingsResponses, Guest, PkgOpenapiSharedError, PkgOpenapiSharedErrors, PkgOpenapiSharedOffsetLimitParam, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedOffsetParam, PkgOpenapiSharedProblemDetails, Player, UpdateBooking, UpdateBookingData, UpdateBookingError, UpdateBookingErrors, UpdateBookingResponse, UpdateBookingResponses } from './types.gen.js';
2
- export { addBooking, client, deleteBooking, findBookingById, findBookings, updateBooking } from './sdk.gen.js';
1
+ export { AddBookingData, AddBookingError, AddBookingErrors, AddBookingResponse, AddBookingResponses, Booking, CreateBooking, CreateFacilityOfferOrderData, CreateFacilityOfferOrderError, CreateFacilityOfferOrderErrors, CreateFacilityOfferOrderResponse, CreateFacilityOfferOrderResponses, DeleteBookingData, DeleteBookingError, DeleteBookingErrors, DeleteBookingResponse, DeleteBookingResponses, FacilityIdPath, FacilityOffer, FacilityOfferCondition, FacilityOfferConditionActivities, FacilityOfferConditionCourts, FacilityOfferConditionDate, FacilityOfferConditionHoursinadvance, FacilityOfferConditionNotImplemented, FacilityOfferConditionTime, FacilityOfferConditionWeekdays, FacilityOfferList, FacilityOfferOrder, FacilityPunchCardData, FacilityValueCardData, FindBookingByIdData, FindBookingByIdError, FindBookingByIdErrors, FindBookingByIdResponse, FindBookingByIdResponses, FindBookingsData, FindBookingsError, FindBookingsErrors, FindBookingsResponse, FindBookingsResponses, Guest, ListFacilityOffersData, ListFacilityOffersError, ListFacilityOffersErrors, ListFacilityOffersResponse, ListFacilityOffersResponses, OfferIdPath, PkgOpenapiSharedCursorLimitParam, PkgOpenapiSharedCursorPaginatedResultSet, PkgOpenapiSharedCursorParam, PkgOpenapiSharedError, PkgOpenapiSharedErrors, PkgOpenapiSharedOffsetLimitParam, PkgOpenapiSharedOffsetPaginatedResultSet, PkgOpenapiSharedOffsetParam, PkgOpenapiSharedProblemDetails, Player, UpdateBooking, UpdateBookingData, UpdateBookingError, UpdateBookingErrors, UpdateBookingResponse, UpdateBookingResponses } from './types.gen.js';
2
+ export { addBooking, client, createFacilityOfferOrder, deleteBooking, findBookingById, findBookings, listFacilityOffers, updateBooking } from './sdk.gen.js';
3
3
  import '@hey-api/client-fetch';
package/dist/v1/index.js CHANGED
@@ -1 +1 @@
1
- "use strict";var w=Object.defineProperty;var v=Object.getOwnPropertyDescriptor;var A=Object.getOwnPropertyNames;var U=Object.prototype.hasOwnProperty;var $=(e,t)=>{for(var r in t)w(e,r,{get:t[r],enumerable:!0})},C=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of A(t))!U.call(e,a)&&a!==r&&w(e,a,{get:()=>t[a],enumerable:!(i=v(t,a))||i.enumerable});return e};var q=e=>C(w({},"__esModule",{value:!0}),e);var ee={};$(ee,{addBooking:()=>K,client:()=>f,deleteBooking:()=>X,findBookingById:()=>Y,findBookings:()=>Q,updateBooking:()=>Z});module.exports=q(ee);var I=/\{[^{}]+\}/g,m=({allowReserved:e,name:t,value:r})=>{if(r==null)return"";if(typeof r=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${t}=${e?r:encodeURIComponent(r)}`},z=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},_=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},F=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},x=({allowReserved:e,explode:t,name:r,style:i,value:a})=>{if(!t){let n=(e?a:a.map(l=>encodeURIComponent(l))).join(_(i));switch(i){case"label":return`.${n}`;case"matrix":return`;${r}=${n}`;case"simple":return n;default:return`${r}=${n}`}}let s=z(i),o=a.map(n=>i==="label"||i==="simple"?e?n:encodeURIComponent(n):m({allowReserved:e,name:r,value:n})).join(s);return i==="label"||i==="matrix"?s+o:o},j=({allowReserved:e,explode:t,name:r,style:i,value:a})=>{if(a instanceof Date)return`${r}=${a.toISOString()}`;if(i!=="deepObject"&&!t){let n=[];Object.entries(a).forEach(([p,u])=>{n=[...n,p,e?u:encodeURIComponent(u)]});let l=n.join(",");switch(i){case"form":return`${r}=${l}`;case"label":return`.${l}`;case"matrix":return`;${r}=${l}`;default:return l}}let s=F(i),o=Object.entries(a).map(([n,l])=>m({allowReserved:e,name:i==="deepObject"?`${r}[${n}]`:n,value:l})).join(s);return i==="label"||i==="matrix"?s+o:o},W=({path:e,url:t})=>{let r=t,i=t.match(I);if(i)for(let a of i){let s=!1,o=a.substring(1,a.length-1),n="simple";o.endsWith("*")&&(s=!0,o=o.substring(0,o.length-1)),o.startsWith(".")?(o=o.substring(1),n="label"):o.startsWith(";")&&(o=o.substring(1),n="matrix");let l=e[o];if(l==null)continue;if(Array.isArray(l)){r=r.replace(a,x({explode:s,name:o,style:n,value:l}));continue}if(typeof l=="object"){r=r.replace(a,j({explode:s,name:o,style:n,value:l}));continue}if(n==="matrix"){r=r.replace(a,`;${m({name:o,value:l})}`);continue}let p=encodeURIComponent(n==="label"?`.${l}`:l);r=r.replace(a,p)}return r},T=({allowReserved:e,array:t,object:r}={})=>i=>{let a=[];if(i&&typeof i=="object")for(let s in i){let o=i[s];if(o!=null){if(Array.isArray(o)){a=[...a,x({allowReserved:e,explode:!0,name:s,style:"form",value:o,...t})];continue}if(typeof o=="object"){a=[...a,j({allowReserved:e,explode:!0,name:s,style:"deepObject",value:o,...r})];continue}a=[...a,m({allowReserved:e,name:s,value:o})]}}return a.join("&")},N=e=>{if(!e)return"stream";let t=e.split(";")[0]?.trim();if(t){if(t.startsWith("application/json")||t.endsWith("+json"))return"json";if(t==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(r=>t.startsWith(r)))return"blob";if(t.startsWith("text/"))return"text"}},P=async(e,t)=>{let r=typeof t=="function"?await t(e):t;if(r)return e.scheme==="bearer"?`Bearer ${r}`:e.scheme==="basic"?`Basic ${btoa(r)}`:r},H=async({security:e,...t})=>{for(let r of e){let i=await P(r,t.auth);if(!i)continue;let a=r.name??"Authorization";switch(r.in){case"query":t.query||(t.query={}),t.query[a]=i;break;case"header":default:t.headers.set(a,i);break}return}},O=e=>J({baseUrl:e.baseUrl??"",path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:T(e.querySerializer),url:e.url}),J=({baseUrl:e,path:t,query:r,querySerializer:i,url:a})=>{let s=a.startsWith("/")?a:`/${a}`,o=e+s;t&&(o=W({path:t,url:o}));let n=r?i(r):"";return n.startsWith("?")&&(n=n.substring(1)),n&&(o+=`?${n}`),o},E=(e,t)=>{let r={...e,...t};return r.baseUrl?.endsWith("/")&&(r.baseUrl=r.baseUrl.substring(0,r.baseUrl.length-1)),r.headers=R(e.headers,t.headers),r},R=(...e)=>{let t=new Headers;for(let r of e){if(!r||typeof r!="object")continue;let i=r instanceof Headers?r.entries():Object.entries(r);for(let[a,s]of i)if(s===null)t.delete(a);else if(Array.isArray(s))for(let o of s)t.append(a,o);else s!==void 0&&t.set(a,typeof s=="object"?JSON.stringify(s):s)}return t},B=class{_fns;constructor(){this._fns=[]}clear(){this._fns=[]}exists(e){return this._fns.indexOf(e)!==-1}eject(e){let t=this._fns.indexOf(e);t!==-1&&(this._fns=[...this._fns.slice(0,t),...this._fns.slice(t+1)])}use(e){this._fns=[...this._fns,e]}},L=()=>({error:new B,request:new B,response:new B});var V={bodySerializer:e=>JSON.stringify(e)};var G=T({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),M={"Content-Type":"application/json"},k=(e={})=>({...V,baseUrl:"",headers:M,parseAs:"auto",querySerializer:G,...e}),S=(e={})=>{let t=E(k(),e),r=()=>({...t}),i=o=>(t=E(t,o),r()),a=L(),s=async o=>{let n={...t,...o,fetch:o.fetch??t.fetch??globalThis.fetch,headers:R(t.headers,o.headers)};n.security&&await H({...n,security:n.security}),n.body&&n.bodySerializer&&(n.body=n.bodySerializer(n.body)),n.body||n.headers.delete("Content-Type");let l=O(n),p={redirect:"follow",...n},u=new Request(l,p);for(let c of a.request._fns)u=await c(u,n);let D=n.fetch,d=await D(u);for(let c of a.response._fns)d=await c(d,u,n);let y={request:u,response:d};if(d.ok){if(d.status===204||d.headers.get("Content-Length")==="0")return{data:{},...y};let c=(n.parseAs==="auto"?N(d.headers.get("Content-Type")):n.parseAs)??"json";if(c==="stream")return{data:d.body,...y};let g=await d[c]();return c==="json"&&(n.responseValidator&&await n.responseValidator(g),n.responseTransformer&&(g=await n.responseTransformer(g))),{data:g,...y}}let b=await d.text();try{b=JSON.parse(b)}catch{}let h=b;for(let c of a.error._fns)h=await c(b,d,u,n);if(h=h||{},n.throwOnError)throw h;return{error:h,...y}};return{buildUrl:O,connect:o=>s({...o,method:"CONNECT"}),delete:o=>s({...o,method:"DELETE"}),get:o=>s({...o,method:"GET"}),getConfig:r,head:o=>s({...o,method:"HEAD"}),interceptors:a,options:o=>s({...o,method:"OPTIONS"}),patch:o=>s({...o,method:"PATCH"}),post:o=>s({...o,method:"POST"}),put:o=>s({...o,method:"PUT"}),request:s,setConfig:i,trace:o=>s({...o,method:"TRACE"})}};var f=S(k()),Q=e=>(e?.client??f).get({...e,url:"/bookings"}),K=e=>(e?.client??f).post({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings"}),X=e=>(e?.client??f).delete({...e,url:"/bookings/{bookingId}"}),Y=e=>(e?.client??f).get({...e,url:"/bookings/{bookingId}"}),Z=e=>(e?.client??f).put({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings/{bookingId}"});0&&(module.exports={addBooking,client,deleteBooking,findBookingById,findBookings,updateBooking});
1
+ "use strict";var m=Object.defineProperty;var F=Object.getOwnPropertyDescriptor;var S=Object.getOwnPropertyNames;var v=Object.prototype.hasOwnProperty;var A=(e,t)=>{for(var r in t)m(e,r,{get:t[r],enumerable:!0})},U=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of S(t))!v.call(e,a)&&a!==r&&m(e,a,{get:()=>t[a],enumerable:!(i=F(t,a))||i.enumerable});return e};var $=e=>U(m({},"__esModule",{value:!0}),e);var te={};A(te,{addBooking:()=>K,client:()=>c,createFacilityOfferOrder:()=>re,deleteBooking:()=>X,findBookingById:()=>Y,findBookings:()=>Q,listFacilityOffers:()=>ee,updateBooking:()=>Z});module.exports=$(te);var q=/\{[^{}]+\}/g,O=({allowReserved:e,name:t,value:r})=>{if(r==null)return"";if(typeof r=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${t}=${e?r:encodeURIComponent(r)}`},I=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},z=e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},_=e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},x=({allowReserved:e,explode:t,name:r,style:i,value:a})=>{if(!t){let n=(e?a:a.map(l=>encodeURIComponent(l))).join(z(i));switch(i){case"label":return`.${n}`;case"matrix":return`;${r}=${n}`;case"simple":return n;default:return`${r}=${n}`}}let s=I(i),o=a.map(n=>i==="label"||i==="simple"?e?n:encodeURIComponent(n):O({allowReserved:e,name:r,value:n})).join(s);return i==="label"||i==="matrix"?s+o:o},T=({allowReserved:e,explode:t,name:r,style:i,value:a})=>{if(a instanceof Date)return`${r}=${a.toISOString()}`;if(i!=="deepObject"&&!t){let n=[];Object.entries(a).forEach(([p,f])=>{n=[...n,p,e?f:encodeURIComponent(f)]});let l=n.join(",");switch(i){case"form":return`${r}=${l}`;case"label":return`.${l}`;case"matrix":return`;${r}=${l}`;default:return l}}let s=_(i),o=Object.entries(a).map(([n,l])=>O({allowReserved:e,name:i==="deepObject"?`${r}[${n}]`:n,value:l})).join(s);return i==="label"||i==="matrix"?s+o:o},W=({path:e,url:t})=>{let r=t,i=t.match(q);if(i)for(let a of i){let s=!1,o=a.substring(1,a.length-1),n="simple";o.endsWith("*")&&(s=!0,o=o.substring(0,o.length-1)),o.startsWith(".")?(o=o.substring(1),n="label"):o.startsWith(";")&&(o=o.substring(1),n="matrix");let l=e[o];if(l==null)continue;if(Array.isArray(l)){r=r.replace(a,x({explode:s,name:o,style:n,value:l}));continue}if(typeof l=="object"){r=r.replace(a,T({explode:s,name:o,style:n,value:l}));continue}if(n==="matrix"){r=r.replace(a,`;${O({name:o,value:l})}`);continue}let p=encodeURIComponent(n==="label"?`.${l}`:l);r=r.replace(a,p)}return r},j=({allowReserved:e,array:t,object:r}={})=>i=>{let a=[];if(i&&typeof i=="object")for(let s in i){let o=i[s];if(o!=null){if(Array.isArray(o)){a=[...a,x({allowReserved:e,explode:!0,name:s,style:"form",value:o,...t})];continue}if(typeof o=="object"){a=[...a,T({allowReserved:e,explode:!0,name:s,style:"deepObject",value:o,...r})];continue}a=[...a,O({allowReserved:e,name:s,value:o})]}}return a.join("&")},L=e=>{if(!e)return"stream";let t=e.split(";")[0]?.trim();if(t){if(t.startsWith("application/json")||t.endsWith("+json"))return"json";if(t==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(r=>t.startsWith(r)))return"blob";if(t.startsWith("text/"))return"text"}},N=async(e,t)=>{let r=typeof t=="function"?await t(e):t;if(r)return e.scheme==="bearer"?`Bearer ${r}`:e.scheme==="basic"?`Basic ${btoa(r)}`:r},P=async({security:e,...t})=>{for(let r of e){let i=await N(r,t.auth);if(!i)continue;let a=r.name??"Authorization";switch(r.in){case"query":t.query||(t.query={}),t.query[a]=i;break;case"header":default:t.headers.set(a,i);break}return}},B=e=>H({baseUrl:e.baseUrl??"",path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:j(e.querySerializer),url:e.url}),H=({baseUrl:e,path:t,query:r,querySerializer:i,url:a})=>{let s=a.startsWith("/")?a:`/${a}`,o=e+s;t&&(o=W({path:t,url:o}));let n=r?i(r):"";return n.startsWith("?")&&(n=n.substring(1)),n&&(o+=`?${n}`),o},k=(e,t)=>{let r={...e,...t};return r.baseUrl?.endsWith("/")&&(r.baseUrl=r.baseUrl.substring(0,r.baseUrl.length-1)),r.headers=R(e.headers,t.headers),r},R=(...e)=>{let t=new Headers;for(let r of e){if(!r||typeof r!="object")continue;let i=r instanceof Headers?r.entries():Object.entries(r);for(let[a,s]of i)if(s===null)t.delete(a);else if(Array.isArray(s))for(let o of s)t.append(a,o);else s!==void 0&&t.set(a,typeof s=="object"?JSON.stringify(s):s)}return t},w=class{_fns;constructor(){this._fns=[]}clear(){this._fns=[]}exists(e){return this._fns.indexOf(e)!==-1}eject(e){let t=this._fns.indexOf(e);t!==-1&&(this._fns=[...this._fns.slice(0,t),...this._fns.slice(t+1)])}use(e){this._fns=[...this._fns,e]}},J=()=>({error:new w,request:new w,response:new w});var V={bodySerializer:e=>JSON.stringify(e)};var G=j({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),M={"Content-Type":"application/json"},E=(e={})=>({...V,baseUrl:"",headers:M,parseAs:"auto",querySerializer:G,...e}),D=(e={})=>{let t=k(E(),e),r=()=>({...t}),i=o=>(t=k(t,o),r()),a=J(),s=async o=>{let n={...t,...o,fetch:o.fetch??t.fetch??globalThis.fetch,headers:R(t.headers,o.headers)};n.security&&await P({...n,security:n.security}),n.body&&n.bodySerializer&&(n.body=n.bodySerializer(n.body)),n.body||n.headers.delete("Content-Type");let l=B(n),p={redirect:"follow",...n},f=new Request(l,p);for(let u of a.request._fns)f=await u(f,n);let C=n.fetch,d=await C(f);for(let u of a.response._fns)d=await u(d,f,n);let y={request:f,response:d};if(d.ok){if(d.status===204||d.headers.get("Content-Length")==="0")return{data:{},...y};let u=(n.parseAs==="auto"?L(d.headers.get("Content-Type")):n.parseAs)??"json";if(u==="stream")return{data:d.body,...y};let g=await d[u]();return u==="json"&&(n.responseValidator&&await n.responseValidator(g),n.responseTransformer&&(g=await n.responseTransformer(g))),{data:g,...y}}let b=await d.text();try{b=JSON.parse(b)}catch{}let h=b;for(let u of a.error._fns)h=await u(b,d,f,n);if(h=h||{},n.throwOnError)throw h;return{error:h,...y}};return{buildUrl:B,connect:o=>s({...o,method:"CONNECT"}),delete:o=>s({...o,method:"DELETE"}),get:o=>s({...o,method:"GET"}),getConfig:r,head:o=>s({...o,method:"HEAD"}),interceptors:a,options:o=>s({...o,method:"OPTIONS"}),patch:o=>s({...o,method:"PATCH"}),post:o=>s({...o,method:"POST"}),put:o=>s({...o,method:"PUT"}),request:s,setConfig:i,trace:o=>s({...o,method:"TRACE"})}};var c=D(E()),Q=e=>(e?.client??c).get({...e,url:"/bookings"}),K=e=>(e?.client??c).post({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings"}),X=e=>(e?.client??c).delete({...e,url:"/bookings/{bookingId}"}),Y=e=>(e?.client??c).get({...e,url:"/bookings/{bookingId}"}),Z=e=>(e?.client??c).put({...e,headers:{"Content-Type":"application/json",...e?.headers},url:"/bookings/{bookingId}"}),ee=e=>(e?.client??c).get({...e,url:"/facilities/{facility_id}/offers"}),re=e=>(e?.client??c).post({...e,url:"/facilities/{facility_id}/offers/{offer_id}"});0&&(module.exports={addBooking,client,createFacilityOfferOrder,deleteBooking,findBookingById,findBookings,listFacilityOffers,updateBooking});
package/dist/v1/index.mjs CHANGED
@@ -1 +1 @@
1
- import"./chunk-PT2OYMNL.mjs";import{a as o,b as r,c as e,d as f,e as m,f as p}from"./chunk-SNGJPP3Q.mjs";export{e as addBooking,o as client,f as deleteBooking,m as findBookingById,r as findBookings,p as updateBooking};
1
+ import"./chunk-PT2OYMNL.mjs";import{a as o,b as r,c as e,d as f,e as m,f as p,g as t,h as x}from"./chunk-M5A265XW.mjs";export{e as addBooking,o as client,x as createFacilityOfferOrder,f as deleteBooking,m as findBookingById,r as findBookings,t as listFacilityOffers,p as updateBooking};