@wix/auto_sdk_bookings_multi-service-availability-time-slots 1.0.155 → 1.0.157
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/build/cjs/index.d.ts +52 -123
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +311 -551
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +134 -207
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +52 -123
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +311 -551
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +134 -207
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +52 -123
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +311 -551
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +134 -207
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +52 -123
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +311 -551
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +134 -207
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +3 -2
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../../../meta.ts","../../../src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.http.ts","../../../src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.meta.ts"],"sourcesContent":["export * from './src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.meta.js';\n","import { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n 'manage._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n ],\n 'www._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n _: [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'editor.wixapps.net': [\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME =\n '@wix/auto_sdk_bookings_multi-service-availability-time-slots';\n\n/**\n * Retrieves a list of multiService `TimeSlot`s that match the provided filters.\n *\n * <blockquote class=\"important\">\n * <p><strong>Important:</strong><br/>\n * Currently supported only for services of type <code class=\"grey-background\">APPOINTMENT</code>.</p>\n * </blockquote>\n *\n * The request body __must__ include either:\n * + All of the following filters: `service`.`serviceId`, `fromLocalDate`, `toLocalDate`, `location`, and `timeZone`. You may add additional filters as you wish.\n * + A `cursorPaging` with a valid `cursor` from previous response.\n *\n *\n * Each [TimeSlot](https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/availability-time-slots/time-slot-object) in response\n * represents the availability of the given sequence of services in a specific order, location, and within a given range of time.\n *\n * Each `TimeSlot`.`NestedTimeSlot` represents a single service from the given list. The order of the `NestedTimeSlots` is the same as the order\n * of the given services in request.\n * The first `NestedTimeSlot` has `localStartDate` within the given `fromLocalDate` and `toLocalDate` exclusive,\n * and each following `NestedTimeSlot` has a `localStartDate` that equals to the previous `NestedTimeSlot`'s `localEndDate`.\n *\n * By default,\n * the response contains at most 1000 results.\n * If there are more than 1000 results, we return a `cursorPagingMetadata` with\n * a cursor for the next page of results, regardless of whether a `cursorPaging`\n * was provided in request.\n *\n * > __Notes:__\n * > + All nested time slots share the same location.\n * > + You can pass up to 8 services in request.\n *\n * ### AvailableResources in response:\n * The `TimeSlot`.`NestedTimeSlot`'s `AvailableResources` contains information about the resources that are available to provide the service\n * within the `NestedTimeSlot` range of time. Each `AvailableResources` contains information about available resources of the same type.\n *\n * <blockquote class=\"important\">\n * <p><strong>Important:</strong><br/>\n * By default,\n * if you don't specify <code class=\"grey-background\">service</code>.<code class=\"grey-background\">includeResourceTypeIds</code>\n * or <code class=\"grey-background\">service</code>.<code class=\"grey-background\">resourceIds</code> filters in request,\n * we return TimeSlots with <code class=\"grey-background\">NestedTimeSlot</code>s with an empty <code class=\"grey-background\">AvailableResources</code>.\n * <br/><strong>Note:</strong><br/> Not specifying resources filters can be handy in case you want to avoid large response in flows that only\n * interested of whether the time slots are available. [Finding the next available slot within the next 3 months](https://bo.wix.com/wix-docs/rest/all-apis/service-availability/multi-service-availability-time-slots/sample-flows?localViewerId=inbari#all-apis_service-availability_multi-service-availability-time-slots_sample-flows_find-the-first-date-within-the-next-3-months-that-all-selected-services-are-available-for)\n * is an example for such flow.\n * </p>\n * </blockquote>\n *\n *\n * If you wish to get a list of available resources for a `TimeSlot`.`NestedTimeSlot` you should either:\n * + provide `service`.`resourceIds` in request.\n * + provide `service`.`includeResourceTypeIds` in request.\n *\n * __Notes:__\n * + In both cases the returned `TimeSlot`.`NestedTimeSlot` contains __up__ to 10 `AvailableResources` that match the provided filters. Each `AvailableResources` contains __up__ to 10 available `resources` of the same type that match the provided filters.\n * + If an `AvailableResources` has more available resources which are not listed within it, we return `AvailableResources`.`hasMoreAvailableResources` as true.\n * + If you wish to get the full available resources list for all `NestedTimeSlot` of a specific `TimeSlot`, you should call [GetMultiServiceAvailabilityTimeSlot](https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/get-multi-service-availability-time-slot).\n *\n *\n * ### Availability VS Bookability\n * An `available` time slot is not necessarily `bookable`.\n * The `bookable` field of a `TimeSlot` indicates whether the customer can book all of the of the services within the given time slot,\n * at a specific period of time.\n * Read more about [Availability VS Bookability](https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/introduction#all-apis_wix-service-availability_multi-service-availability-time-slots_introduction_availability-vs-bookability).\n *\n * By default,\n * + The response does not contains `unavailable` TimeSlots.For example, if there are no available resources to provide one of the services from `2024-01-30T14:30:00` to `2024-01-30T15:30:00`, we don't return TimeSlots with `NestedTimeSlot`.`localStartDate` within this range for this service.\n * + The response contains both `bookable` and `un-bookable` TimeSlots.For example, if one of the services has a booking policy which enforces booking the service up to 10 minutes before the session starts, we return TimeSlots with the violating `NestedTimeSlot`.`localStartDate`, with `bookable` as `false`. If you want to list only __bookable__ TimeSlots you should pass `bookable` as `true`.\n * + If booking one of the `NestedTimeSlot`s violates one of the corresponding service's booking policies, the `TimeSlot` returns with `bookable` as false. There is no indication which service's policy was violated.\n *\n * <blockquote class=\"important\">\n * <p><strong>Important:</strong>\n * Because of DST, there are edge cases where certain times either do not exist or exist twice for a local time zone.\n * Read more about <a href=\"https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/introduction#all-apis_wix-service-availability_multi-service-availability-time-slots_introduction_daylight-saving-time-dst-handling\">DST Handling</a></p>\n * </blockquote>\n *\n * ### ListAvailabilityTimeSlots runs with the following defaults:\n * + `localStartDate` is sorted in `ASC` order.\n * + `cursorPaging`.`limit` is `1000`.\n */\nexport function listMultiServiceAvailabilityTimeSlots(\n payload: object\n): RequestOptionsFactory<any> {\n function __listMultiServiceAvailabilityTimeSlots({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [{ path: 'bookingPolicyViolations.earliestBookingDate' }],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.bookings.availability.v2.time_slot',\n method: 'POST' as any,\n methodFqn:\n 'com.wixpress.bookings.availability.v2.MultiServiceAvailabilityTimeSlots.ListMultiServiceAvailabilityTimeSlots',\n packageName: PACKAGE_NAME,\n url: resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n {\n protoPath: '/v2/multi-service-time-slots',\n data: serializedData,\n host,\n }\n ),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'timeSlots.bookingPolicyViolations.earliestBookingDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listMultiServiceAvailabilityTimeSlots;\n}\n\n/**\n * Retrieves an available multiService `TimeSlot` that match the provided filters.\n *\n * Throws `SlotNotFound` if there is no such available time slot.\n *\n * <blockquote class=\"important\">\n * <p><strong>Important:</strong><br/>\n * Currently supported only for services of type <code class=\"grey-background\">APPOINTMENT</code>.</p>\n * </blockquote>\n *\n * By default,\n * if you don't provide a `service`.`includeResourceTypeIds` or `service`.`resourceIds` in request,\n * we return for each `TimeSlot`.`NestedTimeSlot` all `AvailableResources` with all `AvailableResources`.`resources` which are available to provide\n * the corresponding service within the time slot.\n *\n * If you specify `service`.`includeResourceTypeIds` or `service`.`resourceIds` in request,\n * the returned `TimeSlot`.`NestedTimeSlot` for this service will contain only `AvailableResources` with at least one available resource\n * which match the given resources filters,\n * each contains all available resources out of those requested.\n *\n * + Notes:\n * + All nested time slots share the same location.\n * + You can pass up to 8 services.\n *\n * <blockquote class=\"tip\">\n * <p><strong>Tip:</strong><br/>\n * Use this API in order to get the availability of a specific <code class=\"grey-background\">TimeSlot</code> out of those returned from <code class=\"grey-background\">ListMultiServiceAvailabilityTimeSlots</code> API.</p>\n * </blockquote>\n */\nexport function getMultiServiceAvailabilityTimeSlot(\n payload: object\n): RequestOptionsFactory<any> {\n function __getMultiServiceAvailabilityTimeSlot({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.bookings.availability.v2.time_slot',\n method: 'POST' as any,\n methodFqn:\n 'com.wixpress.bookings.availability.v2.MultiServiceAvailabilityTimeSlots.GetMultiServiceAvailabilityTimeSlot',\n packageName: PACKAGE_NAME,\n url: resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n { protoPath: '/v2/multi-service-time-slots/get', data: payload, host }\n ),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'timeSlot.bookingPolicyViolations.earliestBookingDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getMultiServiceAvailabilityTimeSlot;\n}\n","import * as ambassadorWixBookingsAvailabilityV2TimeSlot from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.http.js';\nimport * as ambassadorWixBookingsAvailabilityV2TimeSlotTypes from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.types.js';\nimport * as ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.universal.js';\n\nexport type __PublicMethodMetaInfo<\n K = string,\n M = unknown,\n T = unknown,\n S = unknown,\n Q = unknown,\n R = unknown\n> = {\n getUrl: (context: any) => string;\n httpMethod: K;\n path: string;\n pathParams: M;\n __requestType: T;\n __originalRequestType: S;\n __responseType: Q;\n __originalResponseType: R;\n};\n\nexport function listMultiServiceAvailabilityTimeSlots(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.ListMultiServiceAvailabilityTimeSlotsRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.ListMultiServiceAvailabilityTimeSlotsRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.ListMultiServiceAvailabilityTimeSlotsResponse,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.ListMultiServiceAvailabilityTimeSlotsResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixBookingsAvailabilityV2TimeSlot.listMultiServiceAvailabilityTimeSlots(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v2/multi-service-time-slots',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n\nexport function getMultiServiceAvailabilityTimeSlot(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.GetMultiServiceAvailabilityTimeSlotRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.GetMultiServiceAvailabilityTimeSlotRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.GetMultiServiceAvailabilityTimeSlotResponse,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.GetMultiServiceAvailabilityTimeSlotResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixBookingsAvailabilityV2TimeSlot.getMultiServiceAvailabilityTimeSlot(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v2/multi-service-time-slots/get',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,6CAAAA;AAAA,EAAA,6CA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A,IACA,YAAY;AAAA,IACZ,MAAM;AAAA,IACN,YAAY,CAAC;AAAA,IACb,eAAe;AAAA,IACf,uBAAuB;AAAA,IACvB,gBAAgB;AAAA,IAChB,wBAAwB;AAAA,EAC1B;AACF;","names":["getMultiServiceAvailabilityTimeSlot","listMultiServiceAvailabilityTimeSlots","import_timestamp","payload","listMultiServiceAvailabilityTimeSlots","getMultiServiceAvailabilityTimeSlot"]}
|
1
|
+
{"version":3,"sources":["../../../meta.ts","../../../src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.http.ts","../../../src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.meta.ts"],"sourcesContent":["export * from './src/bookings-availability-v2-time-slot-multi-service-availability-time-slots.meta.js';\n","import { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n 'manage._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n ],\n 'www._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n ],\n _: [\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/service-availability/v2/multi-service-time-slots',\n destPath: '/v2/multi-service-time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots',\n destPath: '/v2/time-slots',\n },\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n 'editor.wixapps.net': [\n {\n srcPath: '/_api/service-availability/v2/time-slots/event',\n destPath: '/v2/time-slots/event',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME =\n '@wix/auto_sdk_bookings_multi-service-availability-time-slots';\n\n/**\n * Retrieves a list of multi-service time slots that match the provided filters.\n *\n *\n * ## Required filters\n *\n * You must supply either:\n * - `services.serviceId`, `fromLocalDate`, `toLocalDate`, `location`, and `timeZone` (additional filters are optional), or\n * - `cursorPaging.cursor` returned from a previous response.\n *\n * Each returned `timeSlot` acts as a container spanning the entire service sequence, with nested time slots providing individual service details.\n *\n * ## Defaults\n *\n * - Results are sorted by `localStartDate` in ascending order.\n * - `cursorPaging.limit` is `1000`.\n * - The response contains both bookable and un-bookable slots.\n *\n * ## Service type limitations\n *\n * Only appointment-type services are supported.\n *\n * To retrieve appointment availability for a single service, call List Availability Time Slots ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/availability/availability-time-slots/list-availability-time-slots) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/availability/availability-time-slots/list-availability-time-slots)).\n */\nexport function listMultiServiceAvailabilityTimeSlots(\n payload: object\n): RequestOptionsFactory<any> {\n function __listMultiServiceAvailabilityTimeSlots({ host }: any) {\n const serializedData = transformPaths(payload, [\n {\n transformFn: transformSDKTimestampToRESTTimestamp,\n paths: [{ path: 'bookingPolicyViolations.earliestBookingDate' }],\n },\n ]);\n const metadata = {\n entityFqdn: 'wix.bookings.availability.v2.time_slot',\n method: 'POST' as any,\n methodFqn:\n 'com.wixpress.bookings.availability.v2.MultiServiceAvailabilityTimeSlots.ListMultiServiceAvailabilityTimeSlots',\n packageName: PACKAGE_NAME,\n url: resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n {\n protoPath: '/v2/multi-service-time-slots',\n data: serializedData,\n host,\n }\n ),\n data: serializedData,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'timeSlots.bookingPolicyViolations.earliestBookingDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __listMultiServiceAvailabilityTimeSlots;\n}\n\n/**\n * Retrieves a multi-service time slot that matches the specified filters.\n *\n *\n * Call this method after finding a suitable slot with List Multi-Service Availability Time Slots to obtain full capacity, resource, and booking-policy details.\n *\n * The returned time slot acts as a container spanning the entire service sequence, with nested time slots providing detailed information for each individual service.\n *\n * ## Defaults\n *\n * - Returns all available resources unless you filter by `services.resourceIds` or `services.includeResourceTypeIds`.\n * - Includes full booking-status and capacity details.\n *\n * ## Service type limitations\n *\n * Only appointment-type services are supported.\n *\n * To retrieve appointment availability for a single service, call List Availability Time Slots ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/availability/availability-time-slots/list-availability-time-slots) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/availability/availability-time-slots/list-availability-time-slots)).\n */\nexport function getMultiServiceAvailabilityTimeSlot(\n payload: object\n): RequestOptionsFactory<any> {\n function __getMultiServiceAvailabilityTimeSlot({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.bookings.availability.v2.time_slot',\n method: 'POST' as any,\n methodFqn:\n 'com.wixpress.bookings.availability.v2.MultiServiceAvailabilityTimeSlots.GetMultiServiceAvailabilityTimeSlot',\n packageName: PACKAGE_NAME,\n url: resolveComWixpressBookingsAvailabilityV2MultiServiceAvailabilityTimeSlotsUrl(\n { protoPath: '/v2/multi-service-time-slots/get', data: payload, host }\n ),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'timeSlot.bookingPolicyViolations.earliestBookingDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getMultiServiceAvailabilityTimeSlot;\n}\n","import * as ambassadorWixBookingsAvailabilityV2TimeSlot from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.http.js';\nimport * as ambassadorWixBookingsAvailabilityV2TimeSlotTypes from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.types.js';\nimport * as ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes from './bookings-availability-v2-time-slot-multi-service-availability-time-slots.universal.js';\n\nexport type __PublicMethodMetaInfo<\n K = string,\n M = unknown,\n T = unknown,\n S = unknown,\n Q = unknown,\n R = unknown\n> = {\n getUrl: (context: any) => string;\n httpMethod: K;\n path: string;\n pathParams: M;\n __requestType: T;\n __originalRequestType: S;\n __responseType: Q;\n __originalResponseType: R;\n};\n\nexport function listMultiServiceAvailabilityTimeSlots(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.ListMultiServiceAvailabilityTimeSlotsRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.ListMultiServiceAvailabilityTimeSlotsRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.ListMultiServiceAvailabilityTimeSlotsResponse,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.ListMultiServiceAvailabilityTimeSlotsResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixBookingsAvailabilityV2TimeSlot.listMultiServiceAvailabilityTimeSlots(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v2/multi-service-time-slots',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n\nexport function getMultiServiceAvailabilityTimeSlot(): __PublicMethodMetaInfo<\n 'POST',\n {},\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.GetMultiServiceAvailabilityTimeSlotRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.GetMultiServiceAvailabilityTimeSlotRequest,\n ambassadorWixBookingsAvailabilityV2TimeSlotUniversalTypes.GetMultiServiceAvailabilityTimeSlotResponse,\n ambassadorWixBookingsAvailabilityV2TimeSlotTypes.GetMultiServiceAvailabilityTimeSlotResponse\n> {\n const payload = {} as any;\n\n const getRequestOptions =\n ambassadorWixBookingsAvailabilityV2TimeSlot.getMultiServiceAvailabilityTimeSlot(\n payload\n );\n\n const getUrl = (context: any): string => {\n const { url } = getRequestOptions(context);\n return url!;\n };\n\n return {\n getUrl,\n httpMethod: 'POST',\n path: '/v2/multi-service-time-slots/get',\n pathParams: {},\n __requestType: null as any,\n __originalRequestType: null as any,\n __responseType: null as any,\n __originalResponseType: null as any,\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,6CAAAA;AAAA,EAAA,6CAAAC;AAAA;AAAA;;;ACAA,uBAAqD;AACrD,IAAAC,oBAAqD;AACrD,6BAA+B;AAC/B,0BAA2B;AAI3B,SAAS,6EACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,MACA;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAA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;AAEA,SAAO;AACT;;;AC5OO,SAASC,yCAOd;AACA,QAAM,UAAU,CAAC;AAEjB,QAAM,oBACwC;AAAA,IAC1C;AAAA,EACF;AAEF,QAAM,SAAS,CAAC,YAAyB;AACvC,UAAM,EAAE,IAAI,IAAI,kBAAkB,OAAO;AACzC,WAAO;AAAA,EACT;AAEA,SAAO;AAAA,IACL;AAAA,IACA,YAAY;AAAA,IACZ,MAAM;AAAA,IACN,YAAY,CAAC;AAAA,IACb,eAAe;AAAA,IACf,uBAAuB;AAAA,IACvB,gBAAgB;AAAA,IAChB,wBAAwB;AAAA,EAC1B;AACF;AAEO,SAASC,uCAOd;AACA,QAAM,UAAU,CAAC;AAEjB,QAAM,oBACwC;AAAA,IAC1C;AAAA,EACF;AAEF,QAAM,SAAS,CAAC,YAAyB;AACvC,UAAM,EAAE,IAAI,IAAI,kBAAkB,OAAO;AACzC,WAAO;AAAA,EACT;AAEA,SAAO;AAAA,IACL;AAAA,IACA,YAAY;AAAA,IACZ,MAAM;AAAA,IACN,YAAY,CAAC;AAAA,IACb,eAAe;AAAA,IACf,uBAAuB;AAAA,IACvB,gBAAgB;AAAA,IAChB,wBAAwB;AAAA,EAC1B;AACF;","names":["getMultiServiceAvailabilityTimeSlot","listMultiServiceAvailabilityTimeSlots","import_timestamp","payload","listMultiServiceAvailabilityTimeSlots","getMultiServiceAvailabilityTimeSlot"]}
|
@@ -6,83 +6,28 @@ type TimeSlotNonNullablePaths = `location.locationType` | `availableResources` |
|
|
6
6
|
declare function listMultiServiceAvailabilityTimeSlots$1(httpClient: HttpClient): ListMultiServiceAvailabilityTimeSlotsSignature;
|
7
7
|
interface ListMultiServiceAvailabilityTimeSlotsSignature {
|
8
8
|
/**
|
9
|
-
* Retrieves a list of
|
10
|
-
*
|
11
|
-
*
|
12
|
-
*
|
13
|
-
*
|
14
|
-
*
|
15
|
-
*
|
16
|
-
*
|
17
|
-
*
|
18
|
-
*
|
19
|
-
*
|
20
|
-
*
|
21
|
-
*
|
22
|
-
*
|
23
|
-
*
|
24
|
-
*
|
25
|
-
*
|
26
|
-
*
|
27
|
-
*
|
28
|
-
*
|
29
|
-
*
|
30
|
-
*
|
31
|
-
* If there are more than 1000 results, we return a `cursorPagingMetadata` with
|
32
|
-
* a cursor for the next page of results, regardless of whether a `cursorPaging`
|
33
|
-
* was provided in request.
|
34
|
-
*
|
35
|
-
* > __Notes:__
|
36
|
-
* > + All nested time slots share the same location.
|
37
|
-
* > + You can pass up to 8 services in request.
|
38
|
-
*
|
39
|
-
* ### AvailableResources in response:
|
40
|
-
* The `TimeSlot`.`NestedTimeSlot`'s `AvailableResources` contains information about the resources that are available to provide the service
|
41
|
-
* within the `NestedTimeSlot` range of time. Each `AvailableResources` contains information about available resources of the same type.
|
42
|
-
*
|
43
|
-
* <blockquote class="important">
|
44
|
-
* <p><strong>Important:</strong><br/>
|
45
|
-
* By default,
|
46
|
-
* if you don't specify <code class="grey-background">service</code>.<code class="grey-background">includeResourceTypeIds</code>
|
47
|
-
* or <code class="grey-background">service</code>.<code class="grey-background">resourceIds</code> filters in request,
|
48
|
-
* we return TimeSlots with <code class="grey-background">NestedTimeSlot</code>s with an empty <code class="grey-background">AvailableResources</code>.
|
49
|
-
* <br/><strong>Note:</strong><br/> Not specifying resources filters can be handy in case you want to avoid large response in flows that only
|
50
|
-
* interested of whether the time slots are available. [Finding the next available slot within the next 3 months](https://bo.wix.com/wix-docs/rest/all-apis/service-availability/multi-service-availability-time-slots/sample-flows?localViewerId=inbari#all-apis_service-availability_multi-service-availability-time-slots_sample-flows_find-the-first-date-within-the-next-3-months-that-all-selected-services-are-available-for)
|
51
|
-
* is an example for such flow.
|
52
|
-
* </p>
|
53
|
-
* </blockquote>
|
54
|
-
*
|
55
|
-
*
|
56
|
-
* If you wish to get a list of available resources for a `TimeSlot`.`NestedTimeSlot` you should either:
|
57
|
-
* + provide `service`.`resourceIds` in request.
|
58
|
-
* + provide `service`.`includeResourceTypeIds` in request.
|
59
|
-
*
|
60
|
-
* __Notes:__
|
61
|
-
* + In both cases the returned `TimeSlot`.`NestedTimeSlot` contains __up__ to 10 `AvailableResources` that match the provided filters. Each `AvailableResources` contains __up__ to 10 available `resources` of the same type that match the provided filters.
|
62
|
-
* + If an `AvailableResources` has more available resources which are not listed within it, we return `AvailableResources`.`hasMoreAvailableResources` as true.
|
63
|
-
* + If you wish to get the full available resources list for all `NestedTimeSlot` of a specific `TimeSlot`, you should call [GetMultiServiceAvailabilityTimeSlot](https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/get-multi-service-availability-time-slot).
|
64
|
-
*
|
65
|
-
*
|
66
|
-
* ### Availability VS Bookability
|
67
|
-
* An `available` time slot is not necessarily `bookable`.
|
68
|
-
* The `bookable` field of a `TimeSlot` indicates whether the customer can book all of the of the services within the given time slot,
|
69
|
-
* at a specific period of time.
|
70
|
-
* Read more about [Availability VS Bookability](https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/introduction#all-apis_wix-service-availability_multi-service-availability-time-slots_introduction_availability-vs-bookability).
|
71
|
-
*
|
72
|
-
* By default,
|
73
|
-
* + The response does not contains `unavailable` TimeSlots.For example, if there are no available resources to provide one of the services from `2024-01-30T14:30:00` to `2024-01-30T15:30:00`, we don't return TimeSlots with `NestedTimeSlot`.`localStartDate` within this range for this service.
|
74
|
-
* + The response contains both `bookable` and `un-bookable` TimeSlots.For example, if one of the services has a booking policy which enforces booking the service up to 10 minutes before the session starts, we return TimeSlots with the violating `NestedTimeSlot`.`localStartDate`, with `bookable` as `false`. If you want to list only __bookable__ TimeSlots you should pass `bookable` as `true`.
|
75
|
-
* + If booking one of the `NestedTimeSlot`s violates one of the corresponding service's booking policies, the `TimeSlot` returns with `bookable` as false. There is no indication which service's policy was violated.
|
76
|
-
*
|
77
|
-
* <blockquote class="important">
|
78
|
-
* <p><strong>Important:</strong>
|
79
|
-
* Because of DST, there are edge cases where certain times either do not exist or exist twice for a local time zone.
|
80
|
-
* Read more about <a href="https://bo.wix.com/wix-docs/rest/all-apis/wix-service-availability/multi-service-availability-time-slots/introduction#all-apis_wix-service-availability_multi-service-availability-time-slots_introduction_daylight-saving-time-dst-handling">DST Handling</a></p>
|
81
|
-
* </blockquote>
|
82
|
-
*
|
83
|
-
* ### ListAvailabilityTimeSlots runs with the following defaults:
|
84
|
-
* + `localStartDate` is sorted in `ASC` order.
|
85
|
-
* + `cursorPaging`.`limit` is `1000`.
|
9
|
+
* Retrieves a list of multi-service time slots that match the provided filters.
|
10
|
+
*
|
11
|
+
*
|
12
|
+
* ## Required filters
|
13
|
+
*
|
14
|
+
* You must supply either:
|
15
|
+
* - `services.serviceId`, `fromLocalDate`, `toLocalDate`, `location`, and `timeZone` (additional filters are optional), or
|
16
|
+
* - `cursorPaging.cursor` returned from a previous response.
|
17
|
+
*
|
18
|
+
* Each returned `timeSlot` acts as a container spanning the entire service sequence, with nested time slots providing individual service details.
|
19
|
+
*
|
20
|
+
* ## Defaults
|
21
|
+
*
|
22
|
+
* - Results are sorted by `localStartDate` in ascending order.
|
23
|
+
* - `cursorPaging.limit` is `1000`.
|
24
|
+
* - The response contains both bookable and un-bookable slots.
|
25
|
+
*
|
26
|
+
* ## Service type limitations
|
27
|
+
*
|
28
|
+
* Only appointment-type services are supported.
|
29
|
+
*
|
30
|
+
* To retrieve appointment availability for a single service, call List Availability Time Slots ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/availability/availability-time-slots/list-availability-time-slots) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/availability/availability-time-slots/list-availability-time-slots)).
|
86
31
|
*/
|
87
32
|
(options?: ListMultiServiceAvailabilityTimeSlotsOptions): Promise<NonNullablePaths<ListMultiServiceAvailabilityTimeSlotsResponse, {
|
88
33
|
[P in TimeSlotNonNullablePaths]: `timeSlots.${number}.${P}`;
|
@@ -93,52 +38,36 @@ interface ListMultiServiceAvailabilityTimeSlotsSignature {
|
|
93
38
|
declare function getMultiServiceAvailabilityTimeSlot$1(httpClient: HttpClient): GetMultiServiceAvailabilityTimeSlotSignature;
|
94
39
|
interface GetMultiServiceAvailabilityTimeSlotSignature {
|
95
40
|
/**
|
96
|
-
* Retrieves
|
97
|
-
*
|
98
|
-
*
|
99
|
-
*
|
100
|
-
*
|
101
|
-
*
|
102
|
-
*
|
103
|
-
*
|
104
|
-
*
|
105
|
-
*
|
106
|
-
*
|
107
|
-
*
|
108
|
-
*
|
109
|
-
*
|
110
|
-
*
|
111
|
-
*
|
112
|
-
*
|
113
|
-
*
|
114
|
-
*
|
115
|
-
*
|
116
|
-
*
|
117
|
-
*
|
118
|
-
*
|
119
|
-
*
|
120
|
-
*
|
121
|
-
*
|
122
|
-
*
|
123
|
-
* @param -
|
124
|
-
*
|
125
|
-
*
|
126
|
-
* MinSize: 2.
|
127
|
-
* MaxSize: 8.
|
128
|
-
* @param - Local start date of the time slot, in ISO-8601 format.
|
129
|
-
* For example, "2024-01-30T13:30:00".
|
130
|
-
* @param - Local end date of the time slot, in ISO-8601 format.
|
131
|
-
* For example, "2024-01-30T14:30:00".
|
132
|
-
* @param - Time zone, in IANA time zone format.
|
133
|
-
* @param - The location of the time slot.
|
134
|
-
*
|
135
|
-
* You must provide a specific `locationType`.
|
136
|
-
* If locationType is `BUSINESS`, you __must__ also provide a `locationId`.
|
137
|
-
*
|
138
|
-
* <blockquote class="warning">
|
139
|
-
* <p>Supports filtering by location type, or by location ID.
|
140
|
-
* Other fields like <code class="grey-background">name</code> are ignored.</p>
|
141
|
-
* </blockquote>
|
41
|
+
* Retrieves a multi-service time slot that matches the specified filters.
|
42
|
+
*
|
43
|
+
*
|
44
|
+
* Call this method after finding a suitable slot with List Multi-Service Availability Time Slots to obtain full capacity, resource, and booking-policy details.
|
45
|
+
*
|
46
|
+
* The returned time slot acts as a container spanning the entire service sequence, with nested time slots providing detailed information for each individual service.
|
47
|
+
*
|
48
|
+
* ## Defaults
|
49
|
+
*
|
50
|
+
* - Returns all available resources unless you filter by `services.resourceIds` or `services.includeResourceTypeIds`.
|
51
|
+
* - Includes full booking-status and capacity details.
|
52
|
+
*
|
53
|
+
* ## Service type limitations
|
54
|
+
*
|
55
|
+
* Only appointment-type services are supported.
|
56
|
+
*
|
57
|
+
* To retrieve appointment availability for a single service, call List Availability Time Slots ([SDK](https://dev.wix.com/docs/sdk/backend-modules/bookings/availability/availability-time-slots/list-availability-time-slots) | [REST](https://dev.wix.com/docs/rest/business-solutions/bookings/availability/availability-time-slots/list-availability-time-slots)).
|
58
|
+
* @param - Services for which the multi-service time slots are returned.
|
59
|
+
* You can specify resource filters for each service.
|
60
|
+
* @param - Local start date of the time slot in `YYYY-MM-DDThh:mm:ss` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601).
|
61
|
+
* For example, `2026-01-30T13:30:00`.
|
62
|
+
* @param - Local end date of the time slot in `YYYY-MM-DDThh:mm:ss` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601).
|
63
|
+
* For example, `2026-01-30T13:30:00`.
|
64
|
+
* @param - Time zone in [IANA tz database format](https://en.wikipedia.org/wiki/Tz_database) for adjusting `fromLocalDate` and `toLocalDate` values.
|
65
|
+
* For example, `America/New_York` or `UTC`.
|
66
|
+
*
|
67
|
+
* Default: `timeZone` specified in the business site properties ([SDK](https://dev.wix.com/docs/sdk/backend-modules/site-properties/properties/get-site-properties) | [REST](https://dev.wix.com/docs/rest/business-management/site-properties/properties/get-site-properties)).
|
68
|
+
* @param - Location for which the multi-service time slots are returned. If you filter by `{"type": "BUSINESS"}`, you must also specify a location ID. A filter for `location.name` is ignored.
|
69
|
+
*
|
70
|
+
* Required unless you specify `cursorPaging.cursor`.
|
142
71
|
*/
|
143
72
|
(services: NonNullablePaths<Service, `serviceId`>[], localStartDate: string, localEndDate: string, timeZone: string, location: NonNullablePaths<Location, `locationType`>): Promise<NonNullablePaths<GetMultiServiceAvailabilityTimeSlotResponse, {
|
144
73
|
[P in TimeSlotNonNullablePaths]: `timeSlot.${P}`;
|