@wix/table-reservations 1.0.101 → 1.0.102

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/table-reservations",
3
- "version": "1.0.101",
3
+ "version": "1.0.102",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org/",
6
6
  "access": "public"
@@ -44,5 +44,5 @@
44
44
  "fqdn": ""
45
45
  }
46
46
  },
47
- "falconPackageHash": "382cff5dfaea68b8d0c6d7c09dd27fd159844ad971bd3bb1094bfe70"
47
+ "falconPackageHash": "65755e4c7de012732b70b6bc3af6a78d6ec2c70cb1217bb86cd3d21a"
48
48
  }
@@ -941,41 +941,41 @@ interface ReservationsQueryBuilder {
941
941
  find: () => Promise<ReservationsQueryResult>;
942
942
  }
943
943
 
944
- type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
945
- interface HttpClient {
946
- request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
944
+ type RESTFunctionDescriptor$2<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$2) => T;
945
+ interface HttpClient$2 {
946
+ request<TResponse, TData = any>(req: RequestOptionsFactory$2<TResponse, TData>): Promise<HttpResponse$2<TResponse>>;
947
947
  fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
948
948
  }
949
- type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
950
- type HttpResponse<T = any> = {
949
+ type RequestOptionsFactory$2<TResponse = any, TData = any> = (context: any) => RequestOptions$2<TResponse, TData>;
950
+ type HttpResponse$2<T = any> = {
951
951
  data: T;
952
952
  status: number;
953
953
  statusText: string;
954
954
  headers: any;
955
955
  request?: any;
956
956
  };
957
- type RequestOptions<_TResponse = any, Data = any> = {
957
+ type RequestOptions$2<_TResponse = any, Data = any> = {
958
958
  method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
959
959
  url: string;
960
960
  data?: Data;
961
961
  params?: URLSearchParams;
962
- } & APIMetadata;
963
- type APIMetadata = {
962
+ } & APIMetadata$2;
963
+ type APIMetadata$2 = {
964
964
  methodFqn?: string;
965
965
  entityFqdn?: string;
966
966
  packageName?: string;
967
967
  };
968
- type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
969
- type EventDefinition<Payload = unknown, Type extends string = string> = {
968
+ type BuildRESTFunction$2<T extends RESTFunctionDescriptor$2> = T extends RESTFunctionDescriptor$2<infer U> ? U : never;
969
+ type EventDefinition$1<Payload = unknown, Type extends string = string> = {
970
970
  __type: 'event-definition';
971
971
  type: Type;
972
972
  isDomainEvent?: boolean;
973
973
  transformations?: (envelope: unknown) => Payload;
974
974
  __payload: Payload;
975
975
  };
976
- declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
977
- type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
978
- type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
976
+ declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
977
+ type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
978
+ type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
979
979
 
980
980
  declare global {
981
981
  // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
@@ -984,39 +984,39 @@ declare global {
984
984
  }
985
985
  }
986
986
 
987
- declare function createReservation$1(httpClient: HttpClient): (reservation: Reservation, options?: CreateReservationOptions) => Promise<Reservation & {
987
+ declare function createReservation$1(httpClient: HttpClient$2): (reservation: Reservation, options?: CreateReservationOptions) => Promise<Reservation & {
988
988
  status: Status$1;
989
989
  source: Source;
990
990
  paymentStatus: PaymentStatus;
991
991
  }>;
992
- declare function getReservation$1(httpClient: HttpClient): (reservationId: string, options?: GetReservationOptions) => Promise<Reservation & {
992
+ declare function getReservation$1(httpClient: HttpClient$2): (reservationId: string, options?: GetReservationOptions) => Promise<Reservation & {
993
993
  status: Status$1;
994
994
  source: Source;
995
995
  paymentStatus: PaymentStatus;
996
996
  }>;
997
- declare function updateReservation$1(httpClient: HttpClient): (_id: string | null, reservation: UpdateReservation, options?: UpdateReservationOptions) => Promise<Reservation & {
997
+ declare function updateReservation$1(httpClient: HttpClient$2): (_id: string | null, reservation: UpdateReservation, options?: UpdateReservationOptions) => Promise<Reservation & {
998
998
  status: Status$1;
999
999
  source: Source;
1000
1000
  paymentStatus: PaymentStatus;
1001
1001
  }>;
1002
- declare function createHeldReservation$1(httpClient: HttpClient): (reservationDetails: HeldReservationDetails) => Promise<CreateHeldReservationResponse & CreateHeldReservationResponseNonNullableFields>;
1003
- declare function reserveReservation$1(httpClient: HttpClient): (reservationId: string, reservee: Reservee, revision: string | null) => Promise<ReserveReservationResponse & ReserveReservationResponseNonNullableFields>;
1004
- declare function cancelReservation$1(httpClient: HttpClient): (reservationId: string, revision: string | null, options?: CancelReservationOptions) => Promise<CancelReservationResponse & CancelReservationResponseNonNullableFields>;
1005
- declare function listReservations$1(httpClient: HttpClient): (options?: ListReservationsOptions) => Promise<ListReservationsResponse & ListReservationsResponseNonNullableFields>;
1006
- declare function queryReservations$1(httpClient: HttpClient): () => ReservationsQueryBuilder;
1007
- declare function searchReservations$1(httpClient: HttpClient): (search: CursorSearch) => Promise<SearchReservationsResponse & SearchReservationsResponseNonNullableFields>;
1008
- declare const onReservationCreated$1: EventDefinition<ReservationCreatedEnvelope, "wix.table_reservations.v1.reservation_created">;
1002
+ declare function createHeldReservation$1(httpClient: HttpClient$2): (reservationDetails: HeldReservationDetails) => Promise<CreateHeldReservationResponse & CreateHeldReservationResponseNonNullableFields>;
1003
+ declare function reserveReservation$1(httpClient: HttpClient$2): (reservationId: string, reservee: Reservee, revision: string | null) => Promise<ReserveReservationResponse & ReserveReservationResponseNonNullableFields>;
1004
+ declare function cancelReservation$1(httpClient: HttpClient$2): (reservationId: string, revision: string | null, options?: CancelReservationOptions) => Promise<CancelReservationResponse & CancelReservationResponseNonNullableFields>;
1005
+ declare function listReservations$1(httpClient: HttpClient$2): (options?: ListReservationsOptions) => Promise<ListReservationsResponse & ListReservationsResponseNonNullableFields>;
1006
+ declare function queryReservations$1(httpClient: HttpClient$2): () => ReservationsQueryBuilder;
1007
+ declare function searchReservations$1(httpClient: HttpClient$2): (search: CursorSearch) => Promise<SearchReservationsResponse & SearchReservationsResponseNonNullableFields>;
1008
+ declare const onReservationCreated$1: EventDefinition$1<ReservationCreatedEnvelope, "wix.table_reservations.v1.reservation_created">;
1009
1009
 
1010
- declare const createReservation: BuildRESTFunction<typeof createReservation$1>;
1011
- declare const getReservation: BuildRESTFunction<typeof getReservation$1>;
1012
- declare const updateReservation: BuildRESTFunction<typeof updateReservation$1>;
1013
- declare const createHeldReservation: BuildRESTFunction<typeof createHeldReservation$1>;
1014
- declare const reserveReservation: BuildRESTFunction<typeof reserveReservation$1>;
1015
- declare const cancelReservation: BuildRESTFunction<typeof cancelReservation$1>;
1016
- declare const listReservations: BuildRESTFunction<typeof listReservations$1>;
1017
- declare const queryReservations: BuildRESTFunction<typeof queryReservations$1>;
1018
- declare const searchReservations: BuildRESTFunction<typeof searchReservations$1>;
1019
- declare const onReservationCreated: BuildEventDefinition<typeof onReservationCreated$1>;
1010
+ declare const createReservation: BuildRESTFunction$2<typeof createReservation$1>;
1011
+ declare const getReservation: BuildRESTFunction$2<typeof getReservation$1>;
1012
+ declare const updateReservation: BuildRESTFunction$2<typeof updateReservation$1>;
1013
+ declare const createHeldReservation: BuildRESTFunction$2<typeof createHeldReservation$1>;
1014
+ declare const reserveReservation: BuildRESTFunction$2<typeof reserveReservation$1>;
1015
+ declare const cancelReservation: BuildRESTFunction$2<typeof cancelReservation$1>;
1016
+ declare const listReservations: BuildRESTFunction$2<typeof listReservations$1>;
1017
+ declare const queryReservations: BuildRESTFunction$2<typeof queryReservations$1>;
1018
+ declare const searchReservations: BuildRESTFunction$2<typeof searchReservations$1>;
1019
+ declare const onReservationCreated: BuildEventDefinition$1<typeof onReservationCreated$1>;
1020
1020
 
1021
1021
  declare const context$2_cancelReservation: typeof cancelReservation;
1022
1022
  declare const context$2_createHeldReservation: typeof createHeldReservation;
@@ -1791,7 +1791,50 @@ interface ListReservationLocationsOptions {
1791
1791
  fieldsets?: Set[];
1792
1792
  }
1793
1793
 
1794
- declare function getReservationLocation$1(httpClient: HttpClient): (reservationLocationId: string, options?: GetReservationLocationOptions) => Promise<ReservationLocation & {
1794
+ type RESTFunctionDescriptor$1<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$1) => T;
1795
+ interface HttpClient$1 {
1796
+ request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
1797
+ fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
1798
+ }
1799
+ type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
1800
+ type HttpResponse$1<T = any> = {
1801
+ data: T;
1802
+ status: number;
1803
+ statusText: string;
1804
+ headers: any;
1805
+ request?: any;
1806
+ };
1807
+ type RequestOptions$1<_TResponse = any, Data = any> = {
1808
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
1809
+ url: string;
1810
+ data?: Data;
1811
+ params?: URLSearchParams;
1812
+ } & APIMetadata$1;
1813
+ type APIMetadata$1 = {
1814
+ methodFqn?: string;
1815
+ entityFqdn?: string;
1816
+ packageName?: string;
1817
+ };
1818
+ type BuildRESTFunction$1<T extends RESTFunctionDescriptor$1> = T extends RESTFunctionDescriptor$1<infer U> ? U : never;
1819
+ type EventDefinition<Payload = unknown, Type extends string = string> = {
1820
+ __type: 'event-definition';
1821
+ type: Type;
1822
+ isDomainEvent?: boolean;
1823
+ transformations?: (envelope: unknown) => Payload;
1824
+ __payload: Payload;
1825
+ };
1826
+ declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
1827
+ type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
1828
+ type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
1829
+
1830
+ declare global {
1831
+ // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
1832
+ interface SymbolConstructor {
1833
+ readonly observable: symbol;
1834
+ }
1835
+ }
1836
+
1837
+ declare function getReservationLocation$1(httpClient: HttpClient$1): (reservationLocationId: string, options?: GetReservationLocationOptions) => Promise<ReservationLocation & {
1795
1838
  configuration?: {
1796
1839
  onlineReservations?: {
1797
1840
  seatPacing?: {
@@ -1875,7 +1918,7 @@ declare function getReservationLocation$1(httpClient: HttpClient): (reservationL
1875
1918
  } | undefined;
1876
1919
  } | undefined;
1877
1920
  }>;
1878
- declare function updateReservationLocation$1(httpClient: HttpClient): (_id: string | null, reservationLocation: UpdateReservationLocation) => Promise<ReservationLocation & {
1921
+ declare function updateReservationLocation$1(httpClient: HttpClient$1): (_id: string | null, reservationLocation: UpdateReservationLocation) => Promise<ReservationLocation & {
1879
1922
  configuration?: {
1880
1923
  onlineReservations?: {
1881
1924
  seatPacing?: {
@@ -1959,15 +2002,15 @@ declare function updateReservationLocation$1(httpClient: HttpClient): (_id: stri
1959
2002
  } | undefined;
1960
2003
  } | undefined;
1961
2004
  }>;
1962
- declare function queryReservationLocations$1(httpClient: HttpClient): (options?: QueryReservationLocationsOptions) => ReservationLocationsQueryBuilder;
1963
- declare function listReservationLocations$1(httpClient: HttpClient): (options?: ListReservationLocationsOptions) => Promise<ListReservationLocationsResponse & ListReservationLocationsResponseNonNullableFields>;
2005
+ declare function queryReservationLocations$1(httpClient: HttpClient$1): (options?: QueryReservationLocationsOptions) => ReservationLocationsQueryBuilder;
2006
+ declare function listReservationLocations$1(httpClient: HttpClient$1): (options?: ListReservationLocationsOptions) => Promise<ListReservationLocationsResponse & ListReservationLocationsResponseNonNullableFields>;
1964
2007
  declare const onReservationLocationUpdated$1: EventDefinition<ReservationLocationUpdatedEnvelope, "wix.table_reservations.v1.reservation_location_updated">;
1965
2008
  declare const onReservationLocationCreated$1: EventDefinition<ReservationLocationCreatedEnvelope, "wix.table_reservations.v1.reservation_location_created">;
1966
2009
 
1967
- declare const getReservationLocation: BuildRESTFunction<typeof getReservationLocation$1>;
1968
- declare const updateReservationLocation: BuildRESTFunction<typeof updateReservationLocation$1>;
1969
- declare const queryReservationLocations: BuildRESTFunction<typeof queryReservationLocations$1>;
1970
- declare const listReservationLocations: BuildRESTFunction<typeof listReservationLocations$1>;
2010
+ declare const getReservationLocation: BuildRESTFunction$1<typeof getReservationLocation$1>;
2011
+ declare const updateReservationLocation: BuildRESTFunction$1<typeof updateReservationLocation$1>;
2012
+ declare const queryReservationLocations: BuildRESTFunction$1<typeof queryReservationLocations$1>;
2013
+ declare const listReservationLocations: BuildRESTFunction$1<typeof listReservationLocations$1>;
1971
2014
  declare const onReservationLocationUpdated: BuildEventDefinition<typeof onReservationLocationUpdated$1>;
1972
2015
  declare const onReservationLocationCreated: BuildEventDefinition<typeof onReservationLocationCreated$1>;
1973
2016
 
@@ -2025,6 +2068,39 @@ interface GetTimeSlotsOptions {
2025
2068
  slotsAfter?: number | null;
2026
2069
  }
2027
2070
 
2071
+ type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
2072
+ interface HttpClient {
2073
+ request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
2074
+ fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
2075
+ }
2076
+ type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
2077
+ type HttpResponse<T = any> = {
2078
+ data: T;
2079
+ status: number;
2080
+ statusText: string;
2081
+ headers: any;
2082
+ request?: any;
2083
+ };
2084
+ type RequestOptions<_TResponse = any, Data = any> = {
2085
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
2086
+ url: string;
2087
+ data?: Data;
2088
+ params?: URLSearchParams;
2089
+ } & APIMetadata;
2090
+ type APIMetadata = {
2091
+ methodFqn?: string;
2092
+ entityFqdn?: string;
2093
+ packageName?: string;
2094
+ };
2095
+ type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
2096
+
2097
+ declare global {
2098
+ // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
2099
+ interface SymbolConstructor {
2100
+ readonly observable: symbol;
2101
+ }
2102
+ }
2103
+
2028
2104
  declare function getTimeSlots$1(httpClient: HttpClient): (reservationLocationId: string, date: Date, partySize: number | null, options?: GetTimeSlotsOptions) => Promise<GetTimeSlotsResponse & GetTimeSlotsResponseNonNullableFields>;
2029
2105
 
2030
2106
  declare const getTimeSlots: BuildRESTFunction<typeof getTimeSlots$1>;
@@ -1298,37 +1298,37 @@ interface ReservationsQueryBuilder {
1298
1298
  find: () => Promise<ReservationsQueryResult>;
1299
1299
  }
1300
1300
 
1301
- interface HttpClient {
1302
- request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
1301
+ interface HttpClient$2 {
1302
+ request<TResponse, TData = any>(req: RequestOptionsFactory$2<TResponse, TData>): Promise<HttpResponse$2<TResponse>>;
1303
1303
  fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
1304
1304
  }
1305
- type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
1306
- type HttpResponse<T = any> = {
1305
+ type RequestOptionsFactory$2<TResponse = any, TData = any> = (context: any) => RequestOptions$2<TResponse, TData>;
1306
+ type HttpResponse$2<T = any> = {
1307
1307
  data: T;
1308
1308
  status: number;
1309
1309
  statusText: string;
1310
1310
  headers: any;
1311
1311
  request?: any;
1312
1312
  };
1313
- type RequestOptions<_TResponse = any, Data = any> = {
1313
+ type RequestOptions$2<_TResponse = any, Data = any> = {
1314
1314
  method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
1315
1315
  url: string;
1316
1316
  data?: Data;
1317
1317
  params?: URLSearchParams;
1318
- } & APIMetadata;
1319
- type APIMetadata = {
1318
+ } & APIMetadata$2;
1319
+ type APIMetadata$2 = {
1320
1320
  methodFqn?: string;
1321
1321
  entityFqdn?: string;
1322
1322
  packageName?: string;
1323
1323
  };
1324
- type EventDefinition<Payload = unknown, Type extends string = string> = {
1324
+ type EventDefinition$1<Payload = unknown, Type extends string = string> = {
1325
1325
  __type: 'event-definition';
1326
1326
  type: Type;
1327
1327
  isDomainEvent?: boolean;
1328
1328
  transformations?: (envelope: unknown) => Payload;
1329
1329
  __payload: Payload;
1330
1330
  };
1331
- declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
1331
+ declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
1332
1332
 
1333
1333
  declare global {
1334
1334
  // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
@@ -1340,28 +1340,28 @@ declare global {
1340
1340
  declare const __metadata$2: {
1341
1341
  PACKAGE_NAME: string;
1342
1342
  };
1343
- declare function createReservation(httpClient: HttpClient): (reservation: Reservation, options?: CreateReservationOptions) => Promise<Reservation & {
1343
+ declare function createReservation(httpClient: HttpClient$2): (reservation: Reservation, options?: CreateReservationOptions) => Promise<Reservation & {
1344
1344
  status: Status$1;
1345
1345
  source: Source;
1346
1346
  paymentStatus: PaymentStatus;
1347
1347
  }>;
1348
- declare function getReservation(httpClient: HttpClient): (reservationId: string, options?: GetReservationOptions) => Promise<Reservation & {
1348
+ declare function getReservation(httpClient: HttpClient$2): (reservationId: string, options?: GetReservationOptions) => Promise<Reservation & {
1349
1349
  status: Status$1;
1350
1350
  source: Source;
1351
1351
  paymentStatus: PaymentStatus;
1352
1352
  }>;
1353
- declare function updateReservation(httpClient: HttpClient): (_id: string | null, reservation: UpdateReservation, options?: UpdateReservationOptions) => Promise<Reservation & {
1353
+ declare function updateReservation(httpClient: HttpClient$2): (_id: string | null, reservation: UpdateReservation, options?: UpdateReservationOptions) => Promise<Reservation & {
1354
1354
  status: Status$1;
1355
1355
  source: Source;
1356
1356
  paymentStatus: PaymentStatus;
1357
1357
  }>;
1358
- declare function createHeldReservation(httpClient: HttpClient): (reservationDetails: HeldReservationDetails) => Promise<CreateHeldReservationResponse & CreateHeldReservationResponseNonNullableFields>;
1359
- declare function reserveReservation(httpClient: HttpClient): (reservationId: string, reservee: Reservee, revision: string | null) => Promise<ReserveReservationResponse & ReserveReservationResponseNonNullableFields>;
1360
- declare function cancelReservation(httpClient: HttpClient): (reservationId: string, revision: string | null, options?: CancelReservationOptions) => Promise<CancelReservationResponse & CancelReservationResponseNonNullableFields>;
1361
- declare function listReservations(httpClient: HttpClient): (options?: ListReservationsOptions) => Promise<ListReservationsResponse & ListReservationsResponseNonNullableFields>;
1362
- declare function queryReservations(httpClient: HttpClient): () => ReservationsQueryBuilder;
1363
- declare function searchReservations(httpClient: HttpClient): (search: CursorSearch) => Promise<SearchReservationsResponse & SearchReservationsResponseNonNullableFields>;
1364
- declare const onReservationCreated: EventDefinition<ReservationCreatedEnvelope, "wix.table_reservations.v1.reservation_created">;
1358
+ declare function createHeldReservation(httpClient: HttpClient$2): (reservationDetails: HeldReservationDetails) => Promise<CreateHeldReservationResponse & CreateHeldReservationResponseNonNullableFields>;
1359
+ declare function reserveReservation(httpClient: HttpClient$2): (reservationId: string, reservee: Reservee, revision: string | null) => Promise<ReserveReservationResponse & ReserveReservationResponseNonNullableFields>;
1360
+ declare function cancelReservation(httpClient: HttpClient$2): (reservationId: string, revision: string | null, options?: CancelReservationOptions) => Promise<CancelReservationResponse & CancelReservationResponseNonNullableFields>;
1361
+ declare function listReservations(httpClient: HttpClient$2): (options?: ListReservationsOptions) => Promise<ListReservationsResponse & ListReservationsResponseNonNullableFields>;
1362
+ declare function queryReservations(httpClient: HttpClient$2): () => ReservationsQueryBuilder;
1363
+ declare function searchReservations(httpClient: HttpClient$2): (search: CursorSearch) => Promise<SearchReservationsResponse & SearchReservationsResponseNonNullableFields>;
1364
+ declare const onReservationCreated: EventDefinition$1<ReservationCreatedEnvelope, "wix.table_reservations.v1.reservation_created">;
1365
1365
 
1366
1366
  type index_d$2_Aggregation = Aggregation;
1367
1367
  type index_d$2_AggregationData = AggregationData;
@@ -3831,10 +3831,49 @@ interface ListReservationLocationsOptions {
3831
3831
  fieldsets?: Set[];
3832
3832
  }
3833
3833
 
3834
+ interface HttpClient$1 {
3835
+ request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
3836
+ fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
3837
+ }
3838
+ type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
3839
+ type HttpResponse$1<T = any> = {
3840
+ data: T;
3841
+ status: number;
3842
+ statusText: string;
3843
+ headers: any;
3844
+ request?: any;
3845
+ };
3846
+ type RequestOptions$1<_TResponse = any, Data = any> = {
3847
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
3848
+ url: string;
3849
+ data?: Data;
3850
+ params?: URLSearchParams;
3851
+ } & APIMetadata$1;
3852
+ type APIMetadata$1 = {
3853
+ methodFqn?: string;
3854
+ entityFqdn?: string;
3855
+ packageName?: string;
3856
+ };
3857
+ type EventDefinition<Payload = unknown, Type extends string = string> = {
3858
+ __type: 'event-definition';
3859
+ type: Type;
3860
+ isDomainEvent?: boolean;
3861
+ transformations?: (envelope: unknown) => Payload;
3862
+ __payload: Payload;
3863
+ };
3864
+ declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
3865
+
3866
+ declare global {
3867
+ // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
3868
+ interface SymbolConstructor {
3869
+ readonly observable: symbol;
3870
+ }
3871
+ }
3872
+
3834
3873
  declare const __metadata$1: {
3835
3874
  PACKAGE_NAME: string;
3836
3875
  };
3837
- declare function getReservationLocation(httpClient: HttpClient): (reservationLocationId: string, options?: GetReservationLocationOptions) => Promise<ReservationLocation & {
3876
+ declare function getReservationLocation(httpClient: HttpClient$1): (reservationLocationId: string, options?: GetReservationLocationOptions) => Promise<ReservationLocation & {
3838
3877
  configuration?: {
3839
3878
  onlineReservations?: {
3840
3879
  seatPacing?: {
@@ -3918,7 +3957,7 @@ declare function getReservationLocation(httpClient: HttpClient): (reservationLoc
3918
3957
  } | undefined;
3919
3958
  } | undefined;
3920
3959
  }>;
3921
- declare function updateReservationLocation(httpClient: HttpClient): (_id: string | null, reservationLocation: UpdateReservationLocation) => Promise<ReservationLocation & {
3960
+ declare function updateReservationLocation(httpClient: HttpClient$1): (_id: string | null, reservationLocation: UpdateReservationLocation) => Promise<ReservationLocation & {
3922
3961
  configuration?: {
3923
3962
  onlineReservations?: {
3924
3963
  seatPacing?: {
@@ -4002,8 +4041,8 @@ declare function updateReservationLocation(httpClient: HttpClient): (_id: string
4002
4041
  } | undefined;
4003
4042
  } | undefined;
4004
4043
  }>;
4005
- declare function queryReservationLocations(httpClient: HttpClient): (options?: QueryReservationLocationsOptions) => ReservationLocationsQueryBuilder;
4006
- declare function listReservationLocations(httpClient: HttpClient): (options?: ListReservationLocationsOptions) => Promise<ListReservationLocationsResponse & ListReservationLocationsResponseNonNullableFields>;
4044
+ declare function queryReservationLocations(httpClient: HttpClient$1): (options?: QueryReservationLocationsOptions) => ReservationLocationsQueryBuilder;
4045
+ declare function listReservationLocations(httpClient: HttpClient$1): (options?: ListReservationLocationsOptions) => Promise<ListReservationLocationsResponse & ListReservationLocationsResponseNonNullableFields>;
4007
4046
  declare const onReservationLocationUpdated: EventDefinition<ReservationLocationUpdatedEnvelope, "wix.table_reservations.v1.reservation_location_updated">;
4008
4047
  declare const onReservationLocationCreated: EventDefinition<ReservationLocationCreatedEnvelope, "wix.table_reservations.v1.reservation_location_created">;
4009
4048
 
@@ -4355,6 +4394,37 @@ interface GetTimeSlotsOptions {
4355
4394
  slotsAfter?: number | null;
4356
4395
  }
4357
4396
 
4397
+ interface HttpClient {
4398
+ request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
4399
+ fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
4400
+ }
4401
+ type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
4402
+ type HttpResponse<T = any> = {
4403
+ data: T;
4404
+ status: number;
4405
+ statusText: string;
4406
+ headers: any;
4407
+ request?: any;
4408
+ };
4409
+ type RequestOptions<_TResponse = any, Data = any> = {
4410
+ method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
4411
+ url: string;
4412
+ data?: Data;
4413
+ params?: URLSearchParams;
4414
+ } & APIMetadata;
4415
+ type APIMetadata = {
4416
+ methodFqn?: string;
4417
+ entityFqdn?: string;
4418
+ packageName?: string;
4419
+ };
4420
+
4421
+ declare global {
4422
+ // eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
4423
+ interface SymbolConstructor {
4424
+ readonly observable: symbol;
4425
+ }
4426
+ }
4427
+
4358
4428
  declare const __metadata: {
4359
4429
  PACKAGE_NAME: string;
4360
4430
  };