reach-api-sdk 1.0.42 → 1.0.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/reach-sdk.d.ts +76 -1
- package/dist/reach-sdk.js +34 -1
- package/package.json +1 -1
- package/src/apiClient.ts +3 -0
- package/src/definition/swagger.yaml +124 -0
- package/src/index.ts +4 -0
- package/src/models/ChoiceMessage.ts +18 -0
- package/src/models/CompletionChoice.ts +17 -0
- package/src/models/DescriptionCompletionResponse.ts +32 -0
- package/src/services/ChatService.ts +45 -0
package/dist/reach-sdk.d.ts
CHANGED
|
@@ -4896,6 +4896,80 @@ declare class BookingService {
|
|
|
4896
4896
|
}): CancelablePromise<boolean>;
|
|
4897
4897
|
}
|
|
4898
4898
|
|
|
4899
|
+
/**
|
|
4900
|
+
* The OpenAI description completion choice message.
|
|
4901
|
+
*/
|
|
4902
|
+
type ChoiceMessage = {
|
|
4903
|
+
/**
|
|
4904
|
+
* Gets or sets the role.
|
|
4905
|
+
*/
|
|
4906
|
+
role?: string | null;
|
|
4907
|
+
/**
|
|
4908
|
+
* Gets or sets the content.
|
|
4909
|
+
*/
|
|
4910
|
+
content?: string | null;
|
|
4911
|
+
};
|
|
4912
|
+
|
|
4913
|
+
/**
|
|
4914
|
+
* The OpenAI description completion choice.
|
|
4915
|
+
*/
|
|
4916
|
+
type CompletionChoice = {
|
|
4917
|
+
/**
|
|
4918
|
+
* Gets or sets the choice index.
|
|
4919
|
+
*/
|
|
4920
|
+
index?: number;
|
|
4921
|
+
message?: ChoiceMessage;
|
|
4922
|
+
};
|
|
4923
|
+
|
|
4924
|
+
/**
|
|
4925
|
+
* The OpenAI description completion response model.
|
|
4926
|
+
*/
|
|
4927
|
+
type DescriptionCompletionResponse = {
|
|
4928
|
+
/**
|
|
4929
|
+
* Gets or sets the openai response id.
|
|
4930
|
+
*/
|
|
4931
|
+
id?: string | null;
|
|
4932
|
+
/**
|
|
4933
|
+
* Gets or sets the used endpoint.
|
|
4934
|
+
*/
|
|
4935
|
+
object?: string | null;
|
|
4936
|
+
/**
|
|
4937
|
+
* Gets or sets the created timestamp.
|
|
4938
|
+
*/
|
|
4939
|
+
created?: number;
|
|
4940
|
+
/**
|
|
4941
|
+
* Gets or sets the model used.
|
|
4942
|
+
*/
|
|
4943
|
+
model?: string | null;
|
|
4944
|
+
/**
|
|
4945
|
+
* Gets or sets the returned choices.
|
|
4946
|
+
*/
|
|
4947
|
+
choices?: Array<CompletionChoice> | null;
|
|
4948
|
+
};
|
|
4949
|
+
|
|
4950
|
+
declare class ChatService {
|
|
4951
|
+
readonly httpRequest: BaseHttpRequest;
|
|
4952
|
+
constructor(httpRequest: BaseHttpRequest);
|
|
4953
|
+
/**
|
|
4954
|
+
* Returns a suggestion for an activity description based on given attributes.
|
|
4955
|
+
* Example request body
|
|
4956
|
+
* {
|
|
4957
|
+
* "name": "Shervs Tennis Fun",
|
|
4958
|
+
* "activity": "Tennis",
|
|
4959
|
+
* "Gender": "Mixed",
|
|
4960
|
+
* etc...
|
|
4961
|
+
* }.
|
|
4962
|
+
* @returns DescriptionCompletionResponse Success
|
|
4963
|
+
* @throws ApiError
|
|
4964
|
+
*/
|
|
4965
|
+
getActivityDescriptionCompletion({ requestBody, }: {
|
|
4966
|
+
/**
|
|
4967
|
+
* The attributes to use to generate the the open AI response.
|
|
4968
|
+
*/
|
|
4969
|
+
requestBody?: Record<string, any>;
|
|
4970
|
+
}): CancelablePromise<DescriptionCompletionResponse>;
|
|
4971
|
+
}
|
|
4972
|
+
|
|
4899
4973
|
declare class CountryService {
|
|
4900
4974
|
readonly httpRequest: BaseHttpRequest;
|
|
4901
4975
|
constructor(httpRequest: BaseHttpRequest);
|
|
@@ -29129,6 +29203,7 @@ declare class ApiClient {
|
|
|
29129
29203
|
readonly attendees: AttendeesService;
|
|
29130
29204
|
readonly badEnglandReport: BadEnglandReportService;
|
|
29131
29205
|
readonly booking: BookingService;
|
|
29206
|
+
readonly chat: ChatService;
|
|
29132
29207
|
readonly country: CountryService;
|
|
29133
29208
|
readonly courses: CoursesService;
|
|
29134
29209
|
readonly courseSessions: CourseSessionsService;
|
|
@@ -29329,4 +29404,4 @@ type ValidationResultModel = {
|
|
|
29329
29404
|
readonly errors?: Array<ValidationError> | null;
|
|
29330
29405
|
};
|
|
29331
29406
|
|
|
29332
|
-
export { Activity, ActivityService, ActivityType, AdvanceBooking, Amenity, AmenityService, ApiClient, ApiError, AppUserRole, ApplicationRole, Attendee, AttendeePage, AttendeePatch, AttendeePost, AttendeesService, AutoCompleteResponseModel, BadEnglandReportService, BaseHttpRequest, BookingService, BookingStatus, CancelError, CancelablePromise, ContactOnConfirmation, Country, CountryService, Course, CourseBookingCutoff, CourseCreate, CoursePage, CoursePatch, CoursePost, CourseSearchSortBy, CourseSession, CourseSessionPage, CourseSessionPatch, CourseSessionPost, CourseSessionSchedule, CourseSessionSchedulePage, CourseSessionSchedulePatch, CourseSessionSchedulePost, CourseSessionSchedulesService, CourseSessionsService, CourseStatus, CoursesService, CreateOffer, CreateQuestion, CreateQuestionOption, CreateVenue, Customer, CustomerCancellationOption, CustomerPage, CustomerPatch, CustomerPost, CustomerStats, CustomerType, CustomersService, DatabaseState, DayOfWeek, EmailReminderSchedule, EmailReminderSchedulePage, EmailReminderSchedulePatch, EmailReminderSchedulePost, EmailReminderSchedulesService, EmailSetting, EmailSettingPage, EmailSettingPatch, EmailSettingPost, EmailSettingsService, FacilitiesService, Facility, FacilityIndividual, FacilityIndividualPage, FacilityIndividualPatch, FacilityIndividualPost, FacilityIndividualsService, FacilityIndividualsType, FacilityPage, FacilityPatch, FacilityPost, FilestackImageMetaResponseModel, FilestackService, Gender, GenericActivity, GenericActivityPage, GenericActivityPatch, GenericActivityPost, GenericActivityService, GeocodeResponseModel, GeocodeService, GooglePrediction, HereAddressDetails, HereAutoComplete, HereAutocompleteLookupService, HereLookupResults, HereMapDetails, HerePositionDetails, HttpStatusCode, IOpportunity, Image, ImagePage, ImagePatch, ImagePost, ImagesService, InviteStatus, LeasingService, LoqateGeocode, LoqatePlaceResult, LoqatePlacesService, LoqatePrediction, Northeast, NotificationQueue, NotificationQueuePage, NotificationQueuePatch, NotificationQueuePost, NotificationQueueService, NotificationSetting, NotificationSettingPage, NotificationSettingPatch, NotificationSettingPost, NotificationSettingsService, NotificationType, Offer, OfferPage, OfferPatch, OfferPost, OffersService, OpenAPI, OpenAPIConfig, OpenactiveFeedIntermediate, OpenactiveFeedIntermediatePage, OpenactiveFeedIntermediatePatch, OpenactiveFeedIntermediatePost, OpenactiveFeedIntermediateService, OpenactiveFeedItem, OpenactiveFeedItemPage, OpenactiveFeedItemPatch, OpenactiveFeedItemPost, OpenactiveFeedItemService, OpportunityRegister, OpportunityRegisterPage, OpportunityRegisterPatch, OpportunityRegisterPost, OpportunityRegisterService, OpportunityType, Order, OrderItem, OrderItemPage, OrderItemPatch, OrderItemPost, OrderItemStatus, OrderItemsService, OrderPage, OrderPatch, OrderPost, OrderPostItem, OrderRefresh, OrderSource, OrderStage, OrderToken, OrderTokenPage, OrderTokenPatch, OrderTokenPost, OrderUpdateContact, OrdersService, OrgCourseUtilisation, OrgCourseUtilisationPage, OrgCourseUtilisationPatch, OrgCourseUtilisationPost, OrgCourseUtilisationService, OrganisationApplicationFeeHandling, OrganisationAvailableChannel, OrganisationRefundPolicy, OrganisationTaxMode, OrganisationType, Pagination, PatchSurveyQuestionOption, Payment, PaymentMethod, PaymentPage, PaymentPatch, PaymentPost, PaymentsService, Permission, PermissionPage, PermissionPatch, PermissionPost, PermissionsService, PlaceDetailsResponseModel, PlaceGeometry, PlaceLocation, PlaceResult, PlaceViewport, PlacesService, PlusCode, Prepayment, Programme, ProgrammePage, ProgrammePatch, ProgrammePost, ProgrammesService, PublicBookingService, PublicCoursesService, PublicFacilitiesService, PublicHealthCheckService, PublicLeasingService, PublicOrderTokensService, PublicOrdersService, PublicProgrammesService, PublicScheduledSessionsService, PublicSessionsService, PublicSlotsService, PublicStripeWebhookService, PublicSurveyQuestionsService, PublicSurveysService, PublicTenantsService, PublicVenuesService, PublicWaitlistActivityService, PublicWaitlistOpportunityService, ReachEntity, ReachError, ReachOperation, RecentOrderActivityReport, RecentOrderActivityReportPage, RecentOrderActivityReportPatch, RecentOrderActivityReportPost, RecentOrderActivityReportService, RefundStatus, ScheduleStatus, ScheduledSession, ScheduledSessionPage, ScheduledSessionPatch, ScheduledSessionPost, ScheduledSessionSchedule, ScheduledSessionSchedulePage, ScheduledSessionSchedulePatch, ScheduledSessionSchedulePost, ScheduledSessionSearchSortBy, ScheduledSessionsSchedulesService, ScheduledSessionsService, SearchSortOrderDirection, Session, SessionCreate, SessionPage, SessionPatch, SessionPost, SessionType, SessionsService, Slot, SlotAvailabilityStatus, SlotOffer, SlotOfferPage, SlotOfferPatch, SlotOfferPost, SlotOffersService, SlotPage, SlotPatch, SlotPost, SlotSchedule, SlotScheduleOffer, SlotScheduleOfferPage, SlotScheduleOfferPatch, SlotScheduleOfferPost, SlotScheduleOffersService, SlotSchedulePage, SlotSchedulePatch, SlotSchedulePost, SlotSchedulesService, SlotStatus, SlotsService, Southwest, StripeAccount, StripeAccountPage, StripeAccountPatch, StripeAccountPost, StripeAccountService, StructuredFormatting, Surface, SurfacesService, Survey, SurveyAnswer, SurveyAnswerPage, SurveyAnswerPatch, SurveyAnswerPost, SurveyAnswersService, SurveyCreate, SurveyPage, SurveyPatch, SurveyPost, SurveyQuestion, SurveyQuestionOption, SurveyQuestionPage, SurveyQuestionPatch, SurveyQuestionPost, SurveyQuestionType, SurveyQuestionsService, SurveyQuestionsTarget, SurveyReportExtended, SurveyReportExtendedPage, SurveyReportExtendedPatch, SurveyReportExtendedPost, SurveyReportExtendedService, SurveyResponseMode, SurveySubmissionModel, SurveySubmissionResponse, SurveySubmit, SurveyType, SurveysService, Tax, Tenant, TenantPage, TenantPatch, TenantPost, TenantWebsiteSetting, TenantWebsiteSettingPage, TenantWebsiteSettingPatch, TenantWebsiteSettingPost, TenantWebsiteSettingsService, TenantsService, Timezone, TimezoneService, TotalRevenueReport, TotalRevenueReportPage, TotalRevenueReportPatch, TotalRevenueReportPost, TotalRevenueReportService, UpdateEmailSettings, UpdateOffer, User, UserPage, UserPatch, UserPost, UserRole, UsersService, ValidationError, ValidationResultModel, Venue, VenueBadmintonEnglandReport, VenueBadmintonEnglandReportPage, VenueBadmintonEnglandReportPatch, VenueBadmintonEnglandReportPost, VenueCreate, VenueOpeningHourUpdate, VenueOpeningHours, VenuePage, VenuePatch, VenuePost, VenuesReport, VenuesReportPage, VenuesReportPatch, VenuesReportPost, VenuesReportService, VenuesService, WaitlistActivity, WaitlistActivityPage, WaitlistActivityPatch, WaitlistActivityPost, WaitlistActivityService, WaitlistOpportunity, WaitlistOpportunityPage, WaitlistOpportunityPatch, WaitlistOpportunityPost, WaitlistOpportunityService };
|
|
29407
|
+
export { Activity, ActivityService, ActivityType, AdvanceBooking, Amenity, AmenityService, ApiClient, ApiError, AppUserRole, ApplicationRole, Attendee, AttendeePage, AttendeePatch, AttendeePost, AttendeesService, AutoCompleteResponseModel, BadEnglandReportService, BaseHttpRequest, BookingService, BookingStatus, CancelError, CancelablePromise, ChatService, ChoiceMessage, CompletionChoice, ContactOnConfirmation, Country, CountryService, Course, CourseBookingCutoff, CourseCreate, CoursePage, CoursePatch, CoursePost, CourseSearchSortBy, CourseSession, CourseSessionPage, CourseSessionPatch, CourseSessionPost, CourseSessionSchedule, CourseSessionSchedulePage, CourseSessionSchedulePatch, CourseSessionSchedulePost, CourseSessionSchedulesService, CourseSessionsService, CourseStatus, CoursesService, CreateOffer, CreateQuestion, CreateQuestionOption, CreateVenue, Customer, CustomerCancellationOption, CustomerPage, CustomerPatch, CustomerPost, CustomerStats, CustomerType, CustomersService, DatabaseState, DayOfWeek, DescriptionCompletionResponse, EmailReminderSchedule, EmailReminderSchedulePage, EmailReminderSchedulePatch, EmailReminderSchedulePost, EmailReminderSchedulesService, EmailSetting, EmailSettingPage, EmailSettingPatch, EmailSettingPost, EmailSettingsService, FacilitiesService, Facility, FacilityIndividual, FacilityIndividualPage, FacilityIndividualPatch, FacilityIndividualPost, FacilityIndividualsService, FacilityIndividualsType, FacilityPage, FacilityPatch, FacilityPost, FilestackImageMetaResponseModel, FilestackService, Gender, GenericActivity, GenericActivityPage, GenericActivityPatch, GenericActivityPost, GenericActivityService, GeocodeResponseModel, GeocodeService, GooglePrediction, HereAddressDetails, HereAutoComplete, HereAutocompleteLookupService, HereLookupResults, HereMapDetails, HerePositionDetails, HttpStatusCode, IOpportunity, Image, ImagePage, ImagePatch, ImagePost, ImagesService, InviteStatus, LeasingService, LoqateGeocode, LoqatePlaceResult, LoqatePlacesService, LoqatePrediction, Northeast, NotificationQueue, NotificationQueuePage, NotificationQueuePatch, NotificationQueuePost, NotificationQueueService, NotificationSetting, NotificationSettingPage, NotificationSettingPatch, NotificationSettingPost, NotificationSettingsService, NotificationType, Offer, OfferPage, OfferPatch, OfferPost, OffersService, OpenAPI, OpenAPIConfig, OpenactiveFeedIntermediate, OpenactiveFeedIntermediatePage, OpenactiveFeedIntermediatePatch, OpenactiveFeedIntermediatePost, OpenactiveFeedIntermediateService, OpenactiveFeedItem, OpenactiveFeedItemPage, OpenactiveFeedItemPatch, OpenactiveFeedItemPost, OpenactiveFeedItemService, OpportunityRegister, OpportunityRegisterPage, OpportunityRegisterPatch, OpportunityRegisterPost, OpportunityRegisterService, OpportunityType, Order, OrderItem, OrderItemPage, OrderItemPatch, OrderItemPost, OrderItemStatus, OrderItemsService, OrderPage, OrderPatch, OrderPost, OrderPostItem, OrderRefresh, OrderSource, OrderStage, OrderToken, OrderTokenPage, OrderTokenPatch, OrderTokenPost, OrderUpdateContact, OrdersService, OrgCourseUtilisation, OrgCourseUtilisationPage, OrgCourseUtilisationPatch, OrgCourseUtilisationPost, OrgCourseUtilisationService, OrganisationApplicationFeeHandling, OrganisationAvailableChannel, OrganisationRefundPolicy, OrganisationTaxMode, OrganisationType, Pagination, PatchSurveyQuestionOption, Payment, PaymentMethod, PaymentPage, PaymentPatch, PaymentPost, PaymentsService, Permission, PermissionPage, PermissionPatch, PermissionPost, PermissionsService, PlaceDetailsResponseModel, PlaceGeometry, PlaceLocation, PlaceResult, PlaceViewport, PlacesService, PlusCode, Prepayment, Programme, ProgrammePage, ProgrammePatch, ProgrammePost, ProgrammesService, PublicBookingService, PublicCoursesService, PublicFacilitiesService, PublicHealthCheckService, PublicLeasingService, PublicOrderTokensService, PublicOrdersService, PublicProgrammesService, PublicScheduledSessionsService, PublicSessionsService, PublicSlotsService, PublicStripeWebhookService, PublicSurveyQuestionsService, PublicSurveysService, PublicTenantsService, PublicVenuesService, PublicWaitlistActivityService, PublicWaitlistOpportunityService, ReachEntity, ReachError, ReachOperation, RecentOrderActivityReport, RecentOrderActivityReportPage, RecentOrderActivityReportPatch, RecentOrderActivityReportPost, RecentOrderActivityReportService, RefundStatus, ScheduleStatus, ScheduledSession, ScheduledSessionPage, ScheduledSessionPatch, ScheduledSessionPost, ScheduledSessionSchedule, ScheduledSessionSchedulePage, ScheduledSessionSchedulePatch, ScheduledSessionSchedulePost, ScheduledSessionSearchSortBy, ScheduledSessionsSchedulesService, ScheduledSessionsService, SearchSortOrderDirection, Session, SessionCreate, SessionPage, SessionPatch, SessionPost, SessionType, SessionsService, Slot, SlotAvailabilityStatus, SlotOffer, SlotOfferPage, SlotOfferPatch, SlotOfferPost, SlotOffersService, SlotPage, SlotPatch, SlotPost, SlotSchedule, SlotScheduleOffer, SlotScheduleOfferPage, SlotScheduleOfferPatch, SlotScheduleOfferPost, SlotScheduleOffersService, SlotSchedulePage, SlotSchedulePatch, SlotSchedulePost, SlotSchedulesService, SlotStatus, SlotsService, Southwest, StripeAccount, StripeAccountPage, StripeAccountPatch, StripeAccountPost, StripeAccountService, StructuredFormatting, Surface, SurfacesService, Survey, SurveyAnswer, SurveyAnswerPage, SurveyAnswerPatch, SurveyAnswerPost, SurveyAnswersService, SurveyCreate, SurveyPage, SurveyPatch, SurveyPost, SurveyQuestion, SurveyQuestionOption, SurveyQuestionPage, SurveyQuestionPatch, SurveyQuestionPost, SurveyQuestionType, SurveyQuestionsService, SurveyQuestionsTarget, SurveyReportExtended, SurveyReportExtendedPage, SurveyReportExtendedPatch, SurveyReportExtendedPost, SurveyReportExtendedService, SurveyResponseMode, SurveySubmissionModel, SurveySubmissionResponse, SurveySubmit, SurveyType, SurveysService, Tax, Tenant, TenantPage, TenantPatch, TenantPost, TenantWebsiteSetting, TenantWebsiteSettingPage, TenantWebsiteSettingPatch, TenantWebsiteSettingPost, TenantWebsiteSettingsService, TenantsService, Timezone, TimezoneService, TotalRevenueReport, TotalRevenueReportPage, TotalRevenueReportPatch, TotalRevenueReportPost, TotalRevenueReportService, UpdateEmailSettings, UpdateOffer, User, UserPage, UserPatch, UserPost, UserRole, UsersService, ValidationError, ValidationResultModel, Venue, VenueBadmintonEnglandReport, VenueBadmintonEnglandReportPage, VenueBadmintonEnglandReportPatch, VenueBadmintonEnglandReportPost, VenueCreate, VenueOpeningHourUpdate, VenueOpeningHours, VenuePage, VenuePatch, VenuePost, VenuesReport, VenuesReportPage, VenuesReportPatch, VenuesReportPost, VenuesReportService, VenuesService, WaitlistActivity, WaitlistActivityPage, WaitlistActivityPatch, WaitlistActivityPost, WaitlistActivityService, WaitlistOpportunity, WaitlistOpportunityPage, WaitlistOpportunityPatch, WaitlistOpportunityPost, WaitlistOpportunityService };
|
package/dist/reach-sdk.js
CHANGED
|
@@ -1704,6 +1704,37 @@ const request = (config, options, axiosClient = axios) => {
|
|
|
1704
1704
|
}
|
|
1705
1705
|
});
|
|
1706
1706
|
}
|
|
1707
|
+
}class ChatService {
|
|
1708
|
+
constructor(httpRequest) {
|
|
1709
|
+
this.httpRequest = httpRequest;
|
|
1710
|
+
}
|
|
1711
|
+
/**
|
|
1712
|
+
* Returns a suggestion for an activity description based on given attributes.
|
|
1713
|
+
* Example request body
|
|
1714
|
+
* {
|
|
1715
|
+
* "name": "Shervs Tennis Fun",
|
|
1716
|
+
* "activity": "Tennis",
|
|
1717
|
+
* "Gender": "Mixed",
|
|
1718
|
+
* etc...
|
|
1719
|
+
* }.
|
|
1720
|
+
* @returns DescriptionCompletionResponse Success
|
|
1721
|
+
* @throws ApiError
|
|
1722
|
+
*/
|
|
1723
|
+
getActivityDescriptionCompletion({
|
|
1724
|
+
requestBody
|
|
1725
|
+
}) {
|
|
1726
|
+
return this.httpRequest.request({
|
|
1727
|
+
method: "POST",
|
|
1728
|
+
url: "/api/external/open-ai-chat/activity-description-completion",
|
|
1729
|
+
body: requestBody,
|
|
1730
|
+
mediaType: "application/json",
|
|
1731
|
+
errors: {
|
|
1732
|
+
400: `Bad Request`,
|
|
1733
|
+
422: `Client Error`,
|
|
1734
|
+
500: `Server Error`
|
|
1735
|
+
}
|
|
1736
|
+
});
|
|
1737
|
+
}
|
|
1707
1738
|
}class CountryService {
|
|
1708
1739
|
constructor(httpRequest) {
|
|
1709
1740
|
this.httpRequest = httpRequest;
|
|
@@ -22793,6 +22824,7 @@ const request = (config, options, axiosClient = axios) => {
|
|
|
22793
22824
|
attendees;
|
|
22794
22825
|
badEnglandReport;
|
|
22795
22826
|
booking;
|
|
22827
|
+
chat;
|
|
22796
22828
|
country;
|
|
22797
22829
|
courses;
|
|
22798
22830
|
courseSessions;
|
|
@@ -22881,6 +22913,7 @@ const request = (config, options, axiosClient = axios) => {
|
|
|
22881
22913
|
this.attendees = new AttendeesService(this.request);
|
|
22882
22914
|
this.badEnglandReport = new BadEnglandReportService(this.request);
|
|
22883
22915
|
this.booking = new BookingService(this.request);
|
|
22916
|
+
this.chat = new ChatService(this.request);
|
|
22884
22917
|
this.country = new CountryService(this.request);
|
|
22885
22918
|
this.courses = new CoursesService(this.request);
|
|
22886
22919
|
this.courseSessions = new CourseSessionsService(this.request);
|
|
@@ -23255,4 +23288,4 @@ const request = (config, options, axiosClient = axios) => {
|
|
|
23255
23288
|
SurveyType2["CHECKOUT"] = "Checkout";
|
|
23256
23289
|
SurveyType2["POST_COMPLETION"] = "PostCompletion";
|
|
23257
23290
|
return SurveyType2;
|
|
23258
|
-
})(SurveyType || {});export{ActivityService,ActivityType,AdvanceBooking,AmenityService,ApiClient,ApiError,AppUserRole,ApplicationRole,AttendeesService,BadEnglandReportService,BaseHttpRequest,BookingService,BookingStatus,CancelError,CancelablePromise,ContactOnConfirmation,CountryService,CourseBookingCutoff,CourseSearchSortBy,CourseSessionSchedulesService,CourseSessionsService,CourseStatus,CoursesService,CustomerCancellationOption,CustomerType,CustomersService,DayOfWeek,EmailReminderSchedulesService,EmailSettingsService,FacilitiesService,FacilityIndividualsService,FacilityIndividualsType,FilestackService,Gender,GenericActivityService,GeocodeService,HereAutocompleteLookupService,HttpStatusCode,ImagesService,InviteStatus,LeasingService,LoqatePlacesService,NotificationQueueService,NotificationSettingsService,NotificationType,OffersService,OpenAPI,OpenactiveFeedIntermediateService,OpenactiveFeedItemService,OpportunityRegisterService,OpportunityType,OrderItemStatus,OrderItemsService,OrderSource,OrderStage,OrdersService,OrgCourseUtilisationService,OrganisationApplicationFeeHandling,OrganisationAvailableChannel,OrganisationRefundPolicy,OrganisationTaxMode,OrganisationType,PaymentMethod,PaymentsService,PermissionsService,PlacesService,Prepayment,ProgrammesService,PublicBookingService,PublicCoursesService,PublicFacilitiesService,PublicHealthCheckService,PublicLeasingService,PublicOrderTokensService,PublicOrdersService,PublicProgrammesService,PublicScheduledSessionsService,PublicSessionsService,PublicSlotsService,PublicStripeWebhookService,PublicSurveyQuestionsService,PublicSurveysService,PublicTenantsService,PublicVenuesService,PublicWaitlistActivityService,PublicWaitlistOpportunityService,ReachEntity,ReachOperation,RecentOrderActivityReportService,RefundStatus,ScheduleStatus,ScheduledSessionSearchSortBy,ScheduledSessionsSchedulesService,ScheduledSessionsService,SearchSortOrderDirection,SessionType,SessionsService,SlotAvailabilityStatus,SlotOffersService,SlotScheduleOffersService,SlotSchedulesService,SlotStatus,SlotsService,StripeAccountService,SurfacesService,SurveyAnswersService,SurveyQuestionType,SurveyQuestionsService,SurveyQuestionsTarget,SurveyReportExtendedService,SurveyResponseMode,SurveyType,SurveysService,TenantWebsiteSettingsService,TenantsService,TimezoneService,TotalRevenueReportService,UsersService,VenuesReportService,VenuesService,WaitlistActivityService,WaitlistOpportunityService};
|
|
23291
|
+
})(SurveyType || {});export{ActivityService,ActivityType,AdvanceBooking,AmenityService,ApiClient,ApiError,AppUserRole,ApplicationRole,AttendeesService,BadEnglandReportService,BaseHttpRequest,BookingService,BookingStatus,CancelError,CancelablePromise,ChatService,ContactOnConfirmation,CountryService,CourseBookingCutoff,CourseSearchSortBy,CourseSessionSchedulesService,CourseSessionsService,CourseStatus,CoursesService,CustomerCancellationOption,CustomerType,CustomersService,DayOfWeek,EmailReminderSchedulesService,EmailSettingsService,FacilitiesService,FacilityIndividualsService,FacilityIndividualsType,FilestackService,Gender,GenericActivityService,GeocodeService,HereAutocompleteLookupService,HttpStatusCode,ImagesService,InviteStatus,LeasingService,LoqatePlacesService,NotificationQueueService,NotificationSettingsService,NotificationType,OffersService,OpenAPI,OpenactiveFeedIntermediateService,OpenactiveFeedItemService,OpportunityRegisterService,OpportunityType,OrderItemStatus,OrderItemsService,OrderSource,OrderStage,OrdersService,OrgCourseUtilisationService,OrganisationApplicationFeeHandling,OrganisationAvailableChannel,OrganisationRefundPolicy,OrganisationTaxMode,OrganisationType,PaymentMethod,PaymentsService,PermissionsService,PlacesService,Prepayment,ProgrammesService,PublicBookingService,PublicCoursesService,PublicFacilitiesService,PublicHealthCheckService,PublicLeasingService,PublicOrderTokensService,PublicOrdersService,PublicProgrammesService,PublicScheduledSessionsService,PublicSessionsService,PublicSlotsService,PublicStripeWebhookService,PublicSurveyQuestionsService,PublicSurveysService,PublicTenantsService,PublicVenuesService,PublicWaitlistActivityService,PublicWaitlistOpportunityService,ReachEntity,ReachOperation,RecentOrderActivityReportService,RefundStatus,ScheduleStatus,ScheduledSessionSearchSortBy,ScheduledSessionsSchedulesService,ScheduledSessionsService,SearchSortOrderDirection,SessionType,SessionsService,SlotAvailabilityStatus,SlotOffersService,SlotScheduleOffersService,SlotSchedulesService,SlotStatus,SlotsService,StripeAccountService,SurfacesService,SurveyAnswersService,SurveyQuestionType,SurveyQuestionsService,SurveyQuestionsTarget,SurveyReportExtendedService,SurveyResponseMode,SurveyType,SurveysService,TenantWebsiteSettingsService,TenantsService,TimezoneService,TotalRevenueReportService,UsersService,VenuesReportService,VenuesService,WaitlistActivityService,WaitlistOpportunityService};
|
package/package.json
CHANGED
package/src/apiClient.ts
CHANGED
|
@@ -11,6 +11,7 @@ import { AmenityService } from './services/AmenityService';
|
|
|
11
11
|
import { AttendeesService } from './services/AttendeesService';
|
|
12
12
|
import { BadEnglandReportService } from './services/BadEnglandReportService';
|
|
13
13
|
import { BookingService } from './services/BookingService';
|
|
14
|
+
import { ChatService } from './services/ChatService';
|
|
14
15
|
import { CountryService } from './services/CountryService';
|
|
15
16
|
import { CoursesService } from './services/CoursesService';
|
|
16
17
|
import { CourseSessionsService } from './services/CourseSessionsService';
|
|
@@ -90,6 +91,7 @@ export class ApiClient {
|
|
|
90
91
|
public readonly attendees: AttendeesService;
|
|
91
92
|
public readonly badEnglandReport: BadEnglandReportService;
|
|
92
93
|
public readonly booking: BookingService;
|
|
94
|
+
public readonly chat: ChatService;
|
|
93
95
|
public readonly country: CountryService;
|
|
94
96
|
public readonly courses: CoursesService;
|
|
95
97
|
public readonly courseSessions: CourseSessionsService;
|
|
@@ -184,6 +186,7 @@ export class ApiClient {
|
|
|
184
186
|
this.attendees = new AttendeesService(this.request);
|
|
185
187
|
this.badEnglandReport = new BadEnglandReportService(this.request);
|
|
186
188
|
this.booking = new BookingService(this.request);
|
|
189
|
+
this.chat = new ChatService(this.request);
|
|
187
190
|
this.country = new CountryService(this.request);
|
|
188
191
|
this.courses = new CoursesService(this.request);
|
|
189
192
|
this.courseSessions = new CourseSessionsService(this.request);
|
|
@@ -4010,6 +4010,77 @@ paths:
|
|
|
4010
4010
|
text/json:
|
|
4011
4011
|
schema:
|
|
4012
4012
|
$ref: '#/components/schemas/ValidationResultModel'
|
|
4013
|
+
/api/external/open-ai-chat/activity-description-completion:
|
|
4014
|
+
post:
|
|
4015
|
+
tags:
|
|
4016
|
+
- Chat
|
|
4017
|
+
summary: Returns a suggestion for an activity description based on given attributes.
|
|
4018
|
+
description: "Example request body\r\n{\r\n \"name\": \"Shervs Tennis Fun\",\r\n \"activity\": \"Tennis\",\r\n \"Gender\": \"Mixed\",\r\n etc...\r\n}."
|
|
4019
|
+
operationId: GetActivityDescriptionCompletion
|
|
4020
|
+
requestBody:
|
|
4021
|
+
description: The attributes to use to generate the the open AI response.
|
|
4022
|
+
content:
|
|
4023
|
+
application/json:
|
|
4024
|
+
schema:
|
|
4025
|
+
type: object
|
|
4026
|
+
additionalProperties: { }
|
|
4027
|
+
text/json:
|
|
4028
|
+
schema:
|
|
4029
|
+
type: object
|
|
4030
|
+
additionalProperties: { }
|
|
4031
|
+
application/*+json:
|
|
4032
|
+
schema:
|
|
4033
|
+
type: object
|
|
4034
|
+
additionalProperties: { }
|
|
4035
|
+
responses:
|
|
4036
|
+
'200':
|
|
4037
|
+
description: Success
|
|
4038
|
+
content:
|
|
4039
|
+
text/plain:
|
|
4040
|
+
schema:
|
|
4041
|
+
$ref: '#/components/schemas/DescriptionCompletionResponse'
|
|
4042
|
+
application/json:
|
|
4043
|
+
schema:
|
|
4044
|
+
$ref: '#/components/schemas/DescriptionCompletionResponse'
|
|
4045
|
+
text/json:
|
|
4046
|
+
schema:
|
|
4047
|
+
$ref: '#/components/schemas/DescriptionCompletionResponse'
|
|
4048
|
+
'400':
|
|
4049
|
+
description: Bad Request
|
|
4050
|
+
content:
|
|
4051
|
+
text/plain:
|
|
4052
|
+
schema:
|
|
4053
|
+
$ref: '#/components/schemas/ReachError'
|
|
4054
|
+
application/json:
|
|
4055
|
+
schema:
|
|
4056
|
+
$ref: '#/components/schemas/ReachError'
|
|
4057
|
+
text/json:
|
|
4058
|
+
schema:
|
|
4059
|
+
$ref: '#/components/schemas/ReachError'
|
|
4060
|
+
'500':
|
|
4061
|
+
description: Server Error
|
|
4062
|
+
content:
|
|
4063
|
+
text/plain:
|
|
4064
|
+
schema:
|
|
4065
|
+
$ref: '#/components/schemas/ReachError'
|
|
4066
|
+
application/json:
|
|
4067
|
+
schema:
|
|
4068
|
+
$ref: '#/components/schemas/ReachError'
|
|
4069
|
+
text/json:
|
|
4070
|
+
schema:
|
|
4071
|
+
$ref: '#/components/schemas/ReachError'
|
|
4072
|
+
'422':
|
|
4073
|
+
description: Client Error
|
|
4074
|
+
content:
|
|
4075
|
+
text/plain:
|
|
4076
|
+
schema:
|
|
4077
|
+
$ref: '#/components/schemas/ValidationResultModel'
|
|
4078
|
+
application/json:
|
|
4079
|
+
schema:
|
|
4080
|
+
$ref: '#/components/schemas/ValidationResultModel'
|
|
4081
|
+
text/json:
|
|
4082
|
+
schema:
|
|
4083
|
+
$ref: '#/components/schemas/ValidationResultModel'
|
|
4013
4084
|
'/api/countries/{id}':
|
|
4014
4085
|
get:
|
|
4015
4086
|
tags:
|
|
@@ -66837,6 +66908,31 @@ components:
|
|
|
66837
66908
|
- Free
|
|
66838
66909
|
type: string
|
|
66839
66910
|
description: 'The Opportunity booking status, indicating whether the opportunity has an active booking or has been attended.'
|
|
66911
|
+
ChoiceMessage:
|
|
66912
|
+
type: object
|
|
66913
|
+
properties:
|
|
66914
|
+
role:
|
|
66915
|
+
type: string
|
|
66916
|
+
description: Gets or sets the role.
|
|
66917
|
+
nullable: true
|
|
66918
|
+
content:
|
|
66919
|
+
type: string
|
|
66920
|
+
description: Gets or sets the content.
|
|
66921
|
+
nullable: true
|
|
66922
|
+
additionalProperties: false
|
|
66923
|
+
description: The OpenAI description completion choice message.
|
|
66924
|
+
CompletionChoice:
|
|
66925
|
+
type: object
|
|
66926
|
+
properties:
|
|
66927
|
+
index:
|
|
66928
|
+
type: integer
|
|
66929
|
+
description: Gets or sets the choice index.
|
|
66930
|
+
format: int32
|
|
66931
|
+
default: 0
|
|
66932
|
+
message:
|
|
66933
|
+
$ref: '#/components/schemas/ChoiceMessage'
|
|
66934
|
+
additionalProperties: false
|
|
66935
|
+
description: The OpenAI description completion choice.
|
|
66840
66936
|
ContactOnConfirmation:
|
|
66841
66937
|
enum:
|
|
66842
66938
|
- Organisation
|
|
@@ -68281,6 +68377,34 @@ components:
|
|
|
68281
68377
|
- Friday
|
|
68282
68378
|
- Saturday
|
|
68283
68379
|
type: string
|
|
68380
|
+
DescriptionCompletionResponse:
|
|
68381
|
+
type: object
|
|
68382
|
+
properties:
|
|
68383
|
+
id:
|
|
68384
|
+
type: string
|
|
68385
|
+
description: Gets or sets the openai response id.
|
|
68386
|
+
nullable: true
|
|
68387
|
+
object:
|
|
68388
|
+
type: string
|
|
68389
|
+
description: Gets or sets the used endpoint.
|
|
68390
|
+
nullable: true
|
|
68391
|
+
created:
|
|
68392
|
+
type: integer
|
|
68393
|
+
description: Gets or sets the created timestamp.
|
|
68394
|
+
format: int32
|
|
68395
|
+
default: 0
|
|
68396
|
+
model:
|
|
68397
|
+
type: string
|
|
68398
|
+
description: Gets or sets the model used.
|
|
68399
|
+
nullable: true
|
|
68400
|
+
choices:
|
|
68401
|
+
type: array
|
|
68402
|
+
items:
|
|
68403
|
+
$ref: '#/components/schemas/CompletionChoice'
|
|
68404
|
+
description: Gets or sets the returned choices.
|
|
68405
|
+
nullable: true
|
|
68406
|
+
additionalProperties: false
|
|
68407
|
+
description: The OpenAI description completion response model.
|
|
68284
68408
|
EmailReminderSchedule:
|
|
68285
68409
|
required:
|
|
68286
68410
|
- dateCreated
|
package/src/index.ts
CHANGED
|
@@ -22,6 +22,8 @@ export type { AttendeePatch } from './models/AttendeePatch';
|
|
|
22
22
|
export type { AttendeePost } from './models/AttendeePost';
|
|
23
23
|
export type { AutoCompleteResponseModel } from './models/AutoCompleteResponseModel';
|
|
24
24
|
export { BookingStatus } from './models/BookingStatus';
|
|
25
|
+
export type { ChoiceMessage } from './models/ChoiceMessage';
|
|
26
|
+
export type { CompletionChoice } from './models/CompletionChoice';
|
|
25
27
|
export { ContactOnConfirmation } from './models/ContactOnConfirmation';
|
|
26
28
|
export type { Country } from './models/Country';
|
|
27
29
|
export type { Course } from './models/Course';
|
|
@@ -53,6 +55,7 @@ export type { CustomerStats } from './models/CustomerStats';
|
|
|
53
55
|
export { CustomerType } from './models/CustomerType';
|
|
54
56
|
export type { DatabaseState } from './models/DatabaseState';
|
|
55
57
|
export { DayOfWeek } from './models/DayOfWeek';
|
|
58
|
+
export type { DescriptionCompletionResponse } from './models/DescriptionCompletionResponse';
|
|
56
59
|
export type { EmailReminderSchedule } from './models/EmailReminderSchedule';
|
|
57
60
|
export type { EmailReminderSchedulePage } from './models/EmailReminderSchedulePage';
|
|
58
61
|
export type { EmailReminderSchedulePatch } from './models/EmailReminderSchedulePatch';
|
|
@@ -296,6 +299,7 @@ export { AmenityService } from './services/AmenityService';
|
|
|
296
299
|
export { AttendeesService } from './services/AttendeesService';
|
|
297
300
|
export { BadEnglandReportService } from './services/BadEnglandReportService';
|
|
298
301
|
export { BookingService } from './services/BookingService';
|
|
302
|
+
export { ChatService } from './services/ChatService';
|
|
299
303
|
export { CountryService } from './services/CountryService';
|
|
300
304
|
export { CoursesService } from './services/CoursesService';
|
|
301
305
|
export { CourseSessionsService } from './services/CourseSessionsService';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do no edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* The OpenAI description completion choice message.
|
|
8
|
+
*/
|
|
9
|
+
export type ChoiceMessage = {
|
|
10
|
+
/**
|
|
11
|
+
* Gets or sets the role.
|
|
12
|
+
*/
|
|
13
|
+
role?: string | null;
|
|
14
|
+
/**
|
|
15
|
+
* Gets or sets the content.
|
|
16
|
+
*/
|
|
17
|
+
content?: string | null;
|
|
18
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do no edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
|
|
6
|
+
import type { ChoiceMessage } from './ChoiceMessage';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The OpenAI description completion choice.
|
|
10
|
+
*/
|
|
11
|
+
export type CompletionChoice = {
|
|
12
|
+
/**
|
|
13
|
+
* Gets or sets the choice index.
|
|
14
|
+
*/
|
|
15
|
+
index?: number;
|
|
16
|
+
message?: ChoiceMessage;
|
|
17
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do no edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
|
|
6
|
+
import type { CompletionChoice } from './CompletionChoice';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The OpenAI description completion response model.
|
|
10
|
+
*/
|
|
11
|
+
export type DescriptionCompletionResponse = {
|
|
12
|
+
/**
|
|
13
|
+
* Gets or sets the openai response id.
|
|
14
|
+
*/
|
|
15
|
+
id?: string | null;
|
|
16
|
+
/**
|
|
17
|
+
* Gets or sets the used endpoint.
|
|
18
|
+
*/
|
|
19
|
+
object?: string | null;
|
|
20
|
+
/**
|
|
21
|
+
* Gets or sets the created timestamp.
|
|
22
|
+
*/
|
|
23
|
+
created?: number;
|
|
24
|
+
/**
|
|
25
|
+
* Gets or sets the model used.
|
|
26
|
+
*/
|
|
27
|
+
model?: string | null;
|
|
28
|
+
/**
|
|
29
|
+
* Gets or sets the returned choices.
|
|
30
|
+
*/
|
|
31
|
+
choices?: Array<CompletionChoice> | null;
|
|
32
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do no edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
import type { DescriptionCompletionResponse } from '../models/DescriptionCompletionResponse';
|
|
6
|
+
|
|
7
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
8
|
+
import type { BaseHttpRequest } from '../core/BaseHttpRequest';
|
|
9
|
+
|
|
10
|
+
export class ChatService {
|
|
11
|
+
constructor(public readonly httpRequest: BaseHttpRequest) {}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Returns a suggestion for an activity description based on given attributes.
|
|
15
|
+
* Example request body
|
|
16
|
+
* {
|
|
17
|
+
* "name": "Shervs Tennis Fun",
|
|
18
|
+
* "activity": "Tennis",
|
|
19
|
+
* "Gender": "Mixed",
|
|
20
|
+
* etc...
|
|
21
|
+
* }.
|
|
22
|
+
* @returns DescriptionCompletionResponse Success
|
|
23
|
+
* @throws ApiError
|
|
24
|
+
*/
|
|
25
|
+
public getActivityDescriptionCompletion({
|
|
26
|
+
requestBody,
|
|
27
|
+
}: {
|
|
28
|
+
/**
|
|
29
|
+
* The attributes to use to generate the the open AI response.
|
|
30
|
+
*/
|
|
31
|
+
requestBody?: Record<string, any>;
|
|
32
|
+
}): CancelablePromise<DescriptionCompletionResponse> {
|
|
33
|
+
return this.httpRequest.request({
|
|
34
|
+
method: 'POST',
|
|
35
|
+
url: '/api/external/open-ai-chat/activity-description-completion',
|
|
36
|
+
body: requestBody,
|
|
37
|
+
mediaType: 'application/json',
|
|
38
|
+
errors: {
|
|
39
|
+
400: `Bad Request`,
|
|
40
|
+
422: `Client Error`,
|
|
41
|
+
500: `Server Error`,
|
|
42
|
+
},
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
}
|