diff --git a/frontend/src/client/@tanstack/react-query.gen.ts b/frontend/src/client/@tanstack/react-query.gen.ts index f901433..094cc5a 100644 --- a/frontend/src/client/@tanstack/react-query.gen.ts +++ b/frontend/src/client/@tanstack/react-query.gen.ts @@ -2,174 +2,116 @@ import { type Options, - loginLoginAccessToken, - loginTestToken, - loginRecoverPassword, - loginResetPassword, - loginRecoverPasswordHtmlContent, - usersReadUsers, - usersCreateUser, - usersDeleteUserMe, - usersReadUserMe, - usersUpdateUserMe, - usersUpdatePasswordMe, - usersRegisterUser, - usersDeleteUser, - usersReadUserById, - usersUpdateUser, - utilsTestEmail, - utilsHealthCheck, - utilsSystemHealthCheck, - utilsDbHealth, - productsReadProducts, - productsCreateProduct, - productsDeleteProduct, - productsReadProduct, - productsUpdateProduct, - productsReadProductGenerations, - productsRetrainProduct, - productsUpdateProductArchiveStatus, - productsSetSelectedShot, - subjectsReadSubjects, - subjectsCreateSubject, - subjectsDeleteSubject, - subjectsReadSubject, - subjectsUpdateSubject, - generationsReadGenerations, - generationsCreateGeneration, - generationsDeleteGeneration, - generationsReadGeneration, - generationsGetGenerationStatus, - trainingTrainingWebhook, - trainingGetTrainingStatus, - promptsBuildPrompt, - promptsBuildPromptSection, - predictionsReadPrediction, - predictionsReadPredictions, - predictionsRefinePrediction, - predictionsUpdatePredictionFavouriteStatus, - subscriptionsCreateUserSubscription, - subscriptionsReadSubscription, - subscriptionsUpdateSubscription, - subscriptionsRenewSubscription, - subscriptionsReadSubscriptions, + rootGet, + register, + login, + loginOauth, + refreshToken, + changePassword, + getCurrentUserInfo, + listEventThemes, + createEventTheme, + deleteEventTheme, + getEventTheme, + updateEventTheme, + getGuests, + createGuest, + deleteGuest, + getGuest, + updateGuest, + setGuestStatusApiV1EventsGuestsGuestIdStatusPatch, + getRsvps, + createRsvp, + deleteRsvp, + getRsvp, + updateRsvp, + updateRsvpStatus, + createEvent, + getUserEvents, + getUpcomingEvents, + getPublicEvents, + deleteEvent, + getEvent, + updateEvent, + getEventBySlug, + generatePresignedUrl, + uploadFile, } from "../sdk.gen"; -import { - queryOptions, - type UseMutationOptions, - type DefaultError, -} from "@tanstack/react-query"; +import { queryOptions, type UseMutationOptions } from "@tanstack/react-query"; import type { - LoginLoginAccessTokenData, - LoginLoginAccessTokenError, - LoginLoginAccessTokenResponse, - LoginTestTokenData, - LoginTestTokenResponse, - LoginRecoverPasswordData, - LoginRecoverPasswordError, - LoginRecoverPasswordResponse, - LoginResetPasswordData, - LoginResetPasswordError, - LoginResetPasswordResponse, - LoginRecoverPasswordHtmlContentData, - LoginRecoverPasswordHtmlContentError, - LoginRecoverPasswordHtmlContentResponse, - UsersReadUsersData, - UsersCreateUserData, - UsersCreateUserError, - UsersCreateUserResponse, - UsersDeleteUserMeData, - UsersDeleteUserMeResponse, - UsersReadUserMeData, - UsersUpdateUserMeData, - UsersUpdateUserMeError, - UsersUpdateUserMeResponse, - UsersUpdatePasswordMeData, - UsersUpdatePasswordMeError, - UsersUpdatePasswordMeResponse, - UsersRegisterUserData, - UsersRegisterUserError, - UsersRegisterUserResponse, - UsersDeleteUserData, - UsersDeleteUserError, - UsersDeleteUserResponse, - UsersReadUserByIdData, - UsersUpdateUserData, - UsersUpdateUserError, - UsersUpdateUserResponse, - UtilsTestEmailData, - UtilsTestEmailError, - UtilsTestEmailResponse, - UtilsHealthCheckData, - UtilsSystemHealthCheckData, - UtilsDbHealthData, - ProductsReadProductsData, - ProductsCreateProductData, - ProductsCreateProductError, - ProductsCreateProductResponse, - ProductsDeleteProductData, - ProductsDeleteProductError, - ProductsDeleteProductResponse, - ProductsReadProductData, - ProductsUpdateProductData, - ProductsUpdateProductError, - ProductsUpdateProductResponse, - ProductsReadProductGenerationsData, - ProductsRetrainProductData, - ProductsRetrainProductError, - ProductsRetrainProductResponse, - ProductsUpdateProductArchiveStatusData, - ProductsUpdateProductArchiveStatusError, - ProductsUpdateProductArchiveStatusResponse, - ProductsSetSelectedShotData, - ProductsSetSelectedShotError, - ProductsSetSelectedShotResponse, - SubjectsReadSubjectsData, - SubjectsCreateSubjectData, - SubjectsCreateSubjectError, - SubjectsCreateSubjectResponse, - SubjectsDeleteSubjectData, - SubjectsDeleteSubjectError, - SubjectsDeleteSubjectResponse, - SubjectsReadSubjectData, - SubjectsUpdateSubjectData, - SubjectsUpdateSubjectError, - SubjectsUpdateSubjectResponse, - GenerationsReadGenerationsData, - GenerationsCreateGenerationData, - GenerationsCreateGenerationError, - GenerationsCreateGenerationResponse, - GenerationsDeleteGenerationData, - GenerationsDeleteGenerationError, - GenerationsDeleteGenerationResponse, - GenerationsReadGenerationData, - GenerationsGetGenerationStatusData, - TrainingTrainingWebhookData, - TrainingTrainingWebhookError, - TrainingGetTrainingStatusData, - PromptsBuildPromptData, - PromptsBuildPromptError, - PromptsBuildPromptResponse, - PromptsBuildPromptSectionData, - PromptsBuildPromptSectionError, - PromptsBuildPromptSectionResponse, - PredictionsReadPredictionData, - PredictionsReadPredictionsData, - PredictionsRefinePredictionData, - PredictionsUpdatePredictionFavouriteStatusData, - PredictionsUpdatePredictionFavouriteStatusError, - PredictionsUpdatePredictionFavouriteStatusResponse, - SubscriptionsCreateUserSubscriptionData, - SubscriptionsCreateUserSubscriptionError, - SubscriptionsCreateUserSubscriptionResponse, - SubscriptionsReadSubscriptionData, - SubscriptionsUpdateSubscriptionData, - SubscriptionsUpdateSubscriptionError, - SubscriptionsUpdateSubscriptionResponse, - SubscriptionsRenewSubscriptionData, - SubscriptionsRenewSubscriptionError, - SubscriptionsRenewSubscriptionResponse, - SubscriptionsReadSubscriptionsData, + RootGetData, + RegisterData, + RegisterError, + RegisterResponse, + LoginData, + LoginError, + LoginResponse, + LoginOauthData, + LoginOauthError, + LoginOauthResponse, + RefreshTokenData, + RefreshTokenError, + RefreshTokenResponse, + ChangePasswordData, + ChangePasswordError, + GetCurrentUserInfoData, + ListEventThemesData, + CreateEventThemeData, + CreateEventThemeError, + CreateEventThemeResponse, + DeleteEventThemeData, + DeleteEventThemeError, + GetEventThemeData, + UpdateEventThemeData, + UpdateEventThemeError, + UpdateEventThemeResponse, + GetGuestsData, + CreateGuestData, + CreateGuestError, + CreateGuestResponse, + DeleteGuestData, + DeleteGuestError, + DeleteGuestResponse, + GetGuestData, + UpdateGuestData, + UpdateGuestError, + UpdateGuestResponse, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchData, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchError, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponse, + GetRsvpsData, + CreateRsvpData, + CreateRsvpError, + CreateRsvpResponse, + DeleteRsvpData, + DeleteRsvpError, + DeleteRsvpResponse, + GetRsvpData, + UpdateRsvpData, + UpdateRsvpError, + UpdateRsvpResponse, + UpdateRsvpStatusData, + UpdateRsvpStatusError, + UpdateRsvpStatusResponse, + CreateEventData, + CreateEventError, + CreateEventResponse, + GetUserEventsData, + GetUpcomingEventsData, + GetPublicEventsData, + DeleteEventData, + DeleteEventError, + DeleteEventResponse, + GetEventData, + UpdateEventData, + UpdateEventError, + UpdateEventResponse, + GetEventBySlugData, + GeneratePresignedUrlData, + GeneratePresignedUrlError, + GeneratePresignedUrlResponse, + UploadFileData, + UploadFileError, } from "../types.gen"; import type { AxiosError } from "axios"; import { client as _heyApiClient } from "../client.gen"; @@ -208,16 +150,13 @@ const createQueryKey = ( return [params]; }; -export const loginLoginAccessTokenQueryKey = ( - options: Options, -) => createQueryKey("loginLoginAccessToken", options); +export const rootGetQueryKey = (options?: Options) => + createQueryKey("rootGet", options); -export const loginLoginAccessTokenOptions = ( - options: Options, -) => { +export const rootGetOptions = (options?: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await loginLoginAccessToken({ + const { data } = await rootGet({ ...options, ...queryKey[0], signal, @@ -225,20 +164,36 @@ export const loginLoginAccessTokenOptions = ( }); return data; }, - queryKey: loginLoginAccessTokenQueryKey(options), + queryKey: rootGetQueryKey(options), }); }; -export const loginLoginAccessTokenMutation = ( - options?: Partial>, -) => { +export const registerQueryKey = (options: Options) => + createQueryKey("register", options); + +export const registerOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await register({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: registerQueryKey(options), + }); +}; + +export const registerMutation = (options?: Partial>) => { const mutationOptions: UseMutationOptions< - LoginLoginAccessTokenResponse, - AxiosError, - Options + RegisterResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await loginLoginAccessToken({ + const { data } = await register({ ...options, ...localOptions, throwOnError: true, @@ -249,15 +204,13 @@ export const loginLoginAccessTokenMutation = ( return mutationOptions; }; -export const loginTestTokenQueryKey = (options?: Options) => - createQueryKey("loginTestToken", options); +export const loginQueryKey = (options: Options) => + createQueryKey("login", options); -export const loginTestTokenOptions = ( - options?: Options, -) => { +export const loginOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await loginTestToken({ + const { data } = await login({ ...options, ...queryKey[0], signal, @@ -265,20 +218,18 @@ export const loginTestTokenOptions = ( }); return data; }, - queryKey: loginTestTokenQueryKey(options), + queryKey: loginQueryKey(options), }); }; -export const loginTestTokenMutation = ( - options?: Partial>, -) => { +export const loginMutation = (options?: Partial>) => { const mutationOptions: UseMutationOptions< - LoginTestTokenResponse, - AxiosError, - Options + LoginResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await loginTestToken({ + const { data } = await login({ ...options, ...localOptions, throwOnError: true, @@ -289,16 +240,13 @@ export const loginTestTokenMutation = ( return mutationOptions; }; -export const loginRecoverPasswordQueryKey = ( - options: Options, -) => createQueryKey("loginRecoverPassword", options); +export const loginOauthQueryKey = (options: Options) => + createQueryKey("loginOauth", options); -export const loginRecoverPasswordOptions = ( - options: Options, -) => { +export const loginOauthOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await loginRecoverPassword({ + const { data } = await loginOauth({ ...options, ...queryKey[0], signal, @@ -306,20 +254,20 @@ export const loginRecoverPasswordOptions = ( }); return data; }, - queryKey: loginRecoverPasswordQueryKey(options), + queryKey: loginOauthQueryKey(options), }); }; -export const loginRecoverPasswordMutation = ( - options?: Partial>, +export const loginOauthMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - LoginRecoverPasswordResponse, - AxiosError, - Options + LoginOauthResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await loginRecoverPassword({ + const { data } = await loginOauth({ ...options, ...localOptions, throwOnError: true, @@ -330,16 +278,13 @@ export const loginRecoverPasswordMutation = ( return mutationOptions; }; -export const loginResetPasswordQueryKey = ( - options: Options, -) => createQueryKey("loginResetPassword", options); +export const refreshTokenQueryKey = (options: Options) => + createQueryKey("refreshToken", options); -export const loginResetPasswordOptions = ( - options: Options, -) => { +export const refreshTokenOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await loginResetPassword({ + const { data } = await refreshToken({ ...options, ...queryKey[0], signal, @@ -347,20 +292,20 @@ export const loginResetPasswordOptions = ( }); return data; }, - queryKey: loginResetPasswordQueryKey(options), + queryKey: refreshTokenQueryKey(options), }); }; -export const loginResetPasswordMutation = ( - options?: Partial>, +export const refreshTokenMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - LoginResetPasswordResponse, - AxiosError, - Options + RefreshTokenResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await loginResetPassword({ + const { data } = await refreshToken({ ...options, ...localOptions, throwOnError: true, @@ -371,16 +316,13 @@ export const loginResetPasswordMutation = ( return mutationOptions; }; -export const loginRecoverPasswordHtmlContentQueryKey = ( - options: Options, -) => createQueryKey("loginRecoverPasswordHtmlContent", options); +export const changePasswordQueryKey = (options: Options) => + createQueryKey("changePassword", options); -export const loginRecoverPasswordHtmlContentOptions = ( - options: Options, -) => { +export const changePasswordOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await loginRecoverPasswordHtmlContent({ + const { data } = await changePassword({ ...options, ...queryKey[0], signal, @@ -388,896 +330,20 @@ export const loginRecoverPasswordHtmlContentOptions = ( }); return data; }, - queryKey: loginRecoverPasswordHtmlContentQueryKey(options), + queryKey: changePasswordQueryKey(options), }); }; -export const loginRecoverPasswordHtmlContentMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - LoginRecoverPasswordHtmlContentResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await loginRecoverPasswordHtmlContent({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersReadUsersQueryKey = (options?: Options) => - createQueryKey("usersReadUsers", options); - -export const usersReadUsersOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await usersReadUsers({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: usersReadUsersQueryKey(options), - }); -}; - -export const usersCreateUserQueryKey = ( - options: Options, -) => createQueryKey("usersCreateUser", options); - -export const usersCreateUserOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await usersCreateUser({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: usersCreateUserQueryKey(options), - }); -}; - -export const usersCreateUserMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersCreateUserResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersCreateUser({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersDeleteUserMeMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersDeleteUserMeResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersDeleteUserMe({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersReadUserMeQueryKey = ( - options?: Options, -) => createQueryKey("usersReadUserMe", options); - -export const usersReadUserMeOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await usersReadUserMe({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: usersReadUserMeQueryKey(options), - }); -}; - -export const usersUpdateUserMeMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersUpdateUserMeResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersUpdateUserMe({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersUpdatePasswordMeMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersUpdatePasswordMeResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersUpdatePasswordMe({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersRegisterUserQueryKey = ( - options: Options, -) => createQueryKey("usersRegisterUser", options); - -export const usersRegisterUserOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await usersRegisterUser({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: usersRegisterUserQueryKey(options), - }); -}; - -export const usersRegisterUserMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersRegisterUserResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersRegisterUser({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersDeleteUserMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersDeleteUserResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersDeleteUser({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const usersReadUserByIdQueryKey = ( - options: Options, -) => createQueryKey("usersReadUserById", options); - -export const usersReadUserByIdOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await usersReadUserById({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: usersReadUserByIdQueryKey(options), - }); -}; - -export const usersUpdateUserMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UsersUpdateUserResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await usersUpdateUser({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const utilsTestEmailQueryKey = (options: Options) => - createQueryKey("utilsTestEmail", options); - -export const utilsTestEmailOptions = (options: Options) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await utilsTestEmail({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: utilsTestEmailQueryKey(options), - }); -}; - -export const utilsTestEmailMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - UtilsTestEmailResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await utilsTestEmail({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const utilsHealthCheckQueryKey = ( - options?: Options, -) => createQueryKey("utilsHealthCheck", options); - -export const utilsHealthCheckOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await utilsHealthCheck({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: utilsHealthCheckQueryKey(options), - }); -}; - -export const utilsSystemHealthCheckQueryKey = ( - options?: Options, -) => createQueryKey("utilsSystemHealthCheck", options); - -export const utilsSystemHealthCheckOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await utilsSystemHealthCheck({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: utilsSystemHealthCheckQueryKey(options), - }); -}; - -export const utilsDbHealthQueryKey = (options?: Options) => - createQueryKey("utilsDbHealth", options); - -export const utilsDbHealthOptions = (options?: Options) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await utilsDbHealth({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: utilsDbHealthQueryKey(options), - }); -}; - -export const productsReadProductsQueryKey = ( - options?: Options, -) => createQueryKey("productsReadProducts", options); - -export const productsReadProductsOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsReadProducts({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsReadProductsQueryKey(options), - }); -}; - -export const productsCreateProductQueryKey = ( - options: Options, -) => createQueryKey("productsCreateProduct", options); - -export const productsCreateProductOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsCreateProduct({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsCreateProductQueryKey(options), - }); -}; - -export const productsCreateProductMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsCreateProductResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsCreateProduct({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const productsDeleteProductMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsDeleteProductResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsDeleteProduct({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const productsReadProductQueryKey = ( - options: Options, -) => createQueryKey("productsReadProduct", options); - -export const productsReadProductOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsReadProduct({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsReadProductQueryKey(options), - }); -}; - -export const productsUpdateProductMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsUpdateProductResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsUpdateProduct({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const productsReadProductGenerationsQueryKey = ( - options: Options, -) => createQueryKey("productsReadProductGenerations", options); - -export const productsReadProductGenerationsOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsReadProductGenerations({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsReadProductGenerationsQueryKey(options), - }); -}; - -export const productsRetrainProductQueryKey = ( - options: Options, -) => createQueryKey("productsRetrainProduct", options); - -export const productsRetrainProductOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsRetrainProduct({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsRetrainProductQueryKey(options), - }); -}; - -export const productsRetrainProductMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsRetrainProductResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsRetrainProduct({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const productsUpdateProductArchiveStatusMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsUpdateProductArchiveStatusResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsUpdateProductArchiveStatus({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const productsSetSelectedShotQueryKey = ( - options: Options, -) => createQueryKey("productsSetSelectedShot", options); - -export const productsSetSelectedShotOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await productsSetSelectedShot({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: productsSetSelectedShotQueryKey(options), - }); -}; - -export const productsSetSelectedShotMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - ProductsSetSelectedShotResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await productsSetSelectedShot({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const subjectsReadSubjectsQueryKey = ( - options?: Options, -) => createQueryKey("subjectsReadSubjects", options); - -export const subjectsReadSubjectsOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await subjectsReadSubjects({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: subjectsReadSubjectsQueryKey(options), - }); -}; - -export const subjectsCreateSubjectQueryKey = ( - options: Options, -) => createQueryKey("subjectsCreateSubject", options); - -export const subjectsCreateSubjectOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await subjectsCreateSubject({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: subjectsCreateSubjectQueryKey(options), - }); -}; - -export const subjectsCreateSubjectMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - SubjectsCreateSubjectResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await subjectsCreateSubject({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const subjectsDeleteSubjectMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - SubjectsDeleteSubjectResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await subjectsDeleteSubject({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const subjectsReadSubjectQueryKey = ( - options: Options, -) => createQueryKey("subjectsReadSubject", options); - -export const subjectsReadSubjectOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await subjectsReadSubject({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: subjectsReadSubjectQueryKey(options), - }); -}; - -export const subjectsUpdateSubjectMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - SubjectsUpdateSubjectResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await subjectsUpdateSubject({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const generationsReadGenerationsQueryKey = ( - options?: Options, -) => createQueryKey("generationsReadGenerations", options); - -export const generationsReadGenerationsOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await generationsReadGenerations({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: generationsReadGenerationsQueryKey(options), - }); -}; - -export const generationsCreateGenerationQueryKey = ( - options: Options, -) => createQueryKey("generationsCreateGeneration", options); - -export const generationsCreateGenerationOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await generationsCreateGeneration({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: generationsCreateGenerationQueryKey(options), - }); -}; - -export const generationsCreateGenerationMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - GenerationsCreateGenerationResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await generationsCreateGeneration({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const generationsDeleteGenerationMutation = ( - options?: Partial>, -) => { - const mutationOptions: UseMutationOptions< - GenerationsDeleteGenerationResponse, - AxiosError, - Options - > = { - mutationFn: async (localOptions) => { - const { data } = await generationsDeleteGeneration({ - ...options, - ...localOptions, - throwOnError: true, - }); - return data; - }, - }; - return mutationOptions; -}; - -export const generationsReadGenerationQueryKey = ( - options: Options, -) => createQueryKey("generationsReadGeneration", options); - -export const generationsReadGenerationOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await generationsReadGeneration({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: generationsReadGenerationQueryKey(options), - }); -}; - -export const generationsGetGenerationStatusQueryKey = ( - options: Options, -) => createQueryKey("generationsGetGenerationStatus", options); - -export const generationsGetGenerationStatusOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await generationsGetGenerationStatus({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: generationsGetGenerationStatusQueryKey(options), - }); -}; - -export const trainingTrainingWebhookQueryKey = ( - options: Options, -) => createQueryKey("trainingTrainingWebhook", options); - -export const trainingTrainingWebhookOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await trainingTrainingWebhook({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: trainingTrainingWebhookQueryKey(options), - }); -}; - -export const trainingTrainingWebhookMutation = ( - options?: Partial>, +export const changePasswordMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< unknown, - AxiosError, - Options + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await trainingTrainingWebhook({ + const { data } = await changePassword({ ...options, ...localOptions, throwOnError: true, @@ -1288,16 +354,16 @@ export const trainingTrainingWebhookMutation = ( return mutationOptions; }; -export const trainingGetTrainingStatusQueryKey = ( - options: Options, -) => createQueryKey("trainingGetTrainingStatus", options); +export const getCurrentUserInfoQueryKey = ( + options?: Options, +) => createQueryKey("getCurrentUserInfo", options); -export const trainingGetTrainingStatusOptions = ( - options: Options, +export const getCurrentUserInfoOptions = ( + options?: Options, ) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await trainingGetTrainingStatus({ + const { data } = await getCurrentUserInfo({ ...options, ...queryKey[0], signal, @@ -1305,20 +371,20 @@ export const trainingGetTrainingStatusOptions = ( }); return data; }, - queryKey: trainingGetTrainingStatusQueryKey(options), + queryKey: getCurrentUserInfoQueryKey(options), }); }; -export const promptsBuildPromptQueryKey = ( - options: Options, -) => createQueryKey("promptsBuildPrompt", options); +export const listEventThemesQueryKey = ( + options?: Options, +) => createQueryKey("listEventThemes", options); -export const promptsBuildPromptOptions = ( - options: Options, +export const listEventThemesOptions = ( + options?: Options, ) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await promptsBuildPrompt({ + const { data } = await listEventThemes({ ...options, ...queryKey[0], signal, @@ -1326,20 +392,41 @@ export const promptsBuildPromptOptions = ( }); return data; }, - queryKey: promptsBuildPromptQueryKey(options), + queryKey: listEventThemesQueryKey(options), }); }; -export const promptsBuildPromptMutation = ( - options?: Partial>, +export const createEventThemeQueryKey = ( + options: Options, +) => createQueryKey("createEventTheme", options); + +export const createEventThemeOptions = ( + options: Options, +) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await createEventTheme({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: createEventThemeQueryKey(options), + }); +}; + +export const createEventThemeMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - PromptsBuildPromptResponse, - AxiosError, - Options + CreateEventThemeResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await promptsBuildPrompt({ + const { data } = await createEventTheme({ ...options, ...localOptions, throwOnError: true, @@ -1350,37 +437,16 @@ export const promptsBuildPromptMutation = ( return mutationOptions; }; -export const promptsBuildPromptSectionQueryKey = ( - options: Options, -) => createQueryKey("promptsBuildPromptSection", options); - -export const promptsBuildPromptSectionOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await promptsBuildPromptSection({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: promptsBuildPromptSectionQueryKey(options), - }); -}; - -export const promptsBuildPromptSectionMutation = ( - options?: Partial>, +export const deleteEventThemeMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - PromptsBuildPromptSectionResponse, - AxiosError, - Options + unknown, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await promptsBuildPromptSection({ + const { data } = await deleteEventTheme({ ...options, ...localOptions, throwOnError: true, @@ -1391,16 +457,13 @@ export const promptsBuildPromptSectionMutation = ( return mutationOptions; }; -export const predictionsReadPredictionQueryKey = ( - options: Options, -) => createQueryKey("predictionsReadPrediction", options); +export const getEventThemeQueryKey = (options: Options) => + createQueryKey("getEventTheme", options); -export const predictionsReadPredictionOptions = ( - options: Options, -) => { +export const getEventThemeOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await predictionsReadPrediction({ + const { data } = await getEventTheme({ ...options, ...queryKey[0], signal, @@ -1408,62 +471,20 @@ export const predictionsReadPredictionOptions = ( }); return data; }, - queryKey: predictionsReadPredictionQueryKey(options), + queryKey: getEventThemeQueryKey(options), }); }; -export const predictionsReadPredictionsQueryKey = ( - options?: Options, -) => createQueryKey("predictionsReadPredictions", options); - -export const predictionsReadPredictionsOptions = ( - options?: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await predictionsReadPredictions({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: predictionsReadPredictionsQueryKey(options), - }); -}; - -export const predictionsRefinePredictionQueryKey = ( - options: Options, -) => createQueryKey("predictionsRefinePrediction", options); - -export const predictionsRefinePredictionOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await predictionsRefinePrediction({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: predictionsRefinePredictionQueryKey(options), - }); -}; - -export const predictionsUpdatePredictionFavouriteStatusMutation = ( - options?: Partial>, +export const updateEventThemeMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - PredictionsUpdatePredictionFavouriteStatusResponse, - AxiosError, - Options + UpdateEventThemeResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await predictionsUpdatePredictionFavouriteStatus({ + const { data } = await updateEventTheme({ ...options, ...localOptions, throwOnError: true, @@ -1474,16 +495,13 @@ export const predictionsUpdatePredictionFavouriteStatusMutation = ( return mutationOptions; }; -export const subscriptionsCreateUserSubscriptionQueryKey = ( - options: Options, -) => createQueryKey("subscriptionsCreateUserSubscription", options); +export const getGuestsQueryKey = (options?: Options) => + createQueryKey("getGuests", options); -export const subscriptionsCreateUserSubscriptionOptions = ( - options: Options, -) => { +export const getGuestsOptions = (options?: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await subscriptionsCreateUserSubscription({ + const { data } = await getGuests({ ...options, ...queryKey[0], signal, @@ -1491,20 +509,38 @@ export const subscriptionsCreateUserSubscriptionOptions = ( }); return data; }, - queryKey: subscriptionsCreateUserSubscriptionQueryKey(options), + queryKey: getGuestsQueryKey(options), }); }; -export const subscriptionsCreateUserSubscriptionMutation = ( - options?: Partial>, +export const createGuestQueryKey = (options: Options) => + createQueryKey("createGuest", options); + +export const createGuestOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await createGuest({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: createGuestQueryKey(options), + }); +}; + +export const createGuestMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - SubscriptionsCreateUserSubscriptionResponse, - AxiosError, - Options + CreateGuestResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await subscriptionsCreateUserSubscription({ + const { data } = await createGuest({ ...options, ...localOptions, throwOnError: true, @@ -1515,37 +551,16 @@ export const subscriptionsCreateUserSubscriptionMutation = ( return mutationOptions; }; -export const subscriptionsReadSubscriptionQueryKey = ( - options: Options, -) => createQueryKey("subscriptionsReadSubscription", options); - -export const subscriptionsReadSubscriptionOptions = ( - options: Options, -) => { - return queryOptions({ - queryFn: async ({ queryKey, signal }) => { - const { data } = await subscriptionsReadSubscription({ - ...options, - ...queryKey[0], - signal, - throwOnError: true, - }); - return data; - }, - queryKey: subscriptionsReadSubscriptionQueryKey(options), - }); -}; - -export const subscriptionsUpdateSubscriptionMutation = ( - options?: Partial>, +export const deleteGuestMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - SubscriptionsUpdateSubscriptionResponse, - AxiosError, - Options + DeleteGuestResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await subscriptionsUpdateSubscription({ + const { data } = await deleteGuest({ ...options, ...localOptions, throwOnError: true, @@ -1556,16 +571,13 @@ export const subscriptionsUpdateSubscriptionMutation = ( return mutationOptions; }; -export const subscriptionsRenewSubscriptionQueryKey = ( - options: Options, -) => createQueryKey("subscriptionsRenewSubscription", options); +export const getGuestQueryKey = (options: Options) => + createQueryKey("getGuest", options); -export const subscriptionsRenewSubscriptionOptions = ( - options: Options, -) => { +export const getGuestOptions = (options: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await subscriptionsRenewSubscription({ + const { data } = await getGuest({ ...options, ...queryKey[0], signal, @@ -1573,20 +585,20 @@ export const subscriptionsRenewSubscriptionOptions = ( }); return data; }, - queryKey: subscriptionsRenewSubscriptionQueryKey(options), + queryKey: getGuestQueryKey(options), }); }; -export const subscriptionsRenewSubscriptionMutation = ( - options?: Partial>, +export const updateGuestMutation = ( + options?: Partial>, ) => { const mutationOptions: UseMutationOptions< - SubscriptionsRenewSubscriptionResponse, - AxiosError, - Options + UpdateGuestResponse, + AxiosError, + Options > = { mutationFn: async (localOptions) => { - const { data } = await subscriptionsRenewSubscription({ + const { data } = await updateGuest({ ...options, ...localOptions, throwOnError: true, @@ -1597,16 +609,35 @@ export const subscriptionsRenewSubscriptionMutation = ( return mutationOptions; }; -export const subscriptionsReadSubscriptionsQueryKey = ( - options?: Options, -) => createQueryKey("subscriptionsReadSubscriptions", options); - -export const subscriptionsReadSubscriptionsOptions = ( - options?: Options, +export const setGuestStatusApiV1EventsGuestsGuestIdStatusPatchMutation = ( + options?: Partial< + Options + >, ) => { + const mutationOptions: UseMutationOptions< + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await setGuestStatusApiV1EventsGuestsGuestIdStatusPatch({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const getRsvpsQueryKey = (options?: Options) => + createQueryKey("getRsvps", options); + +export const getRsvpsOptions = (options?: Options) => { return queryOptions({ queryFn: async ({ queryKey, signal }) => { - const { data } = await subscriptionsReadSubscriptions({ + const { data } = await getRsvps({ ...options, ...queryKey[0], signal, @@ -1614,6 +645,375 @@ export const subscriptionsReadSubscriptionsOptions = ( }); return data; }, - queryKey: subscriptionsReadSubscriptionsQueryKey(options), + queryKey: getRsvpsQueryKey(options), }); }; + +export const createRsvpQueryKey = (options: Options) => + createQueryKey("createRsvp", options); + +export const createRsvpOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await createRsvp({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: createRsvpQueryKey(options), + }); +}; + +export const createRsvpMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + CreateRsvpResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await createRsvp({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const deleteRsvpMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + DeleteRsvpResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await deleteRsvp({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const getRsvpQueryKey = (options: Options) => + createQueryKey("getRsvp", options); + +export const getRsvpOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getRsvp({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getRsvpQueryKey(options), + }); +}; + +export const updateRsvpMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + UpdateRsvpResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await updateRsvp({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const updateRsvpStatusMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + UpdateRsvpStatusResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await updateRsvpStatus({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const createEventQueryKey = (options: Options) => + createQueryKey("createEvent", options); + +export const createEventOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await createEvent({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: createEventQueryKey(options), + }); +}; + +export const createEventMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + CreateEventResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await createEvent({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const getUserEventsQueryKey = (options?: Options) => + createQueryKey("getUserEvents", options); + +export const getUserEventsOptions = (options?: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getUserEvents({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getUserEventsQueryKey(options), + }); +}; + +export const getUpcomingEventsQueryKey = ( + options?: Options, +) => createQueryKey("getUpcomingEvents", options); + +export const getUpcomingEventsOptions = ( + options?: Options, +) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getUpcomingEvents({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getUpcomingEventsQueryKey(options), + }); +}; + +export const getPublicEventsQueryKey = ( + options?: Options, +) => createQueryKey("getPublicEvents", options); + +export const getPublicEventsOptions = ( + options?: Options, +) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getPublicEvents({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getPublicEventsQueryKey(options), + }); +}; + +export const deleteEventMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + DeleteEventResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await deleteEvent({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const getEventQueryKey = (options: Options) => + createQueryKey("getEvent", options); + +export const getEventOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getEvent({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getEventQueryKey(options), + }); +}; + +export const updateEventMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + UpdateEventResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await updateEvent({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const getEventBySlugQueryKey = (options: Options) => + createQueryKey("getEventBySlug", options); + +export const getEventBySlugOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await getEventBySlug({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: getEventBySlugQueryKey(options), + }); +}; + +export const generatePresignedUrlQueryKey = ( + options: Options, +) => createQueryKey("generatePresignedUrl", options); + +export const generatePresignedUrlOptions = ( + options: Options, +) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await generatePresignedUrl({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: generatePresignedUrlQueryKey(options), + }); +}; + +export const generatePresignedUrlMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + GeneratePresignedUrlResponse, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await generatePresignedUrl({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; + +export const uploadFileQueryKey = (options: Options) => + createQueryKey("uploadFile", options); + +export const uploadFileOptions = (options: Options) => { + return queryOptions({ + queryFn: async ({ queryKey, signal }) => { + const { data } = await uploadFile({ + ...options, + ...queryKey[0], + signal, + throwOnError: true, + }); + return data; + }, + queryKey: uploadFileQueryKey(options), + }); +}; + +export const uploadFileMutation = ( + options?: Partial>, +) => { + const mutationOptions: UseMutationOptions< + unknown, + AxiosError, + Options + > = { + mutationFn: async (localOptions) => { + const { data } = await uploadFile({ + ...options, + ...localOptions, + throwOnError: true, + }); + return data; + }, + }; + return mutationOptions; +}; diff --git a/frontend/src/client/schemas.gen.ts b/frontend/src/client/schemas.gen.ts index 255b182..fc9c6e4 100644 --- a/frontend/src/client/schemas.gen.ts +++ b/frontend/src/client/schemas.gen.ts @@ -1,26 +1,28 @@ // This file is auto-generated by @hey-api/openapi-ts -export const AgeClassSchema = { - type: "string", - enum: ["kid", "teen", "young", "middle_age", "elder"], - title: "AgeClass", +export const Body_change_passwordSchema = { + properties: { + current_password: { + type: "string", + title: "Current Password", + }, + new_password: { + type: "string", + title: "New Password", + }, + }, + type: "object", + required: ["current_password", "new_password"], + title: "Body_change_password", } as const; -export const BackgroundTypeSchema = { - type: "string", - enum: ["white", "soft_gray", "creamy", "white_creamy", "raw_concrete"], - title: "BackgroundType", - description: `Enumeration of all possible background types. -The value is a lowercase string with underscores for spaces.`, -} as const; - -export const Body_login_login_access_tokenSchema = { +export const Body_login_oauthSchema = { properties: { grant_type: { anyOf: [ { type: "string", - pattern: "password", + pattern: "^password$", }, { type: "null", @@ -66,34 +68,446 @@ export const Body_login_login_access_tokenSchema = { }, type: "object", required: ["username", "password"], - title: "Body_login-login_access_token", + title: "Body_login_oauth", } as const; -export const FramingTypeSchema = { - type: "string", - enum: [ - "front_half_body", - "front_half_body_lower", - "front_full_body", - "back_half_body", - "back_half_body_lower", - "back_full_body", - "side_half_body", - "side_half_body_lower", - "side_full_body", - ], - title: "FramingType", - description: `Enumeration of all possible framing types for the subject. -The value is a lowercase string with underscores for spaces.`, -} as const; - -export const GenerationCreateSchema = { +export const Body_upload_fileSchema = { properties: { + file: { + type: "string", + format: "binary", + title: "File", + }, + }, + type: "object", + required: ["file"], + title: "Body_upload_file", +} as const; + +export const EventCreateSchema = { + properties: { + title: { + type: "string", + maxLength: 200, + minLength: 1, + title: "Title", + }, + description: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Description", + }, + location_name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Name", + }, + location_address: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Address", + }, + location_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Url", + }, + event_date: { + type: "string", + format: "date-time", + title: "Event Date", + }, + event_start_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event Start Time", + }, + event_end_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event End Time", + }, + timezone: { + type: "string", + title: "Timezone", + }, + rsvp_deadline: { + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Rsvp Deadline", + }, + is_public: { + type: "boolean", + title: "Is Public", + default: false, + }, + access_code: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Access Code", + }, + theme_id: { + anyOf: [ + { + type: "string", + format: "uuid", + }, + { + type: "null", + }, + ], + title: "Theme Id", + }, + custom_theme_settings: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Theme Settings", + }, + additional_info: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Additional Info", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + rsvp_enabled: { + type: "boolean", + title: "Rsvp Enabled", + default: true, + }, + gift_registry_enabled: { + type: "boolean", + title: "Gift Registry Enabled", + default: true, + }, + updates_enabled: { + type: "boolean", + title: "Updates Enabled", + default: true, + }, + max_guests_per_invitation: { + anyOf: [ + { + type: "integer", + minimum: 1, + }, + { + type: "null", + }, + ], + title: "Max Guests Per Invitation", + }, + contact_email: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Contact Email", + }, + contact_phone: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Contact Phone", + }, + slug: { + type: "string", + minLength: 1, + pattern: "^[a-z0-9-]+$", + title: "Slug", + }, + }, + type: "object", + required: ["title", "event_date", "timezone", "slug"], + title: "EventCreate", +} as const; + +export const EventResponseSchema = { + properties: { + title: { + type: "string", + maxLength: 200, + minLength: 1, + title: "Title", + }, + description: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Description", + }, + location_name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Name", + }, + location_address: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Address", + }, + location_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Url", + }, + event_date: { + type: "string", + format: "date-time", + title: "Event Date", + }, + event_start_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event Start Time", + }, + event_end_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event End Time", + }, + timezone: { + type: "string", + title: "Timezone", + }, + rsvp_deadline: { + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Rsvp Deadline", + }, + is_public: { + type: "boolean", + title: "Is Public", + default: false, + }, + access_code: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Access Code", + }, + theme_id: { + anyOf: [ + { + type: "string", + format: "uuid", + }, + { + type: "null", + }, + ], + title: "Theme Id", + }, + custom_theme_settings: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Theme Settings", + }, + additional_info: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Additional Info", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + rsvp_enabled: { + type: "boolean", + title: "Rsvp Enabled", + default: true, + }, + gift_registry_enabled: { + type: "boolean", + title: "Gift Registry Enabled", + default: true, + }, + updates_enabled: { + type: "boolean", + title: "Updates Enabled", + default: true, + }, + max_guests_per_invitation: { + anyOf: [ + { + type: "integer", + minimum: 1, + }, + { + type: "null", + }, + ], + title: "Max Guests Per Invitation", + }, + contact_email: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Contact Email", + }, + contact_phone: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Contact Phone", + }, id: { type: "string", format: "uuid", title: "Id", }, + created_by: { + type: "string", + format: "uuid", + title: "Created By", + }, created_at: { type: "string", format: "date-time", @@ -104,15 +518,33 @@ export const GenerationCreateSchema = { format: "date-time", title: "Updated At", }, - batch_size: { - type: "integer", - title: "Batch Size", - }, - positive_prompt: { + slug: { type: "string", - title: "Positive Prompt", + title: "Slug", }, - negative_prompt: { + }, + type: "object", + required: [ + "title", + "event_date", + "timezone", + "id", + "created_by", + "created_at", + "updated_at", + "slug", + ], + title: "EventResponse", +} as const; + +export const EventThemeCreateSchema = { + properties: { + name: { + type: "string", + minLength: 1, + title: "Name", + }, + description: { anyOf: [ { type: "string", @@ -121,9 +553,421 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Negative Prompt", + title: "Description", }, - subject_id: { + preview_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Preview Image Url", + }, + background_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Background Image Url", + }, + foreground_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Foreground Image Url", + }, + color_palette: { + additionalProperties: { + type: "string", + }, + type: "object", + minProperties: 1, + title: "Color Palette", + }, + asset_image_urls: { + anyOf: [ + { + additionalProperties: { + type: "string", + }, + type: "object", + }, + { + type: "null", + }, + ], + title: "Asset Image Urls", + }, + fonts: { + additionalProperties: { + type: "string", + }, + type: "object", + minProperties: 1, + title: "Fonts", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + }, + type: "object", + required: ["name", "color_palette", "fonts"], + title: "EventThemeCreate", +} as const; + +export const EventThemeResponseSchema = { + properties: { + name: { + type: "string", + minLength: 1, + title: "Name", + }, + description: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Description", + }, + preview_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Preview Image Url", + }, + background_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Background Image Url", + }, + foreground_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Foreground Image Url", + }, + color_palette: { + additionalProperties: { + type: "string", + }, + type: "object", + minProperties: 1, + title: "Color Palette", + }, + asset_image_urls: { + anyOf: [ + { + additionalProperties: { + type: "string", + }, + type: "object", + }, + { + type: "null", + }, + ], + title: "Asset Image Urls", + }, + fonts: { + additionalProperties: { + type: "string", + }, + type: "object", + minProperties: 1, + title: "Fonts", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + id: { + type: "string", + format: "uuid", + title: "Id", + }, + }, + type: "object", + required: ["name", "color_palette", "fonts", "id"], + title: "EventThemeResponse", +} as const; + +export const EventThemeUpdateSchema = { + properties: { + name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Name", + }, + description: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Description", + }, + preview_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Preview Image Url", + }, + background_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Background Image Url", + }, + foreground_image_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Foreground Image Url", + }, + color_palette: { + anyOf: [ + { + additionalProperties: { + type: "string", + }, + type: "object", + }, + { + type: "null", + }, + ], + title: "Color Palette", + }, + asset_image_urls: { + anyOf: [ + { + additionalProperties: { + type: "string", + }, + type: "object", + }, + { + type: "null", + }, + ], + title: "Asset Image Urls", + }, + fonts: { + anyOf: [ + { + additionalProperties: { + type: "string", + }, + type: "object", + }, + { + type: "null", + }, + ], + title: "Fonts", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + }, + type: "object", + title: "EventThemeUpdate", +} as const; + +export const EventUpdateSchema = { + properties: { + title: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Title", + }, + description: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Description", + }, + location_name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Name", + }, + location_address: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Address", + }, + location_url: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Location Url", + }, + event_date: { + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Event Date", + }, + event_start_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event Start Time", + }, + event_end_time: { + anyOf: [ + { + type: "string", + format: "time", + }, + { + type: "null", + }, + ], + title: "Event End Time", + }, + timezone: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Timezone", + }, + rsvp_deadline: { + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Rsvp Deadline", + }, + is_public: { + type: "boolean", + title: "Is Public", + default: false, + }, + access_code: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Access Code", + }, + theme_id: { anyOf: [ { type: "string", @@ -133,9 +977,63 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Subject Id", + title: "Theme Id", }, - subject_slug: { + custom_theme_settings: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Theme Settings", + }, + additional_info: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Additional Info", + }, + is_active: { + type: "boolean", + title: "Is Active", + default: true, + }, + rsvp_enabled: { + type: "boolean", + title: "Rsvp Enabled", + default: true, + }, + gift_registry_enabled: { + type: "boolean", + title: "Gift Registry Enabled", + default: true, + }, + updates_enabled: { + type: "boolean", + title: "Updates Enabled", + default: true, + }, + max_guests_per_invitation: { + anyOf: [ + { + type: "integer", + minimum: 1, + }, + { + type: "null", + }, + ], + title: "Max Guests Per Invitation", + }, + contact_email: { anyOf: [ { type: "string", @@ -144,9 +1042,50 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Subject Slug", + title: "Contact Email", }, - product_id: { + contact_phone: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Contact Phone", + }, + slug: { + anyOf: [ + { + type: "string", + minLength: 1, + pattern: "^[a-z0-9-]+$", + }, + { + type: "null", + }, + ], + title: "Slug", + }, + }, + type: "object", + title: "EventUpdate", +} as const; + +export const GuestCreateSchema = { + properties: { + event_id: { + type: "string", + format: "uuid", + title: "Event Id", + }, + invited_by: { + type: "string", + format: "uuid", + title: "Invited By", + }, + user_id: { anyOf: [ { type: "string", @@ -156,9 +1095,25 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Product Id", + title: "User Id", }, - product_slug: { + full_name: { + type: "string", + title: "Full Name", + }, + email: { + anyOf: [ + { + type: "string", + format: "email", + }, + { + type: "null", + }, + ], + title: "Email", + }, + phone: { anyOf: [ { type: "string", @@ -167,82 +1122,9 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Product Slug", + title: "Phone", }, - product_image: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Product Image", - }, - product_lora_weight: { - type: "number", - title: "Product Lora Weight", - default: 0.9, - }, - subject_lora_weight: { - type: "number", - title: "Subject Lora Weight", - default: 1, - }, - product2_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Product2 Id", - }, - product2_slug: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Product2 Slug", - }, - product2_image: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Product2 Image", - }, - product2_lora_weight: { - type: "number", - title: "Product2 Lora Weight", - default: 0.8, - }, - width: { - type: "integer", - title: "Width", - }, - height: { - type: "integer", - title: "Height", - }, - steps: { - type: "integer", - title: "Steps", - default: 20, - }, - seed: { + max_additional_guests: { anyOf: [ { type: "integer", @@ -251,219 +1133,77 @@ export const GenerationCreateSchema = { type: "null", }, ], - title: "Seed", + title: "Max Additional Guests", + default: 0, }, - refine: { - type: "boolean", - title: "Refine", + dietary_restrictions: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Dietary Restrictions", + }, + notes: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Notes", + }, + custom_fields: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Fields", + }, + can_bring_guests: { + anyOf: [ + { + type: "boolean", + }, + { + type: "null", + }, + ], + title: "Can Bring Guests", default: false, }, - scale_factor: { - anyOf: [ - { - type: "number", - }, - { - type: "null", - }, - ], - title: "Scale Factor", - }, - lighting: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Lighting", - }, - framing: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Framing", - }, - perspective: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Perspective", - }, - background: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Background", - }, - tone: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Tone", - }, - pose: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Pose", - }, - style: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Style", - }, - extra_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Extra Prompt", - }, - generated_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Generated Prompt", - }, - shot_type: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Shot Type", + invitation_code: { + type: "string", + title: "Invitation Code", }, }, type: "object", - required: ["batch_size", "positive_prompt", "width", "height"], - title: "GenerationCreate", + required: ["event_id", "invited_by", "full_name", "invitation_code"], + title: "GuestCreate", } as const; -export const GenerationPublicSchema = { +export const GuestReadSchema = { properties: { - id: { + event_id: { type: "string", format: "uuid", - title: "Id", + title: "Event Id", }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - batch_size: { - type: "integer", - title: "Batch Size", - }, - positive_prompt: { - type: "string", - title: "Positive Prompt", - }, - negative_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Negative Prompt", - }, - subject_id: { + invited_by: { type: "string", format: "uuid", - title: "Subject Id", + title: "Invited By", }, - product_id: { - type: "string", - format: "uuid", - title: "Product Id", - }, - subject_image_url: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Subject Image Url", - }, - product_image_url: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Product Image Url", - }, - product_lora_weight: { - type: "number", - title: "Product Lora Weight", - default: 1, - }, - subject_lora_weight: { - type: "number", - title: "Subject Lora Weight", - default: 1, - }, - product2_id: { + user_id: { anyOf: [ { type: "string", @@ -473,167 +1213,25 @@ export const GenerationPublicSchema = { type: "null", }, ], - title: "Product2 Id", + title: "User Id", }, - product2_image_url: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Product2 Image Url", - }, - product2_lora_weight: { - type: "number", - title: "Product2 Lora Weight", - default: 1, - }, - width: { - type: "integer", - title: "Width", - }, - height: { - type: "integer", - title: "Height", - }, - steps: { - type: "integer", - title: "Steps", - }, - seed: { - type: "integer", - title: "Seed", - }, - refine: { - type: "boolean", - title: "Refine", - }, - scale_factor: { - anyOf: [ - { - type: "number", - }, - { - type: "null", - }, - ], - title: "Scale Factor", - }, - lighting: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Lighting", - }, - framing: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Framing", - }, - perspective: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Perspective", - }, - background: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Background", - }, - tone: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Tone", - }, - pose: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Pose", - }, - style: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Style", - }, - generated_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Generated Prompt", - }, - extra_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Extra Prompt", - }, - predictions: { - items: { - $ref: "#/components/schemas/Prediction", - }, - type: "array", - title: "Predictions", - }, - owner_id: { + full_name: { type: "string", - format: "uuid", - title: "Owner Id", + title: "Full Name", }, - shot_type: { + email: { + anyOf: [ + { + type: "string", + format: "email", + }, + { + type: "null", + }, + ], + title: "Email", + }, + phone: { anyOf: [ { type: "string", @@ -642,66 +1240,258 @@ export const GenerationPublicSchema = { type: "null", }, ], - title: "Shot Type", + title: "Phone", + }, + max_additional_guests: { + anyOf: [ + { + type: "integer", + }, + { + type: "null", + }, + ], + title: "Max Additional Guests", + default: 0, + }, + dietary_restrictions: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Dietary Restrictions", + }, + notes: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Notes", + }, + custom_fields: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Fields", + }, + can_bring_guests: { + anyOf: [ + { + type: "boolean", + }, + { + type: "null", + }, + ], + title: "Can Bring Guests", + default: false, }, - }, - type: "object", - required: [ - "id", - "created_at", - "updated_at", - "batch_size", - "positive_prompt", - "subject_id", - "product_id", - "width", - "height", - "steps", - "seed", - "refine", - "predictions", - "owner_id", - ], - title: "GenerationPublic", -} as const; - -export const GenerationStatusSchema = { - properties: { id: { type: "string", format: "uuid", title: "Id", }, status: { - type: "string", - title: "Status", + $ref: "#/components/schemas/GuestStatus", }, - total: { - type: "integer", - title: "Total", - }, - completed: { - type: "integer", - title: "Completed", - }, - error: { - type: "integer", - title: "Error", - }, - latest_prediction_status: { + invitation_sent_at: { anyOf: [ { - $ref: "#/components/schemas/PredictionStatus", + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Invitation Sent At", + }, + response_date: { + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], + title: "Response Date", + }, + actual_additional_guests: { + type: "integer", + title: "Actual Additional Guests", + }, + is_blocked: { + type: "boolean", + title: "Is Blocked", + }, + }, + type: "object", + required: [ + "event_id", + "invited_by", + "full_name", + "id", + "status", + "actual_additional_guests", + "is_blocked", + ], + title: "GuestRead", +} as const; + +export const GuestStatusSchema = { + type: "string", + enum: [ + "invited", + "pending", + "confirmed", + "declined", + "waitlisted", + "cancelled", + ], + title: "GuestStatus", +} as const; + +export const GuestUpdateSchema = { + properties: { + full_name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Full Name", + }, + email: { + anyOf: [ + { + type: "string", + format: "email", + }, + { + type: "null", + }, + ], + title: "Email", + }, + phone: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Phone", + }, + status: { + anyOf: [ + { + $ref: "#/components/schemas/GuestStatus", }, { type: "null", }, ], }, + max_additional_guests: { + anyOf: [ + { + type: "integer", + }, + { + type: "null", + }, + ], + title: "Max Additional Guests", + }, + actual_additional_guests: { + anyOf: [ + { + type: "integer", + }, + { + type: "null", + }, + ], + title: "Actual Additional Guests", + }, + dietary_restrictions: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Dietary Restrictions", + }, + notes: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Notes", + }, + custom_fields: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Custom Fields", + }, + is_blocked: { + anyOf: [ + { + type: "boolean", + }, + { + type: "null", + }, + ], + title: "Is Blocked", + }, + can_bring_guests: { + anyOf: [ + { + type: "boolean", + }, + { + type: "null", + }, + ], + title: "Can Bring Guests", + }, }, type: "object", - required: ["id", "status", "total", "completed", "error"], - title: "GenerationStatus", + title: "GuestUpdate", } as const; export const HTTPValidationErrorSchema = { @@ -718,83 +1508,111 @@ export const HTTPValidationErrorSchema = { title: "HTTPValidationError", } as const; -export const MessageSchema = { +export const LoginRequestSchema = { properties: { - message: { + email: { type: "string", - title: "Message", + format: "email", + title: "Email", + }, + password: { + type: "string", + title: "Password", }, }, type: "object", - required: ["message"], - title: "Message", + required: ["email", "password"], + title: "LoginRequest", } as const; -export const NewPasswordSchema = { +export const PaginatedResponse_EventResponse_Schema = { properties: { - token: { - type: "string", - title: "Token", + total: { + type: "integer", + title: "Total", }, - new_password: { - type: "string", - maxLength: 40, - minLength: 8, - title: "New Password", + items: { + items: { + $ref: "#/components/schemas/EventResponse", + }, + type: "array", + title: "Items", + }, + page: { + type: "integer", + title: "Page", + }, + size: { + type: "integer", + title: "Size", }, }, type: "object", - required: ["token", "new_password"], - title: "NewPassword", + required: ["total", "items", "page", "size"], + title: "PaginatedResponse[EventResponse]", } as const; -export const PaymentStatusSchema = { - type: "string", - enum: [ - "PENDING", - "PAID", - "PARTIALLY_PAID", - "FAILED", - "REFUNDED", - "PARTIALLY_REFUNDED", - ], - title: "PaymentStatus", - description: `Tracks the payment state of a subscription - -PENDING: Initial state when subscription is created but not paid -PAID: Payment successfully received -PARTIALLY_PAID: Some payment received but full amount not covered -FAILED: Payment attempt failed -REFUNDED: Full payment refunded -PARTIALLY_REFUNDED: Partial refund issued`, -} as const; - -export const PredictionSchema = { +export const PresignedUrlRequestSchema = { properties: { - id: { + filename: { type: "string", - format: "uuid", - title: "Id", + title: "Filename", + description: "Original filename of the image", }, - created_at: { + content_type: { type: "string", - format: "date-time", - title: "Created At", + title: "Content Type", + description: "Content type of the file (e.g., image/jpeg)", }, - updated_at: { + folder: { type: "string", - format: "date-time", - title: "Updated At", + title: "Folder", + description: "Folder to store the file in", + default: "images", }, + }, + type: "object", + required: ["filename", "content_type"], + title: "PresignedUrlRequest", + description: "Request model for generating presigned URLs.", +} as const; + +export const PresignedUrlResponseSchema = { + properties: { + upload_url: { + type: "string", + title: "Upload Url", + description: "URL to upload the file to", + }, + file_url: { + type: "string", + title: "File Url", + description: "URL where the file will be accessible after upload", + }, + expires_in: { + type: "integer", + title: "Expires In", + description: "Time in seconds until the upload URL expires", + }, + }, + type: "object", + required: ["upload_url", "file_url", "expires_in"], + title: "PresignedUrlResponse", + description: "Response model for presigned URL generation.", +} as const; + +export const RSVPSchemaSchema = { + properties: { status: { - $ref: "#/components/schemas/PredictionStatus", - default: "pending", + $ref: "#/components/schemas/RSVPStatus", }, - seed: { + number_of_guests: { type: "integer", - title: "Seed", + minimum: 1, + title: "Number Of Guests", + default: 1, }, - result_image_url: { + response_message: { anyOf: [ { type: "string", @@ -803,9 +1621,9 @@ export const PredictionSchema = { type: "null", }, ], - title: "Result Image Url", + title: "Response Message", }, - refined_image_url: { + dietary_requirements: { anyOf: [ { type: "string", @@ -814,87 +1632,21 @@ export const PredictionSchema = { type: "null", }, ], - title: "Refined Image Url", + title: "Dietary Requirements", }, - prompt_id: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Prompt Id", + additional_info: { + title: "Additional Info", }, - generation_id: { - type: "string", - format: "uuid", - title: "Generation Id", - }, - favourite: { - type: "boolean", - title: "Favourite", - default: false, - }, - shot_type: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Shot Type", - }, - }, - type: "object", - required: ["seed", "generation_id"], - title: "Prediction", -} as const; - -export const PredictionStatusSchema = { - type: "string", - enum: [ - "pending", - "captioning", - "generating", - "intermediate", - "tryon-generating", - "refining", - "completed", - "error", - ], - title: "PredictionStatus", -} as const; - -export const PredictionsPublicSchema = { - properties: { - data: { - items: { - $ref: "#/components/schemas/Prediction", - }, - type: "array", - title: "Data", - }, - count: { - type: "integer", - title: "Count", - }, - }, - type: "object", - required: ["data", "count"], - title: "PredictionsPublic", -} as const; - -export const ProductSchema = { - properties: { id: { type: "string", format: "uuid", title: "Id", }, + response_date: { + type: "string", + format: "date-time", + title: "Response Date", + }, created_at: { type: "string", format: "date-time", @@ -905,734 +1657,24 @@ export const ProductSchema = { format: "date-time", title: "Updated At", }, - sku: { - type: "string", - title: "Sku", - }, - name: { - type: "string", - maxLength: 255, - title: "Name", - }, - slug: { - type: "string", - maxLength: 255, - title: "Slug", - }, - local_model_path: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Local Model Path", - }, - lora_trigger: { - anyOf: [ - { - type: "string", - maxLength: 128, - }, - { - type: "null", - }, - ], - title: "Lora Trigger", - }, - brand: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Brand", - }, - description: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Description", - }, - type: { - $ref: "#/components/schemas/ProductType", - }, - category: { - $ref: "#/components/schemas/ProductCategory", - }, - fitting: { - anyOf: [ - { - $ref: "#/components/schemas/ProductFitting", - }, - { - type: "null", - }, - ], - }, - cover_image_url: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Cover Image Url", - }, - materials: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Materials", - }, - public: { - type: "boolean", - title: "Public", - default: false, - }, - enabled: { - type: "boolean", - title: "Enabled", - default: true, - }, - archived: { - type: "boolean", - title: "Archived", - default: false, - }, - demo: { - type: "boolean", - title: "Demo", - default: false, - }, - owner_id: { - type: "string", - format: "uuid", - title: "Owner Id", - }, - lora_status: { - type: "string", - maxLength: 20, - title: "Lora Status", - default: "none", - }, - current_training_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Current Training Id", - description: "ID of the current/last training task", - }, - training_progress: { - type: "number", - title: "Training Progress", - description: "Current training progress percentage", - default: 0, - }, - training_error: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Training Error", - description: "Last training error message if any", - }, - data_image_urls: { - items: { - type: "string", - }, - type: "array", - title: "Data Image Urls", - }, - selected_shots: { - additionalProperties: { - type: "object", - }, - type: "object", - title: "Selected Shots", - description: "Dictionary of selected shots with their predictions", - }, }, type: "object", - required: ["sku", "name", "slug", "type", "category", "owner_id"], - title: "Product", + required: ["status", "id", "response_date", "created_at", "updated_at"], + title: "RSVPSchema", } as const; -export const ProductCategorySchema = { - type: "string", - enum: ["UPPER_BODY", "LOWER_BODY", "DRESSES"], - title: "ProductCategory", -} as const; - -export const ProductCreateSchema = { +export const RSVPSchemaCreateSchema = { properties: { - sku: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Sku", + status: { + $ref: "#/components/schemas/RSVPStatus", }, - name: { - type: "string", - maxLength: 255, - title: "Name", - }, - brand: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Brand", - }, - description: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Description", - }, - type: { - $ref: "#/components/schemas/ProductType", - }, - local_model_path: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Local Model Path", - }, - lora_trigger: { - anyOf: [ - { - type: "string", - maxLength: 128, - }, - { - type: "null", - }, - ], - title: "Lora Trigger", - }, - category: { - $ref: "#/components/schemas/ProductCategory", - }, - fitting: { - anyOf: [ - { - $ref: "#/components/schemas/ProductFitting", - }, - { - type: "null", - }, - ], - }, - cover_image: { - type: "string", - title: "Cover Image", - description: "URL or base64 string for cover image", - }, - materials: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Materials", - }, - public: { - type: "boolean", - title: "Public", - default: false, - }, - data_images: { - anyOf: [ - { - items: { - type: "string", - }, - type: "array", - }, - { - type: "null", - }, - ], - title: "Data Images", - description: "List of image URLs or base64 strings", - }, - train: { - type: "boolean", - title: "Train", - description: "Whether to start training after creation", - default: true, - }, - }, - type: "object", - required: ["name", "type", "category", "cover_image"], - title: "ProductCreate", - example: { - category: "UPPER_BODY", - cover_image: "https://example.com/image.jpg", - materials: "100% Cotton", - name: "Black T-Shirt", - public: false, - type: "GARMENT", - }, -} as const; - -export const ProductFittingSchema = { - type: "string", - enum: ["regular", "slim", "loose", "oversize"], - title: "ProductFitting", -} as const; - -export const ProductPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - sku: { - type: "string", - title: "Sku", - }, - name: { - type: "string", - title: "Name", - }, - slug: { - type: "string", - title: "Slug", - }, - brand: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Brand", - }, - description: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Description", - }, - type: { - $ref: "#/components/schemas/ProductType", - }, - category: { - $ref: "#/components/schemas/ProductCategory", - }, - fitting: { - anyOf: [ - { - $ref: "#/components/schemas/ProductFitting", - }, - { - type: "null", - }, - ], - }, - cover_image_url: { - type: "string", - title: "Cover Image Url", - }, - materials: { - type: "string", - title: "Materials", - }, - public: { - type: "boolean", - title: "Public", - }, - enabled: { - type: "boolean", - title: "Enabled", - }, - archived: { - type: "boolean", - title: "Archived", - }, - demo: { - type: "boolean", - title: "Demo", - }, - owner_id: { - type: "string", - format: "uuid", - title: "Owner Id", - }, - lora_status: { - type: "string", - title: "Lora Status", - }, - lora_trigger: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Lora Trigger", - }, - data_image_urls: { - items: { - type: "string", - }, - type: "array", - title: "Data Image Urls", - }, - current_training_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Current Training Id", - }, - training_progress: { - type: "number", - title: "Training Progress", - default: 0, - }, - training_error: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Training Error", - }, - selected_shots: { - type: "object", - title: "Selected Shots", - default: {}, - }, - }, - type: "object", - required: [ - "id", - "created_at", - "sku", - "name", - "slug", - "brand", - "description", - "type", - "category", - "fitting", - "cover_image_url", - "materials", - "public", - "enabled", - "archived", - "demo", - "owner_id", - "lora_status", - "lora_trigger", - "data_image_urls", - ], - title: "ProductPublic", -} as const; - -export const ProductTypeSchema = { - type: "string", - enum: ["garment", "bag", "other"], - title: "ProductType", -} as const; - -export const ProductUpdateSchema = { - properties: { - name: { - anyOf: [ - { - type: "string", - maxLength: 255, - }, - { - type: "null", - }, - ], - title: "Name", - }, - sku: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Sku", - }, - brand: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Brand", - }, - description: { - anyOf: [ - { - type: "string", - maxLength: 1000, - }, - { - type: "null", - }, - ], - title: "Description", - }, - type: { - anyOf: [ - { - $ref: "#/components/schemas/ProductType", - }, - { - type: "null", - }, - ], - }, - category: { - anyOf: [ - { - $ref: "#/components/schemas/ProductCategory", - }, - { - type: "null", - }, - ], - }, - fitting: { - anyOf: [ - { - $ref: "#/components/schemas/ProductFitting", - }, - { - type: "null", - }, - ], - }, - cover_image: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Cover Image", - description: "URL or base64 string for cover image", - }, - materials: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Materials", - }, - public: { - anyOf: [ - { - type: "boolean", - }, - { - type: "null", - }, - ], - title: "Public", - }, - data_images: { - anyOf: [ - { - items: { - type: "string", - }, - type: "array", - }, - { - type: "null", - }, - ], - title: "Data Images", - description: "List of image URLs or base64 strings to update", - }, - }, - type: "object", - title: "ProductUpdate", - example: { - brand: "New Brand", - category: "UPPER_BODY", - name: "Updated Black T-Shirt", - public: true, - }, -} as const; - -export const ProductsPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - data: { - items: { - $ref: "#/components/schemas/ProductPublic", - }, - type: "array", - title: "Data", - }, - count: { + number_of_guests: { type: "integer", - title: "Count", + minimum: 1, + title: "Number Of Guests", + default: 1, }, - }, - type: "object", - required: ["data", "count"], - title: "ProductsPublic", -} as const; - -export const PromptBuildRequestSchema = { - properties: { - subject_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Subject Id", - }, - product_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Product Id", - }, - framing: { - anyOf: [ - { - $ref: "#/components/schemas/FramingType", - }, - { - type: "null", - }, - ], - default: "front_half_body", - }, - background: { + response_message: { anyOf: [ { type: "string", @@ -1641,9 +1683,9 @@ export const PromptBuildRequestSchema = { type: "null", }, ], - title: "Background", + title: "Response Message", }, - style: { + dietary_requirements: { anyOf: [ { type: "string", @@ -1652,752 +1694,105 @@ export const PromptBuildRequestSchema = { type: "null", }, ], - title: "Style", - default: "ecommerce", + title: "Dietary Requirements", }, - }, - type: "object", - title: "PromptBuildRequest", -} as const; - -export const PromptResponseSchema = { - properties: { - prompt: { + additional_info: { + title: "Additional Info", + }, + event_id: { type: "string", - title: "Prompt", + format: "uuid", + title: "Event Id", }, - parameters: { - type: "object", - title: "Parameters", + guest_id: { + type: "string", + format: "uuid", + title: "Guest Id", }, }, type: "object", - required: ["prompt", "parameters"], - title: "PromptResponse", + required: ["status", "event_id", "guest_id"], + title: "RSVPSchemaCreate", } as const; -export const PromptSectionSchema = { +export const RSVPSchemaUpdateSchema = { + properties: { + status: { + anyOf: [ + { + $ref: "#/components/schemas/RSVPStatus", + }, + { + type: "null", + }, + ], + }, + number_of_guests: { + anyOf: [ + { + type: "integer", + minimum: 1, + }, + { + type: "null", + }, + ], + title: "Number Of Guests", + }, + response_message: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Response Message", + }, + dietary_requirements: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Dietary Requirements", + }, + additional_info: { + anyOf: [ + { + type: "object", + }, + { + type: "null", + }, + ], + title: "Additional Info", + }, + }, + type: "object", + title: "RSVPSchemaUpdate", +} as const; + +export const RSVPStatusSchema = { type: "string", - enum: ["subject", "product", "background", "framing"], - title: "PromptSection", + enum: ["attending", "not_attending", "maybe"], + title: "RSVPStatus", } as const; -export const PromptSectionRequestSchema = { +export const RefreshTokenRequestSchema = { properties: { - section: { - $ref: "#/components/schemas/PromptSection", - }, - id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Id", - description: "Mandatory for subject and product sections", - }, - selector: { - anyOf: [ - { - $ref: "#/components/schemas/FramingType", - }, - { - $ref: "#/components/schemas/BackgroundType", - }, - { - type: "null", - }, - ], - title: "Selector", - description: "Mandatory for framing and background sections", + refresh_token: { + type: "string", + title: "Refresh Token", }, }, type: "object", - required: ["section"], - title: "PromptSectionRequest", -} as const; - -export const PromptSectionResponseSchema = { - properties: { - section: { - $ref: "#/components/schemas/PromptSection", - }, - id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Id", - }, - selector: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Selector", - }, - result: { - type: "string", - title: "Result", - }, - }, - type: "object", - required: ["section", "result"], - title: "PromptSectionResponse", -} as const; - -export const SelectedShotRequestSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - product_id: { - type: "string", - format: "uuid", - title: "Product Id", - description: "ID of the product", - }, - shot_type: { - type: "string", - title: "Shot Type", - description: "Type of shot (e.g. 'full-body', 'half-body-front')", - }, - prediction_id: { - anyOf: [ - { - type: "string", - format: "uuid", - }, - { - type: "null", - }, - ], - title: "Prediction Id", - description: - "ID of the prediction to set as favorite. If None, any existing favorite will be removed.", - }, - }, - type: "object", - required: ["product_id", "shot_type"], - title: "SelectedShotRequest", -} as const; - -export const ServiceTypeSchema = { - type: "string", - enum: ["SELF_SERVICE", "AGENCY"], - title: "ServiceType", - description: "Defines the type of service subscription", -} as const; - -export const SubjectCreateSchema = { - properties: { - name: { - type: "string", - title: "Name", - }, - description: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Description", - }, - local_model_path: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Local Model Path", - }, - lora_trigger: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Lora Trigger", - }, - lora_status: { - type: "string", - title: "Lora Status", - default: "none", - }, - cover_image: { - type: "string", - title: "Cover Image", - }, - data_images: { - anyOf: [ - { - items: { - type: "string", - }, - type: "array", - }, - { - type: "null", - }, - ], - title: "Data Images", - }, - age_class: { - $ref: "#/components/schemas/AgeClass", - }, - positive_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Positive Prompt", - }, - negative_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Negative Prompt", - }, - ethnicity: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Ethnicity", - }, - public: { - type: "boolean", - title: "Public", - default: false, - }, - subject_type: { - $ref: "#/components/schemas/SubjectType", - default: "AI", - }, - }, - type: "object", - required: ["name", "cover_image", "age_class"], - title: "SubjectCreate", -} as const; - -export const SubjectPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - name: { - type: "string", - title: "Name", - }, - slug: { - type: "string", - title: "Slug", - }, - description: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Description", - }, - age_class: { - $ref: "#/components/schemas/AgeClass", - }, - subject_type: { - $ref: "#/components/schemas/SubjectType", - }, - positive_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Positive Prompt", - }, - negative_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Negative Prompt", - }, - ethnicity: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Ethnicity", - }, - public: { - type: "boolean", - title: "Public", - }, - enabled: { - type: "boolean", - title: "Enabled", - }, - lora_status: { - type: "string", - title: "Lora Status", - }, - lora_trigger: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Lora Trigger", - }, - cover_image_url: { - type: "string", - title: "Cover Image Url", - }, - data_image_urls: { - items: { - type: "string", - }, - type: "array", - title: "Data Image Urls", - }, - owner_id: { - type: "string", - format: "uuid", - title: "Owner Id", - }, - }, - type: "object", - required: [ - "id", - "created_at", - "name", - "slug", - "description", - "age_class", - "subject_type", - "ethnicity", - "public", - "enabled", - "lora_status", - "lora_trigger", - "cover_image_url", - "data_image_urls", - "owner_id", - ], - title: "SubjectPublic", -} as const; - -export const SubjectTypeSchema = { - type: "string", - enum: ["AI", "REAL"], - title: "SubjectType", -} as const; - -export const SubjectUpdateSchema = { - properties: { - name: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Name", - }, - description: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Description", - }, - cover_image: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Cover Image", - }, - data_images: { - anyOf: [ - { - items: { - type: "string", - }, - type: "array", - }, - { - type: "null", - }, - ], - title: "Data Images", - }, - age_class: { - anyOf: [ - { - $ref: "#/components/schemas/AgeClass", - }, - { - type: "null", - }, - ], - }, - positive_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Positive Prompt", - }, - negative_prompt: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Negative Prompt", - }, - ethnicity: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Ethnicity", - }, - public: { - anyOf: [ - { - type: "boolean", - }, - { - type: "null", - }, - ], - title: "Public", - }, - }, - type: "object", - title: "SubjectUpdate", -} as const; - -export const SubjectsPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - data: { - items: { - $ref: "#/components/schemas/SubjectPublic", - }, - type: "array", - title: "Data", - }, - count: { - type: "integer", - title: "Count", - }, - }, - type: "object", - required: ["data", "count"], - title: "SubjectsPublic", -} as const; - -export const SubscriptionCreateSchema = { - properties: { - service_type: { - $ref: "#/components/schemas/ServiceType", - }, - tier: { - $ref: "#/components/schemas/SubscriptionTier", - }, - payment_id: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Payment Id", - }, - }, - type: "object", - required: ["service_type", "tier"], - title: "SubscriptionCreate", -} as const; - -export const SubscriptionPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - user_id: { - type: "string", - format: "uuid", - title: "User Id", - }, - service_type: { - $ref: "#/components/schemas/ServiceType", - }, - tier: { - $ref: "#/components/schemas/SubscriptionTier", - }, - start_date: { - type: "string", - format: "date-time", - title: "Start Date", - }, - end_date: { - type: "string", - format: "date-time", - title: "End Date", - }, - grace_period_end: { - type: "string", - format: "date-time", - title: "Grace Period End", - }, - credits_total: { - type: "integer", - title: "Credits Total", - }, - credits_used: { - type: "integer", - title: "Credits Used", - }, - credits_remaining: { - type: "integer", - title: "Credits Remaining", - }, - is_active: { - type: "boolean", - title: "Is Active", - }, - payment_status: { - $ref: "#/components/schemas/PaymentStatus", - }, - base_price: { - type: "number", - title: "Base Price", - }, - actual_price: { - type: "number", - title: "Actual Price", - }, - currency: { - type: "string", - title: "Currency", - }, - }, - type: "object", - required: [ - "id", - "user_id", - "service_type", - "tier", - "start_date", - "end_date", - "grace_period_end", - "credits_total", - "credits_used", - "credits_remaining", - "is_active", - "payment_status", - "base_price", - "actual_price", - "currency", - ], - title: "SubscriptionPublic", -} as const; - -export const SubscriptionTierSchema = { - type: "string", - enum: ["START", "SCALE", "ENTERPRISE"], - title: "SubscriptionTier", - description: "Defines the subscription tier level", -} as const; - -export const SubscriptionUpdateSchema = { - properties: { - service_type: { - anyOf: [ - { - $ref: "#/components/schemas/ServiceType", - }, - { - type: "null", - }, - ], - }, - tier: { - anyOf: [ - { - $ref: "#/components/schemas/SubscriptionTier", - }, - { - type: "null", - }, - ], - }, - }, - type: "object", - title: "SubscriptionUpdate", -} as const; - -export const SubscriptionsPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - data: { - items: { - $ref: "#/components/schemas/SubscriptionPublic", - }, - type: "array", - title: "Data", - }, - count: { - type: "integer", - title: "Count", - }, - }, - type: "object", - required: ["data", "count"], - title: "SubscriptionsPublic", + required: ["refresh_token"], + title: "RefreshTokenRequest", } as const; export const TokenSchema = { @@ -2406,6 +1801,17 @@ export const TokenSchema = { type: "string", title: "Access Token", }, + refresh_token: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Refresh Token", + }, token_type: { type: "string", title: "Token Type", @@ -2417,26 +1823,6 @@ export const TokenSchema = { title: "Token", } as const; -export const UpdatePasswordSchema = { - properties: { - current_password: { - type: "string", - maxLength: 40, - minLength: 8, - title: "Current Password", - }, - new_password: { - type: "string", - maxLength: 40, - minLength: 8, - title: "New Password", - }, - }, - type: "object", - required: ["current_password", "new_password"], - title: "UpdatePassword", -} as const; - export const UserCreateSchema = { properties: { email: { @@ -2444,13 +1830,11 @@ export const UserCreateSchema = { format: "email", title: "Email", }, - password: { + first_name: { type: "string", - maxLength: 40, - minLength: 8, - title: "Password", + title: "First Name", }, - full_name: { + last_name: { anyOf: [ { type: "string", @@ -2459,47 +1843,46 @@ export const UserCreateSchema = { type: "null", }, ], - title: "Full Name", + title: "Last Name", + }, + phone_number: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Phone Number", + }, + password: { + type: "string", + title: "Password", }, is_superuser: { type: "boolean", title: "Is Superuser", default: false, }, - is_active: { - type: "boolean", - title: "Is Active", - default: true, - }, }, type: "object", - required: ["email", "password"], + required: ["email", "first_name", "password"], title: "UserCreate", } as const; -export const UserPublicSchema = { +export const UserResponseSchema = { properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, email: { type: "string", format: "email", title: "Email", }, - full_name: { + first_name: { + type: "string", + title: "First Name", + }, + last_name: { anyOf: [ { type: "string", @@ -2508,7 +1891,23 @@ export const UserPublicSchema = { type: "null", }, ], - title: "Full Name", + title: "Last Name", + }, + phone_number: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Phone Number", + }, + id: { + type: "string", + format: "uuid", + title: "Id", }, is_active: { type: "boolean", @@ -2517,20 +1916,6 @@ export const UserPublicSchema = { is_superuser: { type: "boolean", title: "Is Superuser", - default: false, - }, - }, - type: "object", - required: ["id", "email", "full_name", "is_active"], - title: "UserPublic", -} as const; - -export const UserRegisterSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", }, created_at: { type: "string", @@ -2538,169 +1923,28 @@ export const UserRegisterSchema = { title: "Created At", }, updated_at: { - type: "string", - format: "date-time", + anyOf: [ + { + type: "string", + format: "date-time", + }, + { + type: "null", + }, + ], title: "Updated At", }, - email: { - type: "string", - maxLength: 255, - format: "email", - title: "Email", - }, - password: { - type: "string", - maxLength: 40, - minLength: 8, - title: "Password", - }, - full_name: { - anyOf: [ - { - type: "string", - maxLength: 255, - }, - { - type: "null", - }, - ], - title: "Full Name", - }, }, type: "object", - required: ["email", "password"], - title: "UserRegister", -} as const; - -export const UserUpdateSchema = { - properties: { - email: { - anyOf: [ - { - type: "string", - format: "email", - }, - { - type: "null", - }, - ], - title: "Email", - }, - full_name: { - anyOf: [ - { - type: "string", - }, - { - type: "null", - }, - ], - title: "Full Name", - }, - password: { - anyOf: [ - { - type: "string", - maxLength: 40, - minLength: 8, - }, - { - type: "null", - }, - ], - title: "Password", - }, - is_superuser: { - anyOf: [ - { - type: "boolean", - }, - { - type: "null", - }, - ], - title: "Is Superuser", - }, - is_active: { - anyOf: [ - { - type: "boolean", - }, - { - type: "null", - }, - ], - title: "Is Active", - }, - }, - type: "object", - title: "UserUpdate", -} as const; - -export const UserUpdateMeSchema = { - properties: { - full_name: { - anyOf: [ - { - type: "string", - maxLength: 255, - }, - { - type: "null", - }, - ], - title: "Full Name", - }, - email: { - anyOf: [ - { - type: "string", - maxLength: 255, - format: "email", - }, - { - type: "null", - }, - ], - title: "Email", - }, - }, - type: "object", - title: "UserUpdateMe", -} as const; - -export const UsersPublicSchema = { - properties: { - id: { - type: "string", - format: "uuid", - title: "Id", - }, - created_at: { - type: "string", - format: "date-time", - title: "Created At", - }, - updated_at: { - type: "string", - format: "date-time", - title: "Updated At", - }, - data: { - items: { - $ref: "#/components/schemas/UserPublic", - }, - type: "array", - title: "Data", - }, - count: { - type: "integer", - title: "Count", - }, - }, - type: "object", - required: ["data", "count"], - title: "UsersPublic", + required: [ + "email", + "first_name", + "id", + "is_active", + "is_superuser", + "created_at", + ], + title: "UserResponse", } as const; export const ValidationErrorSchema = { diff --git a/frontend/src/client/sdk.gen.ts b/frontend/src/client/sdk.gen.ts index 522ba88..a78a7b9 100644 --- a/frontend/src/client/sdk.gen.ts +++ b/frontend/src/client/sdk.gen.ts @@ -5,153 +5,106 @@ import { type TDataShape, type Client, urlSearchParamsBodySerializer, + formDataBodySerializer, } from "@hey-api/client-axios"; import type { - LoginLoginAccessTokenData, - LoginLoginAccessTokenResponse, - LoginLoginAccessTokenError, - LoginTestTokenData, - LoginTestTokenResponse, - LoginRecoverPasswordData, - LoginRecoverPasswordResponse, - LoginRecoverPasswordError, - LoginResetPasswordData, - LoginResetPasswordResponse, - LoginResetPasswordError, - LoginRecoverPasswordHtmlContentData, - LoginRecoverPasswordHtmlContentResponse, - LoginRecoverPasswordHtmlContentError, - UsersReadUsersData, - UsersReadUsersResponse, - UsersReadUsersError, - UsersCreateUserData, - UsersCreateUserResponse, - UsersCreateUserError, - UsersDeleteUserMeData, - UsersDeleteUserMeResponse, - UsersReadUserMeData, - UsersReadUserMeResponse, - UsersUpdateUserMeData, - UsersUpdateUserMeResponse, - UsersUpdateUserMeError, - UsersUpdatePasswordMeData, - UsersUpdatePasswordMeResponse, - UsersUpdatePasswordMeError, - UsersRegisterUserData, - UsersRegisterUserResponse, - UsersRegisterUserError, - UsersDeleteUserData, - UsersDeleteUserResponse, - UsersDeleteUserError, - UsersReadUserByIdData, - UsersReadUserByIdResponse, - UsersReadUserByIdError, - UsersUpdateUserData, - UsersUpdateUserResponse, - UsersUpdateUserError, - UtilsTestEmailData, - UtilsTestEmailResponse, - UtilsTestEmailError, - UtilsHealthCheckData, - UtilsHealthCheckResponse, - UtilsSystemHealthCheckData, - UtilsSystemHealthCheckResponse, - UtilsDbHealthData, - ProductsReadProductsData, - ProductsReadProductsResponse, - ProductsReadProductsError, - ProductsCreateProductData, - ProductsCreateProductResponse, - ProductsCreateProductError, - ProductsDeleteProductData, - ProductsDeleteProductResponse, - ProductsDeleteProductError, - ProductsReadProductData, - ProductsReadProductResponse, - ProductsReadProductError, - ProductsUpdateProductData, - ProductsUpdateProductResponse, - ProductsUpdateProductError, - ProductsReadProductGenerationsData, - ProductsReadProductGenerationsResponse, - ProductsReadProductGenerationsError, - ProductsRetrainProductData, - ProductsRetrainProductResponse, - ProductsRetrainProductError, - ProductsUpdateProductArchiveStatusData, - ProductsUpdateProductArchiveStatusResponse, - ProductsUpdateProductArchiveStatusError, - ProductsSetSelectedShotData, - ProductsSetSelectedShotResponse, - ProductsSetSelectedShotError, - SubjectsReadSubjectsData, - SubjectsReadSubjectsResponse, - SubjectsReadSubjectsError, - SubjectsCreateSubjectData, - SubjectsCreateSubjectResponse, - SubjectsCreateSubjectError, - SubjectsDeleteSubjectData, - SubjectsDeleteSubjectResponse, - SubjectsDeleteSubjectError, - SubjectsReadSubjectData, - SubjectsReadSubjectResponse, - SubjectsReadSubjectError, - SubjectsUpdateSubjectData, - SubjectsUpdateSubjectResponse, - SubjectsUpdateSubjectError, - GenerationsReadGenerationsData, - GenerationsReadGenerationsResponse, - GenerationsReadGenerationsError, - GenerationsCreateGenerationData, - GenerationsCreateGenerationResponse, - GenerationsCreateGenerationError, - GenerationsDeleteGenerationData, - GenerationsDeleteGenerationResponse, - GenerationsDeleteGenerationError, - GenerationsReadGenerationData, - GenerationsReadGenerationResponse, - GenerationsReadGenerationError, - GenerationsGetGenerationStatusData, - GenerationsGetGenerationStatusResponse, - GenerationsGetGenerationStatusError, - TrainingTrainingWebhookData, - TrainingTrainingWebhookError, - TrainingGetTrainingStatusData, - TrainingGetTrainingStatusResponse, - TrainingGetTrainingStatusError, - PromptsBuildPromptData, - PromptsBuildPromptResponse, - PromptsBuildPromptError, - PromptsBuildPromptSectionData, - PromptsBuildPromptSectionResponse, - PromptsBuildPromptSectionError, - PredictionsReadPredictionData, - PredictionsReadPredictionResponse, - PredictionsReadPredictionError, - PredictionsReadPredictionsData, - PredictionsReadPredictionsResponse, - PredictionsReadPredictionsError, - PredictionsRefinePredictionData, - PredictionsRefinePredictionResponse, - PredictionsRefinePredictionError, - PredictionsUpdatePredictionFavouriteStatusData, - PredictionsUpdatePredictionFavouriteStatusResponse, - PredictionsUpdatePredictionFavouriteStatusError, - SubscriptionsCreateUserSubscriptionData, - SubscriptionsCreateUserSubscriptionResponse, - SubscriptionsCreateUserSubscriptionError, - SubscriptionsReadSubscriptionData, - SubscriptionsReadSubscriptionResponse, - SubscriptionsReadSubscriptionError, - SubscriptionsUpdateSubscriptionData, - SubscriptionsUpdateSubscriptionResponse, - SubscriptionsUpdateSubscriptionError, - SubscriptionsRenewSubscriptionData, - SubscriptionsRenewSubscriptionResponse, - SubscriptionsRenewSubscriptionError, - SubscriptionsReadSubscriptionsData, - SubscriptionsReadSubscriptionsResponse, - SubscriptionsReadSubscriptionsError, + RootGetData, + RootGetResponse, + RegisterData, + RegisterResponse, + RegisterError, + LoginData, + LoginResponse, + LoginError, + LoginOauthData, + LoginOauthResponse, + LoginOauthError, + RefreshTokenData, + RefreshTokenResponse, + RefreshTokenError, + ChangePasswordData, + ChangePasswordError, + GetCurrentUserInfoData, + GetCurrentUserInfoResponse, + ListEventThemesData, + ListEventThemesResponse, + ListEventThemesError, + CreateEventThemeData, + CreateEventThemeResponse, + CreateEventThemeError, + DeleteEventThemeData, + DeleteEventThemeError, + GetEventThemeData, + GetEventThemeResponse, + GetEventThemeError, + UpdateEventThemeData, + UpdateEventThemeResponse, + UpdateEventThemeError, + GetGuestsData, + GetGuestsResponse, + GetGuestsError, + CreateGuestData, + CreateGuestResponse, + CreateGuestError, + DeleteGuestData, + DeleteGuestResponse, + DeleteGuestError, + GetGuestData, + GetGuestResponse, + GetGuestError, + UpdateGuestData, + UpdateGuestResponse, + UpdateGuestError, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchData, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponse, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchError, + GetRsvpsData, + GetRsvpsResponse, + GetRsvpsError, + CreateRsvpData, + CreateRsvpResponse, + CreateRsvpError, + DeleteRsvpData, + DeleteRsvpResponse, + DeleteRsvpError, + GetRsvpData, + GetRsvpResponse, + GetRsvpError, + UpdateRsvpData, + UpdateRsvpResponse, + UpdateRsvpError, + UpdateRsvpStatusData, + UpdateRsvpStatusResponse, + UpdateRsvpStatusError, + CreateEventData, + CreateEventResponse, + CreateEventError, + GetUserEventsData, + GetUserEventsResponse, + GetUserEventsError, + GetUpcomingEventsData, + GetUpcomingEventsResponse, + GetUpcomingEventsError, + GetPublicEventsData, + GetPublicEventsResponse, + GetPublicEventsError, + DeleteEventData, + DeleteEventResponse, + DeleteEventError, + GetEventData, + GetEventResponse, + GetEventError, + UpdateEventData, + UpdateEventResponse, + UpdateEventError, + GetEventBySlugData, + GetEventBySlugResponse, + GetEventBySlugError, + GeneratePresignedUrlData, + GeneratePresignedUrlResponse, + GeneratePresignedUrlError, + UploadFileData, + UploadFileError, } from "./types.gen"; import { client as _heyApiClient } from "./client.gen"; @@ -173,19 +126,87 @@ export type Options< }; /** - * Login Access Token - * OAuth2 compatible token login, get an access token for future requests + * Root */ -export const loginLoginAccessToken = ( - options: Options, +export const rootGet = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + RootGetResponse, + unknown, + ThrowOnError + >({ + responseType: "text", + url: "/", + ...options, + }); +}; + +/** + * Register User + * Register a new user. + * + * Returns: + * The created user information. + */ +export const register = ( + options: Options, ) => { return (options.client ?? _heyApiClient).post< - LoginLoginAccessTokenResponse, - LoginLoginAccessTokenError, + RegisterResponse, + RegisterError, + ThrowOnError + >({ + url: "/api/v1/auth/register", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Login + * Login with username and password. + * + * Returns: + * Access and refresh tokens. + */ +export const login = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + LoginResponse, + LoginError, + ThrowOnError + >({ + url: "/api/v1/auth/login", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Login Oauth + * OAuth2-compatible login endpoint, used by the OpenAPI UI. + * + * Returns: + * Access and refresh tokens. + */ +export const loginOauth = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + LoginOauthResponse, + LoginOauthError, ThrowOnError >({ ...urlSearchParamsBodySerializer, - url: "/api/v1/login/access-token", + url: "/api/v1/auth/login/oauth", ...options, headers: { "Content-Type": "application/x-www-form-urlencoded", @@ -195,976 +216,21 @@ export const loginLoginAccessToken = ( }; /** - * Test Token - * Test access token - */ -export const loginTestToken = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).post< - LoginTestTokenResponse, - unknown, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/login/test-token", - ...options, - }); -}; - -/** - * Recover Password - * Password Recovery - */ -export const loginRecoverPassword = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - LoginRecoverPasswordResponse, - LoginRecoverPasswordError, - ThrowOnError - >({ - url: "/api/v1/password-recovery/{email}", - ...options, - }); -}; - -/** - * Reset Password - * Reset password - */ -export const loginResetPassword = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - LoginResetPasswordResponse, - LoginResetPasswordError, - ThrowOnError - >({ - url: "/api/v1/reset-password/", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Recover Password Html Content - * HTML Content for Password Recovery - */ -export const loginRecoverPasswordHtmlContent = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - LoginRecoverPasswordHtmlContentResponse, - LoginRecoverPasswordHtmlContentError, - ThrowOnError - >({ - responseType: "text", - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/password-recovery-html-content/{email}", - ...options, - }); -}; - -/** - * Read Users - * Retrieve users. - */ -export const usersReadUsers = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - UsersReadUsersResponse, - UsersReadUsersError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/", - ...options, - }); -}; - -/** - * Create User - * Create new user. - */ -export const usersCreateUser = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - UsersCreateUserResponse, - UsersCreateUserError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Delete User Me - * Delete own user. - */ -export const usersDeleteUserMe = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).delete< - UsersDeleteUserMeResponse, - unknown, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/me", - ...options, - }); -}; - -/** - * Read User Me - * Get current user. - */ -export const usersReadUserMe = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - UsersReadUserMeResponse, - unknown, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/me", - ...options, - }); -}; - -/** - * Update User Me - * Update own user. - */ -export const usersUpdateUserMe = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).patch< - UsersUpdateUserMeResponse, - UsersUpdateUserMeError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/me", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Update Password Me - * Update own password. - */ -export const usersUpdatePasswordMe = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).patch< - UsersUpdatePasswordMeResponse, - UsersUpdatePasswordMeError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/me/password", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Register User - * Create new user without the need to be logged in. - */ -export const usersRegisterUser = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - UsersRegisterUserResponse, - UsersRegisterUserError, - ThrowOnError - >({ - url: "/api/v1/users/signup", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Delete User - * Delete a user. - */ -export const usersDeleteUser = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).delete< - UsersDeleteUserResponse, - UsersDeleteUserError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/{user_id}", - ...options, - }); -}; - -/** - * Read User By Id - * Get a specific user by id. - */ -export const usersReadUserById = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - UsersReadUserByIdResponse, - UsersReadUserByIdError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/{user_id}", - ...options, - }); -}; - -/** - * Update User - * Update a user. - */ -export const usersUpdateUser = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).patch< - UsersUpdateUserResponse, - UsersUpdateUserError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/users/{user_id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Test Email - * Test emails. - */ -export const utilsTestEmail = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - UtilsTestEmailResponse, - UtilsTestEmailError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/utils/test-email/", - ...options, - }); -}; - -/** - * Health Check - */ -export const utilsHealthCheck = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - UtilsHealthCheckResponse, - unknown, - ThrowOnError - >({ - url: "/api/v1/utils/health-check/", - ...options, - }); -}; - -/** - * System Health Check - * Comprehensive system health check that verifies all service connections. - * Ensures a response is always returned, even if some services fail to respond. - */ -export const utilsSystemHealthCheck = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - UtilsSystemHealthCheckResponse, - unknown, - ThrowOnError - >({ - url: "/api/v1/utils/system-health-check", - ...options, - }); -}; - -/** - * Db Health - */ -export const utilsDbHealth = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get( - { - url: "/api/v1/utils/db-check/", - ...options, - }, - ); -}; - -/** - * Read Products - * Retrieve products. - * Optionally filter by archive status, enabled status, and brand (case-insensitive). - */ -export const productsReadProducts = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - ProductsReadProductsResponse, - ProductsReadProductsError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/", - ...options, - }); -}; - -/** - * Create Product - * Create new product - */ -export const productsCreateProduct = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - ProductsCreateProductResponse, - ProductsCreateProductError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Delete Product - * Delete a product. - */ -export const productsDeleteProduct = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).delete< - ProductsDeleteProductResponse, - ProductsDeleteProductError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/{id}", - ...options, - }); -}; - -/** - * Read Product - * Get product by ID. - */ -export const productsReadProduct = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - ProductsReadProductResponse, - ProductsReadProductError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/{id}", - ...options, - }); -}; - -/** - * Update Product - * Update a product. - */ -export const productsUpdateProduct = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).put< - ProductsUpdateProductResponse, - ProductsUpdateProductError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/{id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Read Product Generations - * Retrieve generations owned by the current user, ordered by creation date descending. - */ -export const productsReadProductGenerations = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - ProductsReadProductGenerationsResponse, - ProductsReadProductGenerationsError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/{product_id}/generations", - ...options, - }); -}; - -/** - * Retrain Product - * Get product by ID. - */ -export const productsRetrainProduct = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - ProductsRetrainProductResponse, - ProductsRetrainProductError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products{id}/retrain", - ...options, - }); -}; - -/** - * Update Product Archive Status - * Update the archive status of a product. - */ -export const productsUpdateProductArchiveStatus = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).patch< - ProductsUpdateProductArchiveStatusResponse, - ProductsUpdateProductArchiveStatusError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/{id}/archived", - ...options, - }); -}; - -/** - * Set Selected Shot - * Set a prediction as the selected shot for a specific shot type for a product. - * If prediction_id is None, any existing selected shot will be removed. - */ -export const productsSetSelectedShot = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - ProductsSetSelectedShotResponse, - ProductsSetSelectedShotError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/products/selected_shot/{product_id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Read Subjects - * Retrieve subjects. - */ -export const subjectsReadSubjects = ( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - SubjectsReadSubjectsResponse, - SubjectsReadSubjectsError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subjects/", - ...options, - }); -}; - -/** - * Create Subject - * Create new subject. - */ -export const subjectsCreateSubject = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - SubjectsCreateSubjectResponse, - SubjectsCreateSubjectError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subjects/", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Delete Subject - * Delete a subject. - */ -export const subjectsDeleteSubject = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).delete< - SubjectsDeleteSubjectResponse, - SubjectsDeleteSubjectError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subjects/{id}", - ...options, - }); -}; - -/** - * Read Subject - * Get subject by ID. - */ -export const subjectsReadSubject = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - SubjectsReadSubjectResponse, - SubjectsReadSubjectError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subjects/{id}", - ...options, - }); -}; - -/** - * Update Subject - * Update a subject. - */ -export const subjectsUpdateSubject = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).put< - SubjectsUpdateSubjectResponse, - SubjectsUpdateSubjectError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subjects/{id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Read Generations - * Retrieve generations owned by the current user, ordered by creation date descending. - */ -export const generationsReadGenerations = < - ThrowOnError extends boolean = false, ->( - options?: Options, -) => { - return (options?.client ?? _heyApiClient).get< - GenerationsReadGenerationsResponse, - GenerationsReadGenerationsError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/generations/", - ...options, - }); -}; - -/** - * Create Generation - * Create new generation. - */ -export const generationsCreateGeneration = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - GenerationsCreateGenerationResponse, - GenerationsCreateGenerationError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/generations/", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Delete Generation - * Delete a generation. - */ -export const generationsDeleteGeneration = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).delete< - GenerationsDeleteGenerationResponse, - GenerationsDeleteGenerationError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/generations/{id}", - ...options, - }); -}; - -/** - * Read Generation - * Get generation by ID. - */ -export const generationsReadGeneration = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - GenerationsReadGenerationResponse, - GenerationsReadGenerationError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/generations/{id}", - ...options, - }); -}; - -/** - * Get Generation Status - * Get the status of a generation. - */ -export const generationsGetGenerationStatus = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - GenerationsGetGenerationStatusResponse, - GenerationsGetGenerationStatusError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/generations/{id}/status", - ...options, - }); -}; - -/** - * Training Webhook - */ -export const trainingTrainingWebhook = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - unknown, - TrainingTrainingWebhookError, - ThrowOnError - >({ - url: "/api/v1/training/webhook", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Get Training Status - * Endpoint to get the training task status by ID. - */ -export const trainingGetTrainingStatus = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - TrainingGetTrainingStatusResponse, - TrainingGetTrainingStatusError, - ThrowOnError - >({ - url: "/api/v1/training/{task_id}/status", - ...options, - }); -}; - -/** - * Build Prompt - * Build a prompt based on provided parameters. - * This endpoint allows dynamic prompt construction before actual generation. - * Even with no parameters, it will return a basic working prompt. - */ -export const promptsBuildPrompt = ( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - PromptsBuildPromptResponse, - PromptsBuildPromptError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/prompts/build", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Build Prompt Section - * Build a specific section of the prompt based on provided parameters. - * This endpoint allows for granular prompt section construction. + * Refresh Token + * Refresh access token using a refresh token. * * Returns: - * PromptSectionResponse: Contains the generated prompt section and input parameters - * - * Raises: - * HTTPException: - * - 400 if the request is invalid (missing required fields) - * - 404 if requested subject/product is not found + * New access and refresh tokens. */ -export const promptsBuildPromptSection = ( - options: Options, +export const refreshToken = ( + options: Options, ) => { return (options.client ?? _heyApiClient).post< - PromptsBuildPromptSectionResponse, - PromptsBuildPromptSectionError, + RefreshTokenResponse, + RefreshTokenError, ThrowOnError >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/prompts/build-section", + url: "/api/v1/auth/refresh", ...options, headers: { "Content-Type": "application/json", @@ -1174,14 +240,17 @@ export const promptsBuildPromptSection = ( }; /** - * Read Prediction + * Change Password + * Change current user's password. + * + * Requires authentication. */ -export const predictionsReadPrediction = ( - options: Options, +export const changePassword = ( + options: Options, ) => { - return (options.client ?? _heyApiClient).get< - PredictionsReadPredictionResponse, - PredictionsReadPredictionError, + return (options.client ?? _heyApiClient).post< + unknown, + ChangePasswordError, ThrowOnError >({ security: [ @@ -1190,22 +259,27 @@ export const predictionsReadPrediction = ( type: "http", }, ], - url: "/api/v1/predictions/{id}", + url: "/api/v1/auth/change-password", ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, }); }; /** - * Read Predictions + * Get Current User Info + * Get current user information. + * + * Requires authentication. */ -export const predictionsReadPredictions = < - ThrowOnError extends boolean = false, ->( - options?: Options, +export const getCurrentUserInfo = ( + options?: Options, ) => { return (options?.client ?? _heyApiClient).get< - PredictionsReadPredictionsResponse, - PredictionsReadPredictionsError, + GetCurrentUserInfoResponse, + unknown, ThrowOnError >({ security: [ @@ -1214,22 +288,103 @@ export const predictionsReadPredictions = < type: "http", }, ], - url: "/api/v1/predictions/", + url: "/api/v1/auth/me", ...options, }); }; /** - * Refine Prediction + * List Themes + * List event themes. */ -export const predictionsRefinePrediction = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const listEventThemes = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + ListEventThemesResponse, + ListEventThemesError, + ThrowOnError + >({ + url: "/api/v1/event_themes/", + ...options, + }); +}; + +/** + * Create Theme + */ +export const createEventTheme = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + CreateEventThemeResponse, + CreateEventThemeError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/event_themes/", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Delete Theme + * Delete specific theme by ID. + */ +export const deleteEventTheme = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).delete< + unknown, + DeleteEventThemeError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/event_themes/{theme_id}", + ...options, + }); +}; + +/** + * Get Theme + * Get specific theme by ID. + */ +export const getEventTheme = ( + options: Options, ) => { return (options.client ?? _heyApiClient).get< - PredictionsRefinePredictionResponse, - PredictionsRefinePredictionError, + GetEventThemeResponse, + GetEventThemeError, + ThrowOnError + >({ + url: "/api/v1/event_themes/{theme_id}", + ...options, + }); +}; + +/** + * Update Theme + */ +export const updateEventTheme = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).patch< + UpdateEventThemeResponse, + UpdateEventThemeError, ThrowOnError >({ security: [ @@ -1238,175 +393,242 @@ export const predictionsRefinePrediction = < type: "http", }, ], - url: "/api/v1/predictions/refine/{id}", + url: "/api/v1/event_themes/{theme_id}", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Read Guests + */ +export const getGuests = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + GetGuestsResponse, + GetGuestsError, + ThrowOnError + >({ + url: "/api/v1/events/guests/", ...options, }); }; /** - * Update Prediction Favourite Status - * Update the favourite status of a prediction. - * - * Args: - * session: Database session dependency - * current_user: Current authenticated user - * id: UUID of the prediction to update - * favourite: New favourite status (true/false) - * - * Returns: - * Updated Prediction object - * - * Raises: - * HTTPException: 404 if prediction not found or 403 if user not authorized + * Create Guest */ -export const predictionsUpdatePredictionFavouriteStatus = < +export const createGuest = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + CreateGuestResponse, + CreateGuestError, + ThrowOnError + >({ + url: "/api/v1/events/guests/", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Delete Guest + */ +export const deleteGuest = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).delete< + DeleteGuestResponse, + DeleteGuestError, + ThrowOnError + >({ + url: "/api/v1/events/guests/{guest_id}", + ...options, + }); +}; + +/** + * Read Guest + */ +export const getGuest = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).get< + GetGuestResponse, + GetGuestError, + ThrowOnError + >({ + url: "/api/v1/events/guests/{guest_id}", + ...options, + }); +}; + +/** + * Update Guest + */ +export const updateGuest = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).put< + UpdateGuestResponse, + UpdateGuestError, + ThrowOnError + >({ + url: "/api/v1/events/guests/{guest_id}", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Set Guest Status + */ +export const setGuestStatusApiV1EventsGuestsGuestIdStatusPatch = < ThrowOnError extends boolean = false, >( options: Options< - PredictionsUpdatePredictionFavouriteStatusData, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchData, ThrowOnError >, ) => { return (options.client ?? _heyApiClient).patch< - PredictionsUpdatePredictionFavouriteStatusResponse, - PredictionsUpdatePredictionFavouriteStatusError, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponse, + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchError, ThrowOnError >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/predictions/{id}/favourite", + url: "/api/v1/events/guests/{guest_id}/status", ...options, }); }; /** - * Create User Subscription - * Create a subscription for a user (superuser only). + * Read Rsvps */ -export const subscriptionsCreateUserSubscription = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - SubscriptionsCreateUserSubscriptionResponse, - SubscriptionsCreateUserSubscriptionError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subscriptions/{user_id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Read Subscription - * Get a specific subscription. - * Superuser can access any subscription, users can only access their own. - */ -export const subscriptionsReadSubscription = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).get< - SubscriptionsReadSubscriptionResponse, - SubscriptionsReadSubscriptionError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subscriptions/{subscription_id}", - ...options, - }); -}; - -/** - * Update Subscription - * Update a subscription (superuser only). - * Handles upgrades/downgrades. - */ -export const subscriptionsUpdateSubscription = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).put< - SubscriptionsUpdateSubscriptionResponse, - SubscriptionsUpdateSubscriptionError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subscriptions/{subscription_id}", - ...options, - headers: { - "Content-Type": "application/json", - ...options?.headers, - }, - }); -}; - -/** - * Renew Subscription - * Renew a subscription (superuser only). - */ -export const subscriptionsRenewSubscription = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => { - return (options.client ?? _heyApiClient).post< - SubscriptionsRenewSubscriptionResponse, - SubscriptionsRenewSubscriptionError, - ThrowOnError - >({ - security: [ - { - scheme: "bearer", - type: "http", - }, - ], - url: "/api/v1/subscriptions/{subscription_id}/renew", - ...options, - }); -}; - -/** - * Read Subscriptions - * Get subscriptions. - * Regular users can only see their subscriptions. - * Superusers can see all subscriptions. - */ -export const subscriptionsReadSubscriptions = < - ThrowOnError extends boolean = false, ->( - options?: Options, +export const getRsvps = ( + options?: Options, ) => { return (options?.client ?? _heyApiClient).get< - SubscriptionsReadSubscriptionsResponse, - SubscriptionsReadSubscriptionsError, + GetRsvpsResponse, + GetRsvpsError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/", + ...options, + }); +}; + +/** + * Create Rsvp + */ +export const createRsvp = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + CreateRsvpResponse, + CreateRsvpError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Delete Rsvp + */ +export const deleteRsvp = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).delete< + DeleteRsvpResponse, + DeleteRsvpError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/{rsvp_id}", + ...options, + }); +}; + +/** + * Read Rsvp + */ +export const getRsvp = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).get< + GetRsvpResponse, + GetRsvpError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/{rsvp_id}", + ...options, + }); +}; + +/** + * Update Rsvp + */ +export const updateRsvp = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).put< + UpdateRsvpResponse, + UpdateRsvpError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/{rsvp_id}", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Update Rsvp Status + */ +export const updateRsvpStatus = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).patch< + UpdateRsvpStatusResponse, + UpdateRsvpStatusError, + ThrowOnError + >({ + url: "/api/v1/events/rsvps/{rsvp_id}/status", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Create Event + * Create a new event. + */ +export const createEvent = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + CreateEventResponse, + CreateEventError, ThrowOnError >({ security: [ @@ -1415,7 +637,225 @@ export const subscriptionsReadSubscriptions = < type: "http", }, ], - url: "/api/v1/subscriptions/", + url: "/api/v1/events/", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Get User Events + * Get all events created by the current user with pagination. + */ +export const getUserEvents = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + GetUserEventsResponse, + GetUserEventsError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/me", ...options, }); }; + +/** + * Get Upcoming Events + * Get upcoming public events with pagination. + */ +export const getUpcomingEvents = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + GetUpcomingEventsResponse, + GetUpcomingEventsError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/upcoming", + ...options, + }); +}; + +/** + * Get Public Events + * Get all public events with pagination. + */ +export const getPublicEvents = ( + options?: Options, +) => { + return (options?.client ?? _heyApiClient).get< + GetPublicEventsResponse, + GetPublicEventsError, + ThrowOnError + >({ + url: "/api/v1/events/public", + ...options, + }); +}; + +/** + * Delete Event + * Delete event (soft delete by default). + */ +export const deleteEvent = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).delete< + DeleteEventResponse, + DeleteEventError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/{event_id}", + ...options, + }); +}; + +/** + * Get Event + * Get event by ID. + */ +export const getEvent = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).get< + GetEventResponse, + GetEventError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/{event_id}", + ...options, + }); +}; + +/** + * Update Event + * Update event. + */ +export const updateEvent = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).put< + UpdateEventResponse, + UpdateEventError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/{event_id}", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Get Event By Slug + * Get event by slug. + */ +export const getEventBySlug = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).get< + GetEventBySlugResponse, + GetEventBySlugError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/events/by-slug/{slug}", + ...options, + }); +}; + +/** + * Generate Presigned Url + * Generate a presigned URL for uploading a file. + * + * This endpoint creates a secure token that allows direct upload to the storage system. + * After successful upload, the file will be accessible at the returned file_url. + */ +export const generatePresignedUrl = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + GeneratePresignedUrlResponse, + GeneratePresignedUrlError, + ThrowOnError + >({ + security: [ + { + scheme: "bearer", + type: "http", + }, + ], + url: "/api/v1/uploads/presigned-url", + ...options, + headers: { + "Content-Type": "application/json", + ...options?.headers, + }, + }); +}; + +/** + * Upload File + * Upload a file using a presigned URL token. + * + * This endpoint handles the actual file upload after a presigned URL is generated. + * The token validates the upload permissions and destination. + */ +export const uploadFile = ( + options: Options, +) => { + return (options.client ?? _heyApiClient).post< + unknown, + UploadFileError, + ThrowOnError + >({ + ...formDataBodySerializer, + url: "/api/v1/uploads/{token}", + ...options, + headers: { + "Content-Type": null, + ...options?.headers, + }, + }); +}; diff --git a/frontend/src/client/types.gen.ts b/frontend/src/client/types.gen.ts index d02fe6c..1b37e0a 100644 --- a/frontend/src/client/types.gen.ts +++ b/frontend/src/client/types.gen.ts @@ -1,39 +1,11 @@ // This file is auto-generated by @hey-api/openapi-ts -export type AgeClass = "kid" | "teen" | "young" | "middle_age" | "elder"; +export type BodyChangePassword = { + current_password: string; + new_password: string; +}; -export const AgeClass = { - KID: "kid", - TEEN: "teen", - YOUNG: "young", - MIDDLE_AGE: "middle_age", - ELDER: "elder", -} as const; - -/** - * Enumeration of all possible background types. - * The value is a lowercase string with underscores for spaces. - */ -export type BackgroundType = - | "white" - | "soft_gray" - | "creamy" - | "white_creamy" - | "raw_concrete"; - -/** - * Enumeration of all possible background types. - * The value is a lowercase string with underscores for spaces. - */ -export const BackgroundType = { - WHITE: "white", - SOFT_GRAY: "soft_gray", - CREAMY: "creamy", - WHITE_CREAMY: "white_creamy", - RAW_CONCRETE: "raw_concrete", -} as const; - -export type BodyLoginLoginAccessToken = { +export type BodyLoginOauth = { grant_type?: string | null; username: string; password: string; @@ -42,609 +14,352 @@ export type BodyLoginLoginAccessToken = { client_secret?: string | null; }; -/** - * Enumeration of all possible framing types for the subject. - * The value is a lowercase string with underscores for spaces. - */ -export type FramingType = - | "front_half_body" - | "front_half_body_lower" - | "front_full_body" - | "back_half_body" - | "back_half_body_lower" - | "back_full_body" - | "side_half_body" - | "side_half_body_lower" - | "side_full_body"; - -/** - * Enumeration of all possible framing types for the subject. - * The value is a lowercase string with underscores for spaces. - */ -export const FramingType = { - FRONT_HALF_BODY: "front_half_body", - FRONT_HALF_BODY_LOWER: "front_half_body_lower", - FRONT_FULL_BODY: "front_full_body", - BACK_HALF_BODY: "back_half_body", - BACK_HALF_BODY_LOWER: "back_half_body_lower", - BACK_FULL_BODY: "back_full_body", - SIDE_HALF_BODY: "side_half_body", - SIDE_HALF_BODY_LOWER: "side_half_body_lower", - SIDE_FULL_BODY: "side_full_body", -} as const; - -export type GenerationCreate = { - id?: string; - created_at?: string; - updated_at?: string; - batch_size: number; - positive_prompt: string; - negative_prompt?: string | null; - subject_id?: string | null; - subject_slug?: string | null; - product_id?: string | null; - product_slug?: string | null; - product_image?: string | null; - product_lora_weight?: number; - subject_lora_weight?: number; - product2_id?: string | null; - product2_slug?: string | null; - product2_image?: string | null; - product2_lora_weight?: number; - width: number; - height: number; - steps?: number; - seed?: number | null; - refine?: boolean; - scale_factor?: number | null; - lighting?: string | null; - framing?: string | null; - perspective?: string | null; - background?: string | null; - tone?: string | null; - pose?: string | null; - style?: string | null; - extra_prompt?: string | null; - generated_prompt?: string | null; - shot_type?: string | null; +export type BodyUploadFile = { + file: Blob | File; }; -export type GenerationPublic = { +export type EventCreate = { + title: string; + description?: string | null; + location_name?: string | null; + location_address?: string | null; + location_url?: string | null; + event_date: string; + event_start_time?: string | null; + event_end_time?: string | null; + timezone: string; + rsvp_deadline?: string | null; + is_public?: boolean; + access_code?: string | null; + theme_id?: string | null; + custom_theme_settings?: { + [key: string]: unknown; + } | null; + additional_info?: { + [key: string]: unknown; + } | null; + is_active?: boolean; + rsvp_enabled?: boolean; + gift_registry_enabled?: boolean; + updates_enabled?: boolean; + max_guests_per_invitation?: number | null; + contact_email?: string | null; + contact_phone?: string | null; + slug: string; +}; + +export type EventResponse = { + title: string; + description?: string | null; + location_name?: string | null; + location_address?: string | null; + location_url?: string | null; + event_date: string; + event_start_time?: string | null; + event_end_time?: string | null; + timezone: string; + rsvp_deadline?: string | null; + is_public?: boolean; + access_code?: string | null; + theme_id?: string | null; + custom_theme_settings?: { + [key: string]: unknown; + } | null; + additional_info?: { + [key: string]: unknown; + } | null; + is_active?: boolean; + rsvp_enabled?: boolean; + gift_registry_enabled?: boolean; + updates_enabled?: boolean; + max_guests_per_invitation?: number | null; + contact_email?: string | null; + contact_phone?: string | null; id: string; + created_by: string; created_at: string; updated_at: string; - batch_size: number; - positive_prompt: string; - negative_prompt?: string | null; - subject_id: string; - product_id: string; - subject_image_url?: string | null; - product_image_url?: string | null; - product_lora_weight?: number; - subject_lora_weight?: number; - product2_id?: string | null; - product2_image_url?: string | null; - product2_lora_weight?: number; - width: number; - height: number; - steps: number; - seed: number; - refine: boolean; - scale_factor?: number | null; - lighting?: string | null; - framing?: string | null; - perspective?: string | null; - background?: string | null; - tone?: string | null; - pose?: string | null; - style?: string | null; - generated_prompt?: string | null; - extra_prompt?: string | null; - predictions: Array; - owner_id: string; - shot_type?: string | null; + slug: string; }; -export type GenerationStatus = { +export type EventThemeCreate = { + name: string; + description?: string | null; + preview_image_url?: string | null; + background_image_url?: string | null; + foreground_image_url?: string | null; + color_palette: { + [key: string]: string; + }; + asset_image_urls?: { + [key: string]: string; + } | null; + fonts: { + [key: string]: string; + }; + is_active?: boolean; +}; + +export type EventThemeResponse = { + name: string; + description?: string | null; + preview_image_url?: string | null; + background_image_url?: string | null; + foreground_image_url?: string | null; + color_palette: { + [key: string]: string; + }; + asset_image_urls?: { + [key: string]: string; + } | null; + fonts: { + [key: string]: string; + }; + is_active?: boolean; id: string; - status: string; - total: number; - completed: number; - error: number; - latest_prediction_status?: PredictionStatus | null; +}; + +export type EventThemeUpdate = { + name?: string | null; + description?: string | null; + preview_image_url?: string | null; + background_image_url?: string | null; + foreground_image_url?: string | null; + color_palette?: { + [key: string]: string; + } | null; + asset_image_urls?: { + [key: string]: string; + } | null; + fonts?: { + [key: string]: string; + } | null; + is_active?: boolean; +}; + +export type EventUpdate = { + title?: string | null; + description?: string | null; + location_name?: string | null; + location_address?: string | null; + location_url?: string | null; + event_date?: string | null; + event_start_time?: string | null; + event_end_time?: string | null; + timezone?: string | null; + rsvp_deadline?: string | null; + is_public?: boolean; + access_code?: string | null; + theme_id?: string | null; + custom_theme_settings?: { + [key: string]: unknown; + } | null; + additional_info?: { + [key: string]: unknown; + } | null; + is_active?: boolean; + rsvp_enabled?: boolean; + gift_registry_enabled?: boolean; + updates_enabled?: boolean; + max_guests_per_invitation?: number | null; + contact_email?: string | null; + contact_phone?: string | null; + slug?: string | null; +}; + +export type GuestCreate = { + event_id: string; + invited_by: string; + user_id?: string | null; + full_name: string; + email?: string | null; + phone?: string | null; + max_additional_guests?: number | null; + dietary_restrictions?: string | null; + notes?: string | null; + custom_fields?: { + [key: string]: unknown; + } | null; + can_bring_guests?: boolean | null; + invitation_code: string; +}; + +export type GuestRead = { + event_id: string; + invited_by: string; + user_id?: string | null; + full_name: string; + email?: string | null; + phone?: string | null; + max_additional_guests?: number | null; + dietary_restrictions?: string | null; + notes?: string | null; + custom_fields?: { + [key: string]: unknown; + } | null; + can_bring_guests?: boolean | null; + id: string; + status: GuestStatus; + invitation_sent_at?: string | null; + response_date?: string | null; + actual_additional_guests: number; + is_blocked: boolean; +}; + +export type GuestStatus = + | "invited" + | "pending" + | "confirmed" + | "declined" + | "waitlisted" + | "cancelled"; + +export const GuestStatus = { + INVITED: "invited", + PENDING: "pending", + CONFIRMED: "confirmed", + DECLINED: "declined", + WAITLISTED: "waitlisted", + CANCELLED: "cancelled", +} as const; + +export type GuestUpdate = { + full_name?: string | null; + email?: string | null; + phone?: string | null; + status?: GuestStatus | null; + max_additional_guests?: number | null; + actual_additional_guests?: number | null; + dietary_restrictions?: string | null; + notes?: string | null; + custom_fields?: { + [key: string]: unknown; + } | null; + is_blocked?: boolean | null; + can_bring_guests?: boolean | null; }; export type HttpValidationError = { detail?: Array; }; -export type Message = { - message: string; +export type LoginRequest = { + email: string; + password: string; }; -export type NewPassword = { - token: string; - new_password: string; +export type PaginatedResponseEventResponse = { + total: number; + items: Array; + page: number; + size: number; }; /** - * Tracks the payment state of a subscription - * - * PENDING: Initial state when subscription is created but not paid - * PAID: Payment successfully received - * PARTIALLY_PAID: Some payment received but full amount not covered - * FAILED: Payment attempt failed - * REFUNDED: Full payment refunded - * PARTIALLY_REFUNDED: Partial refund issued + * Request model for generating presigned URLs. */ -export type PaymentStatus = - | "PENDING" - | "PAID" - | "PARTIALLY_PAID" - | "FAILED" - | "REFUNDED" - | "PARTIALLY_REFUNDED"; +export type PresignedUrlRequest = { + /** + * Original filename of the image + */ + filename: string; + /** + * Content type of the file (e.g., image/jpeg) + */ + content_type: string; + /** + * Folder to store the file in + */ + folder?: string; +}; /** - * Tracks the payment state of a subscription - * - * PENDING: Initial state when subscription is created but not paid - * PAID: Payment successfully received - * PARTIALLY_PAID: Some payment received but full amount not covered - * FAILED: Payment attempt failed - * REFUNDED: Full payment refunded - * PARTIALLY_REFUNDED: Partial refund issued + * Response model for presigned URL generation. */ -export const PaymentStatus = { - PENDING: "PENDING", - PAID: "PAID", - PARTIALLY_PAID: "PARTIALLY_PAID", - FAILED: "FAILED", - REFUNDED: "REFUNDED", - PARTIALLY_REFUNDED: "PARTIALLY_REFUNDED", -} as const; - -export type Prediction = { - id?: string; - created_at?: string; - updated_at?: string; - status?: PredictionStatus; - seed: number; - result_image_url?: string | null; - refined_image_url?: string | null; - prompt_id?: string | null; - generation_id: string; - favourite?: boolean; - shot_type?: string | null; +export type PresignedUrlResponse = { + /** + * URL to upload the file to + */ + upload_url: string; + /** + * URL where the file will be accessible after upload + */ + file_url: string; + /** + * Time in seconds until the upload URL expires + */ + expires_in: number; }; -export type PredictionStatus = - | "pending" - | "captioning" - | "generating" - | "intermediate" - | "tryon-generating" - | "refining" - | "completed" - | "error"; - -export const PredictionStatus = { - PENDING: "pending", - CAPTIONING: "captioning", - GENERATING: "generating", - INTERMEDIATE: "intermediate", - TRYON_GENERATING: "tryon-generating", - REFINING: "refining", - COMPLETED: "completed", - ERROR: "error", -} as const; - -export type PredictionsPublic = { - data: Array; - count: number; -}; - -export type Product = { - id?: string; - created_at?: string; - updated_at?: string; - sku: string; - name: string; - slug: string; - local_model_path?: string | null; - lora_trigger?: string | null; - brand?: string | null; - description?: string | null; - type: ProductType; - category: ProductCategory; - fitting?: ProductFitting | null; - cover_image_url?: string | null; - materials?: string | null; - public?: boolean; - enabled?: boolean; - archived?: boolean; - demo?: boolean; - owner_id: string; - lora_status?: string; - /** - * ID of the current/last training task - */ - current_training_id?: string | null; - /** - * Current training progress percentage - */ - training_progress?: number; - /** - * Last training error message if any - */ - training_error?: string | null; - data_image_urls?: Array; - /** - * Dictionary of selected shots with their predictions - */ - selected_shots?: { - [key: string]: { - [key: string]: unknown; - }; - }; -}; - -export type ProductCategory = "UPPER_BODY" | "LOWER_BODY" | "DRESSES"; - -export const ProductCategory = { - UPPER_BODY: "UPPER_BODY", - LOWER_BODY: "LOWER_BODY", - DRESSES: "DRESSES", -} as const; - -export type ProductCreate = { - sku?: string | null; - name: string; - brand?: string | null; - description?: string | null; - type: ProductType; - local_model_path?: string | null; - lora_trigger?: string | null; - category: ProductCategory; - fitting?: ProductFitting | null; - /** - * URL or base64 string for cover image - */ - cover_image: string; - materials?: string | null; - public?: boolean; - /** - * List of image URLs or base64 strings - */ - data_images?: Array | null; - /** - * Whether to start training after creation - */ - train?: boolean; -}; - -export type ProductFitting = "regular" | "slim" | "loose" | "oversize"; - -export const ProductFitting = { - REGULAR: "regular", - SLIM: "slim", - LOOSE: "loose", - OVERSIZE: "oversize", -} as const; - -export type ProductPublic = { +export type RsvpSchema = { + status: RsvpStatus; + number_of_guests?: number; + response_message?: string | null; + dietary_requirements?: string | null; + additional_info?: unknown; id: string; + response_date: string; created_at: string; - updated_at?: string; - sku: string; - name: string; - slug: string; - brand: string | null; - description: string | null; - type: ProductType; - category: ProductCategory; - fitting: ProductFitting | null; - cover_image_url: string; - materials: string; - public: boolean; - enabled: boolean; - archived: boolean; - demo: boolean; - owner_id: string; - lora_status: string; - lora_trigger: string | null; - data_image_urls: Array; - current_training_id?: string | null; - training_progress?: number; - training_error?: string | null; - selected_shots?: { + updated_at: string; +}; + +export type RsvpSchemaCreate = { + status: RsvpStatus; + number_of_guests?: number; + response_message?: string | null; + dietary_requirements?: string | null; + additional_info?: unknown; + event_id: string; + guest_id: string; +}; + +export type RsvpSchemaUpdate = { + status?: RsvpStatus | null; + number_of_guests?: number | null; + response_message?: string | null; + dietary_requirements?: string | null; + additional_info?: { [key: string]: unknown; - }; + } | null; }; -export type ProductType = "garment" | "bag" | "other"; +export type RsvpStatus = "attending" | "not_attending" | "maybe"; -export const ProductType = { - GARMENT: "garment", - BAG: "bag", - OTHER: "other", +export const RsvpStatus = { + ATTENDING: "attending", + NOT_ATTENDING: "not_attending", + MAYBE: "maybe", } as const; -export type ProductUpdate = { - name?: string | null; - sku?: string | null; - brand?: string | null; - description?: string | null; - type?: ProductType | null; - category?: ProductCategory | null; - fitting?: ProductFitting | null; - /** - * URL or base64 string for cover image - */ - cover_image?: string | null; - materials?: string | null; - public?: boolean | null; - /** - * List of image URLs or base64 strings to update - */ - data_images?: Array | null; -}; - -export type ProductsPublic = { - id?: string; - created_at?: string; - updated_at?: string; - data: Array; - count: number; -}; - -export type PromptBuildRequest = { - subject_id?: string | null; - product_id?: string | null; - framing?: FramingType | null; - background?: string | null; - style?: string | null; -}; - -export type PromptResponse = { - prompt: string; - parameters: { - [key: string]: unknown; - }; -}; - -export type PromptSection = "subject" | "product" | "background" | "framing"; - -export const PromptSection = { - SUBJECT: "subject", - PRODUCT: "product", - BACKGROUND: "background", - FRAMING: "framing", -} as const; - -export type PromptSectionRequest = { - section: PromptSection; - /** - * Mandatory for subject and product sections - */ - id?: string | null; - /** - * Mandatory for framing and background sections - */ - selector?: FramingType | BackgroundType | null; -}; - -export type PromptSectionResponse = { - section: PromptSection; - id?: string | null; - selector?: string | null; - result: string; -}; - -export type SelectedShotRequest = { - id?: string; - created_at?: string; - updated_at?: string; - /** - * ID of the product - */ - product_id: string; - /** - * Type of shot (e.g. 'full-body', 'half-body-front') - */ - shot_type: string; - /** - * ID of the prediction to set as favorite. If None, any existing favorite will be removed. - */ - prediction_id?: string | null; -}; - -/** - * Defines the type of service subscription - */ -export type ServiceType = "SELF_SERVICE" | "AGENCY"; - -/** - * Defines the type of service subscription - */ -export const ServiceType = { - SELF_SERVICE: "SELF_SERVICE", - AGENCY: "AGENCY", -} as const; - -export type SubjectCreate = { - name: string; - description?: string | null; - local_model_path?: string | null; - lora_trigger?: string | null; - lora_status?: string; - cover_image: string; - data_images?: Array | null; - age_class: AgeClass; - positive_prompt?: string | null; - negative_prompt?: string | null; - ethnicity?: string | null; - public?: boolean; - subject_type?: SubjectType; -}; - -export type SubjectPublic = { - id: string; - created_at: string; - updated_at?: string; - name: string; - slug: string; - description: string | null; - age_class: AgeClass; - subject_type: SubjectType; - positive_prompt?: string | null; - negative_prompt?: string | null; - ethnicity: string | null; - public: boolean; - enabled: boolean; - lora_status: string; - lora_trigger: string | null; - cover_image_url: string; - data_image_urls: Array; - owner_id: string; -}; - -export type SubjectType = "AI" | "REAL"; - -export const SubjectType = { - AI: "AI", - REAL: "REAL", -} as const; - -export type SubjectUpdate = { - name?: string | null; - description?: string | null; - cover_image?: string | null; - data_images?: Array | null; - age_class?: AgeClass | null; - positive_prompt?: string | null; - negative_prompt?: string | null; - ethnicity?: string | null; - public?: boolean | null; -}; - -export type SubjectsPublic = { - id?: string; - created_at?: string; - updated_at?: string; - data: Array; - count: number; -}; - -export type SubscriptionCreate = { - service_type: ServiceType; - tier: SubscriptionTier; - payment_id?: string | null; -}; - -export type SubscriptionPublic = { - id: string; - created_at?: string; - updated_at?: string; - user_id: string; - service_type: ServiceType; - tier: SubscriptionTier; - start_date: string; - end_date: string; - grace_period_end: string; - credits_total: number; - credits_used: number; - credits_remaining: number; - is_active: boolean; - payment_status: PaymentStatus; - base_price: number; - actual_price: number; - currency: string; -}; - -/** - * Defines the subscription tier level - */ -export type SubscriptionTier = "START" | "SCALE" | "ENTERPRISE"; - -/** - * Defines the subscription tier level - */ -export const SubscriptionTier = { - START: "START", - SCALE: "SCALE", - ENTERPRISE: "ENTERPRISE", -} as const; - -export type SubscriptionUpdate = { - service_type?: ServiceType | null; - tier?: SubscriptionTier | null; -}; - -export type SubscriptionsPublic = { - id?: string; - created_at?: string; - updated_at?: string; - data: Array; - count: number; +export type RefreshTokenRequest = { + refresh_token: string; }; export type Token = { access_token: string; + refresh_token?: string | null; token_type?: string; }; -export type UpdatePassword = { - current_password: string; - new_password: string; -}; - export type UserCreate = { email: string; + first_name: string; + last_name?: string | null; + phone_number?: string | null; password: string; - full_name?: string | null; is_superuser?: boolean; - is_active?: boolean; }; -export type UserPublic = { +export type UserResponse = { + email: string; + first_name: string; + last_name?: string | null; + phone_number?: string | null; id: string; - created_at?: string; - updated_at?: string; - email: string; - full_name: string | null; is_active: boolean; - is_superuser?: boolean; -}; - -export type UserRegister = { - id?: string; - created_at?: string; - updated_at?: string; - email: string; - password: string; - full_name?: string | null; -}; - -export type UserUpdate = { - email?: string | null; - full_name?: string | null; - password?: string | null; - is_superuser?: boolean | null; - is_active?: boolean | null; -}; - -export type UserUpdateMe = { - full_name?: string | null; - email?: string | null; -}; - -export type UsersPublic = { - id?: string; - created_at?: string; - updated_at?: string; - data: Array; - count: number; + is_superuser: boolean; + created_at: string; + updated_at?: string | null; }; export type ValidationError = { @@ -653,1407 +368,928 @@ export type ValidationError = { type: string; }; -export type LoginLoginAccessTokenData = { - body: BodyLoginLoginAccessToken; - path?: never; - query?: never; - url: "/api/v1/login/access-token"; -}; - -export type LoginLoginAccessTokenErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type LoginLoginAccessTokenError = - LoginLoginAccessTokenErrors[keyof LoginLoginAccessTokenErrors]; - -export type LoginLoginAccessTokenResponses = { - /** - * Successful Response - */ - 200: Token; -}; - -export type LoginLoginAccessTokenResponse = - LoginLoginAccessTokenResponses[keyof LoginLoginAccessTokenResponses]; - -export type LoginTestTokenData = { +export type RootGetData = { body?: never; path?: never; query?: never; - url: "/api/v1/login/test-token"; + url: "/"; }; -export type LoginTestTokenResponses = { - /** - * Successful Response - */ - 200: UserPublic; -}; - -export type LoginTestTokenResponse = - LoginTestTokenResponses[keyof LoginTestTokenResponses]; - -export type LoginRecoverPasswordData = { - body?: never; - path: { - email: string; - }; - query?: never; - url: "/api/v1/password-recovery/{email}"; -}; - -export type LoginRecoverPasswordErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type LoginRecoverPasswordError = - LoginRecoverPasswordErrors[keyof LoginRecoverPasswordErrors]; - -export type LoginRecoverPasswordResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type LoginRecoverPasswordResponse = - LoginRecoverPasswordResponses[keyof LoginRecoverPasswordResponses]; - -export type LoginResetPasswordData = { - body: NewPassword; - path?: never; - query?: never; - url: "/api/v1/reset-password/"; -}; - -export type LoginResetPasswordErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type LoginResetPasswordError = - LoginResetPasswordErrors[keyof LoginResetPasswordErrors]; - -export type LoginResetPasswordResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type LoginResetPasswordResponse = - LoginResetPasswordResponses[keyof LoginResetPasswordResponses]; - -export type LoginRecoverPasswordHtmlContentData = { - body?: never; - path: { - email: string; - }; - query?: never; - url: "/api/v1/password-recovery-html-content/{email}"; -}; - -export type LoginRecoverPasswordHtmlContentErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type LoginRecoverPasswordHtmlContentError = - LoginRecoverPasswordHtmlContentErrors[keyof LoginRecoverPasswordHtmlContentErrors]; - -export type LoginRecoverPasswordHtmlContentResponses = { +export type RootGetResponses = { /** * Successful Response */ 200: string; }; -export type LoginRecoverPasswordHtmlContentResponse = - LoginRecoverPasswordHtmlContentResponses[keyof LoginRecoverPasswordHtmlContentResponses]; +export type RootGetResponse = RootGetResponses[keyof RootGetResponses]; -export type UsersReadUsersData = { - body?: never; - path?: never; - query?: { - skip?: number; - limit?: number; - }; - url: "/api/v1/users/"; -}; - -export type UsersReadUsersErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type UsersReadUsersError = - UsersReadUsersErrors[keyof UsersReadUsersErrors]; - -export type UsersReadUsersResponses = { - /** - * Successful Response - */ - 200: UsersPublic; -}; - -export type UsersReadUsersResponse = - UsersReadUsersResponses[keyof UsersReadUsersResponses]; - -export type UsersCreateUserData = { +export type RegisterData = { body: UserCreate; path?: never; query?: never; - url: "/api/v1/users/"; + url: "/api/v1/auth/register"; }; -export type UsersCreateUserErrors = { +export type RegisterErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type UsersCreateUserError = - UsersCreateUserErrors[keyof UsersCreateUserErrors]; +export type RegisterError = RegisterErrors[keyof RegisterErrors]; -export type UsersCreateUserResponses = { +export type RegisterResponses = { /** * Successful Response */ - 200: UserPublic; + 201: UserResponse; }; -export type UsersCreateUserResponse = - UsersCreateUserResponses[keyof UsersCreateUserResponses]; +export type RegisterResponse = RegisterResponses[keyof RegisterResponses]; -export type UsersDeleteUserMeData = { - body?: never; +export type LoginData = { + body: LoginRequest; path?: never; query?: never; - url: "/api/v1/users/me"; + url: "/api/v1/auth/login"; }; -export type UsersDeleteUserMeResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type UsersDeleteUserMeResponse = - UsersDeleteUserMeResponses[keyof UsersDeleteUserMeResponses]; - -export type UsersReadUserMeData = { - body?: never; - path?: never; - query?: never; - url: "/api/v1/users/me"; -}; - -export type UsersReadUserMeResponses = { - /** - * Successful Response - */ - 200: UserPublic; -}; - -export type UsersReadUserMeResponse = - UsersReadUserMeResponses[keyof UsersReadUserMeResponses]; - -export type UsersUpdateUserMeData = { - body: UserUpdateMe; - path?: never; - query?: never; - url: "/api/v1/users/me"; -}; - -export type UsersUpdateUserMeErrors = { +export type LoginErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type UsersUpdateUserMeError = - UsersUpdateUserMeErrors[keyof UsersUpdateUserMeErrors]; +export type LoginError = LoginErrors[keyof LoginErrors]; -export type UsersUpdateUserMeResponses = { +export type LoginResponses = { /** * Successful Response */ - 200: UserPublic; + 200: Token; }; -export type UsersUpdateUserMeResponse = - UsersUpdateUserMeResponses[keyof UsersUpdateUserMeResponses]; +export type LoginResponse = LoginResponses[keyof LoginResponses]; -export type UsersUpdatePasswordMeData = { - body: UpdatePassword; +export type LoginOauthData = { + body: BodyLoginOauth; path?: never; query?: never; - url: "/api/v1/users/me/password"; + url: "/api/v1/auth/login/oauth"; }; -export type UsersUpdatePasswordMeErrors = { +export type LoginOauthErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type UsersUpdatePasswordMeError = - UsersUpdatePasswordMeErrors[keyof UsersUpdatePasswordMeErrors]; +export type LoginOauthError = LoginOauthErrors[keyof LoginOauthErrors]; -export type UsersUpdatePasswordMeResponses = { +export type LoginOauthResponses = { /** * Successful Response */ - 200: Message; + 200: Token; }; -export type UsersUpdatePasswordMeResponse = - UsersUpdatePasswordMeResponses[keyof UsersUpdatePasswordMeResponses]; +export type LoginOauthResponse = LoginOauthResponses[keyof LoginOauthResponses]; -export type UsersRegisterUserData = { - body: UserRegister; +export type RefreshTokenData = { + body: RefreshTokenRequest; path?: never; query?: never; - url: "/api/v1/users/signup"; + url: "/api/v1/auth/refresh"; }; -export type UsersRegisterUserErrors = { +export type RefreshTokenErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type UsersRegisterUserError = - UsersRegisterUserErrors[keyof UsersRegisterUserErrors]; +export type RefreshTokenError = RefreshTokenErrors[keyof RefreshTokenErrors]; -export type UsersRegisterUserResponses = { +export type RefreshTokenResponses = { /** * Successful Response */ - 200: UserPublic; + 200: Token; }; -export type UsersRegisterUserResponse = - UsersRegisterUserResponses[keyof UsersRegisterUserResponses]; +export type RefreshTokenResponse = + RefreshTokenResponses[keyof RefreshTokenResponses]; -export type UsersDeleteUserData = { - body?: never; - path: { - user_id: string; - }; +export type ChangePasswordData = { + body: BodyChangePassword; + path?: never; query?: never; - url: "/api/v1/users/{user_id}"; + url: "/api/v1/auth/change-password"; }; -export type UsersDeleteUserErrors = { +export type ChangePasswordErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type UsersDeleteUserError = - UsersDeleteUserErrors[keyof UsersDeleteUserErrors]; +export type ChangePasswordError = + ChangePasswordErrors[keyof ChangePasswordErrors]; -export type UsersDeleteUserResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type UsersDeleteUserResponse = - UsersDeleteUserResponses[keyof UsersDeleteUserResponses]; - -export type UsersReadUserByIdData = { - body?: never; - path: { - user_id: string; - }; - query?: never; - url: "/api/v1/users/{user_id}"; -}; - -export type UsersReadUserByIdErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type UsersReadUserByIdError = - UsersReadUserByIdErrors[keyof UsersReadUserByIdErrors]; - -export type UsersReadUserByIdResponses = { - /** - * Successful Response - */ - 200: UserPublic; -}; - -export type UsersReadUserByIdResponse = - UsersReadUserByIdResponses[keyof UsersReadUserByIdResponses]; - -export type UsersUpdateUserData = { - body: UserUpdate; - path: { - user_id: string; - }; - query?: never; - url: "/api/v1/users/{user_id}"; -}; - -export type UsersUpdateUserErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type UsersUpdateUserError = - UsersUpdateUserErrors[keyof UsersUpdateUserErrors]; - -export type UsersUpdateUserResponses = { - /** - * Successful Response - */ - 200: UserPublic; -}; - -export type UsersUpdateUserResponse = - UsersUpdateUserResponses[keyof UsersUpdateUserResponses]; - -export type UtilsTestEmailData = { - body?: never; - path?: never; - query: { - email_to: string; - }; - url: "/api/v1/utils/test-email/"; -}; - -export type UtilsTestEmailErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type UtilsTestEmailError = - UtilsTestEmailErrors[keyof UtilsTestEmailErrors]; - -export type UtilsTestEmailResponses = { - /** - * Successful Response - */ - 201: Message; -}; - -export type UtilsTestEmailResponse = - UtilsTestEmailResponses[keyof UtilsTestEmailResponses]; - -export type UtilsHealthCheckData = { - body?: never; - path?: never; - query?: never; - url: "/api/v1/utils/health-check/"; -}; - -export type UtilsHealthCheckResponses = { - /** - * Successful Response - */ - 200: boolean; -}; - -export type UtilsHealthCheckResponse = - UtilsHealthCheckResponses[keyof UtilsHealthCheckResponses]; - -export type UtilsSystemHealthCheckData = { - body?: never; - path?: never; - query?: never; - url: "/api/v1/utils/system-health-check"; -}; - -export type UtilsSystemHealthCheckResponses = { - /** - * Successful Response - */ - 200: { - [key: string]: unknown; - }; -}; - -export type UtilsSystemHealthCheckResponse = - UtilsSystemHealthCheckResponses[keyof UtilsSystemHealthCheckResponses]; - -export type UtilsDbHealthData = { - body?: never; - path?: never; - query?: never; - url: "/api/v1/utils/db-check/"; -}; - -export type UtilsDbHealthResponses = { +export type ChangePasswordResponses = { /** * Successful Response */ 200: unknown; }; -export type ProductsReadProductsData = { +export type GetCurrentUserInfoData = { body?: never; path?: never; - query?: { - archived?: boolean | null; - enabled?: boolean; - brand?: string | null; - skip?: number; - limit?: number; - }; - url: "/api/v1/products/"; -}; - -export type ProductsReadProductsErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsReadProductsError = - ProductsReadProductsErrors[keyof ProductsReadProductsErrors]; - -export type ProductsReadProductsResponses = { - /** - * Successful Response - */ - 200: ProductsPublic; -}; - -export type ProductsReadProductsResponse = - ProductsReadProductsResponses[keyof ProductsReadProductsResponses]; - -export type ProductsCreateProductData = { - body: ProductCreate; - path?: never; query?: never; - url: "/api/v1/products/"; + url: "/api/v1/auth/me"; }; -export type ProductsCreateProductErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsCreateProductError = - ProductsCreateProductErrors[keyof ProductsCreateProductErrors]; - -export type ProductsCreateProductResponses = { +export type GetCurrentUserInfoResponses = { /** * Successful Response */ - 200: ProductPublic; + 200: UserResponse; }; -export type ProductsCreateProductResponse = - ProductsCreateProductResponses[keyof ProductsCreateProductResponses]; +export type GetCurrentUserInfoResponse = + GetCurrentUserInfoResponses[keyof GetCurrentUserInfoResponses]; -export type ProductsDeleteProductData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/products/{id}"; -}; - -export type ProductsDeleteProductErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsDeleteProductError = - ProductsDeleteProductErrors[keyof ProductsDeleteProductErrors]; - -export type ProductsDeleteProductResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type ProductsDeleteProductResponse = - ProductsDeleteProductResponses[keyof ProductsDeleteProductResponses]; - -export type ProductsReadProductData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/products/{id}"; -}; - -export type ProductsReadProductErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsReadProductError = - ProductsReadProductErrors[keyof ProductsReadProductErrors]; - -export type ProductsReadProductResponses = { - /** - * Successful Response - */ - 200: ProductPublic; -}; - -export type ProductsReadProductResponse = - ProductsReadProductResponses[keyof ProductsReadProductResponses]; - -export type ProductsUpdateProductData = { - body: ProductUpdate; - path: { - id: string; - }; - query?: never; - url: "/api/v1/products/{id}"; -}; - -export type ProductsUpdateProductErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsUpdateProductError = - ProductsUpdateProductErrors[keyof ProductsUpdateProductErrors]; - -export type ProductsUpdateProductResponses = { - /** - * Successful Response - */ - 200: ProductPublic; -}; - -export type ProductsUpdateProductResponse = - ProductsUpdateProductResponses[keyof ProductsUpdateProductResponses]; - -export type ProductsReadProductGenerationsData = { - body?: never; - path: { - product_id: string; - }; - query?: { - skip?: number; - limit?: number; - }; - url: "/api/v1/products/{product_id}/generations"; -}; - -export type ProductsReadProductGenerationsErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsReadProductGenerationsError = - ProductsReadProductGenerationsErrors[keyof ProductsReadProductGenerationsErrors]; - -export type ProductsReadProductGenerationsResponses = { - /** - * Successful Response - */ - 200: Array; -}; - -export type ProductsReadProductGenerationsResponse = - ProductsReadProductGenerationsResponses[keyof ProductsReadProductGenerationsResponses]; - -export type ProductsRetrainProductData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/products{id}/retrain"; -}; - -export type ProductsRetrainProductErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsRetrainProductError = - ProductsRetrainProductErrors[keyof ProductsRetrainProductErrors]; - -export type ProductsRetrainProductResponses = { - /** - * Successful Response - */ - 200: ProductPublic; -}; - -export type ProductsRetrainProductResponse = - ProductsRetrainProductResponses[keyof ProductsRetrainProductResponses]; - -export type ProductsUpdateProductArchiveStatusData = { - body?: never; - path: { - id: string; - }; - query: { - archived: boolean; - }; - url: "/api/v1/products/{id}/archived"; -}; - -export type ProductsUpdateProductArchiveStatusErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsUpdateProductArchiveStatusError = - ProductsUpdateProductArchiveStatusErrors[keyof ProductsUpdateProductArchiveStatusErrors]; - -export type ProductsUpdateProductArchiveStatusResponses = { - /** - * Successful Response - */ - 200: ProductPublic; -}; - -export type ProductsUpdateProductArchiveStatusResponse = - ProductsUpdateProductArchiveStatusResponses[keyof ProductsUpdateProductArchiveStatusResponses]; - -export type ProductsSetSelectedShotData = { - body: SelectedShotRequest; - path: { - product_id: string; - }; - query?: never; - url: "/api/v1/products/selected_shot/{product_id}"; -}; - -export type ProductsSetSelectedShotErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type ProductsSetSelectedShotError = - ProductsSetSelectedShotErrors[keyof ProductsSetSelectedShotErrors]; - -export type ProductsSetSelectedShotResponses = { - /** - * Successful Response - */ - 200: Product; -}; - -export type ProductsSetSelectedShotResponse = - ProductsSetSelectedShotResponses[keyof ProductsSetSelectedShotResponses]; - -export type SubjectsReadSubjectsData = { +export type ListEventThemesData = { body?: never; path?: never; query?: { skip?: number; limit?: number; }; - url: "/api/v1/subjects/"; + url: "/api/v1/event_themes/"; }; -export type SubjectsReadSubjectsErrors = { +export type ListEventThemesErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type SubjectsReadSubjectsError = - SubjectsReadSubjectsErrors[keyof SubjectsReadSubjectsErrors]; +export type ListEventThemesError = + ListEventThemesErrors[keyof ListEventThemesErrors]; -export type SubjectsReadSubjectsResponses = { +export type ListEventThemesResponses = { /** * Successful Response */ - 200: SubjectsPublic; + 200: Array; }; -export type SubjectsReadSubjectsResponse = - SubjectsReadSubjectsResponses[keyof SubjectsReadSubjectsResponses]; +export type ListEventThemesResponse = + ListEventThemesResponses[keyof ListEventThemesResponses]; -export type SubjectsCreateSubjectData = { - body: SubjectCreate; +export type CreateEventThemeData = { + body: EventThemeCreate; path?: never; query?: never; - url: "/api/v1/subjects/"; + url: "/api/v1/event_themes/"; }; -export type SubjectsCreateSubjectErrors = { +export type CreateEventThemeErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type SubjectsCreateSubjectError = - SubjectsCreateSubjectErrors[keyof SubjectsCreateSubjectErrors]; +export type CreateEventThemeError = + CreateEventThemeErrors[keyof CreateEventThemeErrors]; -export type SubjectsCreateSubjectResponses = { +export type CreateEventThemeResponses = { /** * Successful Response */ - 200: SubjectPublic; + 200: EventThemeResponse; }; -export type SubjectsCreateSubjectResponse = - SubjectsCreateSubjectResponses[keyof SubjectsCreateSubjectResponses]; +export type CreateEventThemeResponse = + CreateEventThemeResponses[keyof CreateEventThemeResponses]; -export type SubjectsDeleteSubjectData = { +export type DeleteEventThemeData = { body?: never; path: { - id: string; + theme_id: string; }; - query?: never; - url: "/api/v1/subjects/{id}"; -}; - -export type SubjectsDeleteSubjectErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubjectsDeleteSubjectError = - SubjectsDeleteSubjectErrors[keyof SubjectsDeleteSubjectErrors]; - -export type SubjectsDeleteSubjectResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type SubjectsDeleteSubjectResponse = - SubjectsDeleteSubjectResponses[keyof SubjectsDeleteSubjectResponses]; - -export type SubjectsReadSubjectData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/subjects/{id}"; -}; - -export type SubjectsReadSubjectErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubjectsReadSubjectError = - SubjectsReadSubjectErrors[keyof SubjectsReadSubjectErrors]; - -export type SubjectsReadSubjectResponses = { - /** - * Successful Response - */ - 200: SubjectPublic; -}; - -export type SubjectsReadSubjectResponse = - SubjectsReadSubjectResponses[keyof SubjectsReadSubjectResponses]; - -export type SubjectsUpdateSubjectData = { - body: SubjectUpdate; - path: { - id: string; - }; - query?: never; - url: "/api/v1/subjects/{id}"; -}; - -export type SubjectsUpdateSubjectErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubjectsUpdateSubjectError = - SubjectsUpdateSubjectErrors[keyof SubjectsUpdateSubjectErrors]; - -export type SubjectsUpdateSubjectResponses = { - /** - * Successful Response - */ - 200: SubjectPublic; -}; - -export type SubjectsUpdateSubjectResponse = - SubjectsUpdateSubjectResponses[keyof SubjectsUpdateSubjectResponses]; - -export type GenerationsReadGenerationsData = { - body?: never; - path?: never; query?: { - skip?: number; - limit?: number; + /** + * Perform hard delete instead of soft delete + */ + hard_delete?: boolean; }; - url: "/api/v1/generations/"; + url: "/api/v1/event_themes/{theme_id}"; }; -export type GenerationsReadGenerationsErrors = { +export type DeleteEventThemeErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type GenerationsReadGenerationsError = - GenerationsReadGenerationsErrors[keyof GenerationsReadGenerationsErrors]; +export type DeleteEventThemeError = + DeleteEventThemeErrors[keyof DeleteEventThemeErrors]; -export type GenerationsReadGenerationsResponses = { - /** - * Successful Response - */ - 200: Array; -}; - -export type GenerationsReadGenerationsResponse = - GenerationsReadGenerationsResponses[keyof GenerationsReadGenerationsResponses]; - -export type GenerationsCreateGenerationData = { - body: GenerationCreate; - path?: never; - query?: never; - url: "/api/v1/generations/"; -}; - -export type GenerationsCreateGenerationErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type GenerationsCreateGenerationError = - GenerationsCreateGenerationErrors[keyof GenerationsCreateGenerationErrors]; - -export type GenerationsCreateGenerationResponses = { - /** - * Successful Response - */ - 200: GenerationPublic; -}; - -export type GenerationsCreateGenerationResponse = - GenerationsCreateGenerationResponses[keyof GenerationsCreateGenerationResponses]; - -export type GenerationsDeleteGenerationData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/generations/{id}"; -}; - -export type GenerationsDeleteGenerationErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type GenerationsDeleteGenerationError = - GenerationsDeleteGenerationErrors[keyof GenerationsDeleteGenerationErrors]; - -export type GenerationsDeleteGenerationResponses = { - /** - * Successful Response - */ - 200: Message; -}; - -export type GenerationsDeleteGenerationResponse = - GenerationsDeleteGenerationResponses[keyof GenerationsDeleteGenerationResponses]; - -export type GenerationsReadGenerationData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/generations/{id}"; -}; - -export type GenerationsReadGenerationErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type GenerationsReadGenerationError = - GenerationsReadGenerationErrors[keyof GenerationsReadGenerationErrors]; - -export type GenerationsReadGenerationResponses = { - /** - * Successful Response - */ - 200: GenerationPublic; -}; - -export type GenerationsReadGenerationResponse = - GenerationsReadGenerationResponses[keyof GenerationsReadGenerationResponses]; - -export type GenerationsGetGenerationStatusData = { - body?: never; - path: { - id: string; - }; - query?: never; - url: "/api/v1/generations/{id}/status"; -}; - -export type GenerationsGetGenerationStatusErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type GenerationsGetGenerationStatusError = - GenerationsGetGenerationStatusErrors[keyof GenerationsGetGenerationStatusErrors]; - -export type GenerationsGetGenerationStatusResponses = { - /** - * Successful Response - */ - 200: GenerationStatus; -}; - -export type GenerationsGetGenerationStatusResponse = - GenerationsGetGenerationStatusResponses[keyof GenerationsGetGenerationStatusResponses]; - -export type TrainingTrainingWebhookData = { - body: { - [key: string]: unknown; - }; - path?: never; - query?: never; - url: "/api/v1/training/webhook"; -}; - -export type TrainingTrainingWebhookErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type TrainingTrainingWebhookError = - TrainingTrainingWebhookErrors[keyof TrainingTrainingWebhookErrors]; - -export type TrainingTrainingWebhookResponses = { +export type DeleteEventThemeResponses = { /** * Successful Response */ 200: unknown; }; -export type TrainingGetTrainingStatusData = { +export type GetEventThemeData = { body?: never; path: { - task_id: string; + theme_id: string; }; query?: never; - url: "/api/v1/training/{task_id}/status"; + url: "/api/v1/event_themes/{theme_id}"; }; -export type TrainingGetTrainingStatusErrors = { +export type GetEventThemeErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type TrainingGetTrainingStatusError = - TrainingGetTrainingStatusErrors[keyof TrainingGetTrainingStatusErrors]; +export type GetEventThemeError = GetEventThemeErrors[keyof GetEventThemeErrors]; -export type TrainingGetTrainingStatusResponses = { +export type GetEventThemeResponses = { /** * Successful Response */ - 200: { - [key: string]: unknown; - }; + 200: EventThemeResponse; }; -export type TrainingGetTrainingStatusResponse = - TrainingGetTrainingStatusResponses[keyof TrainingGetTrainingStatusResponses]; +export type GetEventThemeResponse = + GetEventThemeResponses[keyof GetEventThemeResponses]; -export type PromptsBuildPromptData = { - body: PromptBuildRequest; - path?: never; - query?: never; - url: "/api/v1/prompts/build"; -}; - -export type PromptsBuildPromptErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type PromptsBuildPromptError = - PromptsBuildPromptErrors[keyof PromptsBuildPromptErrors]; - -export type PromptsBuildPromptResponses = { - /** - * Successful Response - */ - 200: PromptResponse; -}; - -export type PromptsBuildPromptResponse = - PromptsBuildPromptResponses[keyof PromptsBuildPromptResponses]; - -export type PromptsBuildPromptSectionData = { - body: PromptSectionRequest; - path?: never; - query?: never; - url: "/api/v1/prompts/build-section"; -}; - -export type PromptsBuildPromptSectionErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type PromptsBuildPromptSectionError = - PromptsBuildPromptSectionErrors[keyof PromptsBuildPromptSectionErrors]; - -export type PromptsBuildPromptSectionResponses = { - /** - * Successful Response - */ - 200: PromptSectionResponse; -}; - -export type PromptsBuildPromptSectionResponse = - PromptsBuildPromptSectionResponses[keyof PromptsBuildPromptSectionResponses]; - -export type PredictionsReadPredictionData = { - body?: never; +export type UpdateEventThemeData = { + body: EventThemeUpdate; path: { - id: string; + theme_id: string; }; query?: never; - url: "/api/v1/predictions/{id}"; + url: "/api/v1/event_themes/{theme_id}"; }; -export type PredictionsReadPredictionErrors = { +export type UpdateEventThemeErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type PredictionsReadPredictionError = - PredictionsReadPredictionErrors[keyof PredictionsReadPredictionErrors]; +export type UpdateEventThemeError = + UpdateEventThemeErrors[keyof UpdateEventThemeErrors]; -export type PredictionsReadPredictionResponses = { +export type UpdateEventThemeResponses = { /** * Successful Response */ - 200: Prediction; + 200: EventThemeResponse; }; -export type PredictionsReadPredictionResponse = - PredictionsReadPredictionResponses[keyof PredictionsReadPredictionResponses]; +export type UpdateEventThemeResponse = + UpdateEventThemeResponses[keyof UpdateEventThemeResponses]; -export type PredictionsReadPredictionsData = { +export type GetGuestsData = { body?: never; path?: never; query?: { - favourite?: boolean | null; skip?: number; limit?: number; }; - url: "/api/v1/predictions/"; + url: "/api/v1/events/guests/"; }; -export type PredictionsReadPredictionsErrors = { +export type GetGuestsErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type PredictionsReadPredictionsError = - PredictionsReadPredictionsErrors[keyof PredictionsReadPredictionsErrors]; +export type GetGuestsError = GetGuestsErrors[keyof GetGuestsErrors]; -export type PredictionsReadPredictionsResponses = { +export type GetGuestsResponses = { /** * Successful Response */ - 200: PredictionsPublic; + 200: Array; }; -export type PredictionsReadPredictionsResponse = - PredictionsReadPredictionsResponses[keyof PredictionsReadPredictionsResponses]; +export type GetGuestsResponse = GetGuestsResponses[keyof GetGuestsResponses]; -export type PredictionsRefinePredictionData = { +export type CreateGuestData = { + body: GuestCreate; + path?: never; + query?: never; + url: "/api/v1/events/guests/"; +}; + +export type CreateGuestErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type CreateGuestError = CreateGuestErrors[keyof CreateGuestErrors]; + +export type CreateGuestResponses = { + /** + * Successful Response + */ + 200: GuestRead; +}; + +export type CreateGuestResponse = + CreateGuestResponses[keyof CreateGuestResponses]; + +export type DeleteGuestData = { body?: never; path: { - id: string; + guest_id: string; }; query?: never; - url: "/api/v1/predictions/refine/{id}"; + url: "/api/v1/events/guests/{guest_id}"; }; -export type PredictionsRefinePredictionErrors = { +export type DeleteGuestErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type PredictionsRefinePredictionError = - PredictionsRefinePredictionErrors[keyof PredictionsRefinePredictionErrors]; +export type DeleteGuestError = DeleteGuestErrors[keyof DeleteGuestErrors]; -export type PredictionsRefinePredictionResponses = { +export type DeleteGuestResponses = { /** * Successful Response */ - 200: Prediction; + 200: GuestRead; }; -export type PredictionsRefinePredictionResponse = - PredictionsRefinePredictionResponses[keyof PredictionsRefinePredictionResponses]; +export type DeleteGuestResponse = + DeleteGuestResponses[keyof DeleteGuestResponses]; -export type PredictionsUpdatePredictionFavouriteStatusData = { +export type GetGuestData = { body?: never; path: { - id: string; + guest_id: string; + }; + query?: never; + url: "/api/v1/events/guests/{guest_id}"; +}; + +export type GetGuestErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetGuestError = GetGuestErrors[keyof GetGuestErrors]; + +export type GetGuestResponses = { + /** + * Successful Response + */ + 200: GuestRead; +}; + +export type GetGuestResponse = GetGuestResponses[keyof GetGuestResponses]; + +export type UpdateGuestData = { + body: GuestUpdate; + path: { + guest_id: string; + }; + query?: never; + url: "/api/v1/events/guests/{guest_id}"; +}; + +export type UpdateGuestErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type UpdateGuestError = UpdateGuestErrors[keyof UpdateGuestErrors]; + +export type UpdateGuestResponses = { + /** + * Successful Response + */ + 200: GuestRead; +}; + +export type UpdateGuestResponse = + UpdateGuestResponses[keyof UpdateGuestResponses]; + +export type SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchData = { + body?: never; + path: { + guest_id: string; }; query: { - favourite: boolean; + status: GuestStatus; }; - url: "/api/v1/predictions/{id}/favourite"; + url: "/api/v1/events/guests/{guest_id}/status"; }; -export type PredictionsUpdatePredictionFavouriteStatusErrors = { +export type SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type PredictionsUpdatePredictionFavouriteStatusError = - PredictionsUpdatePredictionFavouriteStatusErrors[keyof PredictionsUpdatePredictionFavouriteStatusErrors]; +export type SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchError = + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchErrors[keyof SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchErrors]; -export type PredictionsUpdatePredictionFavouriteStatusResponses = { +export type SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponses = { /** * Successful Response */ - 200: Prediction; + 200: GuestRead; }; -export type PredictionsUpdatePredictionFavouriteStatusResponse = - PredictionsUpdatePredictionFavouriteStatusResponses[keyof PredictionsUpdatePredictionFavouriteStatusResponses]; +export type SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponse = + SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponses[keyof SetGuestStatusApiV1EventsGuestsGuestIdStatusPatchResponses]; -export type SubscriptionsCreateUserSubscriptionData = { - body: SubscriptionCreate; - path: { - user_id: string; - }; - query?: never; - url: "/api/v1/subscriptions/{user_id}"; -}; - -export type SubscriptionsCreateUserSubscriptionErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubscriptionsCreateUserSubscriptionError = - SubscriptionsCreateUserSubscriptionErrors[keyof SubscriptionsCreateUserSubscriptionErrors]; - -export type SubscriptionsCreateUserSubscriptionResponses = { - /** - * Successful Response - */ - 200: SubscriptionPublic; -}; - -export type SubscriptionsCreateUserSubscriptionResponse = - SubscriptionsCreateUserSubscriptionResponses[keyof SubscriptionsCreateUserSubscriptionResponses]; - -export type SubscriptionsReadSubscriptionData = { - body?: never; - path: { - subscription_id: string; - }; - query?: never; - url: "/api/v1/subscriptions/{subscription_id}"; -}; - -export type SubscriptionsReadSubscriptionErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubscriptionsReadSubscriptionError = - SubscriptionsReadSubscriptionErrors[keyof SubscriptionsReadSubscriptionErrors]; - -export type SubscriptionsReadSubscriptionResponses = { - /** - * Successful Response - */ - 200: SubscriptionPublic; -}; - -export type SubscriptionsReadSubscriptionResponse = - SubscriptionsReadSubscriptionResponses[keyof SubscriptionsReadSubscriptionResponses]; - -export type SubscriptionsUpdateSubscriptionData = { - body: SubscriptionUpdate; - path: { - subscription_id: string; - }; - query?: never; - url: "/api/v1/subscriptions/{subscription_id}"; -}; - -export type SubscriptionsUpdateSubscriptionErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubscriptionsUpdateSubscriptionError = - SubscriptionsUpdateSubscriptionErrors[keyof SubscriptionsUpdateSubscriptionErrors]; - -export type SubscriptionsUpdateSubscriptionResponses = { - /** - * Successful Response - */ - 200: SubscriptionPublic; -}; - -export type SubscriptionsUpdateSubscriptionResponse = - SubscriptionsUpdateSubscriptionResponses[keyof SubscriptionsUpdateSubscriptionResponses]; - -export type SubscriptionsRenewSubscriptionData = { - body?: never; - path: { - subscription_id: string; - }; - query?: { - payment_id?: string | null; - }; - url: "/api/v1/subscriptions/{subscription_id}/renew"; -}; - -export type SubscriptionsRenewSubscriptionErrors = { - /** - * Validation Error - */ - 422: HttpValidationError; -}; - -export type SubscriptionsRenewSubscriptionError = - SubscriptionsRenewSubscriptionErrors[keyof SubscriptionsRenewSubscriptionErrors]; - -export type SubscriptionsRenewSubscriptionResponses = { - /** - * Successful Response - */ - 200: SubscriptionPublic; -}; - -export type SubscriptionsRenewSubscriptionResponse = - SubscriptionsRenewSubscriptionResponses[keyof SubscriptionsRenewSubscriptionResponses]; - -export type SubscriptionsReadSubscriptionsData = { +export type GetRsvpsData = { body?: never; path?: never; query?: { skip?: number; limit?: number; }; - url: "/api/v1/subscriptions/"; + url: "/api/v1/events/rsvps/"; }; -export type SubscriptionsReadSubscriptionsErrors = { +export type GetRsvpsErrors = { /** * Validation Error */ 422: HttpValidationError; }; -export type SubscriptionsReadSubscriptionsError = - SubscriptionsReadSubscriptionsErrors[keyof SubscriptionsReadSubscriptionsErrors]; +export type GetRsvpsError = GetRsvpsErrors[keyof GetRsvpsErrors]; -export type SubscriptionsReadSubscriptionsResponses = { +export type GetRsvpsResponses = { /** * Successful Response */ - 200: SubscriptionsPublic; + 200: Array; }; -export type SubscriptionsReadSubscriptionsResponse = - SubscriptionsReadSubscriptionsResponses[keyof SubscriptionsReadSubscriptionsResponses]; +export type GetRsvpsResponse = GetRsvpsResponses[keyof GetRsvpsResponses]; + +export type CreateRsvpData = { + body: RsvpSchemaCreate; + path?: never; + query?: never; + url: "/api/v1/events/rsvps/"; +}; + +export type CreateRsvpErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type CreateRsvpError = CreateRsvpErrors[keyof CreateRsvpErrors]; + +export type CreateRsvpResponses = { + /** + * Successful Response + */ + 200: RsvpSchema; +}; + +export type CreateRsvpResponse = CreateRsvpResponses[keyof CreateRsvpResponses]; + +export type DeleteRsvpData = { + body?: never; + path: { + rsvp_id: string; + }; + query?: never; + url: "/api/v1/events/rsvps/{rsvp_id}"; +}; + +export type DeleteRsvpErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type DeleteRsvpError = DeleteRsvpErrors[keyof DeleteRsvpErrors]; + +export type DeleteRsvpResponses = { + /** + * Successful Response + */ + 200: RsvpSchema; +}; + +export type DeleteRsvpResponse = DeleteRsvpResponses[keyof DeleteRsvpResponses]; + +export type GetRsvpData = { + body?: never; + path: { + rsvp_id: string; + }; + query?: never; + url: "/api/v1/events/rsvps/{rsvp_id}"; +}; + +export type GetRsvpErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetRsvpError = GetRsvpErrors[keyof GetRsvpErrors]; + +export type GetRsvpResponses = { + /** + * Successful Response + */ + 200: RsvpSchema; +}; + +export type GetRsvpResponse = GetRsvpResponses[keyof GetRsvpResponses]; + +export type UpdateRsvpData = { + body: RsvpSchemaUpdate; + path: { + rsvp_id: string; + }; + query?: never; + url: "/api/v1/events/rsvps/{rsvp_id}"; +}; + +export type UpdateRsvpErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type UpdateRsvpError = UpdateRsvpErrors[keyof UpdateRsvpErrors]; + +export type UpdateRsvpResponses = { + /** + * Successful Response + */ + 200: RsvpSchema; +}; + +export type UpdateRsvpResponse = UpdateRsvpResponses[keyof UpdateRsvpResponses]; + +export type UpdateRsvpStatusData = { + body: RsvpSchemaUpdate; + path: { + rsvp_id: string; + }; + query?: never; + url: "/api/v1/events/rsvps/{rsvp_id}/status"; +}; + +export type UpdateRsvpStatusErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type UpdateRsvpStatusError = + UpdateRsvpStatusErrors[keyof UpdateRsvpStatusErrors]; + +export type UpdateRsvpStatusResponses = { + /** + * Successful Response + */ + 200: RsvpSchema; +}; + +export type UpdateRsvpStatusResponse = + UpdateRsvpStatusResponses[keyof UpdateRsvpStatusResponses]; + +export type CreateEventData = { + body: EventCreate; + path?: never; + query?: never; + url: "/api/v1/events/"; +}; + +export type CreateEventErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type CreateEventError = CreateEventErrors[keyof CreateEventErrors]; + +export type CreateEventResponses = { + /** + * Successful Response + */ + 201: EventResponse; +}; + +export type CreateEventResponse = + CreateEventResponses[keyof CreateEventResponses]; + +export type GetUserEventsData = { + body?: never; + path?: never; + query?: { + skip?: number; + limit?: number; + include_inactive?: boolean; + }; + url: "/api/v1/events/me"; +}; + +export type GetUserEventsErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetUserEventsError = GetUserEventsErrors[keyof GetUserEventsErrors]; + +export type GetUserEventsResponses = { + /** + * Successful Response + */ + 200: PaginatedResponseEventResponse; +}; + +export type GetUserEventsResponse = + GetUserEventsResponses[keyof GetUserEventsResponses]; + +export type GetUpcomingEventsData = { + body?: never; + path?: never; + query?: { + skip?: number; + limit?: number; + }; + url: "/api/v1/events/upcoming"; +}; + +export type GetUpcomingEventsErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetUpcomingEventsError = + GetUpcomingEventsErrors[keyof GetUpcomingEventsErrors]; + +export type GetUpcomingEventsResponses = { + /** + * Successful Response + */ + 200: PaginatedResponseEventResponse; +}; + +export type GetUpcomingEventsResponse = + GetUpcomingEventsResponses[keyof GetUpcomingEventsResponses]; + +export type GetPublicEventsData = { + body?: never; + path?: never; + query?: { + skip?: number; + limit?: number; + }; + url: "/api/v1/events/public"; +}; + +export type GetPublicEventsErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetPublicEventsError = + GetPublicEventsErrors[keyof GetPublicEventsErrors]; + +export type GetPublicEventsResponses = { + /** + * Successful Response + */ + 200: PaginatedResponseEventResponse; +}; + +export type GetPublicEventsResponse = + GetPublicEventsResponses[keyof GetPublicEventsResponses]; + +export type DeleteEventData = { + body?: never; + path: { + event_id: string; + }; + query?: { + /** + * Perform hard delete instead of soft delete + */ + hard_delete?: boolean; + }; + url: "/api/v1/events/{event_id}"; +}; + +export type DeleteEventErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type DeleteEventError = DeleteEventErrors[keyof DeleteEventErrors]; + +export type DeleteEventResponses = { + /** + * Successful Response + */ + 204: void; +}; + +export type DeleteEventResponse = + DeleteEventResponses[keyof DeleteEventResponses]; + +export type GetEventData = { + body?: never; + path: { + event_id: string; + }; + query?: { + access_code?: string | null; + }; + url: "/api/v1/events/{event_id}"; +}; + +export type GetEventErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetEventError = GetEventErrors[keyof GetEventErrors]; + +export type GetEventResponses = { + /** + * Successful Response + */ + 200: EventResponse; +}; + +export type GetEventResponse = GetEventResponses[keyof GetEventResponses]; + +export type UpdateEventData = { + body: EventUpdate; + path: { + event_id: string; + }; + query?: never; + url: "/api/v1/events/{event_id}"; +}; + +export type UpdateEventErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type UpdateEventError = UpdateEventErrors[keyof UpdateEventErrors]; + +export type UpdateEventResponses = { + /** + * Successful Response + */ + 200: EventResponse; +}; + +export type UpdateEventResponse = + UpdateEventResponses[keyof UpdateEventResponses]; + +export type GetEventBySlugData = { + body?: never; + path: { + slug: string; + }; + query?: { + access_code?: string | null; + }; + url: "/api/v1/events/by-slug/{slug}"; +}; + +export type GetEventBySlugErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GetEventBySlugError = + GetEventBySlugErrors[keyof GetEventBySlugErrors]; + +export type GetEventBySlugResponses = { + /** + * Successful Response + */ + 200: EventResponse; +}; + +export type GetEventBySlugResponse = + GetEventBySlugResponses[keyof GetEventBySlugResponses]; + +export type GeneratePresignedUrlData = { + body: PresignedUrlRequest; + path?: never; + query?: never; + url: "/api/v1/uploads/presigned-url"; +}; + +export type GeneratePresignedUrlErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type GeneratePresignedUrlError = + GeneratePresignedUrlErrors[keyof GeneratePresignedUrlErrors]; + +export type GeneratePresignedUrlResponses = { + /** + * Successful Response + */ + 200: PresignedUrlResponse; +}; + +export type GeneratePresignedUrlResponse = + GeneratePresignedUrlResponses[keyof GeneratePresignedUrlResponses]; + +export type UploadFileData = { + body: BodyUploadFile; + path: { + token: string; + }; + query?: never; + url: "/api/v1/uploads/{token}"; +}; + +export type UploadFileErrors = { + /** + * Validation Error + */ + 422: HttpValidationError; +}; + +export type UploadFileError = UploadFileErrors[keyof UploadFileErrors]; + +export type UploadFileResponses = { + /** + * Successful Response + */ + 200: unknown; +}; export type ClientOptions = { baseURL: "http://localhost:8000" | (string & {});