@turndown/library 0.1.67 → 0.1.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.d.cts +11 -1
- package/dist/types/index.d.ts +11 -1
- package/dist/types/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/types/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/types/index.ts","../../src/types/api/index.ts","../../src/types/validation/index.ts","../../src/types/user/constants.ts","../../src/types/auth/routes.ts","../../src/types/auth/index.ts","../../src/types/base/paging.types.ts","../../src/types/base/index.ts","../../src/types/company/constants.ts","../../src/types/company/routes.ts","../../src/types/damage-report/index.ts","../../src/types/errors/index.ts","../../src/types/health/index.ts","../../src/types/image/index.ts","../../src/types/inventory/index.ts","../../src/types/property/constants.ts","../../src/types/property/routes.ts","../../src/types/room/constants.ts","../../src/types/room/routes.ts","../../src/types/subscription/routes.ts","../../src/types/subscription/index.ts","../../src/types/user/routes.ts","../../src/types/work-session/index.ts"],"sourcesContent":["/**\n * Shared API contracts, domain DTOs, constants, and validation schemas for Turndown.\n */\n\nexport * from \"./api\";\nexport * from \"./auth\";\nexport * from \"./base\";\nexport * from \"./checklist-template\";\nexport * from \"./company\";\nexport * from \"./damage-report\";\nexport * from \"./errors\";\nexport * from \"./health\";\nexport * from \"./image\";\nexport * from \"./inventory\";\nexport * from \"./job\";\nexport * from \"./property\";\nexport * from \"./room\";\nexport * from \"./room-checklist\";\nexport * from \"./subscription\";\nexport * from \"./user\";\nexport * from \"./validation\";\nexport * from \"./work-session\";\n","/**\n * API Response Types\n * Standard response structure for all API endpoints.\n */\n\nimport type { TDateTimeString, TEnvironment, TJsonValue } from \"../base\";\n\nexport const HTTP_METHOD = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n PATCH: \"PATCH\",\n DELETE: \"DELETE\",\n} as const;\n\nexport type THttpMethod = (typeof HTTP_METHOD)[keyof typeof HTTP_METHOD];\n\n/**\n * Error Codes\n * Standardized error codes used across the platform.\n */\nexport const ERROR_CODES = {\n BAD_REQUEST: \"BAD_REQUEST\",\n VALIDATION_ERROR: \"VALIDATION_ERROR\",\n MISSING_FIELDS: \"MISSING_FIELDS\",\n UNAUTHORIZED: \"UNAUTHORIZED\",\n INVALID_TOKEN: \"INVALID_TOKEN\",\n INVALID_CREDENTIALS: \"INVALID_CREDENTIALS\",\n FORBIDDEN: \"FORBIDDEN\",\n NOT_FOUND: \"NOT_FOUND\",\n CONFLICT: \"CONFLICT\",\n ALREADY_EXISTS: \"ALREADY_EXISTS\",\n RATE_LIMIT: \"RATE_LIMIT\",\n RATE_LIMIT_EXCEEDED: \"RATE_LIMIT_EXCEEDED\",\n INTERNAL_ERROR: \"INTERNAL_ERROR\",\n DATABASE_ERROR: \"DATABASE_ERROR\",\n NOT_IMPLEMENTED: \"NOT_IMPLEMENTED\",\n} as const;\n\nexport type TErrorCode = (typeof ERROR_CODES)[keyof typeof ERROR_CODES];\n\n/**\n * HTTP Status Codes\n * Common status codes used in API responses.\n */\nexport const HTTP_STATUS = {\n Ok: 200,\n Created: 201,\n NoContent: 204,\n BadRequest: 400,\n Unauthorized: 401,\n Forbidden: 403,\n NotFound: 404,\n Conflict: 409,\n UnprocessableEntity: 422,\n TooManyRequests: 429,\n InternalError: 500,\n} as const;\n\nexport type THttpStatusCode = (typeof HTTP_STATUS)[keyof typeof HTTP_STATUS];\n\nexport type TApiErrorDetails = TJsonValue;\n\nexport interface IApiError<TDetails = TApiErrorDetails> {\n message: string;\n code?: TErrorCode;\n details?: TDetails;\n}\n\nexport interface IApiMeta {\n timestamp: TDateTimeString;\n version: string;\n environment: TEnvironment;\n requestId?: string;\n}\n\nexport interface IApiSuccessResponse<TData = null> {\n success: true;\n data: TData;\n meta: IApiMeta;\n}\n\nexport interface IApiErrorResponse<TErrorDetails = TApiErrorDetails> {\n success: false;\n error: IApiError<TErrorDetails>;\n meta: IApiMeta;\n}\n\nexport type IApiResponse<TData = null, TErrorDetails = TApiErrorDetails> =\n | IApiSuccessResponse<TData>\n | IApiErrorResponse<TErrorDetails>;\n","export type TValidationIssueType =\n | \"INVALID_BODY\"\n | \"MISSING_FIELD\"\n | \"INVALID_FIELD\"\n | \"UNSUPPORTED_FIELD\";\n\nexport interface IValidationIssue<TFieldName extends string = string> {\n fieldName: TFieldName;\n type: TValidationIssueType;\n}\n\nexport interface IValidationResult<TValue extends object> {\n success: boolean;\n data?: TValue;\n issues: IValidationIssue[];\n}\n\nexport type TMissingValuePolicy = \"Nullish\" | \"BlankString\";\n\nexport interface IValidationField<TValue, TRequired extends boolean> {\n readonly valueType?: TValue;\n required: TRequired;\n missingValuePolicy: TMissingValuePolicy;\n validate: (value: unknown) => boolean;\n}\n\nexport type TValidationFieldMap = Record<\n string,\n IValidationField<unknown, boolean>\n>;\n\ntype TRequiredSchemaKeys<TFields extends TValidationFieldMap> = {\n [TKey in keyof TFields]: TFields[TKey] extends IValidationField<unknown, true>\n ? TKey\n : never;\n}[keyof TFields];\n\ntype TOptionalSchemaKeys<TFields extends TValidationFieldMap> = Exclude<\n keyof TFields,\n TRequiredSchemaKeys<TFields>\n>;\n\ntype TFieldValue<TField> =\n TField extends IValidationField<infer TValue, boolean> ? TValue : never;\n\nexport type TInferValidationFields<TFields extends TValidationFieldMap> = {\n [TKey in TRequiredSchemaKeys<TFields>]: TFieldValue<TFields[TKey]>;\n} & {\n [TKey in TOptionalSchemaKeys<TFields>]?: TFieldValue<TFields[TKey]>;\n};\n\nexport type TInferValidationSchemaInput<TSchema> =\n TSchema extends IRuntimeValidationSchema<infer TFields>\n ? TInferValidationFields<TFields>\n : never;\n\nexport interface IRuntimeValidationSchema<\n TFields extends TValidationFieldMap = TValidationFieldMap,\n> {\n fields: TFields;\n allowedFields: readonly Extract<keyof TFields, string>[];\n requiredFields: readonly Extract<TRequiredSchemaKeys<TFields>, string>[];\n validate: (\n value: unknown,\n options?: IRuntimeValidationOptions,\n ) => IValidationResult<TInferValidationFields<TFields>>;\n}\n\nexport interface IRuntimeValidationOptions {\n rejectUnknownFields?: boolean;\n}\n\nexport const createValidationSchema = <TFields extends TValidationFieldMap>(\n fields: TFields,\n): IRuntimeValidationSchema<TFields> => {\n const allowedFields = Object.keys(fields) as Extract<keyof TFields, string>[];\n const requiredFields = allowedFields.filter((fieldName) => {\n return fields[fieldName].required;\n }) as Extract<TRequiredSchemaKeys<TFields>, string>[];\n\n return {\n fields,\n allowedFields,\n requiredFields,\n validate: (value, options = {}) => {\n if (!isRecord(value)) {\n return {\n success: false,\n issues: [\n {\n fieldName: \"body\",\n type: \"INVALID_BODY\",\n },\n ],\n };\n }\n\n const issues = getValidationIssues(fields, value, options);\n\n if (issues.length > 0) {\n return {\n success: false,\n issues,\n };\n }\n\n return {\n success: true,\n data: value as TInferValidationFields<TFields>,\n issues: [],\n };\n },\n };\n};\n\nexport const requiredStringField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isNonEmptyString,\n});\n\nexport const optionalStringField = (): IValidationField<string, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isNonEmptyString,\n});\n\nexport const optionalNullableStringField = (): IValidationField<\n string | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is string | null => {\n return value === null || isNonEmptyString(value);\n },\n});\n\nexport const requiredEmailField = (\n missingValuePolicy: TMissingValuePolicy = \"BlankString\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isEmail,\n});\n\nexport const requiredUuidField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isUuid,\n});\n\nexport const optionalNullableNonNegativeIntegerField = (): IValidationField<\n number | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is number | null => {\n return value === null || (Number.isInteger(value) && Number(value) >= 0);\n },\n});\n\nexport const optionalRecordField = (): IValidationField<\n Record<string, unknown>,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isRecord,\n});\n\nexport const requiredEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<TValue, true> => ({\n required: true,\n missingValuePolicy,\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalNullableEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue | null, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue | null => {\n return value === null || isAllowedStringValue(value, allowedValues);\n },\n});\n\nconst getValidationIssues = <TFields extends TValidationFieldMap>(\n fields: TFields,\n value: Record<string, unknown>,\n options: IRuntimeValidationOptions,\n): IValidationIssue[] => {\n const allowedFieldSet = new Set(Object.keys(fields));\n const issues: IValidationIssue[] = [];\n\n Object.entries(fields).forEach(([fieldName, field]) => {\n const fieldValue = value[fieldName];\n\n if (\n field.required &&\n isMissingValue(fieldValue, field.missingValuePolicy)\n ) {\n issues.push({\n fieldName,\n type: \"MISSING_FIELD\",\n });\n return;\n }\n\n if (fieldValue === undefined) {\n return;\n }\n\n if (!field.validate(fieldValue)) {\n issues.push({\n fieldName,\n type: \"INVALID_FIELD\",\n });\n }\n });\n\n if (options.rejectUnknownFields === true) {\n Object.keys(value).forEach((fieldName) => {\n if (!allowedFieldSet.has(fieldName)) {\n issues.push({\n fieldName,\n type: \"UNSUPPORTED_FIELD\",\n });\n }\n });\n }\n\n return issues;\n};\n\nconst isRecord = (value: unknown): value is Record<string, unknown> => {\n return typeof value === \"object\" && value !== null && !Array.isArray(value);\n};\n\nconst isMissingValue = (\n value: unknown,\n missingValuePolicy: TMissingValuePolicy,\n): boolean => {\n if (value === undefined || value === null) {\n return true;\n }\n\n return (\n missingValuePolicy === \"BlankString\" &&\n typeof value === \"string\" &&\n value.trim().length === 0\n );\n};\n\nconst isNonEmptyString = (value: unknown): value is string => {\n return typeof value === \"string\" && value.trim().length > 0;\n};\n\nconst isAllowedStringValue = <TValue extends string>(\n value: unknown,\n allowedValues: readonly TValue[],\n): value is TValue => {\n return typeof value === \"string\" && allowedValues.includes(value as TValue);\n};\n\nconst isEmail = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value.trim());\n};\n\nconst isUuid = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(\n value,\n );\n};\n","import type { TRecordValue } from \"../base\";\n\nexport const ACCOUNT_TYPE = {\n TURNDOWN_ADMIN: \"TURNDOWN_ADMIN\",\n ACCOUNT_ADMIN: \"ACCOUNT_ADMIN\",\n MANAGER: \"MANAGER\",\n STAFF: \"STAFF\",\n GUEST: \"GUEST\",\n} as const;\n\nexport type TAccountType = TRecordValue<typeof ACCOUNT_TYPE>;\n\nexport const ACCOUNT_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n PENDING: \"PENDING\",\n} as const;\n\nexport type TAccountStatus = TRecordValue<typeof ACCOUNT_STATUS>;\n\nexport const LANGUAGE = {\n ENGLISH: \"ENGLISH\",\n FRENCH: \"FRENCH\",\n SPANISH: \"SPANISH\",\n GERMAN: \"GERMAN\",\n} as const;\n\nexport type TLanguage = TRecordValue<typeof LANGUAGE>;\n","import {\n createValidationSchema,\n optionalRecordField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\nimport type { IAuthTokenResponse } from \"./index\";\nimport type { IEmptyRouteRequest, TDateTimeString } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport type { IDeviceInfo } from \"../user\";\nimport type { IGetUserResponse } from \"../user/routes\";\n\n// Route Params\nexport interface IAuthSessionIdParams {\n sessionId: string;\n}\n\nexport interface IAuthInvitationTokenParams {\n token: string;\n}\n\nexport interface IAuthInvitationIdParams {\n invitationId: string;\n}\n\n// Shared Responses\nexport interface IAuthMessageResponse {\n message: string;\n}\n\nexport interface IAuthRefreshTokenResponse extends IAuthTokenResponse {}\n\nexport interface IAuthInvitationBaseResponse {\n id: string;\n companyId: string;\n companyName: string;\n role: TAccountType;\n invitedBy: string;\n invitedByName: string;\n expiresAt: TDateTimeString;\n}\n\nconst AccountTypeValues = Object.values(ACCOUNT_TYPE);\n\n// Core Authentication\nexport const RegisterRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n accountType: requiredEnumField(AccountTypeValues, \"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterResponse extends IAuthTokenResponse {}\n\nexport const LoginRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type ILoginRequest = Omit<\n TInferValidationSchemaInput<typeof LoginRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface ILoginResponse extends IAuthTokenResponse {\n passwordResetRequired: boolean;\n}\n\nexport const RefreshSessionRequestSchema = createValidationSchema({\n refreshToken: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRefreshSessionRequest = Omit<\n TInferValidationSchemaInput<typeof RefreshSessionRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRefreshSessionResponse extends IAuthRefreshTokenResponse {}\n\nexport const LogoutRequestSchema = createValidationSchema({\n refreshToken: optionalStringField(),\n});\n\nexport type ILogoutRequest = TInferValidationSchemaInput<\n typeof LogoutRequestSchema\n>;\n\nexport interface ILogoutResponse extends IAuthMessageResponse {}\n\nexport interface ILogoutAllRequest {\n userId: string;\n}\n\nexport interface ILogoutAllResponse extends IAuthMessageResponse {}\n\nexport interface IGetMeRequest {\n userId: string;\n}\n\nexport interface IGetMeResponse extends IGetUserResponse {}\n\n// Session Management\nexport type IGetSessionsRequest = IEmptyRouteRequest;\n\nexport interface IGetSessionsResponse {\n id: string;\n deviceInfo: string;\n createdAt: TDateTimeString;\n lastUsedAt: TDateTimeString;\n}\n\nexport interface IRevokeSessionRequest extends IAuthSessionIdParams {}\n\nexport interface IRevokeSessionResponse extends IAuthMessageResponse {}\n\n// Password Management\nexport const ChangePasswordRequestSchema = createValidationSchema({\n currentPassword: requiredStringField(\"BlankString\"),\n newPassword: requiredStringField(\"BlankString\"),\n});\n\nexport type IChangePasswordRequest = TInferValidationSchemaInput<\n typeof ChangePasswordRequestSchema\n>;\n\nexport interface IChangePasswordResponse extends IGetUserResponse {}\n\nexport const ForgotPasswordRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n});\n\nexport type IForgotPasswordRequest = TInferValidationSchemaInput<\n typeof ForgotPasswordRequestSchema\n>;\n\nexport interface IForgotPasswordResponse extends IAuthMessageResponse {}\n\nexport type IGetLoginHistoryRequest = IEmptyRouteRequest;\n\nexport interface IGetLoginHistoryResponse {\n id: string;\n email: string;\n ipAddress: string;\n userAgent: string;\n success: boolean;\n failureReason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetLoginHistoryListResponse {\n history: IGetLoginHistoryResponse[];\n length: number;\n}\n\n// Invitations\nexport interface IValidateInvitationRequest extends IAuthInvitationTokenParams {}\n\nexport interface IValidateInvitationResponse extends IAuthInvitationBaseResponse {\n email: string;\n userExists: boolean;\n}\n\nexport const RegisterWithInvitationRequestSchema = createValidationSchema({\n token: requiredStringField(\"BlankString\"),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterWithInvitationRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterWithInvitationRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterWithInvitationResponse extends IAuthTokenResponse {}\n\nexport const AcceptInvitationRequestSchema = createValidationSchema({\n userId: optionalStringField(),\n token: requiredStringField(\"BlankString\"),\n});\n\nexport type IAcceptInvitationRequest = TInferValidationSchemaInput<\n typeof AcceptInvitationRequestSchema\n>;\n\nexport interface IAcceptInvitationResponse {\n companyId: string;\n companyName: string;\n role: TAccountType;\n}\n\nexport interface IAcceptInvitationRouteResponse {\n invite: IAcceptInvitationResponse;\n message: string;\n}\n\nexport type IGetPendingInvitationsRequest = IEmptyRouteRequest;\n\nexport interface IGetPendingInvitationsResponse extends IAuthInvitationBaseResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetPendingInvitationsListResponse {\n invitations: IGetPendingInvitationsResponse[];\n length: number;\n}\n\nexport interface IRevokeInvitationRequest extends IAuthInvitationIdParams {\n revokedBy?: string;\n}\n\nexport interface IRevokeInvitationResponse extends IAuthMessageResponse {}\n","export * from \"./routes\";\n\nimport type { TDateTimeString, TServiceType } from \"../base\";\nimport type { IUser } from \"../user\";\n\nexport const AUTH_STATUS = {\n Initializing: \"Initializing\",\n Unauthenticated: \"Unauthenticated\",\n Authenticated: \"Authenticated\",\n Refreshing: \"Refreshing\",\n SessionExpired: \"SessionExpired\",\n} as const;\n\nexport type TAuthStatus = (typeof AUTH_STATUS)[keyof typeof AUTH_STATUS];\n\nexport interface IAuthTokenBundle {\n accessToken: string;\n refreshToken: string;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IRefreshTokenData {\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IStoredAuthSession {\n accessToken: string | null;\n refreshToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IAuthTokenResponse extends IAuthTokenBundle {\n user: IUser | null;\n companyId: string | null;\n}\n\nexport interface IAuthSession {\n user: IUser | null;\n accessToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface ISetAuthSessionParams extends IAuthTokenBundle {\n user: IUser | null;\n}\n\nexport interface ILoginCredentials {\n email: string;\n password: string;\n rememberMe: boolean;\n}\n\nexport interface IRegisterCredentials {\n businessType: TServiceType[];\n firstName: string;\n lastName: string;\n email: string;\n password: string;\n}\n\nexport interface IPasswordValidationRules {\n minLength: number;\n requireUppercase: boolean;\n requireLowercase: boolean;\n requireNumbers: boolean;\n requireSpecialChars: boolean;\n}\n\nexport interface IPasswordValidationResult {\n valid: boolean;\n errors: string[];\n}\n\nexport interface IEmailValidationResult {\n valid: boolean;\n error?: string;\n}\n\nexport interface IRateLimitStatus {\n isLimited: boolean;\n attempts: number;\n maxAttempts: number;\n resetTime: TDateTimeString | null;\n}\n","/**\n * Pagination metadata for a paginated response.\n */\nexport interface IPagingResult {\n hasNextPage: boolean;\n totalPages: number;\n totalRecords: number;\n}\n\n/**\n * Generic wrapper for paginated data.\n */\nexport interface IDataWithPagingResult<TData> {\n data: TData;\n pagination: IPagingResult;\n}\n\nexport const SortDirection = {\n Asc: \"Asc\",\n Desc: \"Desc\",\n} as const;\n\nexport type TSortDirection = (typeof SortDirection)[keyof typeof SortDirection];\n\n/**\n * Sorting condition for query results.\n */\nexport interface ISortCondition {\n name: string;\n direction: TSortDirection;\n}\n\nexport const FilterCondition = {\n Equal: \"=\",\n GreaterThan: \">\",\n LessThan: \"<\",\n NotEqual: \"!=\",\n Like: \"LIKE\",\n In: \"IN\",\n GreaterThanOrEqual: \">=\",\n LessThanOrEqual: \"<=\",\n} as const;\n\nexport type TFilterCondition =\n (typeof FilterCondition)[keyof typeof FilterCondition];\n\nexport interface IFilterConditionBase {\n name: string;\n condition: TFilterCondition;\n useAnd?: boolean;\n}\n\nexport interface IStringFilterCondition extends IFilterConditionBase {\n valueString: string;\n valueNumber?: never;\n valueBoolean?: never;\n}\n\nexport interface INumberFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber: number;\n valueBoolean?: never;\n}\n\nexport interface IBooleanFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber?: never;\n valueBoolean: boolean;\n}\n\n/**\n * Filter condition for querying data.\n *\n * Exactly one value field should be provided.\n */\nexport type TFilterConditionValue =\n | IStringFilterCondition\n | INumberFilterCondition\n | IBooleanFilterCondition;\n\n/**\n * Kept as an exported alias to preserve the existing public API name.\n */\nexport type IFilterCondition = TFilterConditionValue;\n\n/**\n * Request shape for paginated data with optional sorting and filtering.\n */\nexport interface IPaginationRequest {\n page: number;\n size: number;\n sort?: ISortCondition[];\n filters?: IFilterCondition[];\n}\n\nexport interface IPagingObject {\n pagination: IPaginationRequest;\n}\n\nexport const createPagingObject = (\n page: number,\n size: number,\n sort?: ISortCondition[],\n filters?: IFilterCondition[],\n): IPagingObject => ({\n pagination: {\n page,\n size,\n sort,\n filters,\n },\n});\n","export type TJsonPrimitive = string | number | boolean | null;\n\nexport type TJsonObject = {\n [key: string]: TJsonValue;\n};\n\nexport type TJsonValue = TJsonPrimitive | TJsonValue[] | TJsonObject;\n\nexport type TUnknownRecord = Record<string, unknown>;\n\n/**\n * Serialized ISO-8601 date/time value returned by API JSON contracts.\n */\nexport type TDateTimeString = string;\n\nexport type TurndownObject<TObject extends object = TUnknownRecord> = TObject;\n\nexport type TEmptyObject = Record<string, never>;\n\nexport type IEmptyRouteRequest = TEmptyObject;\n\nexport type IEmptyRouteParams = TEmptyObject;\n\nexport const ENVIRONMENT = {\n Prod: \"Prod\",\n Dev: \"Dev\",\n Local: \"Local\",\n Test: \"Test\",\n} as const;\n\nexport type TEnvironment = (typeof ENVIRONMENT)[keyof typeof ENVIRONMENT];\n\nexport interface IMessageResponse {\n message: string;\n}\n\nexport interface ISuccessResponse {\n success: boolean;\n}\n\nexport interface ICountResponse {\n count: number;\n}\n\nexport interface IMetaData {\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport type TRecordValue<TRecord extends object> = TRecord[keyof TRecord];\n\nexport type TRecordKeys<TRecord extends object> = keyof TRecord;\n\nexport interface IVersion {\n major: number;\n minor: number;\n patch: number;\n}\n\nexport type TVersionInput = string | IVersion;\n\nexport interface ISelectOption<TValue extends string = string> {\n label: string;\n value: TValue;\n}\n\nexport const MODE = {\n Create: \"Create\",\n Edit: \"Edit\",\n Delete: \"Delete\",\n Details: \"Details\",\n} as const;\n\nexport type TMode = TRecordValue<typeof MODE> | null;\n\nexport const IMAGE_ENTITY = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TImageEntityType = TRecordValue<typeof IMAGE_ENTITY>;\n\nexport type TUSStateCode = TRecordKeys<typeof US_JURISDICTIONS>;\n\nexport const US_JURISDICTIONS = {\n // 50 States\n AL: \"Alabama\",\n AK: \"Alaska\",\n AZ: \"Arizona\",\n AR: \"Arkansas\",\n CA: \"California\",\n CO: \"Colorado\",\n CT: \"Connecticut\",\n DE: \"Delaware\",\n FL: \"Florida\",\n GA: \"Georgia\",\n HI: \"Hawaii\",\n ID: \"Idaho\",\n IL: \"Illinois\",\n IN: \"Indiana\",\n IA: \"Iowa\",\n KS: \"Kansas\",\n KY: \"Kentucky\",\n LA: \"Louisiana\",\n ME: \"Maine\",\n MD: \"Maryland\",\n MA: \"Massachusetts\",\n MI: \"Michigan\",\n MN: \"Minnesota\",\n MS: \"Mississippi\",\n MO: \"Missouri\",\n MT: \"Montana\",\n NE: \"Nebraska\",\n NV: \"Nevada\",\n NH: \"New Hampshire\",\n NJ: \"New Jersey\",\n NM: \"New Mexico\",\n NY: \"New York\",\n NC: \"North Carolina\",\n ND: \"North Dakota\",\n OH: \"Ohio\",\n OK: \"Oklahoma\",\n OR: \"Oregon\",\n PA: \"Pennsylvania\",\n RI: \"Rhode Island\",\n SC: \"South Carolina\",\n SD: \"South Dakota\",\n TN: \"Tennessee\",\n TX: \"Texas\",\n UT: \"Utah\",\n VT: \"Vermont\",\n VA: \"Virginia\",\n WA: \"Washington\",\n WV: \"West Virginia\",\n WI: \"Wisconsin\",\n WY: \"Wyoming\",\n\n // Territories\n DC: \"District of Columbia\",\n PR: \"Puerto Rico\",\n GU: \"Guam\",\n VI: \"United States Virgin Islands\",\n AS: \"American Samoa\",\n MP: \"Northern Mariana Islands\",\n} as const;\n\nexport type TUSJurisdiction = TRecordValue<typeof US_JURISDICTIONS>;\n\nexport const STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n OVERDUE: \"OVERDUE\",\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TStatus = TRecordValue<typeof STATUS>;\n\nexport const SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n} as const;\n\nexport type TSeverity = TRecordValue<typeof SEVERITY>;\n\nexport const SERVICE_TYPES = {\n PROPERTY: \"PROPERTY\",\n CLEANING: \"CLEANING\",\n MAINTENANCE: \"MAINTENANCE\",\n INSPECTION: \"INSPECTION\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TServiceType = TRecordValue<typeof SERVICE_TYPES>;\n\nexport const MONTHS = [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n] as const;\n\nexport type TMonths = (typeof MONTHS)[number];\n\nexport const WEEK_DAY = {\n Sunday: \"Sunday\",\n Monday: \"Monday\",\n Tuesday: \"Tuesday\",\n Wednesday: \"Wednesday\",\n Thursday: \"Thursday\",\n Friday: \"Friday\",\n Saturday: \"Saturday\",\n} as const;\n\nexport type TWeekDay = TRecordValue<typeof WEEK_DAY>;\n\nexport const WEEK_DAY_SHORT_LABEL = {\n Sunday: \"Sun\",\n Monday: \"Mon\",\n Tuesday: \"Tue\",\n Wednesday: \"Wed\",\n Thursday: \"Thu\",\n Friday: \"Fri\",\n Saturday: \"Sat\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayShortLabel = TRecordValue<typeof WEEK_DAY_SHORT_LABEL>;\n\nexport const WEEK_DAY_LETTER = {\n Sunday: \"S\",\n Monday: \"M\",\n Tuesday: \"T\",\n Wednesday: \"W\",\n Thursday: \"T\",\n Friday: \"F\",\n Saturday: \"S\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayLetter = TRecordValue<typeof WEEK_DAY_LETTER>;\n\nexport interface IWeekDay {\n date: Date;\n dayOfMonth: number;\n day: TWeekDay;\n shortLabel: TWeekDayShortLabel;\n letter: TWeekDayLetter;\n isToday: boolean;\n}\n\nconst createSelectOptions = <TValue extends string>(\n values: readonly TValue[],\n): ISelectOption<TValue>[] =>\n values.map((value) => ({\n label: value,\n value,\n }));\n\nconst getRecordValues = <TRecord extends Record<string, string>>(\n record: TRecord,\n): TRecordValue<TRecord>[] => Object.values(record) as TRecordValue<TRecord>[];\n\nexport const UnitedStatesJurisdictionOptions = createSelectOptions(\n getRecordValues(US_JURISDICTIONS),\n);\n\nexport const StatusOptions: ISelectOption<TStatus>[] = [\n { label: \"Pending\", value: STATUS.PENDING },\n { label: \"In Progress\", value: STATUS.IN_PROGRESS },\n { label: \"Completed\", value: STATUS.COMPLETED },\n { label: \"Overdue\", value: STATUS.OVERDUE },\n { label: \"Active\", value: STATUS.ACTIVE },\n { label: \"Inactive\", value: STATUS.INACTIVE },\n];\n\nexport const SeverityOptions: ISelectOption<TSeverity>[] = [\n { label: \"Low\", value: SEVERITY.LOW },\n { label: \"Medium\", value: SEVERITY.MEDIUM },\n { label: \"High\", value: SEVERITY.HIGH },\n];\n\nexport const ServiceTypeOptions: ISelectOption<TServiceType>[] = [\n { label: \"Property\", value: SERVICE_TYPES.PROPERTY },\n { label: \"Cleaning\", value: SERVICE_TYPES.CLEANING },\n { label: \"Maintenance\", value: SERVICE_TYPES.MAINTENANCE },\n { label: \"Inspection\", value: SERVICE_TYPES.INSPECTION },\n { label: \"Other\", value: SERVICE_TYPES.OTHER },\n];\n\nexport * from \"./paging.types\";\n","import type { TRecordValue } from \"../base\";\n\nexport const COMPANY_RELATIONSHIP_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n} as const;\n\nexport const INVITATION_STATUS = {\n PENDING: \"PENDING\",\n ACCEPTED: \"ACCEPTED\",\n EXPIRED: \"EXPIRED\",\n REVOKED: \"REVOKED\",\n DECLINED: \"DECLINED\",\n} as const;\n\nexport type TInvitationStatus = TRecordValue<typeof INVITATION_STATUS>;\n\nexport type TCompanyRelationshipStatus =\n | TRecordValue<typeof COMPANY_RELATIONSHIP_STATUS>\n | typeof INVITATION_STATUS.PENDING\n | null;\n\nexport const COMPANY_TYPES = {\n PROPERTY_MANAGEMENT: \"PROPERTY_MANAGEMENT\",\n MAINTENANCE: \"MAINTENANCE\",\n CLEANER: \"CLEANER\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TCompanyType = TRecordValue<typeof COMPANY_TYPES>;\n","import type { ICompany, ICompanyWithRelationshipStatus } from \".\";\nimport { COMPANY_TYPES } from \"./constants\";\nimport type {\n IEmptyRouteRequest,\n IMessageResponse,\n TDateTimeString,\n TUSStateCode,\n} from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n requiredUuidField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface ICompanyRouteParams {\n companyId: string;\n}\n\nexport interface ICompanyUserRouteParams {\n userId: string;\n}\n\nexport interface ICompanyInvitationTokenParams {\n token: string;\n}\n\nexport interface ICompanyInvitationIdParams extends ICompanyRouteParams {\n invitationId: string;\n}\n\nexport const CompanyFilter = {\n Active: \"active\",\n Pending: \"pending\",\n All: \"all\",\n} as const;\n\nexport type TCompanyFilter = (typeof CompanyFilter)[keyof typeof CompanyFilter];\n\nexport interface IGetCompaniesQuery {\n companyId?: string;\n search?: string;\n filter?: TCompanyFilter;\n}\n\nconst CompanyTypeValues = Object.values(COMPANY_TYPES);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\nconst InviteUserRoleValues = Object.values(ACCOUNT_TYPE).filter(\n (accountType) => accountType !== ACCOUNT_TYPE.TURNDOWN_ADMIN,\n);\n\nexport const CreateCompanyRequestSchema = createValidationSchema({\n displayName: requiredStringField(\"BlankString\"),\n addressLine1: requiredStringField(\"BlankString\"),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(\"BlankString\"),\n stateCode: requiredEnumField(StateCodeValues, \"BlankString\"),\n postalCode: requiredStringField(\"BlankString\"),\n companyType: requiredEnumField(CompanyTypeValues, \"BlankString\"),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type ICreateCompanyRequest = TInferValidationSchemaInput<\n typeof CreateCompanyRequestSchema\n> & {\n stateCode: TUSStateCode;\n companyType: ICompany[\"companyType\"];\n};\n\nexport interface ICreateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport type IGetCompaniesRequest = IEmptyRouteRequest;\nexport type IGetCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport interface IGetCompanyByIdRequest extends ICompanyRouteParams {}\nexport interface IGetCompanyByIdResponse extends ICompanyWithRelationshipStatus {}\n\nexport const UpdateCompanyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n companyType: optionalEnumField(CompanyTypeValues),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type IUpdateCompanyRequest = TInferValidationSchemaInput<\n typeof UpdateCompanyRequestSchema\n> & {\n stateCode?: TUSStateCode;\n companyType?: ICompany[\"companyType\"];\n};\n\nexport interface IUpdateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport const InviteUserToCompanyRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n role: requiredEnumField(InviteUserRoleValues, \"BlankString\"),\n});\n\nexport type IInviteUserToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteUserToCompanyRequestSchema\n> & {\n role: TAccountType;\n};\n\nexport interface IInviteUserToCompanyResponse extends IMessageResponse {}\n\nexport interface IGetCompanyUsersRequest extends ICompanyRouteParams {}\nexport interface ICompanyUserSummary {\n id: string;\n email: string;\n firstName: string;\n lastName: string | null;\n role: TAccountType;\n}\nexport interface ICompanyWithUsers extends ICompanyWithRelationshipStatus {\n users: ICompanyUserSummary[];\n}\nexport interface IGetCompanyUsersResponse extends ICompanyWithUsers {}\n\nexport interface IGetUserCompaniesRequest extends ICompanyUserRouteParams {}\nexport type IGetUserCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport const InviteCompanyToCompanyRequestSchema = createValidationSchema({\n providerCompanyId: requiredUuidField(),\n message: optionalNullableStringField(),\n});\n\nexport type IInviteCompanyToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteCompanyToCompanyRequestSchema\n>;\n\nexport interface IInviteCompanyToCompanyResponse {\n id: string;\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IValidateCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IValidateCompanyInvitationResponse {\n id: string;\n requesterCompanyId: string;\n providerCompanyId: string;\n invitedBy: string;\n message: string | null;\n expiresAt: TDateTimeString;\n requesterCompanyName: string;\n providerCompanyName: string;\n invitedByName: string;\n}\n\nexport interface IAcceptCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IAcceptCompanyInvitationResponse {\n requesterCompanyId: string;\n providerCompanyId: string;\n requesterCompanyName: string;\n providerCompanyName: string;\n}\n\nexport interface IDeclineCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IDeclineCompanyInvitationResponse extends IMessageResponse {}\n\nexport interface IGetPendingCompanyInvitationsRequest extends ICompanyRouteParams {}\nexport interface ICompanyInvitationSummary extends IValidateCompanyInvitationResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport type IGetPendingCompanyInvitationsResponse = ICompanyInvitationSummary[];\n\nexport interface IRevokeCompanyInvitationRequest extends ICompanyInvitationIdParams {}\nexport interface IRevokeCompanyInvitationResponse extends IMessageResponse {}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\n\nexport const DAMAGE_SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n CRITICAL: \"CRITICAL\",\n} as const;\n\nexport type TDamageSeverity = TRecordValue<typeof DAMAGE_SEVERITY>;\n\nexport const DAMAGE_STATUS = {\n OPEN: \"OPEN\",\n IN_REVIEW: \"IN_REVIEW\",\n ASSIGNED: \"ASSIGNED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n RESOLVED: \"RESOLVED\",\n CLOSED: \"CLOSED\",\n ESCALATED: \"ESCALATED\",\n} as const;\n\nexport type TDamageStatus = TRecordValue<typeof DAMAGE_STATUS>;\n\nexport const WORK_ORDER_PRIORITY = {\n LOW: \"LOW\",\n NORMAL: \"NORMAL\",\n HIGH: \"HIGH\",\n URGENT: \"URGENT\",\n} as const;\n\nexport type TWorkOrderPriority = TRecordValue<typeof WORK_ORDER_PRIORITY>;\n\nexport const WORK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n SCHEDULED: \"SCHEDULED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkOrderStatus = TRecordValue<typeof WORK_ORDER_STATUS>;\n\nexport interface IDamageReport {\n id: string;\n propertyId: string;\n roomId: string;\n workSessionId: string | null;\n cleaningSessionId: string | null;\n reportedBy: string;\n reportedAt: TDateTimeString;\n severity: TDamageSeverity;\n status: TDamageStatus;\n title: string;\n description: string;\n locationDetails: string | null;\n estimatedCost: number | null;\n actualCost: number | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n resolvedAt: TDateTimeString | null;\n resolvedBy: string | null;\n resolutionNotes: string | null;\n requiresProfessional: boolean;\n vendorInfo: string | null;\n insuranceClaimNumber: string | null;\n isTenantResponsible: boolean;\n tenantChargeAmount: number | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n photos?: IDamagePhoto[];\n comments?: IDamageComment[];\n}\n\nexport interface IDamageReportPhoto {\n id: string;\n damageReportId: string;\n photoId: string;\n imageUrl: string | null;\n caption: string | null;\n isBeforePhoto: boolean;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IDamagePhoto extends IDamageReportPhoto {}\n\nexport interface IDamageComment {\n id: string;\n damageReportId: string;\n userId: string;\n userName: string | null;\n comment: string;\n isInternal: boolean;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IDamageReportStatusHistory {\n id: string;\n damageReportId: string;\n previousStatus: TDamageStatus | null;\n newStatus: TDamageStatus;\n changedBy: string;\n reason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IWorkOrder {\n id: string;\n damageReportId: string | null;\n propertyId: string;\n roomId: string | null;\n workOrderNumber: string | null;\n priority: TWorkOrderPriority;\n category: string | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n scheduledDate: TDateTimeString | null;\n scheduledTimeStart: string | null;\n scheduledTimeEnd: string | null;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n completedBy: string | null;\n description: string;\n workPerformed: string | null;\n materialsUsed: string | null;\n laborHours: number | null;\n laborCost: number | null;\n materialsCost: number | null;\n totalCost: number | null;\n status: TWorkOrderStatus;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface ICreateDamageReportInput {\n propertyId: string;\n roomId: string;\n workSessionId?: string;\n reportedBy: string;\n severity: TDamageSeverity;\n title: string;\n description: string;\n locationDetails?: string;\n estimatedCost?: number;\n requiresProfessional?: boolean;\n isTenantResponsible?: boolean;\n tenantChargeAmount?: number;\n}\n\nexport interface ICreateWorkOrderInput {\n damageReportId?: string;\n propertyId: string;\n roomId?: string;\n priority?: TWorkOrderPriority;\n category?: string;\n description: string;\n scheduledDate?: TDateTimeString;\n scheduledTimeStart?: string;\n scheduledTimeEnd?: string;\n}\n\nexport * from \"./routes\";\n","/**\n * Error Types\n * Custom error types and validation error structures.\n */\n\nimport { ERROR_CODES } from \"../api\";\nimport type { TErrorCode } from \"../api\";\nimport type { TJsonObject, TJsonValue } from \"../base\";\n\n/**\n * Detailed information about a validation error.\n */\nexport interface IValidationErrorDetail {\n field: string;\n message: string;\n value?: TJsonValue;\n}\n\n/**\n * Information about missing required fields.\n */\nexport interface IMissingFieldsErrorDetail {\n missingFields: string[];\n}\n\n/**\n * Information about rate limiting.\n */\nexport interface IRateLimitErrorDetail {\n retryAfter?: number;\n message: string;\n}\n\nexport type TErrorResponseDetail =\n | IValidationErrorDetail[]\n | IMissingFieldsErrorDetail\n | IRateLimitErrorDetail\n | TJsonObject\n | string;\n\nexport interface ITypedApiError<TDetails = TErrorResponseDetail> {\n message: string;\n code: TErrorCode;\n details?: TDetails;\n}\n\nexport type TValidationError = ITypedApiError<IValidationErrorDetail[]>;\nexport type TMissingFieldsError = ITypedApiError<IMissingFieldsErrorDetail>;\nexport type TRateLimitError = ITypedApiError<IRateLimitErrorDetail>;\n\ntype TErrorLike = {\n code?: string;\n details?: unknown;\n};\n\nconst isErrorLike = (error: unknown): error is TErrorLike => {\n return typeof error === \"object\" && error !== null;\n};\n\n/**\n * Type guard for validation errors.\n */\nexport function isValidationError(error: unknown): error is TValidationError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.VALIDATION_ERROR &&\n Array.isArray(error.details)\n );\n}\n\n/**\n * Type guard for missing-field errors.\n */\nexport function isMissingFieldsError(\n error: unknown,\n): error is TMissingFieldsError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.MISSING_FIELDS &&\n typeof error.details === \"object\" &&\n error.details !== null &&\n \"missingFields\" in error.details &&\n Array.isArray(error.details.missingFields)\n );\n}\n\n/**\n * Type guard for rate-limit errors.\n */\nexport function isRateLimitError(error: unknown): error is TRateLimitError {\n return isErrorLike(error) && error.code === ERROR_CODES.RATE_LIMIT_EXCEEDED;\n}\n\n/**\n * Type guard for authentication errors.\n */\nexport function isAuthError(error: unknown): boolean {\n return (\n isErrorLike(error) &&\n (error.code === ERROR_CODES.UNAUTHORIZED ||\n error.code === ERROR_CODES.INVALID_TOKEN ||\n error.code === ERROR_CODES.INVALID_CREDENTIALS)\n );\n}\n","import type { TDateTimeString, TEnvironment } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const SERVER_STATUS = {\n Healthy: \"Healthy\",\n Unhealthy: \"UnHealthy\",\n} as const;\n\nexport type TServerStatus = (typeof SERVER_STATUS)[keyof typeof SERVER_STATUS];\n\nexport const DATABASE_STATUS = {\n Unknown: \"Unknown\",\n Connected: \"Connected\",\n Disconnected: \"Disconnected\",\n} as const;\n\nexport type TDatabaseStatus =\n (typeof DATABASE_STATUS)[keyof typeof DATABASE_STATUS];\n\nexport interface IHealthCheckResponse {\n status: TServerStatus;\n database: TDatabaseStatus;\n timestamp: TDateTimeString;\n environment: TEnvironment;\n}\n\nexport interface IHealthChecks {\n database: TDatabaseStatus;\n uptime: number;\n memory: {\n rss: number;\n heapTotal: number;\n heapUsed: number;\n external: number;\n arrayBuffers: number;\n };\n timestamp: TDateTimeString;\n databaseError?: string;\n}\n","import type { TDateTimeString } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const IMAGE_ENTITY_TYPE = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TStoredImageEntityType =\n (typeof IMAGE_ENTITY_TYPE)[keyof typeof IMAGE_ENTITY_TYPE];\n\nexport interface IImage {\n id: string;\n entityType: TStoredImageEntityType;\n entityId: string;\n fileName: string;\n mimeType: string;\n fileSizeBytes: number | null;\n width: number | null;\n height: number | null;\n isPublic: boolean;\n category: string | null;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport interface IImageWithUrl extends IImage {\n url: string;\n}\n","import type { IMetaData, TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\nexport const INVENTORY_RESTOCK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n ORDERED: \"ORDERED\",\n SHIPPED: \"SHIPPED\",\n RECEIVED: \"RECEIVED\",\n} as const;\n\nexport type TInventoryRestockOrderStatus = TRecordValue<\n typeof INVENTORY_RESTOCK_ORDER_STATUS\n>;\n\nexport const INVENTORY_UNITS = {\n COUNT: \"COUNT\",\n ROLLS: \"ROLLS\",\n PODS: \"PODS\",\n BOXES: \"BOXES\",\n BOTTLES: \"BOTTLES\",\n PACKS: \"PACKS\",\n BAGS: \"BAGS\",\n GALLONS: \"GALLONS\",\n LITERS: \"LITERS\",\n KILOGRAMS: \"KILOGRAMS\",\n POUNDS: \"POUNDS\",\n OUNCES: \"OUNCES\",\n GRAMS: \"GRAMS\",\n SHEETS: \"SHEETS\",\n CASES: \"CASES\",\n CARTONS: \"CARTONS\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TInventoryUnitType = TRecordValue<typeof INVENTORY_UNITS>;\n\nexport const INVENTORY_ITEM_TYPE = {\n CONSUMABLE: \"CONSUMABLE\",\n FIXED: \"FIXED\",\n} as const;\n\nexport type TInventoryItemType = TRecordValue<typeof INVENTORY_ITEM_TYPE>;\n\nexport interface IInventoryItem extends IMetaData {\n id: string;\n companyId: string;\n name: string;\n description: string | null;\n itemType: TInventoryItemType;\n unit: TInventoryUnitType;\n unitCustom: string | null;\n minimumLevel: number;\n reorderLevel: number;\n maximumLevel: number | null;\n costPerUnit: number | null;\n supplierInfo: string | null;\n sku: string | null;\n barcode: string | null;\n}\n\nexport interface IRoomInventory extends IMetaData {\n id: string;\n roomId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IPropertyInventory extends IMetaData {\n id: string;\n propertyId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IInventoryCount {\n id: string;\n checklistExecutionId: string;\n roomInventoryId: string;\n previousLevel: number;\n countedLevel: number;\n consumedAmount: number;\n restockedAmount: number;\n finalLevel: number;\n countedBy: string;\n countedAt: TDateTimeString;\n needsRestock: boolean;\n notes: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrder {\n id: string;\n companyId: string;\n orderNumber: string | null;\n status: TInventoryRestockOrderStatus;\n totalItems: number | null;\n totalCost: number | null;\n orderedBy: string | null;\n orderedAt: TDateTimeString | null;\n expectedDelivery: TDateTimeString | null;\n receivedBy: string | null;\n receivedAt: TDateTimeString | null;\n supplierInfo: string | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrderItem {\n id: string;\n orderId: string;\n inventoryItemId: string;\n roomInventoryId: string | null;\n propertyInventoryId: string | null;\n quantityOrdered: number;\n quantityReceived: number;\n unitCost: number | null;\n totalCost: number | null;\n createdAt: TDateTimeString;\n}\n","import type { ISelectOption, TRecordValue } from \"../base\";\n\nexport const PROPERTY_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TPropertyStatus = TRecordValue<typeof PROPERTY_STATUS>;\n\nexport const PropertyStatusOptions: ISelectOption<TPropertyStatus>[] = [\n {\n label: \"Active\",\n value: PROPERTY_STATUS.ACTIVE,\n },\n {\n label: \"Inactive\",\n value: PROPERTY_STATUS.INACTIVE,\n },\n];\n\nexport const PROPERTY_TYPES = {\n APARTMENT: \"APARTMENT\",\n COMMERCIAL: \"COMMERCIAL\",\n CONDO: \"CONDO\",\n DUPLEX: \"DUPLEX\",\n HOUSE: \"HOUSE\",\n MULTI_FAMILY: \"MULTI_FAMILY\",\n OFFICE: \"OFFICE\",\n RETAIL: \"RETAIL\",\n TOWNHOUSE: \"TOWNHOUSE\",\n VACATION_RENTAL: \"VACATION_RENTAL\",\n WAREHOUSE: \"WAREHOUSE\",\n} as const;\n\nexport type TPropertyType = TRecordValue<typeof PROPERTY_TYPES>;\n\nexport const PropertyTypeOptions: ISelectOption<TPropertyType>[] = [\n {\n label: \"Apartment\",\n value: PROPERTY_TYPES.APARTMENT,\n },\n {\n label: \"Commercial\",\n value: PROPERTY_TYPES.COMMERCIAL,\n },\n {\n label: \"Condo\",\n value: PROPERTY_TYPES.CONDO,\n },\n {\n label: \"Duplex\",\n value: PROPERTY_TYPES.DUPLEX,\n },\n {\n label: \"House\",\n value: PROPERTY_TYPES.HOUSE,\n },\n {\n label: \"Multi-Family\",\n value: PROPERTY_TYPES.MULTI_FAMILY,\n },\n {\n label: \"Office\",\n value: PROPERTY_TYPES.OFFICE,\n },\n {\n label: \"Retail\",\n value: PROPERTY_TYPES.RETAIL,\n },\n {\n label: \"Townhouse\",\n value: PROPERTY_TYPES.TOWNHOUSE,\n },\n {\n label: \"Vacation Rental\",\n value: PROPERTY_TYPES.VACATION_RENTAL,\n },\n {\n label: \"Warehouse\",\n value: PROPERTY_TYPES.WAREHOUSE,\n },\n];\n","import type {\n IProperty,\n IPropertyAccessInformation,\n IPropertyDetail,\n IPropertySummary,\n TPropertyStatus,\n TPropertyType,\n} from \".\";\nimport { PROPERTY_STATUS, PROPERTY_TYPES } from \"./constants\";\nimport type { IMessageResponse, TUSStateCode } from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableEnumField,\n optionalNullableNonNegativeIntegerField,\n optionalNullableStringField,\n optionalStringField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IPropertyIdParams {\n propertyId: string;\n}\n\nexport interface ICompanyIdParams {\n companyId: string;\n}\n\nconst PropertyTypeValues = Object.values(PROPERTY_TYPES);\nconst PropertyStatusValues = Object.values(PROPERTY_STATUS);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\n\nexport const CreatePropertyRequestSchema = createValidationSchema({\n companyId: requiredStringField(),\n displayName: requiredStringField(),\n propertyType: requiredEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: requiredStringField(),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(),\n stateCode: requiredEnumField(StateCodeValues),\n postalCode: requiredStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type ICreatePropertyRequest = TInferValidationSchemaInput<\n typeof CreatePropertyRequestSchema\n> & {\n companyId: string;\n propertyType: TPropertyType;\n status?: TPropertyStatus | null;\n stateCode: TUSStateCode;\n};\n\nexport const UpdatePropertyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n propertyType: optionalNullableEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type IUpdatePropertyRequest = TInferValidationSchemaInput<\n typeof UpdatePropertyRequestSchema\n> & {\n propertyType?: TPropertyType | null;\n status?: TPropertyStatus | null;\n stateCode?: TUSStateCode;\n};\n\nexport interface IGetPropertiesRequest {\n companyId?: string;\n}\n\nexport interface IGetPropertyByIdRequest extends IPropertyIdParams {}\n\nexport interface IDeletePropertyRequest extends IPropertyIdParams {}\n\nexport type IGetPropertiesResponse = IPropertySummary[];\n\nexport interface IGetPropertyResponse extends IPropertyDetail {}\n\nexport interface ICreatePropertyResponse extends IPropertyDetail {}\n\nexport interface IUpdatePropertyResponse extends IPropertyDetail {}\n\nexport interface IDeletePropertyResponse extends IMessageResponse {}\n\nexport const UpdatePropertyAccessInformationRequestSchema =\n createValidationSchema({\n entryInstructions: optionalNullableStringField(),\n accessCode: optionalNullableStringField(),\n wifiName: optionalNullableStringField(),\n wifiPassword: optionalNullableStringField(),\n alarmCode: optionalNullableStringField(),\n parkingInfo: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n });\n\nexport type IUpdatePropertyAccessInformationRequest =\n TInferValidationSchemaInput<\n typeof UpdatePropertyAccessInformationRequestSchema\n >;\n\nexport interface IUpdatePropertyAccessInformationResponse extends IPropertyAccessInformation {}\n\nexport interface IGetPropertyAccessInformationRequest extends IPropertyIdParams {}\n\nexport type IGetPropertyAccessInformationResponse =\n IPropertyAccessInformation | null;\n\nexport interface IGetPropertyByIdResponse extends IGetPropertyResponse {}\n\nexport interface IGetPropertiesByCompanyIdRequest extends ICompanyIdParams {}\nexport type IGetPropertiesByCompanyIdResponse = IProperty[];\n","import type { TRecordValue } from \"../base\";\n\nexport const ROOM_TYPE = {\n BEDROOM: \"BEDROOM\",\n BATHROOM: \"BATHROOM\",\n KITCHEN: \"KITCHEN\",\n LIVING_ROOM: \"LIVING_ROOM\",\n DINING_ROOM: \"DINING_ROOM\",\n OFFICE: \"OFFICE\",\n GARAGE: \"GARAGE\",\n LAUNDRY_ROOM: \"LAUNDRY_ROOM\",\n BASEMENT: \"BASEMENT\",\n ATTIC: \"ATTIC\",\n BALCONY: \"BALCONY\",\n PORCH: \"PORCH\",\n GARDEN: \"GARDEN\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TRoomType = TRecordValue<typeof ROOM_TYPE>;\n","import type { IRoom } from \".\";\nimport { ROOM_TYPE } from \"./constants\";\nimport type { IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IRoomPropertyRouteParams {\n propertyId: string;\n}\n\nexport interface IRoomRouteParams {\n roomId: string;\n}\n\nconst RoomTypeValues = Object.values(ROOM_TYPE);\n\nexport const CreateRoomRequestSchema = createValidationSchema({\n propertyId: requiredStringField(),\n displayName: requiredStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type ICreateRoomRequest = TInferValidationSchemaInput<\n typeof CreateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface ICreateRoomResponse extends IRoom {}\n\nexport interface IGetRoomsRequest {\n propertyId?: string;\n}\n\nexport interface IGetRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetDetailedRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetDetailedRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetRoomByIdRequest extends IRoomRouteParams {}\nexport interface IGetRoomByIdResponse extends IRoom {}\n\nexport const UpdateRoomRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type IUpdateRoomRequest = TInferValidationSchemaInput<\n typeof UpdateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface IUpdateRoomResponse extends IRoom {}\n\nexport interface IDeleteRoomRequest extends IRoomRouteParams {}\nexport interface IDeleteRoomResponse extends IMessageResponse {}\n","import type {\n ICompanyBillingSummary,\n IEntitlementSnapshot,\n IProviderProduct,\n ISubscriptionProductSummary,\n TSubscriptionProvider,\n} from \".\";\nimport type { IMessageResponse, TJsonObject } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableStringField,\n optionalRecordField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IBillingCompanyRouteParams {\n companyId: string;\n}\n\nexport interface IGetBillingProductsRequest {}\nexport type IGetBillingProductsResponse = ISubscriptionProductSummary[];\n\nexport interface IGetCompanyBillingSummaryRequest\n extends IBillingCompanyRouteParams {}\nexport interface IGetCompanyBillingSummaryResponse\n extends ICompanyBillingSummary {}\n\nexport const CreateStripeCheckoutSessionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n successUrl: requiredStringField(\"BlankString\"),\n cancelUrl: requiredStringField(\"BlankString\"),\n});\n\nexport type ICreateStripeCheckoutSessionRequest =\n TInferValidationSchemaInput<\n typeof CreateStripeCheckoutSessionRequestSchema\n >;\n\nexport interface ICreateStripeCheckoutSessionResponse {\n checkoutUrl: string;\n}\n\nexport const SyncAppleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n transactionId: requiredStringField(\"BlankString\"),\n originalTransactionId: optionalNullableStringField(),\n signedTransactionInfo: requiredStringField(\"BlankString\"),\n});\n\nexport type ISyncAppleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncAppleSubscriptionRequestSchema\n>;\n\nexport const SyncGoogleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n purchaseToken: requiredStringField(\"BlankString\"),\n packageName: requiredStringField(\"BlankString\"),\n providerPriceId: optionalNullableStringField(),\n});\n\nexport type ISyncGoogleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncGoogleSubscriptionRequestSchema\n>;\n\nexport interface ISyncStoreSubscriptionResponse {\n subscription: ICompanyBillingSummary[\"subscription\"];\n entitlement: IEntitlementSnapshot;\n}\n\nexport const BillingProviderWebhookRequestSchema = createValidationSchema({\n providerEventId: requiredStringField(\"BlankString\"),\n eventType: requiredStringField(\"BlankString\"),\n providerSubscriptionId: optionalNullableStringField(),\n providerTransactionId: optionalNullableStringField(),\n providerRefundId: optionalNullableStringField(),\n payload: optionalRecordField(),\n});\n\nexport type IBillingProviderWebhookRequest = TInferValidationSchemaInput<\n typeof BillingProviderWebhookRequestSchema\n> & {\n payload?: TJsonObject;\n};\n\nexport interface IBillingProviderWebhookResponse extends IMessageResponse {}\n\nexport interface IProviderProductLookupRequest {\n provider: TSubscriptionProvider;\n providerProductId: string;\n}\n\nexport interface IProviderProductLookupResponse extends IProviderProduct {}\n\nexport const BillingProviderValues = [\n \"STRIPE\",\n \"APPLE\",\n \"GOOGLE\",\n \"MANUAL\",\n] as const;\n\nexport const ProviderProductLookupRequestSchema = createValidationSchema({\n provider: requiredEnumField(BillingProviderValues, \"BlankString\"),\n providerProductId: requiredStringField(\"BlankString\"),\n});\n","import type {\n IMetaData,\n TDateTimeString,\n TJsonObject,\n TRecordValue,\n} from \"../base\";\n\nexport const SUBSCRIPTION_PLAN = {\n Free: \"FREE\",\n Starter: \"STARTER\",\n Pro: \"PRO\",\n Business: \"BUSINESS\",\n} as const;\n\nexport type TSubscriptionPlan = TRecordValue<typeof SUBSCRIPTION_PLAN>;\n\nexport const SUBSCRIPTION_STATUS = {\n ACTIVE: \"ACTIVE\",\n CANCELED: \"CANCELED\",\n EXPIRED: \"EXPIRED\",\n PAST_DUE: \"PAST_DUE\",\n TRIALING: \"TRIALING\",\n GRACE_PERIOD: \"GRACE_PERIOD\",\n REFUNDED: \"REFUNDED\",\n} as const;\n\nexport type TSubscriptionStatus = TRecordValue<typeof SUBSCRIPTION_STATUS>;\n\nexport const SUBSCRIPTION_PROVIDER = {\n STRIPE: \"STRIPE\",\n APPLE: \"APPLE\",\n GOOGLE: \"GOOGLE\",\n MANUAL: \"MANUAL\",\n} as const;\n\nexport type TSubscriptionProvider = TRecordValue<typeof SUBSCRIPTION_PROVIDER>;\n\nexport const BILLING_PERIOD = {\n MONTHLY: \"MONTHLY\",\n YEARLY: \"YEARLY\",\n} as const;\n\nexport type TBillingPeriod = TRecordValue<typeof BILLING_PERIOD>;\n\nexport const REFUND_STATUS = {\n REQUESTED: \"REQUESTED\",\n APPROVED: \"APPROVED\",\n DECLINED: \"DECLINED\",\n PROCESSED: \"PROCESSED\",\n} as const;\n\nexport type TRefundStatus = TRecordValue<typeof REFUND_STATUS>;\n\nexport const SUBSCRIPTION_FEATURE = {\n CreateProperty: \"CREATE_PROPERTY\",\n InviteTeamMember: \"INVITE_TEAM_MEMBER\",\n CreateChecklistTemplate: \"CREATE_CHECKLIST_TEMPLATE\",\n UploadImage: \"UPLOAD_IMAGE\",\n} as const;\n\nexport type TSubscriptionFeature = TRecordValue<typeof SUBSCRIPTION_FEATURE>;\n\nexport interface ISubscriptionPlan extends IMetaData {\n id: string;\n code: TSubscriptionPlan;\n displayName: string;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n isActive: boolean;\n}\n\nexport interface IProviderProduct extends IMetaData {\n id: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerProductId: string;\n providerPriceId: string | null;\n billingPeriod: TBillingPeriod;\n trialDays: number;\n isActive: boolean;\n}\n\nexport interface ISubscriptionProductSummary {\n plan: ISubscriptionPlan;\n products: IProviderProduct[];\n}\n\nexport interface IBillingAccount extends IMetaData {\n id: string;\n companyId: string;\n billingAdminUserId: string | null;\n}\n\nexport interface ICompanySubscription extends IMetaData {\n id: string;\n billingAccountId: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string | null;\n providerOriginalTransactionId: string | null;\n providerPurchaseToken: string | null;\n providerCustomerId: string | null;\n providerPriceId: string | null;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString | null;\n currentPeriodEnd: TDateTimeString | null;\n trialStart: TDateTimeString | null;\n trialEnd: TDateTimeString | null;\n cancelAtPeriodEnd: boolean;\n canceledAt: TDateTimeString | null;\n refundedAt: TDateTimeString | null;\n latestEventAt: TDateTimeString | null;\n}\n\nexport interface ISubscriptionEvent extends IMetaData {\n id: string;\n subscriptionId: string | null;\n provider: TSubscriptionProvider;\n providerEventId: string;\n eventType: string;\n rawPayload: TJsonObject;\n processedAt: TDateTimeString;\n}\n\nexport interface IEntitlementSnapshot {\n id: string;\n companyId: string;\n subscriptionId: string | null;\n planCode: TSubscriptionPlan;\n status: TSubscriptionStatus;\n effectiveFrom: TDateTimeString;\n effectiveUntil: TDateTimeString | null;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n sourceEventId: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IRefund extends IMetaData {\n id: string;\n subscriptionId: string;\n provider: TSubscriptionProvider;\n providerRefundId: string | null;\n providerTransactionId: string | null;\n amount: number | null;\n currency: string | null;\n reason: string | null;\n status: TRefundStatus;\n refundedAt: TDateTimeString | null;\n rawPayload: TJsonObject | null;\n}\n\nexport interface ICompanyBillingSummary {\n billingAccount: IBillingAccount | null;\n subscription: ICompanySubscription | null;\n entitlement: IEntitlementSnapshot;\n}\n\n/**\n * @deprecated Use ICompanySubscription for company-scoped SaaS access.\n */\nexport interface IUserSubscription {\n id: string;\n userId: string;\n planId: string;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString;\n currentPeriodEnd: TDateTimeString;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string;\n cancelAtPeriodEnd: boolean;\n}\n\nexport * from \"./routes\";\n","import type { IUser, TAccountType } from \".\";\nimport { LANGUAGE } from \"./constants\";\nimport type { IEmptyRouteRequest, IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IUserIdParams {\n id: string;\n}\n\nexport interface IGetUserResponse {\n user: IUser | null;\n}\n\nexport type IGetCurrentUserRequest = IEmptyRouteRequest;\nexport interface IGetCurrentUserResponse extends IGetUserResponse {}\n\nexport interface IGetUserByIdRequest extends IUserIdParams {}\nexport interface IGetUserByIdResponse extends IGetUserResponse {}\n\nexport interface IGetUserByEmailRequest {\n email: string;\n}\nexport interface IGetUserByEmailResponse extends IGetUserResponse {}\n\nexport type IGetStaffRequest = IEmptyRouteRequest;\nexport interface IGetStaffResponse {\n staff: IUser[];\n}\n\nconst LanguageValues = Object.values(LANGUAGE);\n\nexport const UpdateUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalNullableStringField(),\n mi: optionalNullableStringField(),\n username: optionalNullableStringField(),\n email: optionalStringField(),\n phoneNumber: optionalNullableStringField(),\n phoneFormat: optionalNullableStringField(),\n preferredLanguage: optionalEnumField(LanguageValues),\n});\n\nexport type IUpdateUserRequest = TInferValidationSchemaInput<\n typeof UpdateUserRequestSchema\n> & {\n preferredLanguage?: IUser[\"preferredLanguage\"];\n};\n\nexport const UpdateCurrentUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalStringField(),\n});\n\nexport type IUpdateCurrentUserRequest = TInferValidationSchemaInput<\n typeof UpdateCurrentUserRequestSchema\n>;\n\nexport interface IUpdateUserResponse {\n user: IUser;\n}\n\nexport type IDeleteUserRequest = IEmptyRouteRequest;\nexport interface IDeleteUserResponse extends IMessageResponse {}\n\nexport interface IGetUsersByAccountTypeRequest {\n accountType: TAccountType;\n}\nexport interface IGetUsersByAccountTypeResponse {\n users: IUser[];\n}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\n/**\n * Work session status enum.\n */\nexport const WORK_SESSION_STATUS = {\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkSessionStatus = TRecordValue<typeof WORK_SESSION_STATUS>;\n\n/**\n * Checklist execution status enum.\n */\nexport const CHECKLIST_EXECUTION_STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n SKIPPED: \"SKIPPED\",\n} as const;\n\nexport type TChecklistExecutionStatus = TRecordValue<\n typeof CHECKLIST_EXECUTION_STATUS\n>;\n\n/**\n * Work session.\n */\nexport interface IWorkSession {\n id: string;\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n status: TWorkSessionStatus;\n scheduledDate: TDateTimeString | null;\n startedAt: TDateTimeString;\n completedAt: TDateTimeString | null;\n totalTimeMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist execution.\n */\nexport interface IChecklistExecution {\n id: string;\n workSessionId: string;\n roomChecklistId: string;\n roomId: string;\n workerId: string;\n status: TChecklistExecutionStatus;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n timeSpentMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist item completion.\n */\nexport interface IChecklistItemCompletion {\n id: string;\n checklistExecutionId: string;\n roomChecklistItemId: string;\n completedBy: string;\n completedAt: TDateTimeString;\n photoId: string | null;\n notes: string | null;\n skipped: boolean;\n skipReason: string | null;\n createdAt: TDateTimeString;\n}\n\n/**\n * Work session with executions.\n */\nexport interface IWorkSessionWithExecutions extends IWorkSession {\n executions: IChecklistExecution[];\n}\n\n/**\n * Input for creating a work session.\n */\nexport interface ICreateWorkSessionInput {\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n scheduledDate?: TDateTimeString;\n notes?: string;\n}\n\n/**\n * Input for completing a checklist item.\n */\nexport interface ICompleteChecklistItemInput {\n roomChecklistItemId: string;\n completedBy: string;\n photoId?: string;\n notes?: string;\n skipped?: boolean;\n skipReason?: string;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;A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;AAAA,EACT,UAAU;AAAA,EACV,UAAU;AAAA,EACV,cAAc;AAAA,EACd,UAAU;AACZ;AAIO,IAAM,wBAAwB;AAAA,EACnC,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,QAAQ;AACV;AAIO,IAAM,iBAAiB;AAAA,EAC5B,SAAS;AAAA,EACT,QAAQ;AACV;AAIO,IAAM,gBAAgB;AAAA,EAC3B,WAAW;AAAA,EACX,UAAU;AAAA,EACV,UAAU;AAAA,EACV,WAAW;AACb;AAIO,IAAM,uBAAuB;AAAA,EAClC,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,yBAAyB;AAAA,EACzB,aAAa;AACf;;;ACvBA,IAAM,iBAAiB,OAAO,OAAO,QAAQ;AAEtC,IAAM,0BAA0B,uBAAuB;AAAA,EAC5D,WAAW,oBAAoB;AAAA,EAC/B,UAAU,4BAA4B;AAAA,EACtC,IAAI,4BAA4B;AAAA,EAChC,UAAU,4BAA4B;AAAA,EACtC,OAAO,oBAAoB;AAAA,EAC3B,aAAa,4BAA4B;AAAA,EACzC,aAAa,4BAA4B;AAAA,EACzC,mBAAmB,kBAAkB,cAAc;AACrD,CAAC;AAQM,IAAM,iCAAiC,uBAAuB;AAAA,EACnE,WAAW,oBAAoB;AAAA,EAC/B,UAAU,oBAAoB;AAChC,CAAC;;;ACnDM,IAAM,sBAAsB;AAAA,EACjC,aAAa;AAAA,EACb,WAAW;AAAA,EACX,WAAW;AACb;AAOO,IAAM,6BAA6B;AAAA,EACxC,SAAS;AAAA,EACT,aAAa;AAAA,EACb,WAAW;AAAA,EACX,SAAS;AACX;","names":["StateCodeValues"]}
|
|
1
|
+
{"version":3,"sources":["../../src/types/index.ts","../../src/types/api/index.ts","../../src/types/validation/index.ts","../../src/types/user/constants.ts","../../src/types/auth/routes.ts","../../src/types/auth/index.ts","../../src/types/base/paging.types.ts","../../src/types/base/index.ts","../../src/types/company/constants.ts","../../src/types/company/routes.ts","../../src/types/damage-report/index.ts","../../src/types/errors/index.ts","../../src/types/health/index.ts","../../src/types/image/index.ts","../../src/types/inventory/index.ts","../../src/types/property/constants.ts","../../src/types/property/routes.ts","../../src/types/room/constants.ts","../../src/types/room/routes.ts","../../src/types/subscription/routes.ts","../../src/types/subscription/index.ts","../../src/types/user/routes.ts","../../src/types/work-session/index.ts"],"sourcesContent":["/**\n * Shared API contracts, domain DTOs, constants, and validation schemas for Turndown.\n */\n\nexport * from \"./api\";\nexport * from \"./auth\";\nexport * from \"./base\";\nexport * from \"./checklist-template\";\nexport * from \"./company\";\nexport * from \"./damage-report\";\nexport * from \"./errors\";\nexport * from \"./health\";\nexport * from \"./image\";\nexport * from \"./inventory\";\nexport * from \"./job\";\nexport * from \"./property\";\nexport * from \"./room\";\nexport * from \"./room-checklist\";\nexport * from \"./subscription\";\nexport * from \"./user\";\nexport * from \"./validation\";\nexport * from \"./work-session\";\n","/**\n * API Response Types\n * Standard response structure for all API endpoints.\n */\n\nimport type { TDateTimeString, TEnvironment, TJsonValue } from \"../base\";\n\nexport const HTTP_METHOD = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n PATCH: \"PATCH\",\n DELETE: \"DELETE\",\n} as const;\n\nexport type THttpMethod = (typeof HTTP_METHOD)[keyof typeof HTTP_METHOD];\n\n/**\n * Error Codes\n * Standardized error codes used across the platform.\n */\nexport const ERROR_CODES = {\n BAD_REQUEST: \"BAD_REQUEST\",\n VALIDATION_ERROR: \"VALIDATION_ERROR\",\n MISSING_FIELDS: \"MISSING_FIELDS\",\n UNAUTHORIZED: \"UNAUTHORIZED\",\n INVALID_TOKEN: \"INVALID_TOKEN\",\n INVALID_CREDENTIALS: \"INVALID_CREDENTIALS\",\n FORBIDDEN: \"FORBIDDEN\",\n NOT_FOUND: \"NOT_FOUND\",\n CONFLICT: \"CONFLICT\",\n ALREADY_EXISTS: \"ALREADY_EXISTS\",\n RATE_LIMIT: \"RATE_LIMIT\",\n RATE_LIMIT_EXCEEDED: \"RATE_LIMIT_EXCEEDED\",\n INTERNAL_ERROR: \"INTERNAL_ERROR\",\n DATABASE_ERROR: \"DATABASE_ERROR\",\n NOT_IMPLEMENTED: \"NOT_IMPLEMENTED\",\n} as const;\n\nexport type TErrorCode = (typeof ERROR_CODES)[keyof typeof ERROR_CODES];\n\n/**\n * HTTP Status Codes\n * Common status codes used in API responses.\n */\nexport const HTTP_STATUS = {\n Ok: 200,\n Created: 201,\n NoContent: 204,\n BadRequest: 400,\n Unauthorized: 401,\n Forbidden: 403,\n NotFound: 404,\n Conflict: 409,\n UnprocessableEntity: 422,\n TooManyRequests: 429,\n InternalError: 500,\n} as const;\n\nexport type THttpStatusCode = (typeof HTTP_STATUS)[keyof typeof HTTP_STATUS];\n\nexport type TApiErrorDetails = TJsonValue;\n\nexport interface IApiError<TDetails = TApiErrorDetails> {\n message: string;\n code?: TErrorCode;\n details?: TDetails;\n}\n\nexport interface IApiMeta {\n timestamp: TDateTimeString;\n version: string;\n environment: TEnvironment;\n requestId?: string;\n}\n\nexport interface IApiSuccessResponse<TData = null> {\n success: true;\n data: TData;\n meta: IApiMeta;\n}\n\nexport interface IApiErrorResponse<TErrorDetails = TApiErrorDetails> {\n success: false;\n error: IApiError<TErrorDetails>;\n meta: IApiMeta;\n}\n\nexport type IApiResponse<TData = null, TErrorDetails = TApiErrorDetails> =\n | IApiSuccessResponse<TData>\n | IApiErrorResponse<TErrorDetails>;\n","export type TValidationIssueType =\n | \"INVALID_BODY\"\n | \"MISSING_FIELD\"\n | \"INVALID_FIELD\"\n | \"UNSUPPORTED_FIELD\";\n\nexport interface IValidationIssue<TFieldName extends string = string> {\n fieldName: TFieldName;\n type: TValidationIssueType;\n}\n\nexport interface IValidationResult<TValue extends object> {\n success: boolean;\n data?: TValue;\n issues: IValidationIssue[];\n}\n\nexport type TMissingValuePolicy = \"Nullish\" | \"BlankString\";\n\nexport interface IValidationField<TValue, TRequired extends boolean> {\n readonly valueType?: TValue;\n required: TRequired;\n missingValuePolicy: TMissingValuePolicy;\n validate: (value: unknown) => boolean;\n}\n\nexport type TValidationFieldMap = Record<\n string,\n IValidationField<unknown, boolean>\n>;\n\ntype TRequiredSchemaKeys<TFields extends TValidationFieldMap> = {\n [TKey in keyof TFields]: TFields[TKey] extends IValidationField<unknown, true>\n ? TKey\n : never;\n}[keyof TFields];\n\ntype TOptionalSchemaKeys<TFields extends TValidationFieldMap> = Exclude<\n keyof TFields,\n TRequiredSchemaKeys<TFields>\n>;\n\ntype TFieldValue<TField> =\n TField extends IValidationField<infer TValue, boolean> ? TValue : never;\n\nexport type TInferValidationFields<TFields extends TValidationFieldMap> = {\n [TKey in TRequiredSchemaKeys<TFields>]: TFieldValue<TFields[TKey]>;\n} & {\n [TKey in TOptionalSchemaKeys<TFields>]?: TFieldValue<TFields[TKey]>;\n};\n\nexport type TInferValidationSchemaInput<TSchema> =\n TSchema extends IRuntimeValidationSchema<infer TFields>\n ? TInferValidationFields<TFields>\n : never;\n\nexport interface IRuntimeValidationSchema<\n TFields extends TValidationFieldMap = TValidationFieldMap,\n> {\n fields: TFields;\n allowedFields: readonly Extract<keyof TFields, string>[];\n requiredFields: readonly Extract<TRequiredSchemaKeys<TFields>, string>[];\n validate: (\n value: unknown,\n options?: IRuntimeValidationOptions,\n ) => IValidationResult<TInferValidationFields<TFields>>;\n}\n\nexport interface IRuntimeValidationOptions {\n rejectUnknownFields?: boolean;\n}\n\nexport const createValidationSchema = <TFields extends TValidationFieldMap>(\n fields: TFields,\n): IRuntimeValidationSchema<TFields> => {\n const allowedFields = Object.keys(fields) as Extract<keyof TFields, string>[];\n const requiredFields = allowedFields.filter((fieldName) => {\n return fields[fieldName].required;\n }) as Extract<TRequiredSchemaKeys<TFields>, string>[];\n\n return {\n fields,\n allowedFields,\n requiredFields,\n validate: (value, options = {}) => {\n if (!isRecord(value)) {\n return {\n success: false,\n issues: [\n {\n fieldName: \"body\",\n type: \"INVALID_BODY\",\n },\n ],\n };\n }\n\n const issues = getValidationIssues(fields, value, options);\n\n if (issues.length > 0) {\n return {\n success: false,\n issues,\n };\n }\n\n return {\n success: true,\n data: value as TInferValidationFields<TFields>,\n issues: [],\n };\n },\n };\n};\n\nexport const requiredStringField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isNonEmptyString,\n});\n\nexport const optionalStringField = (): IValidationField<string, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isNonEmptyString,\n});\n\nexport const optionalNullableStringField = (): IValidationField<\n string | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is string | null => {\n return value === null || isNonEmptyString(value);\n },\n});\n\nexport const requiredEmailField = (\n missingValuePolicy: TMissingValuePolicy = \"BlankString\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isEmail,\n});\n\nexport const requiredUuidField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isUuid,\n});\n\nexport const optionalNullableNonNegativeIntegerField = (): IValidationField<\n number | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is number | null => {\n return value === null || (Number.isInteger(value) && Number(value) >= 0);\n },\n});\n\nexport const optionalRecordField = (): IValidationField<\n Record<string, unknown>,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isRecord,\n});\n\nexport const requiredEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<TValue, true> => ({\n required: true,\n missingValuePolicy,\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalNullableEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue | null, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue | null => {\n return value === null || isAllowedStringValue(value, allowedValues);\n },\n});\n\nconst getValidationIssues = <TFields extends TValidationFieldMap>(\n fields: TFields,\n value: Record<string, unknown>,\n options: IRuntimeValidationOptions,\n): IValidationIssue[] => {\n const allowedFieldSet = new Set(Object.keys(fields));\n const issues: IValidationIssue[] = [];\n\n Object.entries(fields).forEach(([fieldName, field]) => {\n const fieldValue = value[fieldName];\n\n if (\n field.required &&\n isMissingValue(fieldValue, field.missingValuePolicy)\n ) {\n issues.push({\n fieldName,\n type: \"MISSING_FIELD\",\n });\n return;\n }\n\n if (fieldValue === undefined) {\n return;\n }\n\n if (!field.validate(fieldValue)) {\n issues.push({\n fieldName,\n type: \"INVALID_FIELD\",\n });\n }\n });\n\n if (options.rejectUnknownFields === true) {\n Object.keys(value).forEach((fieldName) => {\n if (!allowedFieldSet.has(fieldName)) {\n issues.push({\n fieldName,\n type: \"UNSUPPORTED_FIELD\",\n });\n }\n });\n }\n\n return issues;\n};\n\nconst isRecord = (value: unknown): value is Record<string, unknown> => {\n return typeof value === \"object\" && value !== null && !Array.isArray(value);\n};\n\nconst isMissingValue = (\n value: unknown,\n missingValuePolicy: TMissingValuePolicy,\n): boolean => {\n if (value === undefined || value === null) {\n return true;\n }\n\n return (\n missingValuePolicy === \"BlankString\" &&\n typeof value === \"string\" &&\n value.trim().length === 0\n );\n};\n\nconst isNonEmptyString = (value: unknown): value is string => {\n return typeof value === \"string\" && value.trim().length > 0;\n};\n\nconst isAllowedStringValue = <TValue extends string>(\n value: unknown,\n allowedValues: readonly TValue[],\n): value is TValue => {\n return typeof value === \"string\" && allowedValues.includes(value as TValue);\n};\n\nconst isEmail = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value.trim());\n};\n\nconst isUuid = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(\n value,\n );\n};\n","import type { TRecordValue } from \"../base\";\n\nexport const ACCOUNT_TYPE = {\n TURNDOWN_ADMIN: \"TURNDOWN_ADMIN\",\n ACCOUNT_ADMIN: \"ACCOUNT_ADMIN\",\n MANAGER: \"MANAGER\",\n STAFF: \"STAFF\",\n GUEST: \"GUEST\",\n} as const;\n\nexport type TAccountType = TRecordValue<typeof ACCOUNT_TYPE>;\n\nexport const ACCOUNT_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n PENDING: \"PENDING\",\n} as const;\n\nexport type TAccountStatus = TRecordValue<typeof ACCOUNT_STATUS>;\n\nexport const LANGUAGE = {\n ENGLISH: \"ENGLISH\",\n FRENCH: \"FRENCH\",\n SPANISH: \"SPANISH\",\n GERMAN: \"GERMAN\",\n} as const;\n\nexport type TLanguage = TRecordValue<typeof LANGUAGE>;\n","import {\n createValidationSchema,\n optionalRecordField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\nimport type { IAuthTokenResponse } from \"./index\";\nimport type { IEmptyRouteRequest, TDateTimeString } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport type { IDeviceInfo } from \"../user\";\nimport type { IGetUserResponse } from \"../user/routes\";\n\n// Route Params\nexport interface IAuthSessionIdParams {\n sessionId: string;\n}\n\nexport interface IAuthInvitationTokenParams {\n token: string;\n}\n\nexport interface IAuthInvitationIdParams {\n invitationId: string;\n}\n\n// Shared Responses\nexport interface IAuthMessageResponse {\n message: string;\n}\n\nexport interface IAuthRefreshTokenResponse extends IAuthTokenResponse {}\n\nexport interface IAuthInvitationBaseResponse {\n id: string;\n companyId: string;\n companyName: string;\n role: TAccountType;\n invitedBy: string;\n invitedByName: string;\n expiresAt: TDateTimeString;\n}\n\nconst AccountTypeValues = Object.values(ACCOUNT_TYPE);\n\n// Core Authentication\nexport const RegisterRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n accountType: requiredEnumField(AccountTypeValues, \"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterResponse extends IAuthTokenResponse {}\n\nexport const LoginRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type ILoginRequest = Omit<\n TInferValidationSchemaInput<typeof LoginRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface ILoginResponse extends IAuthTokenResponse {\n passwordResetRequired: boolean;\n}\n\nexport const RefreshSessionRequestSchema = createValidationSchema({\n refreshToken: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRefreshSessionRequest = Omit<\n TInferValidationSchemaInput<typeof RefreshSessionRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRefreshSessionResponse extends IAuthRefreshTokenResponse {}\n\nexport const LogoutRequestSchema = createValidationSchema({\n refreshToken: optionalStringField(),\n});\n\nexport type ILogoutRequest = TInferValidationSchemaInput<\n typeof LogoutRequestSchema\n>;\n\nexport interface ILogoutResponse extends IAuthMessageResponse {}\n\nexport interface ILogoutAllRequest {\n userId: string;\n}\n\nexport interface ILogoutAllResponse extends IAuthMessageResponse {}\n\nexport interface IGetMeRequest {\n userId: string;\n}\n\nexport interface IGetMeResponse extends IGetUserResponse {}\n\n// Session Management\nexport type IGetSessionsRequest = IEmptyRouteRequest;\n\nexport interface IGetSessionsResponse {\n id: string;\n deviceInfo: string;\n createdAt: TDateTimeString;\n lastUsedAt: TDateTimeString;\n}\n\nexport interface IRevokeSessionRequest extends IAuthSessionIdParams {}\n\nexport interface IRevokeSessionResponse extends IAuthMessageResponse {}\n\n// Password Management\nexport const ChangePasswordRequestSchema = createValidationSchema({\n currentPassword: requiredStringField(\"BlankString\"),\n newPassword: requiredStringField(\"BlankString\"),\n});\n\nexport type IChangePasswordRequest = TInferValidationSchemaInput<\n typeof ChangePasswordRequestSchema\n>;\n\nexport interface IChangePasswordResponse extends IGetUserResponse {}\n\nexport const ForgotPasswordRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n});\n\nexport type IForgotPasswordRequest = TInferValidationSchemaInput<\n typeof ForgotPasswordRequestSchema\n>;\n\nexport interface IForgotPasswordResponse extends IAuthMessageResponse {}\n\nexport type IGetLoginHistoryRequest = IEmptyRouteRequest;\n\nexport interface IGetLoginHistoryResponse {\n id: string;\n email: string;\n ipAddress: string;\n userAgent: string;\n success: boolean;\n failureReason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetLoginHistoryListResponse {\n history: IGetLoginHistoryResponse[];\n length: number;\n}\n\n// Invitations\nexport interface IValidateInvitationRequest extends IAuthInvitationTokenParams {}\n\nexport interface IValidateInvitationResponse extends IAuthInvitationBaseResponse {\n email: string;\n userExists: boolean;\n}\n\nexport const RegisterWithInvitationRequestSchema = createValidationSchema({\n token: requiredStringField(\"BlankString\"),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterWithInvitationRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterWithInvitationRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterWithInvitationResponse extends IAuthTokenResponse {}\n\nexport const AcceptInvitationRequestSchema = createValidationSchema({\n userId: optionalStringField(),\n token: requiredStringField(\"BlankString\"),\n});\n\nexport type IAcceptInvitationRequest = TInferValidationSchemaInput<\n typeof AcceptInvitationRequestSchema\n>;\n\nexport interface IAcceptInvitationResponse {\n companyId: string;\n companyName: string;\n role: TAccountType;\n}\n\nexport interface IAcceptInvitationRouteResponse {\n invite: IAcceptInvitationResponse;\n message: string;\n}\n\nexport type IGetPendingInvitationsRequest = IEmptyRouteRequest;\n\nexport interface IGetPendingInvitationsResponse extends IAuthInvitationBaseResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetPendingInvitationsListResponse {\n invitations: IGetPendingInvitationsResponse[];\n length: number;\n}\n\nexport interface IRevokeInvitationRequest extends IAuthInvitationIdParams {\n revokedBy?: string;\n}\n\nexport interface IRevokeInvitationResponse extends IAuthMessageResponse {}\n","export * from \"./routes\";\n\nimport type { TDateTimeString, TServiceType } from \"../base\";\nimport type { IUser } from \"../user\";\n\nexport const AUTH_STATUS = {\n Initializing: \"Initializing\",\n Unauthenticated: \"Unauthenticated\",\n Authenticated: \"Authenticated\",\n Refreshing: \"Refreshing\",\n SessionExpired: \"SessionExpired\",\n} as const;\n\nexport type TAuthStatus = (typeof AUTH_STATUS)[keyof typeof AUTH_STATUS];\n\nexport interface IAuthTokenBundle {\n accessToken: string;\n refreshToken: string;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IRefreshTokenData {\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IRefreshTokenPersistenceData extends IRefreshTokenData {\n tokenHash: string;\n tokenFamily: string;\n}\n\nexport interface ITokenPayload {\n userId: string;\n email: string;\n name: string;\n}\n\nexport interface IStoredAuthSession {\n accessToken: string | null;\n refreshToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IAuthTokenResponse extends IAuthTokenBundle {\n user: IUser | null;\n companyId: string | null;\n}\n\nexport interface IAuthSession {\n user: IUser | null;\n accessToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface ISetAuthSessionParams extends IAuthTokenBundle {\n user: IUser | null;\n}\n\nexport interface ILoginCredentials {\n email: string;\n password: string;\n rememberMe: boolean;\n}\n\nexport interface IRegisterCredentials {\n businessType: TServiceType[];\n firstName: string;\n lastName: string;\n email: string;\n password: string;\n}\n\nexport interface IPasswordValidationRules {\n minLength: number;\n requireUppercase: boolean;\n requireLowercase: boolean;\n requireNumbers: boolean;\n requireSpecialChars: boolean;\n}\n\nexport interface IPasswordValidationResult {\n valid: boolean;\n errors: string[];\n}\n\nexport interface IEmailValidationResult {\n valid: boolean;\n error?: string;\n}\n\nexport interface IRateLimitStatus {\n isLimited: boolean;\n attempts: number;\n maxAttempts: number;\n resetTime: TDateTimeString | null;\n}\n","/**\n * Pagination metadata for a paginated response.\n */\nexport interface IPagingResult {\n hasNextPage: boolean;\n totalPages: number;\n totalRecords: number;\n}\n\n/**\n * Generic wrapper for paginated data.\n */\nexport interface IDataWithPagingResult<TData> {\n data: TData;\n pagination: IPagingResult;\n}\n\nexport const SortDirection = {\n Asc: \"Asc\",\n Desc: \"Desc\",\n} as const;\n\nexport type TSortDirection = (typeof SortDirection)[keyof typeof SortDirection];\n\n/**\n * Sorting condition for query results.\n */\nexport interface ISortCondition {\n name: string;\n direction: TSortDirection;\n}\n\nexport const FilterCondition = {\n Equal: \"=\",\n GreaterThan: \">\",\n LessThan: \"<\",\n NotEqual: \"!=\",\n Like: \"LIKE\",\n In: \"IN\",\n GreaterThanOrEqual: \">=\",\n LessThanOrEqual: \"<=\",\n} as const;\n\nexport type TFilterCondition =\n (typeof FilterCondition)[keyof typeof FilterCondition];\n\nexport interface IFilterConditionBase {\n name: string;\n condition: TFilterCondition;\n useAnd?: boolean;\n}\n\nexport interface IStringFilterCondition extends IFilterConditionBase {\n valueString: string;\n valueNumber?: never;\n valueBoolean?: never;\n}\n\nexport interface INumberFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber: number;\n valueBoolean?: never;\n}\n\nexport interface IBooleanFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber?: never;\n valueBoolean: boolean;\n}\n\n/**\n * Filter condition for querying data.\n *\n * Exactly one value field should be provided.\n */\nexport type TFilterConditionValue =\n | IStringFilterCondition\n | INumberFilterCondition\n | IBooleanFilterCondition;\n\n/**\n * Kept as an exported alias to preserve the existing public API name.\n */\nexport type IFilterCondition = TFilterConditionValue;\n\n/**\n * Request shape for paginated data with optional sorting and filtering.\n */\nexport interface IPaginationRequest {\n page: number;\n size: number;\n sort?: ISortCondition[];\n filters?: IFilterCondition[];\n}\n\nexport interface IPagingObject {\n pagination: IPaginationRequest;\n}\n\nexport const createPagingObject = (\n page: number,\n size: number,\n sort?: ISortCondition[],\n filters?: IFilterCondition[],\n): IPagingObject => ({\n pagination: {\n page,\n size,\n sort,\n filters,\n },\n});\n","export type TJsonPrimitive = string | number | boolean | null;\n\nexport type TJsonObject = {\n [key: string]: TJsonValue;\n};\n\nexport type TJsonValue = TJsonPrimitive | TJsonValue[] | TJsonObject;\n\nexport type TUnknownRecord = Record<string, unknown>;\n\n/**\n * Serialized ISO-8601 date/time value returned by API JSON contracts.\n */\nexport type TDateTimeString = string;\n\nexport type TurndownObject<TObject extends object = TUnknownRecord> = TObject;\n\nexport type TEmptyObject = Record<string, never>;\n\nexport type IEmptyRouteRequest = TEmptyObject;\n\nexport type IEmptyRouteParams = TEmptyObject;\n\nexport const ENVIRONMENT = {\n Prod: \"Prod\",\n Dev: \"Dev\",\n Local: \"Local\",\n Test: \"Test\",\n} as const;\n\nexport type TEnvironment = (typeof ENVIRONMENT)[keyof typeof ENVIRONMENT];\n\nexport interface IMessageResponse {\n message: string;\n}\n\nexport interface ISuccessResponse {\n success: boolean;\n}\n\nexport interface ICountResponse {\n count: number;\n}\n\nexport interface IMetaData {\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport type TRecordValue<TRecord extends object> = TRecord[keyof TRecord];\n\nexport type TRecordKeys<TRecord extends object> = keyof TRecord;\n\nexport interface IVersion {\n major: number;\n minor: number;\n patch: number;\n}\n\nexport type TVersionInput = string | IVersion;\n\nexport interface ISelectOption<TValue extends string = string> {\n label: string;\n value: TValue;\n}\n\nexport const MODE = {\n Create: \"Create\",\n Edit: \"Edit\",\n Delete: \"Delete\",\n Details: \"Details\",\n} as const;\n\nexport type TMode = TRecordValue<typeof MODE> | null;\n\nexport const IMAGE_ENTITY = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TImageEntityType = TRecordValue<typeof IMAGE_ENTITY>;\n\nexport type TUSStateCode = TRecordKeys<typeof US_JURISDICTIONS>;\n\nexport const US_JURISDICTIONS = {\n // 50 States\n AL: \"Alabama\",\n AK: \"Alaska\",\n AZ: \"Arizona\",\n AR: \"Arkansas\",\n CA: \"California\",\n CO: \"Colorado\",\n CT: \"Connecticut\",\n DE: \"Delaware\",\n FL: \"Florida\",\n GA: \"Georgia\",\n HI: \"Hawaii\",\n ID: \"Idaho\",\n IL: \"Illinois\",\n IN: \"Indiana\",\n IA: \"Iowa\",\n KS: \"Kansas\",\n KY: \"Kentucky\",\n LA: \"Louisiana\",\n ME: \"Maine\",\n MD: \"Maryland\",\n MA: \"Massachusetts\",\n MI: \"Michigan\",\n MN: \"Minnesota\",\n MS: \"Mississippi\",\n MO: \"Missouri\",\n MT: \"Montana\",\n NE: \"Nebraska\",\n NV: \"Nevada\",\n NH: \"New Hampshire\",\n NJ: \"New Jersey\",\n NM: \"New Mexico\",\n NY: \"New York\",\n NC: \"North Carolina\",\n ND: \"North Dakota\",\n OH: \"Ohio\",\n OK: \"Oklahoma\",\n OR: \"Oregon\",\n PA: \"Pennsylvania\",\n RI: \"Rhode Island\",\n SC: \"South Carolina\",\n SD: \"South Dakota\",\n TN: \"Tennessee\",\n TX: \"Texas\",\n UT: \"Utah\",\n VT: \"Vermont\",\n VA: \"Virginia\",\n WA: \"Washington\",\n WV: \"West Virginia\",\n WI: \"Wisconsin\",\n WY: \"Wyoming\",\n\n // Territories\n DC: \"District of Columbia\",\n PR: \"Puerto Rico\",\n GU: \"Guam\",\n VI: \"United States Virgin Islands\",\n AS: \"American Samoa\",\n MP: \"Northern Mariana Islands\",\n} as const;\n\nexport type TUSJurisdiction = TRecordValue<typeof US_JURISDICTIONS>;\n\nexport const STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n OVERDUE: \"OVERDUE\",\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TStatus = TRecordValue<typeof STATUS>;\n\nexport const SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n} as const;\n\nexport type TSeverity = TRecordValue<typeof SEVERITY>;\n\nexport const SERVICE_TYPES = {\n PROPERTY: \"PROPERTY\",\n CLEANING: \"CLEANING\",\n MAINTENANCE: \"MAINTENANCE\",\n INSPECTION: \"INSPECTION\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TServiceType = TRecordValue<typeof SERVICE_TYPES>;\n\nexport const MONTHS = [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n] as const;\n\nexport type TMonths = (typeof MONTHS)[number];\n\nexport const WEEK_DAY = {\n Sunday: \"Sunday\",\n Monday: \"Monday\",\n Tuesday: \"Tuesday\",\n Wednesday: \"Wednesday\",\n Thursday: \"Thursday\",\n Friday: \"Friday\",\n Saturday: \"Saturday\",\n} as const;\n\nexport type TWeekDay = TRecordValue<typeof WEEK_DAY>;\n\nexport const WEEK_DAY_SHORT_LABEL = {\n Sunday: \"Sun\",\n Monday: \"Mon\",\n Tuesday: \"Tue\",\n Wednesday: \"Wed\",\n Thursday: \"Thu\",\n Friday: \"Fri\",\n Saturday: \"Sat\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayShortLabel = TRecordValue<typeof WEEK_DAY_SHORT_LABEL>;\n\nexport const WEEK_DAY_LETTER = {\n Sunday: \"S\",\n Monday: \"M\",\n Tuesday: \"T\",\n Wednesday: \"W\",\n Thursday: \"T\",\n Friday: \"F\",\n Saturday: \"S\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayLetter = TRecordValue<typeof WEEK_DAY_LETTER>;\n\nexport interface IWeekDay {\n date: Date;\n dayOfMonth: number;\n day: TWeekDay;\n shortLabel: TWeekDayShortLabel;\n letter: TWeekDayLetter;\n isToday: boolean;\n}\n\nconst createSelectOptions = <TValue extends string>(\n values: readonly TValue[],\n): ISelectOption<TValue>[] =>\n values.map((value) => ({\n label: value,\n value,\n }));\n\nconst getRecordValues = <TRecord extends Record<string, string>>(\n record: TRecord,\n): TRecordValue<TRecord>[] => Object.values(record) as TRecordValue<TRecord>[];\n\nexport const UnitedStatesJurisdictionOptions = createSelectOptions(\n getRecordValues(US_JURISDICTIONS),\n);\n\nexport const StatusOptions: ISelectOption<TStatus>[] = [\n { label: \"Pending\", value: STATUS.PENDING },\n { label: \"In Progress\", value: STATUS.IN_PROGRESS },\n { label: \"Completed\", value: STATUS.COMPLETED },\n { label: \"Overdue\", value: STATUS.OVERDUE },\n { label: \"Active\", value: STATUS.ACTIVE },\n { label: \"Inactive\", value: STATUS.INACTIVE },\n];\n\nexport const SeverityOptions: ISelectOption<TSeverity>[] = [\n { label: \"Low\", value: SEVERITY.LOW },\n { label: \"Medium\", value: SEVERITY.MEDIUM },\n { label: \"High\", value: SEVERITY.HIGH },\n];\n\nexport const ServiceTypeOptions: ISelectOption<TServiceType>[] = [\n { label: \"Property\", value: SERVICE_TYPES.PROPERTY },\n { label: \"Cleaning\", value: SERVICE_TYPES.CLEANING },\n { label: \"Maintenance\", value: SERVICE_TYPES.MAINTENANCE },\n { label: \"Inspection\", value: SERVICE_TYPES.INSPECTION },\n { label: \"Other\", value: SERVICE_TYPES.OTHER },\n];\n\nexport * from \"./paging.types\";\n","import type { TRecordValue } from \"../base\";\n\nexport const COMPANY_RELATIONSHIP_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n} as const;\n\nexport const INVITATION_STATUS = {\n PENDING: \"PENDING\",\n ACCEPTED: \"ACCEPTED\",\n EXPIRED: \"EXPIRED\",\n REVOKED: \"REVOKED\",\n DECLINED: \"DECLINED\",\n} as const;\n\nexport type TInvitationStatus = TRecordValue<typeof INVITATION_STATUS>;\n\nexport type TCompanyRelationshipStatus =\n | TRecordValue<typeof COMPANY_RELATIONSHIP_STATUS>\n | typeof INVITATION_STATUS.PENDING\n | null;\n\nexport const COMPANY_TYPES = {\n PROPERTY_MANAGEMENT: \"PROPERTY_MANAGEMENT\",\n MAINTENANCE: \"MAINTENANCE\",\n CLEANER: \"CLEANER\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TCompanyType = TRecordValue<typeof COMPANY_TYPES>;\n","import type { ICompany, ICompanyWithRelationshipStatus } from \".\";\nimport { COMPANY_TYPES } from \"./constants\";\nimport type {\n IEmptyRouteRequest,\n IMessageResponse,\n TDateTimeString,\n TUSStateCode,\n} from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n requiredUuidField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface ICompanyRouteParams {\n companyId: string;\n}\n\nexport interface ICompanyUserRouteParams {\n userId: string;\n}\n\nexport interface ICompanyInvitationTokenParams {\n token: string;\n}\n\nexport interface ICompanyInvitationIdParams extends ICompanyRouteParams {\n invitationId: string;\n}\n\nexport const CompanyFilter = {\n Active: \"active\",\n Pending: \"pending\",\n All: \"all\",\n} as const;\n\nexport type TCompanyFilter = (typeof CompanyFilter)[keyof typeof CompanyFilter];\n\nexport interface IGetCompaniesQuery {\n companyId?: string;\n search?: string;\n filter?: TCompanyFilter;\n}\n\nconst CompanyTypeValues = Object.values(COMPANY_TYPES);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\nconst InviteUserRoleValues = Object.values(ACCOUNT_TYPE).filter(\n (accountType) => accountType !== ACCOUNT_TYPE.TURNDOWN_ADMIN,\n);\n\nexport const CreateCompanyRequestSchema = createValidationSchema({\n displayName: requiredStringField(\"BlankString\"),\n addressLine1: requiredStringField(\"BlankString\"),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(\"BlankString\"),\n stateCode: requiredEnumField(StateCodeValues, \"BlankString\"),\n postalCode: requiredStringField(\"BlankString\"),\n companyType: requiredEnumField(CompanyTypeValues, \"BlankString\"),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type ICreateCompanyRequest = TInferValidationSchemaInput<\n typeof CreateCompanyRequestSchema\n> & {\n stateCode: TUSStateCode;\n companyType: ICompany[\"companyType\"];\n};\n\nexport interface ICreateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport type IGetCompaniesRequest = IEmptyRouteRequest;\nexport type IGetCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport interface IGetCompanyByIdRequest extends ICompanyRouteParams {}\nexport interface IGetCompanyByIdResponse extends ICompanyWithRelationshipStatus {}\n\nexport const UpdateCompanyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n companyType: optionalEnumField(CompanyTypeValues),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type IUpdateCompanyRequest = TInferValidationSchemaInput<\n typeof UpdateCompanyRequestSchema\n> & {\n stateCode?: TUSStateCode;\n companyType?: ICompany[\"companyType\"];\n};\n\nexport interface IUpdateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport const InviteUserToCompanyRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n role: requiredEnumField(InviteUserRoleValues, \"BlankString\"),\n});\n\nexport type IInviteUserToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteUserToCompanyRequestSchema\n> & {\n role: TAccountType;\n};\n\nexport interface IInviteUserToCompanyResponse extends IMessageResponse {}\n\nexport interface IGetCompanyUsersRequest extends ICompanyRouteParams {}\nexport interface ICompanyUserSummary {\n id: string;\n email: string;\n firstName: string;\n lastName: string | null;\n role: TAccountType;\n}\nexport interface ICompanyWithUsers extends ICompanyWithRelationshipStatus {\n users: ICompanyUserSummary[];\n}\nexport interface IGetCompanyUsersResponse extends ICompanyWithUsers {}\n\nexport interface IGetUserCompaniesRequest extends ICompanyUserRouteParams {}\nexport type IGetUserCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport const InviteCompanyToCompanyRequestSchema = createValidationSchema({\n providerCompanyId: requiredUuidField(),\n message: optionalNullableStringField(),\n});\n\nexport type IInviteCompanyToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteCompanyToCompanyRequestSchema\n>;\n\nexport interface IInviteCompanyToCompanyResponse {\n id: string;\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IValidateCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IValidateCompanyInvitationResponse {\n id: string;\n requesterCompanyId: string;\n providerCompanyId: string;\n invitedBy: string;\n message: string | null;\n expiresAt: TDateTimeString;\n requesterCompanyName: string;\n providerCompanyName: string;\n invitedByName: string;\n}\n\nexport interface IAcceptCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IAcceptCompanyInvitationResponse {\n requesterCompanyId: string;\n providerCompanyId: string;\n requesterCompanyName: string;\n providerCompanyName: string;\n}\n\nexport interface IDeclineCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IDeclineCompanyInvitationResponse extends IMessageResponse {}\n\nexport interface IGetPendingCompanyInvitationsRequest extends ICompanyRouteParams {}\nexport interface ICompanyInvitationSummary extends IValidateCompanyInvitationResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport type IGetPendingCompanyInvitationsResponse = ICompanyInvitationSummary[];\n\nexport interface IRevokeCompanyInvitationRequest extends ICompanyInvitationIdParams {}\nexport interface IRevokeCompanyInvitationResponse extends IMessageResponse {}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\n\nexport const DAMAGE_SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n CRITICAL: \"CRITICAL\",\n} as const;\n\nexport type TDamageSeverity = TRecordValue<typeof DAMAGE_SEVERITY>;\n\nexport const DAMAGE_STATUS = {\n OPEN: \"OPEN\",\n IN_REVIEW: \"IN_REVIEW\",\n ASSIGNED: \"ASSIGNED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n RESOLVED: \"RESOLVED\",\n CLOSED: \"CLOSED\",\n ESCALATED: \"ESCALATED\",\n} as const;\n\nexport type TDamageStatus = TRecordValue<typeof DAMAGE_STATUS>;\n\nexport const WORK_ORDER_PRIORITY = {\n LOW: \"LOW\",\n NORMAL: \"NORMAL\",\n HIGH: \"HIGH\",\n URGENT: \"URGENT\",\n} as const;\n\nexport type TWorkOrderPriority = TRecordValue<typeof WORK_ORDER_PRIORITY>;\n\nexport const WORK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n SCHEDULED: \"SCHEDULED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkOrderStatus = TRecordValue<typeof WORK_ORDER_STATUS>;\n\nexport interface IDamageReport {\n id: string;\n propertyId: string;\n roomId: string;\n workSessionId: string | null;\n cleaningSessionId: string | null;\n reportedBy: string;\n reportedAt: TDateTimeString;\n severity: TDamageSeverity;\n status: TDamageStatus;\n title: string;\n description: string;\n locationDetails: string | null;\n estimatedCost: number | null;\n actualCost: number | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n resolvedAt: TDateTimeString | null;\n resolvedBy: string | null;\n resolutionNotes: string | null;\n requiresProfessional: boolean;\n vendorInfo: string | null;\n insuranceClaimNumber: string | null;\n isTenantResponsible: boolean;\n tenantChargeAmount: number | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n photos?: IDamagePhoto[];\n comments?: IDamageComment[];\n}\n\nexport interface IDamageReportPhoto {\n id: string;\n damageReportId: string;\n photoId: string;\n imageUrl: string | null;\n caption: string | null;\n isBeforePhoto: boolean;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IDamagePhoto extends IDamageReportPhoto {}\n\nexport interface IDamageComment {\n id: string;\n damageReportId: string;\n userId: string;\n userName: string | null;\n comment: string;\n isInternal: boolean;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IDamageReportStatusHistory {\n id: string;\n damageReportId: string;\n previousStatus: TDamageStatus | null;\n newStatus: TDamageStatus;\n changedBy: string;\n reason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IWorkOrder {\n id: string;\n damageReportId: string | null;\n propertyId: string;\n roomId: string | null;\n workOrderNumber: string | null;\n priority: TWorkOrderPriority;\n category: string | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n scheduledDate: TDateTimeString | null;\n scheduledTimeStart: string | null;\n scheduledTimeEnd: string | null;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n completedBy: string | null;\n description: string;\n workPerformed: string | null;\n materialsUsed: string | null;\n laborHours: number | null;\n laborCost: number | null;\n materialsCost: number | null;\n totalCost: number | null;\n status: TWorkOrderStatus;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface ICreateDamageReportInput {\n propertyId: string;\n roomId: string;\n workSessionId?: string;\n reportedBy: string;\n severity: TDamageSeverity;\n title: string;\n description: string;\n locationDetails?: string;\n estimatedCost?: number;\n requiresProfessional?: boolean;\n isTenantResponsible?: boolean;\n tenantChargeAmount?: number;\n}\n\nexport interface ICreateWorkOrderInput {\n damageReportId?: string;\n propertyId: string;\n roomId?: string;\n priority?: TWorkOrderPriority;\n category?: string;\n description: string;\n scheduledDate?: TDateTimeString;\n scheduledTimeStart?: string;\n scheduledTimeEnd?: string;\n}\n\nexport * from \"./routes\";\n","/**\n * Error Types\n * Custom error types and validation error structures.\n */\n\nimport { ERROR_CODES } from \"../api\";\nimport type { TErrorCode } from \"../api\";\nimport type { TJsonObject, TJsonValue } from \"../base\";\n\n/**\n * Detailed information about a validation error.\n */\nexport interface IValidationErrorDetail {\n field: string;\n message: string;\n value?: TJsonValue;\n}\n\n/**\n * Information about missing required fields.\n */\nexport interface IMissingFieldsErrorDetail {\n missingFields: string[];\n}\n\n/**\n * Information about rate limiting.\n */\nexport interface IRateLimitErrorDetail {\n retryAfter?: number;\n message: string;\n}\n\nexport type TErrorResponseDetail =\n | IValidationErrorDetail[]\n | IMissingFieldsErrorDetail\n | IRateLimitErrorDetail\n | TJsonObject\n | string;\n\nexport interface ITypedApiError<TDetails = TErrorResponseDetail> {\n message: string;\n code: TErrorCode;\n details?: TDetails;\n}\n\nexport type TValidationError = ITypedApiError<IValidationErrorDetail[]>;\nexport type TMissingFieldsError = ITypedApiError<IMissingFieldsErrorDetail>;\nexport type TRateLimitError = ITypedApiError<IRateLimitErrorDetail>;\n\ntype TErrorLike = {\n code?: string;\n details?: unknown;\n};\n\nconst isErrorLike = (error: unknown): error is TErrorLike => {\n return typeof error === \"object\" && error !== null;\n};\n\n/**\n * Type guard for validation errors.\n */\nexport function isValidationError(error: unknown): error is TValidationError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.VALIDATION_ERROR &&\n Array.isArray(error.details)\n );\n}\n\n/**\n * Type guard for missing-field errors.\n */\nexport function isMissingFieldsError(\n error: unknown,\n): error is TMissingFieldsError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.MISSING_FIELDS &&\n typeof error.details === \"object\" &&\n error.details !== null &&\n \"missingFields\" in error.details &&\n Array.isArray(error.details.missingFields)\n );\n}\n\n/**\n * Type guard for rate-limit errors.\n */\nexport function isRateLimitError(error: unknown): error is TRateLimitError {\n return isErrorLike(error) && error.code === ERROR_CODES.RATE_LIMIT_EXCEEDED;\n}\n\n/**\n * Type guard for authentication errors.\n */\nexport function isAuthError(error: unknown): boolean {\n return (\n isErrorLike(error) &&\n (error.code === ERROR_CODES.UNAUTHORIZED ||\n error.code === ERROR_CODES.INVALID_TOKEN ||\n error.code === ERROR_CODES.INVALID_CREDENTIALS)\n );\n}\n","import type { TDateTimeString, TEnvironment } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const SERVER_STATUS = {\n Healthy: \"Healthy\",\n Unhealthy: \"UnHealthy\",\n} as const;\n\nexport type TServerStatus = (typeof SERVER_STATUS)[keyof typeof SERVER_STATUS];\n\nexport const DATABASE_STATUS = {\n Unknown: \"Unknown\",\n Connected: \"Connected\",\n Disconnected: \"Disconnected\",\n} as const;\n\nexport type TDatabaseStatus =\n (typeof DATABASE_STATUS)[keyof typeof DATABASE_STATUS];\n\nexport interface IHealthCheckResponse {\n status: TServerStatus;\n database: TDatabaseStatus;\n timestamp: TDateTimeString;\n environment: TEnvironment;\n}\n\nexport interface IHealthChecks {\n database: TDatabaseStatus;\n uptime: number;\n memory: {\n rss: number;\n heapTotal: number;\n heapUsed: number;\n external: number;\n arrayBuffers: number;\n };\n timestamp: TDateTimeString;\n databaseError?: string;\n}\n","import type { TDateTimeString } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const IMAGE_ENTITY_TYPE = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TStoredImageEntityType =\n (typeof IMAGE_ENTITY_TYPE)[keyof typeof IMAGE_ENTITY_TYPE];\n\nexport interface IImage {\n id: string;\n entityType: TStoredImageEntityType;\n entityId: string;\n fileName: string;\n mimeType: string;\n fileSizeBytes: number | null;\n width: number | null;\n height: number | null;\n isPublic: boolean;\n category: string | null;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport interface IImageWithUrl extends IImage {\n url: string;\n}\n","import type { IMetaData, TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\nexport const INVENTORY_RESTOCK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n ORDERED: \"ORDERED\",\n SHIPPED: \"SHIPPED\",\n RECEIVED: \"RECEIVED\",\n} as const;\n\nexport type TInventoryRestockOrderStatus = TRecordValue<\n typeof INVENTORY_RESTOCK_ORDER_STATUS\n>;\n\nexport const INVENTORY_UNITS = {\n COUNT: \"COUNT\",\n ROLLS: \"ROLLS\",\n PODS: \"PODS\",\n BOXES: \"BOXES\",\n BOTTLES: \"BOTTLES\",\n PACKS: \"PACKS\",\n BAGS: \"BAGS\",\n GALLONS: \"GALLONS\",\n LITERS: \"LITERS\",\n KILOGRAMS: \"KILOGRAMS\",\n POUNDS: \"POUNDS\",\n OUNCES: \"OUNCES\",\n GRAMS: \"GRAMS\",\n SHEETS: \"SHEETS\",\n CASES: \"CASES\",\n CARTONS: \"CARTONS\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TInventoryUnitType = TRecordValue<typeof INVENTORY_UNITS>;\n\nexport const INVENTORY_ITEM_TYPE = {\n CONSUMABLE: \"CONSUMABLE\",\n FIXED: \"FIXED\",\n} as const;\n\nexport type TInventoryItemType = TRecordValue<typeof INVENTORY_ITEM_TYPE>;\n\nexport interface IInventoryItem extends IMetaData {\n id: string;\n companyId: string;\n name: string;\n description: string | null;\n itemType: TInventoryItemType;\n unit: TInventoryUnitType;\n unitCustom: string | null;\n minimumLevel: number;\n reorderLevel: number;\n maximumLevel: number | null;\n costPerUnit: number | null;\n supplierInfo: string | null;\n sku: string | null;\n barcode: string | null;\n}\n\nexport interface IRoomInventory extends IMetaData {\n id: string;\n roomId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IPropertyInventory extends IMetaData {\n id: string;\n propertyId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IInventoryCount {\n id: string;\n checklistExecutionId: string;\n roomInventoryId: string;\n previousLevel: number;\n countedLevel: number;\n consumedAmount: number;\n restockedAmount: number;\n finalLevel: number;\n countedBy: string;\n countedAt: TDateTimeString;\n needsRestock: boolean;\n notes: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrder {\n id: string;\n companyId: string;\n orderNumber: string | null;\n status: TInventoryRestockOrderStatus;\n totalItems: number | null;\n totalCost: number | null;\n orderedBy: string | null;\n orderedAt: TDateTimeString | null;\n expectedDelivery: TDateTimeString | null;\n receivedBy: string | null;\n receivedAt: TDateTimeString | null;\n supplierInfo: string | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrderItem {\n id: string;\n orderId: string;\n inventoryItemId: string;\n roomInventoryId: string | null;\n propertyInventoryId: string | null;\n quantityOrdered: number;\n quantityReceived: number;\n unitCost: number | null;\n totalCost: number | null;\n createdAt: TDateTimeString;\n}\n","import type { ISelectOption, TRecordValue } from \"../base\";\n\nexport const PROPERTY_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TPropertyStatus = TRecordValue<typeof PROPERTY_STATUS>;\n\nexport const PropertyStatusOptions: ISelectOption<TPropertyStatus>[] = [\n {\n label: \"Active\",\n value: PROPERTY_STATUS.ACTIVE,\n },\n {\n label: \"Inactive\",\n value: PROPERTY_STATUS.INACTIVE,\n },\n];\n\nexport const PROPERTY_TYPES = {\n APARTMENT: \"APARTMENT\",\n COMMERCIAL: \"COMMERCIAL\",\n CONDO: \"CONDO\",\n DUPLEX: \"DUPLEX\",\n HOUSE: \"HOUSE\",\n MULTI_FAMILY: \"MULTI_FAMILY\",\n OFFICE: \"OFFICE\",\n RETAIL: \"RETAIL\",\n TOWNHOUSE: \"TOWNHOUSE\",\n VACATION_RENTAL: \"VACATION_RENTAL\",\n WAREHOUSE: \"WAREHOUSE\",\n} as const;\n\nexport type TPropertyType = TRecordValue<typeof PROPERTY_TYPES>;\n\nexport const PropertyTypeOptions: ISelectOption<TPropertyType>[] = [\n {\n label: \"Apartment\",\n value: PROPERTY_TYPES.APARTMENT,\n },\n {\n label: \"Commercial\",\n value: PROPERTY_TYPES.COMMERCIAL,\n },\n {\n label: \"Condo\",\n value: PROPERTY_TYPES.CONDO,\n },\n {\n label: \"Duplex\",\n value: PROPERTY_TYPES.DUPLEX,\n },\n {\n label: \"House\",\n value: PROPERTY_TYPES.HOUSE,\n },\n {\n label: \"Multi-Family\",\n value: PROPERTY_TYPES.MULTI_FAMILY,\n },\n {\n label: \"Office\",\n value: PROPERTY_TYPES.OFFICE,\n },\n {\n label: \"Retail\",\n value: PROPERTY_TYPES.RETAIL,\n },\n {\n label: \"Townhouse\",\n value: PROPERTY_TYPES.TOWNHOUSE,\n },\n {\n label: \"Vacation Rental\",\n value: PROPERTY_TYPES.VACATION_RENTAL,\n },\n {\n label: \"Warehouse\",\n value: PROPERTY_TYPES.WAREHOUSE,\n },\n];\n","import type {\n IProperty,\n IPropertyAccessInformation,\n IPropertyDetail,\n IPropertySummary,\n TPropertyStatus,\n TPropertyType,\n} from \".\";\nimport { PROPERTY_STATUS, PROPERTY_TYPES } from \"./constants\";\nimport type { IMessageResponse, TUSStateCode } from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableEnumField,\n optionalNullableNonNegativeIntegerField,\n optionalNullableStringField,\n optionalStringField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IPropertyIdParams {\n propertyId: string;\n}\n\nexport interface ICompanyIdParams {\n companyId: string;\n}\n\nconst PropertyTypeValues = Object.values(PROPERTY_TYPES);\nconst PropertyStatusValues = Object.values(PROPERTY_STATUS);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\n\nexport const CreatePropertyRequestSchema = createValidationSchema({\n companyId: requiredStringField(),\n displayName: requiredStringField(),\n propertyType: requiredEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: requiredStringField(),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(),\n stateCode: requiredEnumField(StateCodeValues),\n postalCode: requiredStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type ICreatePropertyRequest = TInferValidationSchemaInput<\n typeof CreatePropertyRequestSchema\n> & {\n companyId: string;\n propertyType: TPropertyType;\n status?: TPropertyStatus | null;\n stateCode: TUSStateCode;\n};\n\nexport const UpdatePropertyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n propertyType: optionalNullableEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type IUpdatePropertyRequest = TInferValidationSchemaInput<\n typeof UpdatePropertyRequestSchema\n> & {\n propertyType?: TPropertyType | null;\n status?: TPropertyStatus | null;\n stateCode?: TUSStateCode;\n};\n\nexport interface IGetPropertiesRequest {\n companyId?: string;\n}\n\nexport interface IGetPropertyByIdRequest extends IPropertyIdParams {}\n\nexport interface IDeletePropertyRequest extends IPropertyIdParams {}\n\nexport type IGetPropertiesResponse = IPropertySummary[];\n\nexport interface IGetPropertyResponse extends IPropertyDetail {}\n\nexport interface ICreatePropertyResponse extends IPropertyDetail {}\n\nexport interface IUpdatePropertyResponse extends IPropertyDetail {}\n\nexport interface IDeletePropertyResponse extends IMessageResponse {}\n\nexport const UpdatePropertyAccessInformationRequestSchema =\n createValidationSchema({\n entryInstructions: optionalNullableStringField(),\n accessCode: optionalNullableStringField(),\n wifiName: optionalNullableStringField(),\n wifiPassword: optionalNullableStringField(),\n alarmCode: optionalNullableStringField(),\n parkingInfo: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n });\n\nexport type IUpdatePropertyAccessInformationRequest =\n TInferValidationSchemaInput<\n typeof UpdatePropertyAccessInformationRequestSchema\n >;\n\nexport interface IUpdatePropertyAccessInformationResponse extends IPropertyAccessInformation {}\n\nexport interface IGetPropertyAccessInformationRequest extends IPropertyIdParams {}\n\nexport type IGetPropertyAccessInformationResponse =\n IPropertyAccessInformation | null;\n\nexport interface IGetPropertyByIdResponse extends IGetPropertyResponse {}\n\nexport interface IGetPropertiesByCompanyIdRequest extends ICompanyIdParams {}\nexport type IGetPropertiesByCompanyIdResponse = IProperty[];\n","import type { TRecordValue } from \"../base\";\n\nexport const ROOM_TYPE = {\n BEDROOM: \"BEDROOM\",\n BATHROOM: \"BATHROOM\",\n KITCHEN: \"KITCHEN\",\n LIVING_ROOM: \"LIVING_ROOM\",\n DINING_ROOM: \"DINING_ROOM\",\n OFFICE: \"OFFICE\",\n GARAGE: \"GARAGE\",\n LAUNDRY_ROOM: \"LAUNDRY_ROOM\",\n BASEMENT: \"BASEMENT\",\n ATTIC: \"ATTIC\",\n BALCONY: \"BALCONY\",\n PORCH: \"PORCH\",\n GARDEN: \"GARDEN\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TRoomType = TRecordValue<typeof ROOM_TYPE>;\n","import type { IRoom } from \".\";\nimport { ROOM_TYPE } from \"./constants\";\nimport type { IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IRoomPropertyRouteParams {\n propertyId: string;\n}\n\nexport interface IRoomRouteParams {\n roomId: string;\n}\n\nconst RoomTypeValues = Object.values(ROOM_TYPE);\n\nexport const CreateRoomRequestSchema = createValidationSchema({\n propertyId: requiredStringField(),\n displayName: requiredStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type ICreateRoomRequest = TInferValidationSchemaInput<\n typeof CreateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface ICreateRoomResponse extends IRoom {}\n\nexport interface IGetRoomsRequest {\n propertyId?: string;\n}\n\nexport interface IGetRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetDetailedRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetDetailedRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetRoomByIdRequest extends IRoomRouteParams {}\nexport interface IGetRoomByIdResponse extends IRoom {}\n\nexport const UpdateRoomRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type IUpdateRoomRequest = TInferValidationSchemaInput<\n typeof UpdateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface IUpdateRoomResponse extends IRoom {}\n\nexport interface IDeleteRoomRequest extends IRoomRouteParams {}\nexport interface IDeleteRoomResponse extends IMessageResponse {}\n","import type {\n ICompanyBillingSummary,\n IEntitlementSnapshot,\n IProviderProduct,\n ISubscriptionProductSummary,\n TSubscriptionProvider,\n} from \".\";\nimport type { IMessageResponse, TJsonObject } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableStringField,\n optionalRecordField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IBillingCompanyRouteParams {\n companyId: string;\n}\n\nexport interface IGetBillingProductsRequest {}\nexport type IGetBillingProductsResponse = ISubscriptionProductSummary[];\n\nexport interface IGetCompanyBillingSummaryRequest\n extends IBillingCompanyRouteParams {}\nexport interface IGetCompanyBillingSummaryResponse\n extends ICompanyBillingSummary {}\n\nexport const CreateStripeCheckoutSessionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n successUrl: requiredStringField(\"BlankString\"),\n cancelUrl: requiredStringField(\"BlankString\"),\n});\n\nexport type ICreateStripeCheckoutSessionRequest =\n TInferValidationSchemaInput<\n typeof CreateStripeCheckoutSessionRequestSchema\n >;\n\nexport interface ICreateStripeCheckoutSessionResponse {\n checkoutUrl: string;\n}\n\nexport const SyncAppleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n transactionId: requiredStringField(\"BlankString\"),\n originalTransactionId: optionalNullableStringField(),\n signedTransactionInfo: requiredStringField(\"BlankString\"),\n});\n\nexport type ISyncAppleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncAppleSubscriptionRequestSchema\n>;\n\nexport const SyncGoogleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n purchaseToken: requiredStringField(\"BlankString\"),\n packageName: requiredStringField(\"BlankString\"),\n providerPriceId: optionalNullableStringField(),\n});\n\nexport type ISyncGoogleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncGoogleSubscriptionRequestSchema\n>;\n\nexport interface ISyncStoreSubscriptionResponse {\n subscription: ICompanyBillingSummary[\"subscription\"];\n entitlement: IEntitlementSnapshot;\n}\n\nexport const BillingProviderWebhookRequestSchema = createValidationSchema({\n providerEventId: requiredStringField(\"BlankString\"),\n eventType: requiredStringField(\"BlankString\"),\n providerSubscriptionId: optionalNullableStringField(),\n providerTransactionId: optionalNullableStringField(),\n providerRefundId: optionalNullableStringField(),\n payload: optionalRecordField(),\n});\n\nexport type IBillingProviderWebhookRequest = TInferValidationSchemaInput<\n typeof BillingProviderWebhookRequestSchema\n> & {\n payload?: TJsonObject;\n};\n\nexport interface IBillingProviderWebhookResponse extends IMessageResponse {}\n\nexport interface IProviderProductLookupRequest {\n provider: TSubscriptionProvider;\n providerProductId: string;\n}\n\nexport interface IProviderProductLookupResponse extends IProviderProduct {}\n\nexport const BillingProviderValues = [\n \"STRIPE\",\n \"APPLE\",\n \"GOOGLE\",\n \"MANUAL\",\n] as const;\n\nexport const ProviderProductLookupRequestSchema = createValidationSchema({\n provider: requiredEnumField(BillingProviderValues, \"BlankString\"),\n providerProductId: requiredStringField(\"BlankString\"),\n});\n","import type {\n IMetaData,\n TDateTimeString,\n TJsonObject,\n TRecordValue,\n} from \"../base\";\n\nexport const SUBSCRIPTION_PLAN = {\n Free: \"FREE\",\n Starter: \"STARTER\",\n Pro: \"PRO\",\n Business: \"BUSINESS\",\n} as const;\n\nexport type TSubscriptionPlan = TRecordValue<typeof SUBSCRIPTION_PLAN>;\n\nexport const SUBSCRIPTION_STATUS = {\n ACTIVE: \"ACTIVE\",\n CANCELED: \"CANCELED\",\n EXPIRED: \"EXPIRED\",\n PAST_DUE: \"PAST_DUE\",\n TRIALING: \"TRIALING\",\n GRACE_PERIOD: \"GRACE_PERIOD\",\n REFUNDED: \"REFUNDED\",\n} as const;\n\nexport type TSubscriptionStatus = TRecordValue<typeof SUBSCRIPTION_STATUS>;\n\nexport const SUBSCRIPTION_PROVIDER = {\n STRIPE: \"STRIPE\",\n APPLE: \"APPLE\",\n GOOGLE: \"GOOGLE\",\n MANUAL: \"MANUAL\",\n} as const;\n\nexport type TSubscriptionProvider = TRecordValue<typeof SUBSCRIPTION_PROVIDER>;\n\nexport const BILLING_PERIOD = {\n MONTHLY: \"MONTHLY\",\n YEARLY: \"YEARLY\",\n} as const;\n\nexport type TBillingPeriod = TRecordValue<typeof BILLING_PERIOD>;\n\nexport const REFUND_STATUS = {\n REQUESTED: \"REQUESTED\",\n APPROVED: \"APPROVED\",\n DECLINED: \"DECLINED\",\n PROCESSED: \"PROCESSED\",\n} as const;\n\nexport type TRefundStatus = TRecordValue<typeof REFUND_STATUS>;\n\nexport const SUBSCRIPTION_FEATURE = {\n CreateProperty: \"CREATE_PROPERTY\",\n InviteTeamMember: \"INVITE_TEAM_MEMBER\",\n CreateChecklistTemplate: \"CREATE_CHECKLIST_TEMPLATE\",\n UploadImage: \"UPLOAD_IMAGE\",\n} as const;\n\nexport type TSubscriptionFeature = TRecordValue<typeof SUBSCRIPTION_FEATURE>;\n\nexport interface ISubscriptionPlan extends IMetaData {\n id: string;\n code: TSubscriptionPlan;\n displayName: string;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n isActive: boolean;\n}\n\nexport interface IProviderProduct extends IMetaData {\n id: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerProductId: string;\n providerPriceId: string | null;\n billingPeriod: TBillingPeriod;\n trialDays: number;\n isActive: boolean;\n}\n\nexport interface ISubscriptionProductSummary {\n plan: ISubscriptionPlan;\n products: IProviderProduct[];\n}\n\nexport interface IBillingAccount extends IMetaData {\n id: string;\n companyId: string;\n billingAdminUserId: string | null;\n}\n\nexport interface ICompanySubscription extends IMetaData {\n id: string;\n billingAccountId: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string | null;\n providerOriginalTransactionId: string | null;\n providerPurchaseToken: string | null;\n providerCustomerId: string | null;\n providerPriceId: string | null;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString | null;\n currentPeriodEnd: TDateTimeString | null;\n trialStart: TDateTimeString | null;\n trialEnd: TDateTimeString | null;\n cancelAtPeriodEnd: boolean;\n canceledAt: TDateTimeString | null;\n refundedAt: TDateTimeString | null;\n latestEventAt: TDateTimeString | null;\n}\n\nexport interface ISubscriptionEvent extends IMetaData {\n id: string;\n subscriptionId: string | null;\n provider: TSubscriptionProvider;\n providerEventId: string;\n eventType: string;\n rawPayload: TJsonObject;\n processedAt: TDateTimeString;\n}\n\nexport interface IEntitlementSnapshot {\n id: string;\n companyId: string;\n subscriptionId: string | null;\n planCode: TSubscriptionPlan;\n status: TSubscriptionStatus;\n effectiveFrom: TDateTimeString;\n effectiveUntil: TDateTimeString | null;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n sourceEventId: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IRefund extends IMetaData {\n id: string;\n subscriptionId: string;\n provider: TSubscriptionProvider;\n providerRefundId: string | null;\n providerTransactionId: string | null;\n amount: number | null;\n currency: string | null;\n reason: string | null;\n status: TRefundStatus;\n refundedAt: TDateTimeString | null;\n rawPayload: TJsonObject | null;\n}\n\nexport interface ICompanyBillingSummary {\n billingAccount: IBillingAccount | null;\n subscription: ICompanySubscription | null;\n entitlement: IEntitlementSnapshot;\n}\n\n/**\n * @deprecated Use ICompanySubscription for company-scoped SaaS access.\n */\nexport interface IUserSubscription {\n id: string;\n userId: string;\n planId: string;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString;\n currentPeriodEnd: TDateTimeString;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string;\n cancelAtPeriodEnd: boolean;\n}\n\nexport * from \"./routes\";\n","import type { IUser, TAccountType } from \".\";\nimport { LANGUAGE } from \"./constants\";\nimport type { IEmptyRouteRequest, IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IUserIdParams {\n id: string;\n}\n\nexport interface IGetUserResponse {\n user: IUser | null;\n}\n\nexport type IGetCurrentUserRequest = IEmptyRouteRequest;\nexport interface IGetCurrentUserResponse extends IGetUserResponse {}\n\nexport interface IGetUserByIdRequest extends IUserIdParams {}\nexport interface IGetUserByIdResponse extends IGetUserResponse {}\n\nexport interface IGetUserByEmailRequest {\n email: string;\n}\nexport interface IGetUserByEmailResponse extends IGetUserResponse {}\n\nexport type IGetStaffRequest = IEmptyRouteRequest;\nexport interface IGetStaffResponse {\n staff: IUser[];\n}\n\nconst LanguageValues = Object.values(LANGUAGE);\n\nexport const UpdateUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalNullableStringField(),\n mi: optionalNullableStringField(),\n username: optionalNullableStringField(),\n email: optionalStringField(),\n phoneNumber: optionalNullableStringField(),\n phoneFormat: optionalNullableStringField(),\n preferredLanguage: optionalEnumField(LanguageValues),\n});\n\nexport type IUpdateUserRequest = TInferValidationSchemaInput<\n typeof UpdateUserRequestSchema\n> & {\n preferredLanguage?: IUser[\"preferredLanguage\"];\n};\n\nexport const UpdateCurrentUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalStringField(),\n});\n\nexport type IUpdateCurrentUserRequest = TInferValidationSchemaInput<\n typeof UpdateCurrentUserRequestSchema\n>;\n\nexport interface IUpdateUserResponse {\n user: IUser;\n}\n\nexport type IDeleteUserRequest = IEmptyRouteRequest;\nexport interface IDeleteUserResponse extends IMessageResponse {}\n\nexport interface IGetUsersByAccountTypeRequest {\n accountType: TAccountType;\n}\nexport interface IGetUsersByAccountTypeResponse {\n users: IUser[];\n}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\n/**\n * Work session status enum.\n */\nexport const WORK_SESSION_STATUS = {\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkSessionStatus = TRecordValue<typeof WORK_SESSION_STATUS>;\n\n/**\n * Checklist execution status enum.\n */\nexport const CHECKLIST_EXECUTION_STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n SKIPPED: \"SKIPPED\",\n} as const;\n\nexport type TChecklistExecutionStatus = TRecordValue<\n typeof CHECKLIST_EXECUTION_STATUS\n>;\n\n/**\n * Work session.\n */\nexport interface IWorkSession {\n id: string;\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n status: TWorkSessionStatus;\n scheduledDate: TDateTimeString | null;\n startedAt: TDateTimeString;\n completedAt: TDateTimeString | null;\n totalTimeMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist execution.\n */\nexport interface IChecklistExecution {\n id: string;\n workSessionId: string;\n roomChecklistId: string;\n roomId: string;\n workerId: string;\n status: TChecklistExecutionStatus;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n timeSpentMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist item completion.\n */\nexport interface IChecklistItemCompletion {\n id: string;\n checklistExecutionId: string;\n roomChecklistItemId: string;\n completedBy: string;\n completedAt: TDateTimeString;\n photoId: string | null;\n notes: string | null;\n skipped: boolean;\n skipReason: string | null;\n createdAt: TDateTimeString;\n}\n\n/**\n * Work session with executions.\n */\nexport interface IWorkSessionWithExecutions extends IWorkSession {\n executions: IChecklistExecution[];\n}\n\n/**\n * Input for creating a work session.\n */\nexport interface ICreateWorkSessionInput {\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n scheduledDate?: TDateTimeString;\n notes?: string;\n}\n\n/**\n * Input for completing a checklist item.\n */\nexport interface ICompleteChecklistItemInput {\n roomChecklistItemId: string;\n completedBy: string;\n photoId?: string;\n notes?: string;\n skipped?: boolean;\n skipReason?: string;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAA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AAA,EAClC,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,yBAAyB;AAAA,EACzB,aAAa;AACf;;;ACvBA,IAAM,iBAAiB,OAAO,OAAO,QAAQ;AAEtC,IAAM,0BAA0B,uBAAuB;AAAA,EAC5D,WAAW,oBAAoB;AAAA,EAC/B,UAAU,4BAA4B;AAAA,EACtC,IAAI,4BAA4B;AAAA,EAChC,UAAU,4BAA4B;AAAA,EACtC,OAAO,oBAAoB;AAAA,EAC3B,aAAa,4BAA4B;AAAA,EACzC,aAAa,4BAA4B;AAAA,EACzC,mBAAmB,kBAAkB,cAAc;AACrD,CAAC;AAQM,IAAM,iCAAiC,uBAAuB;AAAA,EACnE,WAAW,oBAAoB;AAAA,EAC/B,UAAU,oBAAoB;AAChC,CAAC;;;ACnDM,IAAM,sBAAsB;AAAA,EACjC,aAAa;AAAA,EACb,WAAW;AAAA,EACX,WAAW;AACb;AAOO,IAAM,6BAA6B;AAAA,EACxC,SAAS;AAAA,EACT,aAAa;AAAA,EACb,WAAW;AAAA,EACX,SAAS;AACX;","names":["StateCodeValues"]}
|
package/dist/types/index.d.cts
CHANGED
|
@@ -170,6 +170,7 @@ interface IUser extends IMetaData {
|
|
|
170
170
|
phoneNumber: string | null;
|
|
171
171
|
phoneFormat: string | null;
|
|
172
172
|
preferredLanguage: TLanguage | null;
|
|
173
|
+
passwordResetRequired: boolean;
|
|
173
174
|
}
|
|
174
175
|
interface IDeviceInfo {
|
|
175
176
|
userAgent?: string;
|
|
@@ -357,6 +358,15 @@ interface IRefreshTokenData {
|
|
|
357
358
|
token: string;
|
|
358
359
|
expiresAt: TDateTimeString;
|
|
359
360
|
}
|
|
361
|
+
interface IRefreshTokenPersistenceData extends IRefreshTokenData {
|
|
362
|
+
tokenHash: string;
|
|
363
|
+
tokenFamily: string;
|
|
364
|
+
}
|
|
365
|
+
interface ITokenPayload {
|
|
366
|
+
userId: string;
|
|
367
|
+
email: string;
|
|
368
|
+
name: string;
|
|
369
|
+
}
|
|
360
370
|
interface IStoredAuthSession {
|
|
361
371
|
accessToken: string | null;
|
|
362
372
|
refreshToken: string | null;
|
|
@@ -2168,4 +2178,4 @@ interface ICompleteChecklistItemInput {
|
|
|
2168
2178
|
skipReason?: string;
|
|
2169
2179
|
}
|
|
2170
2180
|
|
|
2171
|
-
export { ACCOUNT_STATUS, ACCOUNT_TYPE, AUTH_STATUS, AcceptInvitationRequestSchema, BILLING_PERIOD, BillingProviderValues, BillingProviderWebhookRequestSchema, CHECKLIST_EXECUTION_STATUS, COMPANY_RELATIONSHIP_STATUS, COMPANY_TYPES, ChangePasswordRequestSchema, CompanyFilter, CreateCompanyRequestSchema, CreatePropertyRequestSchema, CreateRoomRequestSchema, CreateStripeCheckoutSessionRequestSchema, DAMAGE_SEVERITY, DAMAGE_STATUS, DATABASE_STATUS, ERROR_CODES, ForgotPasswordRequestSchema, HTTP_METHOD, HTTP_STATUS, type IAcceptCompanyInvitationRequest, type IAcceptCompanyInvitationResponse, type IAcceptInvitationRequest, type IAcceptInvitationResponse, type IAcceptInvitationRouteResponse, type IAddChecklistItemRequest, type IAddChecklistItemResponse, type IAddDamageReportCommentRequest, type IAddDamageReportCommentResponse, type IAddDamageReportPhotoRequest, type IAddDamageReportPhotoResponse, type IAddInventoryToPropertyRequest, type IAddInventoryToPropertyResponse, type IAddInventoryToRoomRequest, type IAddInventoryToRoomResponse, type IAddTemplateItemRequest, type IAddTemplateItemResponse, type IApiError, type IApiErrorResponse, type IApiMeta, type IApiResponse, type IApiSuccessResponse, type IAssignDamageReportRequest, type IAssignDamageReportResponse, type IAssignWorkOrderRequest, type IAssignWorkOrderResponse, type IAuthInvitationBaseResponse, type IAuthInvitationIdParams, type IAuthInvitationTokenParams, type IAuthMessageResponse, type IAuthRefreshTokenResponse, type IAuthSession, type IAuthSessionIdParams, type IAuthTokenBundle, type IAuthTokenResponse, type IBillingAccount, type IBillingCompanyRouteParams, type IBillingProviderWebhookRequest, type IBillingProviderWebhookResponse, type ICancelWorkSessionRequest, type ICancelWorkSessionResponse, type IChangePasswordRequest, type IChangePasswordResponse, type IChecklistAndItemIdParams, type IChecklistExecution, type IChecklistIdParams, type IChecklistItemCompletion, type IChecklistItemOrder, type IChecklistTemplate, type IChecklistTemplateCompanyRouteParams, type IChecklistTemplateItem, type IChecklistTemplateWithItems, type ICloneChecklistRequest, type ICloneChecklistResponse, type ICompany, type ICompanyBillingSummary, type ICompanyIdParams, type ICompanyInvitationIdParams, type ICompanyInvitationSummary, type ICompanyInvitationTokenParams, type ICompanyRouteParams, type ICompanySubscription, type ICompanyUserRouteParams, type ICompanyUserSummary, type ICompanyWithRelationshipStatus, type ICompanyWithUsers, type ICompleteChecklistExecutionRequest, type ICompleteChecklistExecutionResponse, type ICompleteChecklistItemInput, type ICompleteExecutionItemRequest, type ICompleteExecutionItemResponse, type ICompleteWorkOrderRequest, type ICompleteWorkOrderResponse, type ICompleteWorkSessionRequest, type ICompleteWorkSessionResponse, ICountResponse, type ICreateChecklistRequest, type ICreateChecklistResponse, type ICreateCompanyRequest, type ICreateCompanyResponse, type ICreateCustomChecklistRequest, type ICreateCustomChecklistResponse, type ICreateDamageReportInput, type ICreateDamageReportRequest, type ICreateDamageReportResponse, type ICreateInventoryItemRequest, type ICreateInventoryItemResponse, type ICreatePropertyRequest, type ICreatePropertyResponse, type ICreateRestockOrderRequest, type ICreateRestockOrderResponse, type ICreateRoomChecklistInput, type ICreateRoomChecklistItemInput, type ICreateRoomRequest, type ICreateRoomResponse, type ICreateStripeCheckoutSessionRequest, type ICreateStripeCheckoutSessionResponse, type ICreateTemplateInput, type ICreateTemplateItemInput, type ICreateTemplateRequest, type ICreateTemplateResponse, type ICreateTemplateWithItemsRequest, type ICreateTemplateWithItemsResponse, type ICreateWorkOrderInput, type ICreateWorkOrderRequest, type ICreateWorkOrderResponse, type ICreateWorkSessionInput, type ICreateWorkSessionRequest, type ICreateWorkSessionResponse, type IDamageComment, type IDamagePhoto, type IDamageReport, type IDamageReportPhoto, type IDamageReportPropertyRouteParams, type IDamageReportRoomRouteParams, type IDamageReportRouteParams, type IDamageReportStatusHistory, type IDamageReportWorkOrderRouteParams, type IDeclineCompanyInvitationRequest, type IDeclineCompanyInvitationResponse, type IDeleteChecklistItemRequest, type IDeleteChecklistItemResponse, type IDeleteChecklistRequest, type IDeleteChecklistResponse, type IDeleteImageRequest, type IDeleteImageResponse, type IDeleteInventoryItemRequest, type IDeleteInventoryItemResponse, type IDeletePropertyRequest, type IDeletePropertyResponse, type IDeleteRoomRequest, type IDeleteRoomResponse, type IDeleteTemplateItemRequest, type IDeleteTemplateItemResponse, type IDeleteTemplateRequest, type IDeleteTemplateResponse, type IDeleteUserRequest, type IDeleteUserResponse, type IDeviceInfo, type IDuplicateTemplateItemRequest, type IDuplicateTemplateItemResponse, type IEmailValidationResult, IEmptyRouteRequest, type IEntitlementSnapshot, type IForgotPasswordRequest, type IForgotPasswordResponse, type IGetActiveWorkSessionRequest, type IGetActiveWorkSessionResponse, type IGetBillingProductsRequest, type IGetBillingProductsResponse, type IGetChecklistByIdRequest, type IGetChecklistByIdResponse, type IGetChecklistByRoomIdRequest, type IGetChecklistByRoomIdResponse, type IGetChecklistExecutionByIdRequest, type IGetChecklistExecutionByIdResponse, type IGetChecklistExecutionsRequest, type IGetChecklistExecutionsResponse, type IGetChecklistItemsRequest, type IGetChecklistItemsResponse, type IGetChecklistWithItemsRequest, type IGetChecklistWithItemsResponse, type IGetCompaniesQuery, type IGetCompaniesRequest, type IGetCompaniesResponse, type IGetCompanyBillingSummaryRequest, type IGetCompanyBillingSummaryResponse, type IGetCompanyByIdRequest, type IGetCompanyByIdResponse, type IGetCompanyUsersRequest, type IGetCompanyUsersResponse, type IGetCurrentUserRequest, type IGetCurrentUserResponse, type IGetCustomChecklistItemsRequest, type IGetCustomChecklistItemsResponse, type IGetDamageReportByIdRequest, type IGetDamageReportByIdResponse, type IGetDamageReportCommentsRequest, type IGetDamageReportCommentsResponse, type IGetDamageReportHistoryRequest, type IGetDamageReportHistoryResponse, type IGetDamageReportPhotosRequest, type IGetDamageReportPhotosResponse, type IGetDamageReportsByPropertyIdRequest, type IGetDamageReportsByPropertyIdResponse, type IGetDamageReportsByRoomIdRequest, type IGetDamageReportsByRoomIdResponse, type IGetDetailedHealthRequest, type IGetDetailedHealthResponse, type IGetDetailedRoomsByPropertyIdRequest, type IGetDetailedRoomsByPropertyIdResponse, type IGetExecutionItemsRequest, type IGetExecutionItemsResponse, type IGetExecutionProgressRequest, type IGetExecutionProgressResponse, type IGetHealthRequest, type IGetHealthResponse, type IGetImagesForEntityResponse, type IGetInventoryByCompanyIdRequest, type IGetInventoryByCompanyIdResponse, type IGetInventoryCountsByExecutionIdRequest, type IGetInventoryCountsByExecutionIdResponse, type IGetInventoryItemByIdRequest, type IGetInventoryItemByIdResponse, type IGetLoginHistoryListResponse, type IGetLoginHistoryRequest, type IGetLoginHistoryResponse, type IGetMeRequest, type IGetMeResponse, type IGetPendingCompanyInvitationsRequest, type IGetPendingCompanyInvitationsResponse, type IGetPendingInvitationsListResponse, type IGetPendingInvitationsRequest, type IGetPendingInvitationsResponse, type IGetPropertiesByCompanyIdRequest, type IGetPropertiesByCompanyIdResponse, type IGetPropertiesRequest, type IGetPropertiesResponse, type IGetPropertyAccessInformationRequest, type IGetPropertyAccessInformationResponse, type IGetPropertyByIdRequest, type IGetPropertyByIdResponse, type IGetPropertyInventoryNeedingRestockRequest, type IGetPropertyInventoryNeedingRestockResponse, type IGetPropertyInventoryRequest, type IGetPropertyInventoryResponse, type IGetPropertyResponse, type IGetRestockOrderItemsRequest, type IGetRestockOrderItemsResponse, type IGetRestockOrdersByCompanyIdRequest, type IGetRestockOrdersByCompanyIdResponse, type IGetRoomByIdRequest, type IGetRoomByIdResponse, type IGetRoomInventoryNeedingRestockRequest, type IGetRoomInventoryNeedingRestockResponse, type IGetRoomInventoryRequest, type IGetRoomInventoryResponse, type IGetRoomsByPropertyIdRequest, type IGetRoomsByPropertyIdResponse, type IGetRoomsRequest, type IGetSessionsRequest, type IGetSessionsResponse, type IGetStaffRequest, type IGetStaffResponse, type IGetTemplateByIdRequest, type IGetTemplateByIdResponse, type IGetTemplateItemsRequest, type IGetTemplateItemsResponse, type IGetTemplateUsageRequest, type IGetTemplateUsageResponse, type IGetTemplateWithItemsRequest, type IGetTemplateWithItemsResponse, type IGetTemplatesByCompanyIdRequest, type IGetTemplatesByCompanyIdResponse, type IGetUserByEmailRequest, type IGetUserByEmailResponse, type IGetUserByIdRequest, type IGetUserByIdResponse, type IGetUserCompaniesRequest, type IGetUserCompaniesResponse, type IGetUserResponse, type IGetUsersByAccountTypeRequest, type IGetUsersByAccountTypeResponse, type IGetWorkOrderByIdRequest, type IGetWorkOrderByIdResponse, type IGetWorkOrdersByPropertyIdRequest, type IGetWorkOrdersByPropertyIdResponse, type IGetWorkSessionByIdRequest, type IGetWorkSessionByIdResponse, type IGetWorkSessionWithExecutionsRequest, type IGetWorkSessionWithExecutionsResponse, type IGetWorkSessionsByPropertyIdRequest, type IGetWorkSessionsByPropertyIdResponse, type IGetWorkSessionsByUserIdRequest, type IGetWorkSessionsByUserIdResponse, type IHealthCheckResponse, type IHealthChecks, type IImage, type IImageCompanyRouteParams, type IImagePropertyRouteParams, type IImageRoomRouteParams, type IImageRouteParams, type IImageUserRouteParams, type IImageWithUrl, type IIncludeInactiveQuery, type IIncludeResolvedQuery, type IInventoryCompanyRouteParams, type IInventoryCount, type IInventoryExecutionRouteParams, type IInventoryItem, type IInventoryItemRouteParams, type IInventoryOrderRouteParams, type IInventoryPropertyRouteParams, type IInventoryRestockOrder, type IInventoryRestockOrderItem, type IInventoryRoomRouteParams, type IInviteCompanyToCompanyRequest, type IInviteCompanyToCompanyResponse, type IInviteUserToCompanyRequest, type IInviteUserToCompanyResponse, type IJobFilterValues, type ILimitQuery, type ILoginCredentials, type ILoginRequest, type ILoginResponse, type ILogoutAllRequest, type ILogoutAllResponse, type ILogoutRequest, type ILogoutResponse, IMAGE_ENTITY_TYPE, IMessageResponse, IMetaData, type IMissingFieldsErrorDetail, INVENTORY_ITEM_TYPE, INVENTORY_RESTOCK_ORDER_STATUS, INVENTORY_UNITS, INVITATION_STATUS, type IPasswordValidationResult, type IPasswordValidationRules, type IProperty, type IPropertyAccessInformation, type IPropertyDetail, type IPropertyIdParams, type IPropertyInventory, type IPropertySummary, type IProviderProduct, type IProviderProductLookupRequest, type IProviderProductLookupResponse, type IRateLimitErrorDetail, type IRateLimitStatus, type IRecordInventoryCountRequest, type IRecordInventoryCountResponse, type IRefreshSessionRequest, type IRefreshSessionResponse, type IRefreshTokenData, type IRefund, type IRegisterCredentials, type IRegisterRequest, type IRegisterResponse, type IRegisterWithInvitationRequest, type IRegisterWithInvitationResponse, type IReorderChecklistItemsRequest, type IReorderChecklistItemsResponse, type IReorderTemplateItemsRequest, type IReorderTemplateItemsResponse, type IResolveDamageReportRequest, type IResolveDamageReportResponse, type IRestockOrderItemInput, type IRevokeCompanyInvitationRequest, type IRevokeCompanyInvitationResponse, type IRevokeInvitationRequest, type IRevokeInvitationResponse, type IRevokeSessionRequest, type IRevokeSessionResponse, type IRoom, type IRoomChecklist, type IRoomChecklistItem, type IRoomChecklistRoomRouteParams, type IRoomChecklistWithItems, type IRoomInventory, type IRoomInventoryIdParams, type IRoomPropertyRouteParams, type IRoomRouteParams, IRuntimeValidationSchema, ISelectOption, type ISetAuthSessionParams, type ISkipChecklistExecutionRequest, type ISkipChecklistExecutionResponse, type IStartChecklistExecutionRequest, type IStartChecklistExecutionResponse, type IStoredAuthSession, type ISubscriptionEvent, type ISubscriptionPlan, type ISubscriptionProductSummary, ISuccessResponse, type ISyncAppleSubscriptionRequest, type ISyncGoogleSubscriptionRequest, type ISyncStoreSubscriptionResponse, type ITemplateAndItemIdParams, type ITemplateIdParams, type ITemplateItemIdParams, type ITemplateItemOrder, type IToggleTemplateActiveRequest, type IToggleTemplateActiveResponse, type ITypedApiError, type IUpdateChecklistItemRequest, type IUpdateChecklistItemResponse, type IUpdateChecklistRequest, type IUpdateChecklistResponse, type IUpdateCompanyRequest, type IUpdateCompanyResponse, type IUpdateCurrentUserRequest, type IUpdateDamageReportRequest, type IUpdateDamageReportResponse, type IUpdateDamageReportStatusRequest, type IUpdateDamageReportStatusResponse, type IUpdateInventoryItemRequest, type IUpdateInventoryItemResponse, type IUpdatePropertyAccessInformationRequest, type IUpdatePropertyAccessInformationResponse, type IUpdatePropertyRequest, type IUpdatePropertyResponse, type IUpdateRestockOrderStatusRequest, type IUpdateRestockOrderStatusResponse, type IUpdateRoomInventoryRequest, type IUpdateRoomInventoryResponse, type IUpdateRoomRequest, type IUpdateRoomResponse, type IUpdateTemplateItemRequest, type IUpdateTemplateItemResponse, type IUpdateTemplateRequest, type IUpdateTemplateResponse, type IUpdateUserRequest, type IUpdateUserResponse, type IUpdateWorkOrderRequest, type IUpdateWorkOrderResponse, type IUpdateWorkOrderStatusRequest, type IUpdateWorkOrderStatusResponse, type IUpdateWorkSessionRequest, type IUpdateWorkSessionResponse, type IUploadImagesResponse, type IUploadProfileImageRequest, type IUploadProfileImageResponse, type IUser, type IUserIdParams, type IUserSession, type IUserSubscription, type IValidateCompanyInvitationRequest, type IValidateCompanyInvitationResponse, type IValidateInvitationRequest, type IValidateInvitationResponse, type IValidationErrorDetail, IValidationField, type IWorkOrder, type IWorkSession, type IWorkSessionExecutionRouteParams, type IWorkSessionPropertyRouteParams, type IWorkSessionRouteParams, type IWorkSessionUserRouteParams, type IWorkSessionWithExecutions, InviteCompanyToCompanyRequestSchema, InviteUserToCompanyRequestSchema, LANGUAGE, LoginRequestSchema, LogoutRequestSchema, PROPERTY_STATUS, PROPERTY_TYPES, PropertyStatusOptions, PropertyTypeOptions, ProviderProductLookupRequestSchema, REFUND_STATUS, ROOM_TYPE, RefreshSessionRequestSchema, RegisterRequestSchema, RegisterWithInvitationRequestSchema, SERVER_STATUS, SUBSCRIPTION_FEATURE, SUBSCRIPTION_PLAN, SUBSCRIPTION_PROVIDER, SUBSCRIPTION_STATUS, SyncAppleSubscriptionRequestSchema, SyncGoogleSubscriptionRequestSchema, type TAccountStatus, type TAccountType, type TApiErrorDetails, type TAuthStatus, type TBillingPeriod, type TChecklistExecutionStatus, type TCompanyFilter, type TCompanyRelationshipStatus, type TCompanyType, type TDamageSeverity, type TDamageStatus, type TDatabaseStatus, TDateTimeString, TEnvironment, type TErrorCode, type TErrorResponseDetail, type THttpMethod, type THttpStatusCode, TInferValidationSchemaInput, type TInventoryItemType, type TInventoryRestockOrderStatus, type TInventoryUnitType, type TInvitationStatus, TJsonObject, TJsonValue, type TLanguage, type TMissingFieldsError, type TPropertyStatus, type TPropertyType, type TRateLimitError, TRecordValue, type TRefundStatus, type TRoomType, type TServerStatus, TServiceType, TStatus, type TStoredImageEntityType, type TSubscriptionFeature, type TSubscriptionPlan, type TSubscriptionProvider, type TSubscriptionStatus, TUSStateCode, type TValidationError, type TWorkOrderPriority, type TWorkOrderStatus, type TWorkSessionStatus, UpdateCompanyRequestSchema, UpdateCurrentUserRequestSchema, UpdatePropertyAccessInformationRequestSchema, UpdatePropertyRequestSchema, UpdateRoomRequestSchema, UpdateUserRequestSchema, WORK_ORDER_PRIORITY, WORK_ORDER_STATUS, WORK_SESSION_STATUS, isAuthError, isMissingFieldsError, isRateLimitError, isValidationError };
|
|
2181
|
+
export { ACCOUNT_STATUS, ACCOUNT_TYPE, AUTH_STATUS, AcceptInvitationRequestSchema, BILLING_PERIOD, BillingProviderValues, BillingProviderWebhookRequestSchema, CHECKLIST_EXECUTION_STATUS, COMPANY_RELATIONSHIP_STATUS, COMPANY_TYPES, ChangePasswordRequestSchema, CompanyFilter, CreateCompanyRequestSchema, CreatePropertyRequestSchema, CreateRoomRequestSchema, CreateStripeCheckoutSessionRequestSchema, DAMAGE_SEVERITY, DAMAGE_STATUS, DATABASE_STATUS, ERROR_CODES, ForgotPasswordRequestSchema, HTTP_METHOD, HTTP_STATUS, type IAcceptCompanyInvitationRequest, type IAcceptCompanyInvitationResponse, type IAcceptInvitationRequest, type IAcceptInvitationResponse, type IAcceptInvitationRouteResponse, type IAddChecklistItemRequest, type IAddChecklistItemResponse, type IAddDamageReportCommentRequest, type IAddDamageReportCommentResponse, type IAddDamageReportPhotoRequest, type IAddDamageReportPhotoResponse, type IAddInventoryToPropertyRequest, type IAddInventoryToPropertyResponse, type IAddInventoryToRoomRequest, type IAddInventoryToRoomResponse, type IAddTemplateItemRequest, type IAddTemplateItemResponse, type IApiError, type IApiErrorResponse, type IApiMeta, type IApiResponse, type IApiSuccessResponse, type IAssignDamageReportRequest, type IAssignDamageReportResponse, type IAssignWorkOrderRequest, type IAssignWorkOrderResponse, type IAuthInvitationBaseResponse, type IAuthInvitationIdParams, type IAuthInvitationTokenParams, type IAuthMessageResponse, type IAuthRefreshTokenResponse, type IAuthSession, type IAuthSessionIdParams, type IAuthTokenBundle, type IAuthTokenResponse, type IBillingAccount, type IBillingCompanyRouteParams, type IBillingProviderWebhookRequest, type IBillingProviderWebhookResponse, type ICancelWorkSessionRequest, type ICancelWorkSessionResponse, type IChangePasswordRequest, type IChangePasswordResponse, type IChecklistAndItemIdParams, type IChecklistExecution, type IChecklistIdParams, type IChecklistItemCompletion, type IChecklistItemOrder, type IChecklistTemplate, type IChecklistTemplateCompanyRouteParams, type IChecklistTemplateItem, type IChecklistTemplateWithItems, type ICloneChecklistRequest, type ICloneChecklistResponse, type ICompany, type ICompanyBillingSummary, type ICompanyIdParams, type ICompanyInvitationIdParams, type ICompanyInvitationSummary, type ICompanyInvitationTokenParams, type ICompanyRouteParams, type ICompanySubscription, type ICompanyUserRouteParams, type ICompanyUserSummary, type ICompanyWithRelationshipStatus, type ICompanyWithUsers, type ICompleteChecklistExecutionRequest, type ICompleteChecklistExecutionResponse, type ICompleteChecklistItemInput, type ICompleteExecutionItemRequest, type ICompleteExecutionItemResponse, type ICompleteWorkOrderRequest, type ICompleteWorkOrderResponse, type ICompleteWorkSessionRequest, type ICompleteWorkSessionResponse, ICountResponse, type ICreateChecklistRequest, type ICreateChecklistResponse, type ICreateCompanyRequest, type ICreateCompanyResponse, type ICreateCustomChecklistRequest, type ICreateCustomChecklistResponse, type ICreateDamageReportInput, type ICreateDamageReportRequest, type ICreateDamageReportResponse, type ICreateInventoryItemRequest, type ICreateInventoryItemResponse, type ICreatePropertyRequest, type ICreatePropertyResponse, type ICreateRestockOrderRequest, type ICreateRestockOrderResponse, type ICreateRoomChecklistInput, type ICreateRoomChecklistItemInput, type ICreateRoomRequest, type ICreateRoomResponse, type ICreateStripeCheckoutSessionRequest, type ICreateStripeCheckoutSessionResponse, type ICreateTemplateInput, type ICreateTemplateItemInput, type ICreateTemplateRequest, type ICreateTemplateResponse, type ICreateTemplateWithItemsRequest, type ICreateTemplateWithItemsResponse, type ICreateWorkOrderInput, type ICreateWorkOrderRequest, type ICreateWorkOrderResponse, type ICreateWorkSessionInput, type ICreateWorkSessionRequest, type ICreateWorkSessionResponse, type IDamageComment, type IDamagePhoto, type IDamageReport, type IDamageReportPhoto, type IDamageReportPropertyRouteParams, type IDamageReportRoomRouteParams, type IDamageReportRouteParams, type IDamageReportStatusHistory, type IDamageReportWorkOrderRouteParams, type IDeclineCompanyInvitationRequest, type IDeclineCompanyInvitationResponse, type IDeleteChecklistItemRequest, type IDeleteChecklistItemResponse, type IDeleteChecklistRequest, type IDeleteChecklistResponse, type IDeleteImageRequest, type IDeleteImageResponse, type IDeleteInventoryItemRequest, type IDeleteInventoryItemResponse, type IDeletePropertyRequest, type IDeletePropertyResponse, type IDeleteRoomRequest, type IDeleteRoomResponse, type IDeleteTemplateItemRequest, type IDeleteTemplateItemResponse, type IDeleteTemplateRequest, type IDeleteTemplateResponse, type IDeleteUserRequest, type IDeleteUserResponse, type IDeviceInfo, type IDuplicateTemplateItemRequest, type IDuplicateTemplateItemResponse, type IEmailValidationResult, IEmptyRouteRequest, type IEntitlementSnapshot, type IForgotPasswordRequest, type IForgotPasswordResponse, type IGetActiveWorkSessionRequest, type IGetActiveWorkSessionResponse, type IGetBillingProductsRequest, type IGetBillingProductsResponse, type IGetChecklistByIdRequest, type IGetChecklistByIdResponse, type IGetChecklistByRoomIdRequest, type IGetChecklistByRoomIdResponse, type IGetChecklistExecutionByIdRequest, type IGetChecklistExecutionByIdResponse, type IGetChecklistExecutionsRequest, type IGetChecklistExecutionsResponse, type IGetChecklistItemsRequest, type IGetChecklistItemsResponse, type IGetChecklistWithItemsRequest, type IGetChecklistWithItemsResponse, type IGetCompaniesQuery, type IGetCompaniesRequest, type IGetCompaniesResponse, type IGetCompanyBillingSummaryRequest, type IGetCompanyBillingSummaryResponse, type IGetCompanyByIdRequest, type IGetCompanyByIdResponse, type IGetCompanyUsersRequest, type IGetCompanyUsersResponse, type IGetCurrentUserRequest, type IGetCurrentUserResponse, type IGetCustomChecklistItemsRequest, type IGetCustomChecklistItemsResponse, type IGetDamageReportByIdRequest, type IGetDamageReportByIdResponse, type IGetDamageReportCommentsRequest, type IGetDamageReportCommentsResponse, type IGetDamageReportHistoryRequest, type IGetDamageReportHistoryResponse, type IGetDamageReportPhotosRequest, type IGetDamageReportPhotosResponse, type IGetDamageReportsByPropertyIdRequest, type IGetDamageReportsByPropertyIdResponse, type IGetDamageReportsByRoomIdRequest, type IGetDamageReportsByRoomIdResponse, type IGetDetailedHealthRequest, type IGetDetailedHealthResponse, type IGetDetailedRoomsByPropertyIdRequest, type IGetDetailedRoomsByPropertyIdResponse, type IGetExecutionItemsRequest, type IGetExecutionItemsResponse, type IGetExecutionProgressRequest, type IGetExecutionProgressResponse, type IGetHealthRequest, type IGetHealthResponse, type IGetImagesForEntityResponse, type IGetInventoryByCompanyIdRequest, type IGetInventoryByCompanyIdResponse, type IGetInventoryCountsByExecutionIdRequest, type IGetInventoryCountsByExecutionIdResponse, type IGetInventoryItemByIdRequest, type IGetInventoryItemByIdResponse, type IGetLoginHistoryListResponse, type IGetLoginHistoryRequest, type IGetLoginHistoryResponse, type IGetMeRequest, type IGetMeResponse, type IGetPendingCompanyInvitationsRequest, type IGetPendingCompanyInvitationsResponse, type IGetPendingInvitationsListResponse, type IGetPendingInvitationsRequest, type IGetPendingInvitationsResponse, type IGetPropertiesByCompanyIdRequest, type IGetPropertiesByCompanyIdResponse, type IGetPropertiesRequest, type IGetPropertiesResponse, type IGetPropertyAccessInformationRequest, type IGetPropertyAccessInformationResponse, type IGetPropertyByIdRequest, type IGetPropertyByIdResponse, type IGetPropertyInventoryNeedingRestockRequest, type IGetPropertyInventoryNeedingRestockResponse, type IGetPropertyInventoryRequest, type IGetPropertyInventoryResponse, type IGetPropertyResponse, type IGetRestockOrderItemsRequest, type IGetRestockOrderItemsResponse, type IGetRestockOrdersByCompanyIdRequest, type IGetRestockOrdersByCompanyIdResponse, type IGetRoomByIdRequest, type IGetRoomByIdResponse, type IGetRoomInventoryNeedingRestockRequest, type IGetRoomInventoryNeedingRestockResponse, type IGetRoomInventoryRequest, type IGetRoomInventoryResponse, type IGetRoomsByPropertyIdRequest, type IGetRoomsByPropertyIdResponse, type IGetRoomsRequest, type IGetSessionsRequest, type IGetSessionsResponse, type IGetStaffRequest, type IGetStaffResponse, type IGetTemplateByIdRequest, type IGetTemplateByIdResponse, type IGetTemplateItemsRequest, type IGetTemplateItemsResponse, type IGetTemplateUsageRequest, type IGetTemplateUsageResponse, type IGetTemplateWithItemsRequest, type IGetTemplateWithItemsResponse, type IGetTemplatesByCompanyIdRequest, type IGetTemplatesByCompanyIdResponse, type IGetUserByEmailRequest, type IGetUserByEmailResponse, type IGetUserByIdRequest, type IGetUserByIdResponse, type IGetUserCompaniesRequest, type IGetUserCompaniesResponse, type IGetUserResponse, type IGetUsersByAccountTypeRequest, type IGetUsersByAccountTypeResponse, type IGetWorkOrderByIdRequest, type IGetWorkOrderByIdResponse, type IGetWorkOrdersByPropertyIdRequest, type IGetWorkOrdersByPropertyIdResponse, type IGetWorkSessionByIdRequest, type IGetWorkSessionByIdResponse, type IGetWorkSessionWithExecutionsRequest, type IGetWorkSessionWithExecutionsResponse, type IGetWorkSessionsByPropertyIdRequest, type IGetWorkSessionsByPropertyIdResponse, type IGetWorkSessionsByUserIdRequest, type IGetWorkSessionsByUserIdResponse, type IHealthCheckResponse, type IHealthChecks, type IImage, type IImageCompanyRouteParams, type IImagePropertyRouteParams, type IImageRoomRouteParams, type IImageRouteParams, type IImageUserRouteParams, type IImageWithUrl, type IIncludeInactiveQuery, type IIncludeResolvedQuery, type IInventoryCompanyRouteParams, type IInventoryCount, type IInventoryExecutionRouteParams, type IInventoryItem, type IInventoryItemRouteParams, type IInventoryOrderRouteParams, type IInventoryPropertyRouteParams, type IInventoryRestockOrder, type IInventoryRestockOrderItem, type IInventoryRoomRouteParams, type IInviteCompanyToCompanyRequest, type IInviteCompanyToCompanyResponse, type IInviteUserToCompanyRequest, type IInviteUserToCompanyResponse, type IJobFilterValues, type ILimitQuery, type ILoginCredentials, type ILoginRequest, type ILoginResponse, type ILogoutAllRequest, type ILogoutAllResponse, type ILogoutRequest, type ILogoutResponse, IMAGE_ENTITY_TYPE, IMessageResponse, IMetaData, type IMissingFieldsErrorDetail, INVENTORY_ITEM_TYPE, INVENTORY_RESTOCK_ORDER_STATUS, INVENTORY_UNITS, INVITATION_STATUS, type IPasswordValidationResult, type IPasswordValidationRules, type IProperty, type IPropertyAccessInformation, type IPropertyDetail, type IPropertyIdParams, type IPropertyInventory, type IPropertySummary, type IProviderProduct, type IProviderProductLookupRequest, type IProviderProductLookupResponse, type IRateLimitErrorDetail, type IRateLimitStatus, type IRecordInventoryCountRequest, type IRecordInventoryCountResponse, type IRefreshSessionRequest, type IRefreshSessionResponse, type IRefreshTokenData, type IRefreshTokenPersistenceData, type IRefund, type IRegisterCredentials, type IRegisterRequest, type IRegisterResponse, type IRegisterWithInvitationRequest, type IRegisterWithInvitationResponse, type IReorderChecklistItemsRequest, type IReorderChecklistItemsResponse, type IReorderTemplateItemsRequest, type IReorderTemplateItemsResponse, type IResolveDamageReportRequest, type IResolveDamageReportResponse, type IRestockOrderItemInput, type IRevokeCompanyInvitationRequest, type IRevokeCompanyInvitationResponse, type IRevokeInvitationRequest, type IRevokeInvitationResponse, type IRevokeSessionRequest, type IRevokeSessionResponse, type IRoom, type IRoomChecklist, type IRoomChecklistItem, type IRoomChecklistRoomRouteParams, type IRoomChecklistWithItems, type IRoomInventory, type IRoomInventoryIdParams, type IRoomPropertyRouteParams, type IRoomRouteParams, IRuntimeValidationSchema, ISelectOption, type ISetAuthSessionParams, type ISkipChecklistExecutionRequest, type ISkipChecklistExecutionResponse, type IStartChecklistExecutionRequest, type IStartChecklistExecutionResponse, type IStoredAuthSession, type ISubscriptionEvent, type ISubscriptionPlan, type ISubscriptionProductSummary, ISuccessResponse, type ISyncAppleSubscriptionRequest, type ISyncGoogleSubscriptionRequest, type ISyncStoreSubscriptionResponse, type ITemplateAndItemIdParams, type ITemplateIdParams, type ITemplateItemIdParams, type ITemplateItemOrder, type IToggleTemplateActiveRequest, type IToggleTemplateActiveResponse, type ITokenPayload, type ITypedApiError, type IUpdateChecklistItemRequest, type IUpdateChecklistItemResponse, type IUpdateChecklistRequest, type IUpdateChecklistResponse, type IUpdateCompanyRequest, type IUpdateCompanyResponse, type IUpdateCurrentUserRequest, type IUpdateDamageReportRequest, type IUpdateDamageReportResponse, type IUpdateDamageReportStatusRequest, type IUpdateDamageReportStatusResponse, type IUpdateInventoryItemRequest, type IUpdateInventoryItemResponse, type IUpdatePropertyAccessInformationRequest, type IUpdatePropertyAccessInformationResponse, type IUpdatePropertyRequest, type IUpdatePropertyResponse, type IUpdateRestockOrderStatusRequest, type IUpdateRestockOrderStatusResponse, type IUpdateRoomInventoryRequest, type IUpdateRoomInventoryResponse, type IUpdateRoomRequest, type IUpdateRoomResponse, type IUpdateTemplateItemRequest, type IUpdateTemplateItemResponse, type IUpdateTemplateRequest, type IUpdateTemplateResponse, type IUpdateUserRequest, type IUpdateUserResponse, type IUpdateWorkOrderRequest, type IUpdateWorkOrderResponse, type IUpdateWorkOrderStatusRequest, type IUpdateWorkOrderStatusResponse, type IUpdateWorkSessionRequest, type IUpdateWorkSessionResponse, type IUploadImagesResponse, type IUploadProfileImageRequest, type IUploadProfileImageResponse, type IUser, type IUserIdParams, type IUserSession, type IUserSubscription, type IValidateCompanyInvitationRequest, type IValidateCompanyInvitationResponse, type IValidateInvitationRequest, type IValidateInvitationResponse, type IValidationErrorDetail, IValidationField, type IWorkOrder, type IWorkSession, type IWorkSessionExecutionRouteParams, type IWorkSessionPropertyRouteParams, type IWorkSessionRouteParams, type IWorkSessionUserRouteParams, type IWorkSessionWithExecutions, InviteCompanyToCompanyRequestSchema, InviteUserToCompanyRequestSchema, LANGUAGE, LoginRequestSchema, LogoutRequestSchema, PROPERTY_STATUS, PROPERTY_TYPES, PropertyStatusOptions, PropertyTypeOptions, ProviderProductLookupRequestSchema, REFUND_STATUS, ROOM_TYPE, RefreshSessionRequestSchema, RegisterRequestSchema, RegisterWithInvitationRequestSchema, SERVER_STATUS, SUBSCRIPTION_FEATURE, SUBSCRIPTION_PLAN, SUBSCRIPTION_PROVIDER, SUBSCRIPTION_STATUS, SyncAppleSubscriptionRequestSchema, SyncGoogleSubscriptionRequestSchema, type TAccountStatus, type TAccountType, type TApiErrorDetails, type TAuthStatus, type TBillingPeriod, type TChecklistExecutionStatus, type TCompanyFilter, type TCompanyRelationshipStatus, type TCompanyType, type TDamageSeverity, type TDamageStatus, type TDatabaseStatus, TDateTimeString, TEnvironment, type TErrorCode, type TErrorResponseDetail, type THttpMethod, type THttpStatusCode, TInferValidationSchemaInput, type TInventoryItemType, type TInventoryRestockOrderStatus, type TInventoryUnitType, type TInvitationStatus, TJsonObject, TJsonValue, type TLanguage, type TMissingFieldsError, type TPropertyStatus, type TPropertyType, type TRateLimitError, TRecordValue, type TRefundStatus, type TRoomType, type TServerStatus, TServiceType, TStatus, type TStoredImageEntityType, type TSubscriptionFeature, type TSubscriptionPlan, type TSubscriptionProvider, type TSubscriptionStatus, TUSStateCode, type TValidationError, type TWorkOrderPriority, type TWorkOrderStatus, type TWorkSessionStatus, UpdateCompanyRequestSchema, UpdateCurrentUserRequestSchema, UpdatePropertyAccessInformationRequestSchema, UpdatePropertyRequestSchema, UpdateRoomRequestSchema, UpdateUserRequestSchema, WORK_ORDER_PRIORITY, WORK_ORDER_STATUS, WORK_SESSION_STATUS, isAuthError, isMissingFieldsError, isRateLimitError, isValidationError };
|
package/dist/types/index.d.ts
CHANGED
|
@@ -170,6 +170,7 @@ interface IUser extends IMetaData {
|
|
|
170
170
|
phoneNumber: string | null;
|
|
171
171
|
phoneFormat: string | null;
|
|
172
172
|
preferredLanguage: TLanguage | null;
|
|
173
|
+
passwordResetRequired: boolean;
|
|
173
174
|
}
|
|
174
175
|
interface IDeviceInfo {
|
|
175
176
|
userAgent?: string;
|
|
@@ -357,6 +358,15 @@ interface IRefreshTokenData {
|
|
|
357
358
|
token: string;
|
|
358
359
|
expiresAt: TDateTimeString;
|
|
359
360
|
}
|
|
361
|
+
interface IRefreshTokenPersistenceData extends IRefreshTokenData {
|
|
362
|
+
tokenHash: string;
|
|
363
|
+
tokenFamily: string;
|
|
364
|
+
}
|
|
365
|
+
interface ITokenPayload {
|
|
366
|
+
userId: string;
|
|
367
|
+
email: string;
|
|
368
|
+
name: string;
|
|
369
|
+
}
|
|
360
370
|
interface IStoredAuthSession {
|
|
361
371
|
accessToken: string | null;
|
|
362
372
|
refreshToken: string | null;
|
|
@@ -2168,4 +2178,4 @@ interface ICompleteChecklistItemInput {
|
|
|
2168
2178
|
skipReason?: string;
|
|
2169
2179
|
}
|
|
2170
2180
|
|
|
2171
|
-
export { ACCOUNT_STATUS, ACCOUNT_TYPE, AUTH_STATUS, AcceptInvitationRequestSchema, BILLING_PERIOD, BillingProviderValues, BillingProviderWebhookRequestSchema, CHECKLIST_EXECUTION_STATUS, COMPANY_RELATIONSHIP_STATUS, COMPANY_TYPES, ChangePasswordRequestSchema, CompanyFilter, CreateCompanyRequestSchema, CreatePropertyRequestSchema, CreateRoomRequestSchema, CreateStripeCheckoutSessionRequestSchema, DAMAGE_SEVERITY, DAMAGE_STATUS, DATABASE_STATUS, ERROR_CODES, ForgotPasswordRequestSchema, HTTP_METHOD, HTTP_STATUS, type IAcceptCompanyInvitationRequest, type IAcceptCompanyInvitationResponse, type IAcceptInvitationRequest, type IAcceptInvitationResponse, type IAcceptInvitationRouteResponse, type IAddChecklistItemRequest, type IAddChecklistItemResponse, type IAddDamageReportCommentRequest, type IAddDamageReportCommentResponse, type IAddDamageReportPhotoRequest, type IAddDamageReportPhotoResponse, type IAddInventoryToPropertyRequest, type IAddInventoryToPropertyResponse, type IAddInventoryToRoomRequest, type IAddInventoryToRoomResponse, type IAddTemplateItemRequest, type IAddTemplateItemResponse, type IApiError, type IApiErrorResponse, type IApiMeta, type IApiResponse, type IApiSuccessResponse, type IAssignDamageReportRequest, type IAssignDamageReportResponse, type IAssignWorkOrderRequest, type IAssignWorkOrderResponse, type IAuthInvitationBaseResponse, type IAuthInvitationIdParams, type IAuthInvitationTokenParams, type IAuthMessageResponse, type IAuthRefreshTokenResponse, type IAuthSession, type IAuthSessionIdParams, type IAuthTokenBundle, type IAuthTokenResponse, type IBillingAccount, type IBillingCompanyRouteParams, type IBillingProviderWebhookRequest, type IBillingProviderWebhookResponse, type ICancelWorkSessionRequest, type ICancelWorkSessionResponse, type IChangePasswordRequest, type IChangePasswordResponse, type IChecklistAndItemIdParams, type IChecklistExecution, type IChecklistIdParams, type IChecklistItemCompletion, type IChecklistItemOrder, type IChecklistTemplate, type IChecklistTemplateCompanyRouteParams, type IChecklistTemplateItem, type IChecklistTemplateWithItems, type ICloneChecklistRequest, type ICloneChecklistResponse, type ICompany, type ICompanyBillingSummary, type ICompanyIdParams, type ICompanyInvitationIdParams, type ICompanyInvitationSummary, type ICompanyInvitationTokenParams, type ICompanyRouteParams, type ICompanySubscription, type ICompanyUserRouteParams, type ICompanyUserSummary, type ICompanyWithRelationshipStatus, type ICompanyWithUsers, type ICompleteChecklistExecutionRequest, type ICompleteChecklistExecutionResponse, type ICompleteChecklistItemInput, type ICompleteExecutionItemRequest, type ICompleteExecutionItemResponse, type ICompleteWorkOrderRequest, type ICompleteWorkOrderResponse, type ICompleteWorkSessionRequest, type ICompleteWorkSessionResponse, ICountResponse, type ICreateChecklistRequest, type ICreateChecklistResponse, type ICreateCompanyRequest, type ICreateCompanyResponse, type ICreateCustomChecklistRequest, type ICreateCustomChecklistResponse, type ICreateDamageReportInput, type ICreateDamageReportRequest, type ICreateDamageReportResponse, type ICreateInventoryItemRequest, type ICreateInventoryItemResponse, type ICreatePropertyRequest, type ICreatePropertyResponse, type ICreateRestockOrderRequest, type ICreateRestockOrderResponse, type ICreateRoomChecklistInput, type ICreateRoomChecklistItemInput, type ICreateRoomRequest, type ICreateRoomResponse, type ICreateStripeCheckoutSessionRequest, type ICreateStripeCheckoutSessionResponse, type ICreateTemplateInput, type ICreateTemplateItemInput, type ICreateTemplateRequest, type ICreateTemplateResponse, type ICreateTemplateWithItemsRequest, type ICreateTemplateWithItemsResponse, type ICreateWorkOrderInput, type ICreateWorkOrderRequest, type ICreateWorkOrderResponse, type ICreateWorkSessionInput, type ICreateWorkSessionRequest, type ICreateWorkSessionResponse, type IDamageComment, type IDamagePhoto, type IDamageReport, type IDamageReportPhoto, type IDamageReportPropertyRouteParams, type IDamageReportRoomRouteParams, type IDamageReportRouteParams, type IDamageReportStatusHistory, type IDamageReportWorkOrderRouteParams, type IDeclineCompanyInvitationRequest, type IDeclineCompanyInvitationResponse, type IDeleteChecklistItemRequest, type IDeleteChecklistItemResponse, type IDeleteChecklistRequest, type IDeleteChecklistResponse, type IDeleteImageRequest, type IDeleteImageResponse, type IDeleteInventoryItemRequest, type IDeleteInventoryItemResponse, type IDeletePropertyRequest, type IDeletePropertyResponse, type IDeleteRoomRequest, type IDeleteRoomResponse, type IDeleteTemplateItemRequest, type IDeleteTemplateItemResponse, type IDeleteTemplateRequest, type IDeleteTemplateResponse, type IDeleteUserRequest, type IDeleteUserResponse, type IDeviceInfo, type IDuplicateTemplateItemRequest, type IDuplicateTemplateItemResponse, type IEmailValidationResult, IEmptyRouteRequest, type IEntitlementSnapshot, type IForgotPasswordRequest, type IForgotPasswordResponse, type IGetActiveWorkSessionRequest, type IGetActiveWorkSessionResponse, type IGetBillingProductsRequest, type IGetBillingProductsResponse, type IGetChecklistByIdRequest, type IGetChecklistByIdResponse, type IGetChecklistByRoomIdRequest, type IGetChecklistByRoomIdResponse, type IGetChecklistExecutionByIdRequest, type IGetChecklistExecutionByIdResponse, type IGetChecklistExecutionsRequest, type IGetChecklistExecutionsResponse, type IGetChecklistItemsRequest, type IGetChecklistItemsResponse, type IGetChecklistWithItemsRequest, type IGetChecklistWithItemsResponse, type IGetCompaniesQuery, type IGetCompaniesRequest, type IGetCompaniesResponse, type IGetCompanyBillingSummaryRequest, type IGetCompanyBillingSummaryResponse, type IGetCompanyByIdRequest, type IGetCompanyByIdResponse, type IGetCompanyUsersRequest, type IGetCompanyUsersResponse, type IGetCurrentUserRequest, type IGetCurrentUserResponse, type IGetCustomChecklistItemsRequest, type IGetCustomChecklistItemsResponse, type IGetDamageReportByIdRequest, type IGetDamageReportByIdResponse, type IGetDamageReportCommentsRequest, type IGetDamageReportCommentsResponse, type IGetDamageReportHistoryRequest, type IGetDamageReportHistoryResponse, type IGetDamageReportPhotosRequest, type IGetDamageReportPhotosResponse, type IGetDamageReportsByPropertyIdRequest, type IGetDamageReportsByPropertyIdResponse, type IGetDamageReportsByRoomIdRequest, type IGetDamageReportsByRoomIdResponse, type IGetDetailedHealthRequest, type IGetDetailedHealthResponse, type IGetDetailedRoomsByPropertyIdRequest, type IGetDetailedRoomsByPropertyIdResponse, type IGetExecutionItemsRequest, type IGetExecutionItemsResponse, type IGetExecutionProgressRequest, type IGetExecutionProgressResponse, type IGetHealthRequest, type IGetHealthResponse, type IGetImagesForEntityResponse, type IGetInventoryByCompanyIdRequest, type IGetInventoryByCompanyIdResponse, type IGetInventoryCountsByExecutionIdRequest, type IGetInventoryCountsByExecutionIdResponse, type IGetInventoryItemByIdRequest, type IGetInventoryItemByIdResponse, type IGetLoginHistoryListResponse, type IGetLoginHistoryRequest, type IGetLoginHistoryResponse, type IGetMeRequest, type IGetMeResponse, type IGetPendingCompanyInvitationsRequest, type IGetPendingCompanyInvitationsResponse, type IGetPendingInvitationsListResponse, type IGetPendingInvitationsRequest, type IGetPendingInvitationsResponse, type IGetPropertiesByCompanyIdRequest, type IGetPropertiesByCompanyIdResponse, type IGetPropertiesRequest, type IGetPropertiesResponse, type IGetPropertyAccessInformationRequest, type IGetPropertyAccessInformationResponse, type IGetPropertyByIdRequest, type IGetPropertyByIdResponse, type IGetPropertyInventoryNeedingRestockRequest, type IGetPropertyInventoryNeedingRestockResponse, type IGetPropertyInventoryRequest, type IGetPropertyInventoryResponse, type IGetPropertyResponse, type IGetRestockOrderItemsRequest, type IGetRestockOrderItemsResponse, type IGetRestockOrdersByCompanyIdRequest, type IGetRestockOrdersByCompanyIdResponse, type IGetRoomByIdRequest, type IGetRoomByIdResponse, type IGetRoomInventoryNeedingRestockRequest, type IGetRoomInventoryNeedingRestockResponse, type IGetRoomInventoryRequest, type IGetRoomInventoryResponse, type IGetRoomsByPropertyIdRequest, type IGetRoomsByPropertyIdResponse, type IGetRoomsRequest, type IGetSessionsRequest, type IGetSessionsResponse, type IGetStaffRequest, type IGetStaffResponse, type IGetTemplateByIdRequest, type IGetTemplateByIdResponse, type IGetTemplateItemsRequest, type IGetTemplateItemsResponse, type IGetTemplateUsageRequest, type IGetTemplateUsageResponse, type IGetTemplateWithItemsRequest, type IGetTemplateWithItemsResponse, type IGetTemplatesByCompanyIdRequest, type IGetTemplatesByCompanyIdResponse, type IGetUserByEmailRequest, type IGetUserByEmailResponse, type IGetUserByIdRequest, type IGetUserByIdResponse, type IGetUserCompaniesRequest, type IGetUserCompaniesResponse, type IGetUserResponse, type IGetUsersByAccountTypeRequest, type IGetUsersByAccountTypeResponse, type IGetWorkOrderByIdRequest, type IGetWorkOrderByIdResponse, type IGetWorkOrdersByPropertyIdRequest, type IGetWorkOrdersByPropertyIdResponse, type IGetWorkSessionByIdRequest, type IGetWorkSessionByIdResponse, type IGetWorkSessionWithExecutionsRequest, type IGetWorkSessionWithExecutionsResponse, type IGetWorkSessionsByPropertyIdRequest, type IGetWorkSessionsByPropertyIdResponse, type IGetWorkSessionsByUserIdRequest, type IGetWorkSessionsByUserIdResponse, type IHealthCheckResponse, type IHealthChecks, type IImage, type IImageCompanyRouteParams, type IImagePropertyRouteParams, type IImageRoomRouteParams, type IImageRouteParams, type IImageUserRouteParams, type IImageWithUrl, type IIncludeInactiveQuery, type IIncludeResolvedQuery, type IInventoryCompanyRouteParams, type IInventoryCount, type IInventoryExecutionRouteParams, type IInventoryItem, type IInventoryItemRouteParams, type IInventoryOrderRouteParams, type IInventoryPropertyRouteParams, type IInventoryRestockOrder, type IInventoryRestockOrderItem, type IInventoryRoomRouteParams, type IInviteCompanyToCompanyRequest, type IInviteCompanyToCompanyResponse, type IInviteUserToCompanyRequest, type IInviteUserToCompanyResponse, type IJobFilterValues, type ILimitQuery, type ILoginCredentials, type ILoginRequest, type ILoginResponse, type ILogoutAllRequest, type ILogoutAllResponse, type ILogoutRequest, type ILogoutResponse, IMAGE_ENTITY_TYPE, IMessageResponse, IMetaData, type IMissingFieldsErrorDetail, INVENTORY_ITEM_TYPE, INVENTORY_RESTOCK_ORDER_STATUS, INVENTORY_UNITS, INVITATION_STATUS, type IPasswordValidationResult, type IPasswordValidationRules, type IProperty, type IPropertyAccessInformation, type IPropertyDetail, type IPropertyIdParams, type IPropertyInventory, type IPropertySummary, type IProviderProduct, type IProviderProductLookupRequest, type IProviderProductLookupResponse, type IRateLimitErrorDetail, type IRateLimitStatus, type IRecordInventoryCountRequest, type IRecordInventoryCountResponse, type IRefreshSessionRequest, type IRefreshSessionResponse, type IRefreshTokenData, type IRefund, type IRegisterCredentials, type IRegisterRequest, type IRegisterResponse, type IRegisterWithInvitationRequest, type IRegisterWithInvitationResponse, type IReorderChecklistItemsRequest, type IReorderChecklistItemsResponse, type IReorderTemplateItemsRequest, type IReorderTemplateItemsResponse, type IResolveDamageReportRequest, type IResolveDamageReportResponse, type IRestockOrderItemInput, type IRevokeCompanyInvitationRequest, type IRevokeCompanyInvitationResponse, type IRevokeInvitationRequest, type IRevokeInvitationResponse, type IRevokeSessionRequest, type IRevokeSessionResponse, type IRoom, type IRoomChecklist, type IRoomChecklistItem, type IRoomChecklistRoomRouteParams, type IRoomChecklistWithItems, type IRoomInventory, type IRoomInventoryIdParams, type IRoomPropertyRouteParams, type IRoomRouteParams, IRuntimeValidationSchema, ISelectOption, type ISetAuthSessionParams, type ISkipChecklistExecutionRequest, type ISkipChecklistExecutionResponse, type IStartChecklistExecutionRequest, type IStartChecklistExecutionResponse, type IStoredAuthSession, type ISubscriptionEvent, type ISubscriptionPlan, type ISubscriptionProductSummary, ISuccessResponse, type ISyncAppleSubscriptionRequest, type ISyncGoogleSubscriptionRequest, type ISyncStoreSubscriptionResponse, type ITemplateAndItemIdParams, type ITemplateIdParams, type ITemplateItemIdParams, type ITemplateItemOrder, type IToggleTemplateActiveRequest, type IToggleTemplateActiveResponse, type ITypedApiError, type IUpdateChecklistItemRequest, type IUpdateChecklistItemResponse, type IUpdateChecklistRequest, type IUpdateChecklistResponse, type IUpdateCompanyRequest, type IUpdateCompanyResponse, type IUpdateCurrentUserRequest, type IUpdateDamageReportRequest, type IUpdateDamageReportResponse, type IUpdateDamageReportStatusRequest, type IUpdateDamageReportStatusResponse, type IUpdateInventoryItemRequest, type IUpdateInventoryItemResponse, type IUpdatePropertyAccessInformationRequest, type IUpdatePropertyAccessInformationResponse, type IUpdatePropertyRequest, type IUpdatePropertyResponse, type IUpdateRestockOrderStatusRequest, type IUpdateRestockOrderStatusResponse, type IUpdateRoomInventoryRequest, type IUpdateRoomInventoryResponse, type IUpdateRoomRequest, type IUpdateRoomResponse, type IUpdateTemplateItemRequest, type IUpdateTemplateItemResponse, type IUpdateTemplateRequest, type IUpdateTemplateResponse, type IUpdateUserRequest, type IUpdateUserResponse, type IUpdateWorkOrderRequest, type IUpdateWorkOrderResponse, type IUpdateWorkOrderStatusRequest, type IUpdateWorkOrderStatusResponse, type IUpdateWorkSessionRequest, type IUpdateWorkSessionResponse, type IUploadImagesResponse, type IUploadProfileImageRequest, type IUploadProfileImageResponse, type IUser, type IUserIdParams, type IUserSession, type IUserSubscription, type IValidateCompanyInvitationRequest, type IValidateCompanyInvitationResponse, type IValidateInvitationRequest, type IValidateInvitationResponse, type IValidationErrorDetail, IValidationField, type IWorkOrder, type IWorkSession, type IWorkSessionExecutionRouteParams, type IWorkSessionPropertyRouteParams, type IWorkSessionRouteParams, type IWorkSessionUserRouteParams, type IWorkSessionWithExecutions, InviteCompanyToCompanyRequestSchema, InviteUserToCompanyRequestSchema, LANGUAGE, LoginRequestSchema, LogoutRequestSchema, PROPERTY_STATUS, PROPERTY_TYPES, PropertyStatusOptions, PropertyTypeOptions, ProviderProductLookupRequestSchema, REFUND_STATUS, ROOM_TYPE, RefreshSessionRequestSchema, RegisterRequestSchema, RegisterWithInvitationRequestSchema, SERVER_STATUS, SUBSCRIPTION_FEATURE, SUBSCRIPTION_PLAN, SUBSCRIPTION_PROVIDER, SUBSCRIPTION_STATUS, SyncAppleSubscriptionRequestSchema, SyncGoogleSubscriptionRequestSchema, type TAccountStatus, type TAccountType, type TApiErrorDetails, type TAuthStatus, type TBillingPeriod, type TChecklistExecutionStatus, type TCompanyFilter, type TCompanyRelationshipStatus, type TCompanyType, type TDamageSeverity, type TDamageStatus, type TDatabaseStatus, TDateTimeString, TEnvironment, type TErrorCode, type TErrorResponseDetail, type THttpMethod, type THttpStatusCode, TInferValidationSchemaInput, type TInventoryItemType, type TInventoryRestockOrderStatus, type TInventoryUnitType, type TInvitationStatus, TJsonObject, TJsonValue, type TLanguage, type TMissingFieldsError, type TPropertyStatus, type TPropertyType, type TRateLimitError, TRecordValue, type TRefundStatus, type TRoomType, type TServerStatus, TServiceType, TStatus, type TStoredImageEntityType, type TSubscriptionFeature, type TSubscriptionPlan, type TSubscriptionProvider, type TSubscriptionStatus, TUSStateCode, type TValidationError, type TWorkOrderPriority, type TWorkOrderStatus, type TWorkSessionStatus, UpdateCompanyRequestSchema, UpdateCurrentUserRequestSchema, UpdatePropertyAccessInformationRequestSchema, UpdatePropertyRequestSchema, UpdateRoomRequestSchema, UpdateUserRequestSchema, WORK_ORDER_PRIORITY, WORK_ORDER_STATUS, WORK_SESSION_STATUS, isAuthError, isMissingFieldsError, isRateLimitError, isValidationError };
|
|
2181
|
+
export { ACCOUNT_STATUS, ACCOUNT_TYPE, AUTH_STATUS, AcceptInvitationRequestSchema, BILLING_PERIOD, BillingProviderValues, BillingProviderWebhookRequestSchema, CHECKLIST_EXECUTION_STATUS, COMPANY_RELATIONSHIP_STATUS, COMPANY_TYPES, ChangePasswordRequestSchema, CompanyFilter, CreateCompanyRequestSchema, CreatePropertyRequestSchema, CreateRoomRequestSchema, CreateStripeCheckoutSessionRequestSchema, DAMAGE_SEVERITY, DAMAGE_STATUS, DATABASE_STATUS, ERROR_CODES, ForgotPasswordRequestSchema, HTTP_METHOD, HTTP_STATUS, type IAcceptCompanyInvitationRequest, type IAcceptCompanyInvitationResponse, type IAcceptInvitationRequest, type IAcceptInvitationResponse, type IAcceptInvitationRouteResponse, type IAddChecklistItemRequest, type IAddChecklistItemResponse, type IAddDamageReportCommentRequest, type IAddDamageReportCommentResponse, type IAddDamageReportPhotoRequest, type IAddDamageReportPhotoResponse, type IAddInventoryToPropertyRequest, type IAddInventoryToPropertyResponse, type IAddInventoryToRoomRequest, type IAddInventoryToRoomResponse, type IAddTemplateItemRequest, type IAddTemplateItemResponse, type IApiError, type IApiErrorResponse, type IApiMeta, type IApiResponse, type IApiSuccessResponse, type IAssignDamageReportRequest, type IAssignDamageReportResponse, type IAssignWorkOrderRequest, type IAssignWorkOrderResponse, type IAuthInvitationBaseResponse, type IAuthInvitationIdParams, type IAuthInvitationTokenParams, type IAuthMessageResponse, type IAuthRefreshTokenResponse, type IAuthSession, type IAuthSessionIdParams, type IAuthTokenBundle, type IAuthTokenResponse, type IBillingAccount, type IBillingCompanyRouteParams, type IBillingProviderWebhookRequest, type IBillingProviderWebhookResponse, type ICancelWorkSessionRequest, type ICancelWorkSessionResponse, type IChangePasswordRequest, type IChangePasswordResponse, type IChecklistAndItemIdParams, type IChecklistExecution, type IChecklistIdParams, type IChecklistItemCompletion, type IChecklistItemOrder, type IChecklistTemplate, type IChecklistTemplateCompanyRouteParams, type IChecklistTemplateItem, type IChecklistTemplateWithItems, type ICloneChecklistRequest, type ICloneChecklistResponse, type ICompany, type ICompanyBillingSummary, type ICompanyIdParams, type ICompanyInvitationIdParams, type ICompanyInvitationSummary, type ICompanyInvitationTokenParams, type ICompanyRouteParams, type ICompanySubscription, type ICompanyUserRouteParams, type ICompanyUserSummary, type ICompanyWithRelationshipStatus, type ICompanyWithUsers, type ICompleteChecklistExecutionRequest, type ICompleteChecklistExecutionResponse, type ICompleteChecklistItemInput, type ICompleteExecutionItemRequest, type ICompleteExecutionItemResponse, type ICompleteWorkOrderRequest, type ICompleteWorkOrderResponse, type ICompleteWorkSessionRequest, type ICompleteWorkSessionResponse, ICountResponse, type ICreateChecklistRequest, type ICreateChecklistResponse, type ICreateCompanyRequest, type ICreateCompanyResponse, type ICreateCustomChecklistRequest, type ICreateCustomChecklistResponse, type ICreateDamageReportInput, type ICreateDamageReportRequest, type ICreateDamageReportResponse, type ICreateInventoryItemRequest, type ICreateInventoryItemResponse, type ICreatePropertyRequest, type ICreatePropertyResponse, type ICreateRestockOrderRequest, type ICreateRestockOrderResponse, type ICreateRoomChecklistInput, type ICreateRoomChecklistItemInput, type ICreateRoomRequest, type ICreateRoomResponse, type ICreateStripeCheckoutSessionRequest, type ICreateStripeCheckoutSessionResponse, type ICreateTemplateInput, type ICreateTemplateItemInput, type ICreateTemplateRequest, type ICreateTemplateResponse, type ICreateTemplateWithItemsRequest, type ICreateTemplateWithItemsResponse, type ICreateWorkOrderInput, type ICreateWorkOrderRequest, type ICreateWorkOrderResponse, type ICreateWorkSessionInput, type ICreateWorkSessionRequest, type ICreateWorkSessionResponse, type IDamageComment, type IDamagePhoto, type IDamageReport, type IDamageReportPhoto, type IDamageReportPropertyRouteParams, type IDamageReportRoomRouteParams, type IDamageReportRouteParams, type IDamageReportStatusHistory, type IDamageReportWorkOrderRouteParams, type IDeclineCompanyInvitationRequest, type IDeclineCompanyInvitationResponse, type IDeleteChecklistItemRequest, type IDeleteChecklistItemResponse, type IDeleteChecklistRequest, type IDeleteChecklistResponse, type IDeleteImageRequest, type IDeleteImageResponse, type IDeleteInventoryItemRequest, type IDeleteInventoryItemResponse, type IDeletePropertyRequest, type IDeletePropertyResponse, type IDeleteRoomRequest, type IDeleteRoomResponse, type IDeleteTemplateItemRequest, type IDeleteTemplateItemResponse, type IDeleteTemplateRequest, type IDeleteTemplateResponse, type IDeleteUserRequest, type IDeleteUserResponse, type IDeviceInfo, type IDuplicateTemplateItemRequest, type IDuplicateTemplateItemResponse, type IEmailValidationResult, IEmptyRouteRequest, type IEntitlementSnapshot, type IForgotPasswordRequest, type IForgotPasswordResponse, type IGetActiveWorkSessionRequest, type IGetActiveWorkSessionResponse, type IGetBillingProductsRequest, type IGetBillingProductsResponse, type IGetChecklistByIdRequest, type IGetChecklistByIdResponse, type IGetChecklistByRoomIdRequest, type IGetChecklistByRoomIdResponse, type IGetChecklistExecutionByIdRequest, type IGetChecklistExecutionByIdResponse, type IGetChecklistExecutionsRequest, type IGetChecklistExecutionsResponse, type IGetChecklistItemsRequest, type IGetChecklistItemsResponse, type IGetChecklistWithItemsRequest, type IGetChecklistWithItemsResponse, type IGetCompaniesQuery, type IGetCompaniesRequest, type IGetCompaniesResponse, type IGetCompanyBillingSummaryRequest, type IGetCompanyBillingSummaryResponse, type IGetCompanyByIdRequest, type IGetCompanyByIdResponse, type IGetCompanyUsersRequest, type IGetCompanyUsersResponse, type IGetCurrentUserRequest, type IGetCurrentUserResponse, type IGetCustomChecklistItemsRequest, type IGetCustomChecklistItemsResponse, type IGetDamageReportByIdRequest, type IGetDamageReportByIdResponse, type IGetDamageReportCommentsRequest, type IGetDamageReportCommentsResponse, type IGetDamageReportHistoryRequest, type IGetDamageReportHistoryResponse, type IGetDamageReportPhotosRequest, type IGetDamageReportPhotosResponse, type IGetDamageReportsByPropertyIdRequest, type IGetDamageReportsByPropertyIdResponse, type IGetDamageReportsByRoomIdRequest, type IGetDamageReportsByRoomIdResponse, type IGetDetailedHealthRequest, type IGetDetailedHealthResponse, type IGetDetailedRoomsByPropertyIdRequest, type IGetDetailedRoomsByPropertyIdResponse, type IGetExecutionItemsRequest, type IGetExecutionItemsResponse, type IGetExecutionProgressRequest, type IGetExecutionProgressResponse, type IGetHealthRequest, type IGetHealthResponse, type IGetImagesForEntityResponse, type IGetInventoryByCompanyIdRequest, type IGetInventoryByCompanyIdResponse, type IGetInventoryCountsByExecutionIdRequest, type IGetInventoryCountsByExecutionIdResponse, type IGetInventoryItemByIdRequest, type IGetInventoryItemByIdResponse, type IGetLoginHistoryListResponse, type IGetLoginHistoryRequest, type IGetLoginHistoryResponse, type IGetMeRequest, type IGetMeResponse, type IGetPendingCompanyInvitationsRequest, type IGetPendingCompanyInvitationsResponse, type IGetPendingInvitationsListResponse, type IGetPendingInvitationsRequest, type IGetPendingInvitationsResponse, type IGetPropertiesByCompanyIdRequest, type IGetPropertiesByCompanyIdResponse, type IGetPropertiesRequest, type IGetPropertiesResponse, type IGetPropertyAccessInformationRequest, type IGetPropertyAccessInformationResponse, type IGetPropertyByIdRequest, type IGetPropertyByIdResponse, type IGetPropertyInventoryNeedingRestockRequest, type IGetPropertyInventoryNeedingRestockResponse, type IGetPropertyInventoryRequest, type IGetPropertyInventoryResponse, type IGetPropertyResponse, type IGetRestockOrderItemsRequest, type IGetRestockOrderItemsResponse, type IGetRestockOrdersByCompanyIdRequest, type IGetRestockOrdersByCompanyIdResponse, type IGetRoomByIdRequest, type IGetRoomByIdResponse, type IGetRoomInventoryNeedingRestockRequest, type IGetRoomInventoryNeedingRestockResponse, type IGetRoomInventoryRequest, type IGetRoomInventoryResponse, type IGetRoomsByPropertyIdRequest, type IGetRoomsByPropertyIdResponse, type IGetRoomsRequest, type IGetSessionsRequest, type IGetSessionsResponse, type IGetStaffRequest, type IGetStaffResponse, type IGetTemplateByIdRequest, type IGetTemplateByIdResponse, type IGetTemplateItemsRequest, type IGetTemplateItemsResponse, type IGetTemplateUsageRequest, type IGetTemplateUsageResponse, type IGetTemplateWithItemsRequest, type IGetTemplateWithItemsResponse, type IGetTemplatesByCompanyIdRequest, type IGetTemplatesByCompanyIdResponse, type IGetUserByEmailRequest, type IGetUserByEmailResponse, type IGetUserByIdRequest, type IGetUserByIdResponse, type IGetUserCompaniesRequest, type IGetUserCompaniesResponse, type IGetUserResponse, type IGetUsersByAccountTypeRequest, type IGetUsersByAccountTypeResponse, type IGetWorkOrderByIdRequest, type IGetWorkOrderByIdResponse, type IGetWorkOrdersByPropertyIdRequest, type IGetWorkOrdersByPropertyIdResponse, type IGetWorkSessionByIdRequest, type IGetWorkSessionByIdResponse, type IGetWorkSessionWithExecutionsRequest, type IGetWorkSessionWithExecutionsResponse, type IGetWorkSessionsByPropertyIdRequest, type IGetWorkSessionsByPropertyIdResponse, type IGetWorkSessionsByUserIdRequest, type IGetWorkSessionsByUserIdResponse, type IHealthCheckResponse, type IHealthChecks, type IImage, type IImageCompanyRouteParams, type IImagePropertyRouteParams, type IImageRoomRouteParams, type IImageRouteParams, type IImageUserRouteParams, type IImageWithUrl, type IIncludeInactiveQuery, type IIncludeResolvedQuery, type IInventoryCompanyRouteParams, type IInventoryCount, type IInventoryExecutionRouteParams, type IInventoryItem, type IInventoryItemRouteParams, type IInventoryOrderRouteParams, type IInventoryPropertyRouteParams, type IInventoryRestockOrder, type IInventoryRestockOrderItem, type IInventoryRoomRouteParams, type IInviteCompanyToCompanyRequest, type IInviteCompanyToCompanyResponse, type IInviteUserToCompanyRequest, type IInviteUserToCompanyResponse, type IJobFilterValues, type ILimitQuery, type ILoginCredentials, type ILoginRequest, type ILoginResponse, type ILogoutAllRequest, type ILogoutAllResponse, type ILogoutRequest, type ILogoutResponse, IMAGE_ENTITY_TYPE, IMessageResponse, IMetaData, type IMissingFieldsErrorDetail, INVENTORY_ITEM_TYPE, INVENTORY_RESTOCK_ORDER_STATUS, INVENTORY_UNITS, INVITATION_STATUS, type IPasswordValidationResult, type IPasswordValidationRules, type IProperty, type IPropertyAccessInformation, type IPropertyDetail, type IPropertyIdParams, type IPropertyInventory, type IPropertySummary, type IProviderProduct, type IProviderProductLookupRequest, type IProviderProductLookupResponse, type IRateLimitErrorDetail, type IRateLimitStatus, type IRecordInventoryCountRequest, type IRecordInventoryCountResponse, type IRefreshSessionRequest, type IRefreshSessionResponse, type IRefreshTokenData, type IRefreshTokenPersistenceData, type IRefund, type IRegisterCredentials, type IRegisterRequest, type IRegisterResponse, type IRegisterWithInvitationRequest, type IRegisterWithInvitationResponse, type IReorderChecklistItemsRequest, type IReorderChecklistItemsResponse, type IReorderTemplateItemsRequest, type IReorderTemplateItemsResponse, type IResolveDamageReportRequest, type IResolveDamageReportResponse, type IRestockOrderItemInput, type IRevokeCompanyInvitationRequest, type IRevokeCompanyInvitationResponse, type IRevokeInvitationRequest, type IRevokeInvitationResponse, type IRevokeSessionRequest, type IRevokeSessionResponse, type IRoom, type IRoomChecklist, type IRoomChecklistItem, type IRoomChecklistRoomRouteParams, type IRoomChecklistWithItems, type IRoomInventory, type IRoomInventoryIdParams, type IRoomPropertyRouteParams, type IRoomRouteParams, IRuntimeValidationSchema, ISelectOption, type ISetAuthSessionParams, type ISkipChecklistExecutionRequest, type ISkipChecklistExecutionResponse, type IStartChecklistExecutionRequest, type IStartChecklistExecutionResponse, type IStoredAuthSession, type ISubscriptionEvent, type ISubscriptionPlan, type ISubscriptionProductSummary, ISuccessResponse, type ISyncAppleSubscriptionRequest, type ISyncGoogleSubscriptionRequest, type ISyncStoreSubscriptionResponse, type ITemplateAndItemIdParams, type ITemplateIdParams, type ITemplateItemIdParams, type ITemplateItemOrder, type IToggleTemplateActiveRequest, type IToggleTemplateActiveResponse, type ITokenPayload, type ITypedApiError, type IUpdateChecklistItemRequest, type IUpdateChecklistItemResponse, type IUpdateChecklistRequest, type IUpdateChecklistResponse, type IUpdateCompanyRequest, type IUpdateCompanyResponse, type IUpdateCurrentUserRequest, type IUpdateDamageReportRequest, type IUpdateDamageReportResponse, type IUpdateDamageReportStatusRequest, type IUpdateDamageReportStatusResponse, type IUpdateInventoryItemRequest, type IUpdateInventoryItemResponse, type IUpdatePropertyAccessInformationRequest, type IUpdatePropertyAccessInformationResponse, type IUpdatePropertyRequest, type IUpdatePropertyResponse, type IUpdateRestockOrderStatusRequest, type IUpdateRestockOrderStatusResponse, type IUpdateRoomInventoryRequest, type IUpdateRoomInventoryResponse, type IUpdateRoomRequest, type IUpdateRoomResponse, type IUpdateTemplateItemRequest, type IUpdateTemplateItemResponse, type IUpdateTemplateRequest, type IUpdateTemplateResponse, type IUpdateUserRequest, type IUpdateUserResponse, type IUpdateWorkOrderRequest, type IUpdateWorkOrderResponse, type IUpdateWorkOrderStatusRequest, type IUpdateWorkOrderStatusResponse, type IUpdateWorkSessionRequest, type IUpdateWorkSessionResponse, type IUploadImagesResponse, type IUploadProfileImageRequest, type IUploadProfileImageResponse, type IUser, type IUserIdParams, type IUserSession, type IUserSubscription, type IValidateCompanyInvitationRequest, type IValidateCompanyInvitationResponse, type IValidateInvitationRequest, type IValidateInvitationResponse, type IValidationErrorDetail, IValidationField, type IWorkOrder, type IWorkSession, type IWorkSessionExecutionRouteParams, type IWorkSessionPropertyRouteParams, type IWorkSessionRouteParams, type IWorkSessionUserRouteParams, type IWorkSessionWithExecutions, InviteCompanyToCompanyRequestSchema, InviteUserToCompanyRequestSchema, LANGUAGE, LoginRequestSchema, LogoutRequestSchema, PROPERTY_STATUS, PROPERTY_TYPES, PropertyStatusOptions, PropertyTypeOptions, ProviderProductLookupRequestSchema, REFUND_STATUS, ROOM_TYPE, RefreshSessionRequestSchema, RegisterRequestSchema, RegisterWithInvitationRequestSchema, SERVER_STATUS, SUBSCRIPTION_FEATURE, SUBSCRIPTION_PLAN, SUBSCRIPTION_PROVIDER, SUBSCRIPTION_STATUS, SyncAppleSubscriptionRequestSchema, SyncGoogleSubscriptionRequestSchema, type TAccountStatus, type TAccountType, type TApiErrorDetails, type TAuthStatus, type TBillingPeriod, type TChecklistExecutionStatus, type TCompanyFilter, type TCompanyRelationshipStatus, type TCompanyType, type TDamageSeverity, type TDamageStatus, type TDatabaseStatus, TDateTimeString, TEnvironment, type TErrorCode, type TErrorResponseDetail, type THttpMethod, type THttpStatusCode, TInferValidationSchemaInput, type TInventoryItemType, type TInventoryRestockOrderStatus, type TInventoryUnitType, type TInvitationStatus, TJsonObject, TJsonValue, type TLanguage, type TMissingFieldsError, type TPropertyStatus, type TPropertyType, type TRateLimitError, TRecordValue, type TRefundStatus, type TRoomType, type TServerStatus, TServiceType, TStatus, type TStoredImageEntityType, type TSubscriptionFeature, type TSubscriptionPlan, type TSubscriptionProvider, type TSubscriptionStatus, TUSStateCode, type TValidationError, type TWorkOrderPriority, type TWorkOrderStatus, type TWorkSessionStatus, UpdateCompanyRequestSchema, UpdateCurrentUserRequestSchema, UpdatePropertyAccessInformationRequestSchema, UpdatePropertyRequestSchema, UpdateRoomRequestSchema, UpdateUserRequestSchema, WORK_ORDER_PRIORITY, WORK_ORDER_STATUS, WORK_SESSION_STATUS, isAuthError, isMissingFieldsError, isRateLimitError, isValidationError };
|
package/dist/types/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/types/api/index.ts","../../src/types/validation/index.ts","../../src/types/user/constants.ts","../../src/types/auth/routes.ts","../../src/types/auth/index.ts","../../src/types/base/paging.types.ts","../../src/types/base/index.ts","../../src/types/company/constants.ts","../../src/types/company/routes.ts","../../src/types/damage-report/index.ts","../../src/types/errors/index.ts","../../src/types/health/index.ts","../../src/types/image/index.ts","../../src/types/inventory/index.ts","../../src/types/property/constants.ts","../../src/types/property/routes.ts","../../src/types/room/constants.ts","../../src/types/room/routes.ts","../../src/types/subscription/routes.ts","../../src/types/subscription/index.ts","../../src/types/user/routes.ts","../../src/types/work-session/index.ts"],"sourcesContent":["/**\n * API Response Types\n * Standard response structure for all API endpoints.\n */\n\nimport type { TDateTimeString, TEnvironment, TJsonValue } from \"../base\";\n\nexport const HTTP_METHOD = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n PATCH: \"PATCH\",\n DELETE: \"DELETE\",\n} as const;\n\nexport type THttpMethod = (typeof HTTP_METHOD)[keyof typeof HTTP_METHOD];\n\n/**\n * Error Codes\n * Standardized error codes used across the platform.\n */\nexport const ERROR_CODES = {\n BAD_REQUEST: \"BAD_REQUEST\",\n VALIDATION_ERROR: \"VALIDATION_ERROR\",\n MISSING_FIELDS: \"MISSING_FIELDS\",\n UNAUTHORIZED: \"UNAUTHORIZED\",\n INVALID_TOKEN: \"INVALID_TOKEN\",\n INVALID_CREDENTIALS: \"INVALID_CREDENTIALS\",\n FORBIDDEN: \"FORBIDDEN\",\n NOT_FOUND: \"NOT_FOUND\",\n CONFLICT: \"CONFLICT\",\n ALREADY_EXISTS: \"ALREADY_EXISTS\",\n RATE_LIMIT: \"RATE_LIMIT\",\n RATE_LIMIT_EXCEEDED: \"RATE_LIMIT_EXCEEDED\",\n INTERNAL_ERROR: \"INTERNAL_ERROR\",\n DATABASE_ERROR: \"DATABASE_ERROR\",\n NOT_IMPLEMENTED: \"NOT_IMPLEMENTED\",\n} as const;\n\nexport type TErrorCode = (typeof ERROR_CODES)[keyof typeof ERROR_CODES];\n\n/**\n * HTTP Status Codes\n * Common status codes used in API responses.\n */\nexport const HTTP_STATUS = {\n Ok: 200,\n Created: 201,\n NoContent: 204,\n BadRequest: 400,\n Unauthorized: 401,\n Forbidden: 403,\n NotFound: 404,\n Conflict: 409,\n UnprocessableEntity: 422,\n TooManyRequests: 429,\n InternalError: 500,\n} as const;\n\nexport type THttpStatusCode = (typeof HTTP_STATUS)[keyof typeof HTTP_STATUS];\n\nexport type TApiErrorDetails = TJsonValue;\n\nexport interface IApiError<TDetails = TApiErrorDetails> {\n message: string;\n code?: TErrorCode;\n details?: TDetails;\n}\n\nexport interface IApiMeta {\n timestamp: TDateTimeString;\n version: string;\n environment: TEnvironment;\n requestId?: string;\n}\n\nexport interface IApiSuccessResponse<TData = null> {\n success: true;\n data: TData;\n meta: IApiMeta;\n}\n\nexport interface IApiErrorResponse<TErrorDetails = TApiErrorDetails> {\n success: false;\n error: IApiError<TErrorDetails>;\n meta: IApiMeta;\n}\n\nexport type IApiResponse<TData = null, TErrorDetails = TApiErrorDetails> =\n | IApiSuccessResponse<TData>\n | IApiErrorResponse<TErrorDetails>;\n","export type TValidationIssueType =\n | \"INVALID_BODY\"\n | \"MISSING_FIELD\"\n | \"INVALID_FIELD\"\n | \"UNSUPPORTED_FIELD\";\n\nexport interface IValidationIssue<TFieldName extends string = string> {\n fieldName: TFieldName;\n type: TValidationIssueType;\n}\n\nexport interface IValidationResult<TValue extends object> {\n success: boolean;\n data?: TValue;\n issues: IValidationIssue[];\n}\n\nexport type TMissingValuePolicy = \"Nullish\" | \"BlankString\";\n\nexport interface IValidationField<TValue, TRequired extends boolean> {\n readonly valueType?: TValue;\n required: TRequired;\n missingValuePolicy: TMissingValuePolicy;\n validate: (value: unknown) => boolean;\n}\n\nexport type TValidationFieldMap = Record<\n string,\n IValidationField<unknown, boolean>\n>;\n\ntype TRequiredSchemaKeys<TFields extends TValidationFieldMap> = {\n [TKey in keyof TFields]: TFields[TKey] extends IValidationField<unknown, true>\n ? TKey\n : never;\n}[keyof TFields];\n\ntype TOptionalSchemaKeys<TFields extends TValidationFieldMap> = Exclude<\n keyof TFields,\n TRequiredSchemaKeys<TFields>\n>;\n\ntype TFieldValue<TField> =\n TField extends IValidationField<infer TValue, boolean> ? TValue : never;\n\nexport type TInferValidationFields<TFields extends TValidationFieldMap> = {\n [TKey in TRequiredSchemaKeys<TFields>]: TFieldValue<TFields[TKey]>;\n} & {\n [TKey in TOptionalSchemaKeys<TFields>]?: TFieldValue<TFields[TKey]>;\n};\n\nexport type TInferValidationSchemaInput<TSchema> =\n TSchema extends IRuntimeValidationSchema<infer TFields>\n ? TInferValidationFields<TFields>\n : never;\n\nexport interface IRuntimeValidationSchema<\n TFields extends TValidationFieldMap = TValidationFieldMap,\n> {\n fields: TFields;\n allowedFields: readonly Extract<keyof TFields, string>[];\n requiredFields: readonly Extract<TRequiredSchemaKeys<TFields>, string>[];\n validate: (\n value: unknown,\n options?: IRuntimeValidationOptions,\n ) => IValidationResult<TInferValidationFields<TFields>>;\n}\n\nexport interface IRuntimeValidationOptions {\n rejectUnknownFields?: boolean;\n}\n\nexport const createValidationSchema = <TFields extends TValidationFieldMap>(\n fields: TFields,\n): IRuntimeValidationSchema<TFields> => {\n const allowedFields = Object.keys(fields) as Extract<keyof TFields, string>[];\n const requiredFields = allowedFields.filter((fieldName) => {\n return fields[fieldName].required;\n }) as Extract<TRequiredSchemaKeys<TFields>, string>[];\n\n return {\n fields,\n allowedFields,\n requiredFields,\n validate: (value, options = {}) => {\n if (!isRecord(value)) {\n return {\n success: false,\n issues: [\n {\n fieldName: \"body\",\n type: \"INVALID_BODY\",\n },\n ],\n };\n }\n\n const issues = getValidationIssues(fields, value, options);\n\n if (issues.length > 0) {\n return {\n success: false,\n issues,\n };\n }\n\n return {\n success: true,\n data: value as TInferValidationFields<TFields>,\n issues: [],\n };\n },\n };\n};\n\nexport const requiredStringField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isNonEmptyString,\n});\n\nexport const optionalStringField = (): IValidationField<string, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isNonEmptyString,\n});\n\nexport const optionalNullableStringField = (): IValidationField<\n string | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is string | null => {\n return value === null || isNonEmptyString(value);\n },\n});\n\nexport const requiredEmailField = (\n missingValuePolicy: TMissingValuePolicy = \"BlankString\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isEmail,\n});\n\nexport const requiredUuidField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isUuid,\n});\n\nexport const optionalNullableNonNegativeIntegerField = (): IValidationField<\n number | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is number | null => {\n return value === null || (Number.isInteger(value) && Number(value) >= 0);\n },\n});\n\nexport const optionalRecordField = (): IValidationField<\n Record<string, unknown>,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isRecord,\n});\n\nexport const requiredEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<TValue, true> => ({\n required: true,\n missingValuePolicy,\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalNullableEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue | null, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue | null => {\n return value === null || isAllowedStringValue(value, allowedValues);\n },\n});\n\nconst getValidationIssues = <TFields extends TValidationFieldMap>(\n fields: TFields,\n value: Record<string, unknown>,\n options: IRuntimeValidationOptions,\n): IValidationIssue[] => {\n const allowedFieldSet = new Set(Object.keys(fields));\n const issues: IValidationIssue[] = [];\n\n Object.entries(fields).forEach(([fieldName, field]) => {\n const fieldValue = value[fieldName];\n\n if (\n field.required &&\n isMissingValue(fieldValue, field.missingValuePolicy)\n ) {\n issues.push({\n fieldName,\n type: \"MISSING_FIELD\",\n });\n return;\n }\n\n if (fieldValue === undefined) {\n return;\n }\n\n if (!field.validate(fieldValue)) {\n issues.push({\n fieldName,\n type: \"INVALID_FIELD\",\n });\n }\n });\n\n if (options.rejectUnknownFields === true) {\n Object.keys(value).forEach((fieldName) => {\n if (!allowedFieldSet.has(fieldName)) {\n issues.push({\n fieldName,\n type: \"UNSUPPORTED_FIELD\",\n });\n }\n });\n }\n\n return issues;\n};\n\nconst isRecord = (value: unknown): value is Record<string, unknown> => {\n return typeof value === \"object\" && value !== null && !Array.isArray(value);\n};\n\nconst isMissingValue = (\n value: unknown,\n missingValuePolicy: TMissingValuePolicy,\n): boolean => {\n if (value === undefined || value === null) {\n return true;\n }\n\n return (\n missingValuePolicy === \"BlankString\" &&\n typeof value === \"string\" &&\n value.trim().length === 0\n );\n};\n\nconst isNonEmptyString = (value: unknown): value is string => {\n return typeof value === \"string\" && value.trim().length > 0;\n};\n\nconst isAllowedStringValue = <TValue extends string>(\n value: unknown,\n allowedValues: readonly TValue[],\n): value is TValue => {\n return typeof value === \"string\" && allowedValues.includes(value as TValue);\n};\n\nconst isEmail = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value.trim());\n};\n\nconst isUuid = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(\n value,\n );\n};\n","import type { TRecordValue } from \"../base\";\n\nexport const ACCOUNT_TYPE = {\n TURNDOWN_ADMIN: \"TURNDOWN_ADMIN\",\n ACCOUNT_ADMIN: \"ACCOUNT_ADMIN\",\n MANAGER: \"MANAGER\",\n STAFF: \"STAFF\",\n GUEST: \"GUEST\",\n} as const;\n\nexport type TAccountType = TRecordValue<typeof ACCOUNT_TYPE>;\n\nexport const ACCOUNT_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n PENDING: \"PENDING\",\n} as const;\n\nexport type TAccountStatus = TRecordValue<typeof ACCOUNT_STATUS>;\n\nexport const LANGUAGE = {\n ENGLISH: \"ENGLISH\",\n FRENCH: \"FRENCH\",\n SPANISH: \"SPANISH\",\n GERMAN: \"GERMAN\",\n} as const;\n\nexport type TLanguage = TRecordValue<typeof LANGUAGE>;\n","import {\n createValidationSchema,\n optionalRecordField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\nimport type { IAuthTokenResponse } from \"./index\";\nimport type { IEmptyRouteRequest, TDateTimeString } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport type { IDeviceInfo } from \"../user\";\nimport type { IGetUserResponse } from \"../user/routes\";\n\n// Route Params\nexport interface IAuthSessionIdParams {\n sessionId: string;\n}\n\nexport interface IAuthInvitationTokenParams {\n token: string;\n}\n\nexport interface IAuthInvitationIdParams {\n invitationId: string;\n}\n\n// Shared Responses\nexport interface IAuthMessageResponse {\n message: string;\n}\n\nexport interface IAuthRefreshTokenResponse extends IAuthTokenResponse {}\n\nexport interface IAuthInvitationBaseResponse {\n id: string;\n companyId: string;\n companyName: string;\n role: TAccountType;\n invitedBy: string;\n invitedByName: string;\n expiresAt: TDateTimeString;\n}\n\nconst AccountTypeValues = Object.values(ACCOUNT_TYPE);\n\n// Core Authentication\nexport const RegisterRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n accountType: requiredEnumField(AccountTypeValues, \"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterResponse extends IAuthTokenResponse {}\n\nexport const LoginRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type ILoginRequest = Omit<\n TInferValidationSchemaInput<typeof LoginRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface ILoginResponse extends IAuthTokenResponse {\n passwordResetRequired: boolean;\n}\n\nexport const RefreshSessionRequestSchema = createValidationSchema({\n refreshToken: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRefreshSessionRequest = Omit<\n TInferValidationSchemaInput<typeof RefreshSessionRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRefreshSessionResponse extends IAuthRefreshTokenResponse {}\n\nexport const LogoutRequestSchema = createValidationSchema({\n refreshToken: optionalStringField(),\n});\n\nexport type ILogoutRequest = TInferValidationSchemaInput<\n typeof LogoutRequestSchema\n>;\n\nexport interface ILogoutResponse extends IAuthMessageResponse {}\n\nexport interface ILogoutAllRequest {\n userId: string;\n}\n\nexport interface ILogoutAllResponse extends IAuthMessageResponse {}\n\nexport interface IGetMeRequest {\n userId: string;\n}\n\nexport interface IGetMeResponse extends IGetUserResponse {}\n\n// Session Management\nexport type IGetSessionsRequest = IEmptyRouteRequest;\n\nexport interface IGetSessionsResponse {\n id: string;\n deviceInfo: string;\n createdAt: TDateTimeString;\n lastUsedAt: TDateTimeString;\n}\n\nexport interface IRevokeSessionRequest extends IAuthSessionIdParams {}\n\nexport interface IRevokeSessionResponse extends IAuthMessageResponse {}\n\n// Password Management\nexport const ChangePasswordRequestSchema = createValidationSchema({\n currentPassword: requiredStringField(\"BlankString\"),\n newPassword: requiredStringField(\"BlankString\"),\n});\n\nexport type IChangePasswordRequest = TInferValidationSchemaInput<\n typeof ChangePasswordRequestSchema\n>;\n\nexport interface IChangePasswordResponse extends IGetUserResponse {}\n\nexport const ForgotPasswordRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n});\n\nexport type IForgotPasswordRequest = TInferValidationSchemaInput<\n typeof ForgotPasswordRequestSchema\n>;\n\nexport interface IForgotPasswordResponse extends IAuthMessageResponse {}\n\nexport type IGetLoginHistoryRequest = IEmptyRouteRequest;\n\nexport interface IGetLoginHistoryResponse {\n id: string;\n email: string;\n ipAddress: string;\n userAgent: string;\n success: boolean;\n failureReason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetLoginHistoryListResponse {\n history: IGetLoginHistoryResponse[];\n length: number;\n}\n\n// Invitations\nexport interface IValidateInvitationRequest extends IAuthInvitationTokenParams {}\n\nexport interface IValidateInvitationResponse extends IAuthInvitationBaseResponse {\n email: string;\n userExists: boolean;\n}\n\nexport const RegisterWithInvitationRequestSchema = createValidationSchema({\n token: requiredStringField(\"BlankString\"),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterWithInvitationRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterWithInvitationRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterWithInvitationResponse extends IAuthTokenResponse {}\n\nexport const AcceptInvitationRequestSchema = createValidationSchema({\n userId: optionalStringField(),\n token: requiredStringField(\"BlankString\"),\n});\n\nexport type IAcceptInvitationRequest = TInferValidationSchemaInput<\n typeof AcceptInvitationRequestSchema\n>;\n\nexport interface IAcceptInvitationResponse {\n companyId: string;\n companyName: string;\n role: TAccountType;\n}\n\nexport interface IAcceptInvitationRouteResponse {\n invite: IAcceptInvitationResponse;\n message: string;\n}\n\nexport type IGetPendingInvitationsRequest = IEmptyRouteRequest;\n\nexport interface IGetPendingInvitationsResponse extends IAuthInvitationBaseResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetPendingInvitationsListResponse {\n invitations: IGetPendingInvitationsResponse[];\n length: number;\n}\n\nexport interface IRevokeInvitationRequest extends IAuthInvitationIdParams {\n revokedBy?: string;\n}\n\nexport interface IRevokeInvitationResponse extends IAuthMessageResponse {}\n","export * from \"./routes\";\n\nimport type { TDateTimeString, TServiceType } from \"../base\";\nimport type { IUser } from \"../user\";\n\nexport const AUTH_STATUS = {\n Initializing: \"Initializing\",\n Unauthenticated: \"Unauthenticated\",\n Authenticated: \"Authenticated\",\n Refreshing: \"Refreshing\",\n SessionExpired: \"SessionExpired\",\n} as const;\n\nexport type TAuthStatus = (typeof AUTH_STATUS)[keyof typeof AUTH_STATUS];\n\nexport interface IAuthTokenBundle {\n accessToken: string;\n refreshToken: string;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IRefreshTokenData {\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IStoredAuthSession {\n accessToken: string | null;\n refreshToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IAuthTokenResponse extends IAuthTokenBundle {\n user: IUser | null;\n companyId: string | null;\n}\n\nexport interface IAuthSession {\n user: IUser | null;\n accessToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface ISetAuthSessionParams extends IAuthTokenBundle {\n user: IUser | null;\n}\n\nexport interface ILoginCredentials {\n email: string;\n password: string;\n rememberMe: boolean;\n}\n\nexport interface IRegisterCredentials {\n businessType: TServiceType[];\n firstName: string;\n lastName: string;\n email: string;\n password: string;\n}\n\nexport interface IPasswordValidationRules {\n minLength: number;\n requireUppercase: boolean;\n requireLowercase: boolean;\n requireNumbers: boolean;\n requireSpecialChars: boolean;\n}\n\nexport interface IPasswordValidationResult {\n valid: boolean;\n errors: string[];\n}\n\nexport interface IEmailValidationResult {\n valid: boolean;\n error?: string;\n}\n\nexport interface IRateLimitStatus {\n isLimited: boolean;\n attempts: number;\n maxAttempts: number;\n resetTime: TDateTimeString | null;\n}\n","/**\n * Pagination metadata for a paginated response.\n */\nexport interface IPagingResult {\n hasNextPage: boolean;\n totalPages: number;\n totalRecords: number;\n}\n\n/**\n * Generic wrapper for paginated data.\n */\nexport interface IDataWithPagingResult<TData> {\n data: TData;\n pagination: IPagingResult;\n}\n\nexport const SortDirection = {\n Asc: \"Asc\",\n Desc: \"Desc\",\n} as const;\n\nexport type TSortDirection = (typeof SortDirection)[keyof typeof SortDirection];\n\n/**\n * Sorting condition for query results.\n */\nexport interface ISortCondition {\n name: string;\n direction: TSortDirection;\n}\n\nexport const FilterCondition = {\n Equal: \"=\",\n GreaterThan: \">\",\n LessThan: \"<\",\n NotEqual: \"!=\",\n Like: \"LIKE\",\n In: \"IN\",\n GreaterThanOrEqual: \">=\",\n LessThanOrEqual: \"<=\",\n} as const;\n\nexport type TFilterCondition =\n (typeof FilterCondition)[keyof typeof FilterCondition];\n\nexport interface IFilterConditionBase {\n name: string;\n condition: TFilterCondition;\n useAnd?: boolean;\n}\n\nexport interface IStringFilterCondition extends IFilterConditionBase {\n valueString: string;\n valueNumber?: never;\n valueBoolean?: never;\n}\n\nexport interface INumberFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber: number;\n valueBoolean?: never;\n}\n\nexport interface IBooleanFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber?: never;\n valueBoolean: boolean;\n}\n\n/**\n * Filter condition for querying data.\n *\n * Exactly one value field should be provided.\n */\nexport type TFilterConditionValue =\n | IStringFilterCondition\n | INumberFilterCondition\n | IBooleanFilterCondition;\n\n/**\n * Kept as an exported alias to preserve the existing public API name.\n */\nexport type IFilterCondition = TFilterConditionValue;\n\n/**\n * Request shape for paginated data with optional sorting and filtering.\n */\nexport interface IPaginationRequest {\n page: number;\n size: number;\n sort?: ISortCondition[];\n filters?: IFilterCondition[];\n}\n\nexport interface IPagingObject {\n pagination: IPaginationRequest;\n}\n\nexport const createPagingObject = (\n page: number,\n size: number,\n sort?: ISortCondition[],\n filters?: IFilterCondition[],\n): IPagingObject => ({\n pagination: {\n page,\n size,\n sort,\n filters,\n },\n});\n","export type TJsonPrimitive = string | number | boolean | null;\n\nexport type TJsonObject = {\n [key: string]: TJsonValue;\n};\n\nexport type TJsonValue = TJsonPrimitive | TJsonValue[] | TJsonObject;\n\nexport type TUnknownRecord = Record<string, unknown>;\n\n/**\n * Serialized ISO-8601 date/time value returned by API JSON contracts.\n */\nexport type TDateTimeString = string;\n\nexport type TurndownObject<TObject extends object = TUnknownRecord> = TObject;\n\nexport type TEmptyObject = Record<string, never>;\n\nexport type IEmptyRouteRequest = TEmptyObject;\n\nexport type IEmptyRouteParams = TEmptyObject;\n\nexport const ENVIRONMENT = {\n Prod: \"Prod\",\n Dev: \"Dev\",\n Local: \"Local\",\n Test: \"Test\",\n} as const;\n\nexport type TEnvironment = (typeof ENVIRONMENT)[keyof typeof ENVIRONMENT];\n\nexport interface IMessageResponse {\n message: string;\n}\n\nexport interface ISuccessResponse {\n success: boolean;\n}\n\nexport interface ICountResponse {\n count: number;\n}\n\nexport interface IMetaData {\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport type TRecordValue<TRecord extends object> = TRecord[keyof TRecord];\n\nexport type TRecordKeys<TRecord extends object> = keyof TRecord;\n\nexport interface IVersion {\n major: number;\n minor: number;\n patch: number;\n}\n\nexport type TVersionInput = string | IVersion;\n\nexport interface ISelectOption<TValue extends string = string> {\n label: string;\n value: TValue;\n}\n\nexport const MODE = {\n Create: \"Create\",\n Edit: \"Edit\",\n Delete: \"Delete\",\n Details: \"Details\",\n} as const;\n\nexport type TMode = TRecordValue<typeof MODE> | null;\n\nexport const IMAGE_ENTITY = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TImageEntityType = TRecordValue<typeof IMAGE_ENTITY>;\n\nexport type TUSStateCode = TRecordKeys<typeof US_JURISDICTIONS>;\n\nexport const US_JURISDICTIONS = {\n // 50 States\n AL: \"Alabama\",\n AK: \"Alaska\",\n AZ: \"Arizona\",\n AR: \"Arkansas\",\n CA: \"California\",\n CO: \"Colorado\",\n CT: \"Connecticut\",\n DE: \"Delaware\",\n FL: \"Florida\",\n GA: \"Georgia\",\n HI: \"Hawaii\",\n ID: \"Idaho\",\n IL: \"Illinois\",\n IN: \"Indiana\",\n IA: \"Iowa\",\n KS: \"Kansas\",\n KY: \"Kentucky\",\n LA: \"Louisiana\",\n ME: \"Maine\",\n MD: \"Maryland\",\n MA: \"Massachusetts\",\n MI: \"Michigan\",\n MN: \"Minnesota\",\n MS: \"Mississippi\",\n MO: \"Missouri\",\n MT: \"Montana\",\n NE: \"Nebraska\",\n NV: \"Nevada\",\n NH: \"New Hampshire\",\n NJ: \"New Jersey\",\n NM: \"New Mexico\",\n NY: \"New York\",\n NC: \"North Carolina\",\n ND: \"North Dakota\",\n OH: \"Ohio\",\n OK: \"Oklahoma\",\n OR: \"Oregon\",\n PA: \"Pennsylvania\",\n RI: \"Rhode Island\",\n SC: \"South Carolina\",\n SD: \"South Dakota\",\n TN: \"Tennessee\",\n TX: \"Texas\",\n UT: \"Utah\",\n VT: \"Vermont\",\n VA: \"Virginia\",\n WA: \"Washington\",\n WV: \"West Virginia\",\n WI: \"Wisconsin\",\n WY: \"Wyoming\",\n\n // Territories\n DC: \"District of Columbia\",\n PR: \"Puerto Rico\",\n GU: \"Guam\",\n VI: \"United States Virgin Islands\",\n AS: \"American Samoa\",\n MP: \"Northern Mariana Islands\",\n} as const;\n\nexport type TUSJurisdiction = TRecordValue<typeof US_JURISDICTIONS>;\n\nexport const STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n OVERDUE: \"OVERDUE\",\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TStatus = TRecordValue<typeof STATUS>;\n\nexport const SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n} as const;\n\nexport type TSeverity = TRecordValue<typeof SEVERITY>;\n\nexport const SERVICE_TYPES = {\n PROPERTY: \"PROPERTY\",\n CLEANING: \"CLEANING\",\n MAINTENANCE: \"MAINTENANCE\",\n INSPECTION: \"INSPECTION\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TServiceType = TRecordValue<typeof SERVICE_TYPES>;\n\nexport const MONTHS = [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n] as const;\n\nexport type TMonths = (typeof MONTHS)[number];\n\nexport const WEEK_DAY = {\n Sunday: \"Sunday\",\n Monday: \"Monday\",\n Tuesday: \"Tuesday\",\n Wednesday: \"Wednesday\",\n Thursday: \"Thursday\",\n Friday: \"Friday\",\n Saturday: \"Saturday\",\n} as const;\n\nexport type TWeekDay = TRecordValue<typeof WEEK_DAY>;\n\nexport const WEEK_DAY_SHORT_LABEL = {\n Sunday: \"Sun\",\n Monday: \"Mon\",\n Tuesday: \"Tue\",\n Wednesday: \"Wed\",\n Thursday: \"Thu\",\n Friday: \"Fri\",\n Saturday: \"Sat\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayShortLabel = TRecordValue<typeof WEEK_DAY_SHORT_LABEL>;\n\nexport const WEEK_DAY_LETTER = {\n Sunday: \"S\",\n Monday: \"M\",\n Tuesday: \"T\",\n Wednesday: \"W\",\n Thursday: \"T\",\n Friday: \"F\",\n Saturday: \"S\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayLetter = TRecordValue<typeof WEEK_DAY_LETTER>;\n\nexport interface IWeekDay {\n date: Date;\n dayOfMonth: number;\n day: TWeekDay;\n shortLabel: TWeekDayShortLabel;\n letter: TWeekDayLetter;\n isToday: boolean;\n}\n\nconst createSelectOptions = <TValue extends string>(\n values: readonly TValue[],\n): ISelectOption<TValue>[] =>\n values.map((value) => ({\n label: value,\n value,\n }));\n\nconst getRecordValues = <TRecord extends Record<string, string>>(\n record: TRecord,\n): TRecordValue<TRecord>[] => Object.values(record) as TRecordValue<TRecord>[];\n\nexport const UnitedStatesJurisdictionOptions = createSelectOptions(\n getRecordValues(US_JURISDICTIONS),\n);\n\nexport const StatusOptions: ISelectOption<TStatus>[] = [\n { label: \"Pending\", value: STATUS.PENDING },\n { label: \"In Progress\", value: STATUS.IN_PROGRESS },\n { label: \"Completed\", value: STATUS.COMPLETED },\n { label: \"Overdue\", value: STATUS.OVERDUE },\n { label: \"Active\", value: STATUS.ACTIVE },\n { label: \"Inactive\", value: STATUS.INACTIVE },\n];\n\nexport const SeverityOptions: ISelectOption<TSeverity>[] = [\n { label: \"Low\", value: SEVERITY.LOW },\n { label: \"Medium\", value: SEVERITY.MEDIUM },\n { label: \"High\", value: SEVERITY.HIGH },\n];\n\nexport const ServiceTypeOptions: ISelectOption<TServiceType>[] = [\n { label: \"Property\", value: SERVICE_TYPES.PROPERTY },\n { label: \"Cleaning\", value: SERVICE_TYPES.CLEANING },\n { label: \"Maintenance\", value: SERVICE_TYPES.MAINTENANCE },\n { label: \"Inspection\", value: SERVICE_TYPES.INSPECTION },\n { label: \"Other\", value: SERVICE_TYPES.OTHER },\n];\n\nexport * from \"./paging.types\";\n","import type { TRecordValue } from \"../base\";\n\nexport const COMPANY_RELATIONSHIP_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n} as const;\n\nexport const INVITATION_STATUS = {\n PENDING: \"PENDING\",\n ACCEPTED: \"ACCEPTED\",\n EXPIRED: \"EXPIRED\",\n REVOKED: \"REVOKED\",\n DECLINED: \"DECLINED\",\n} as const;\n\nexport type TInvitationStatus = TRecordValue<typeof INVITATION_STATUS>;\n\nexport type TCompanyRelationshipStatus =\n | TRecordValue<typeof COMPANY_RELATIONSHIP_STATUS>\n | typeof INVITATION_STATUS.PENDING\n | null;\n\nexport const COMPANY_TYPES = {\n PROPERTY_MANAGEMENT: \"PROPERTY_MANAGEMENT\",\n MAINTENANCE: \"MAINTENANCE\",\n CLEANER: \"CLEANER\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TCompanyType = TRecordValue<typeof COMPANY_TYPES>;\n","import type { ICompany, ICompanyWithRelationshipStatus } from \".\";\nimport { COMPANY_TYPES } from \"./constants\";\nimport type {\n IEmptyRouteRequest,\n IMessageResponse,\n TDateTimeString,\n TUSStateCode,\n} from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n requiredUuidField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface ICompanyRouteParams {\n companyId: string;\n}\n\nexport interface ICompanyUserRouteParams {\n userId: string;\n}\n\nexport interface ICompanyInvitationTokenParams {\n token: string;\n}\n\nexport interface ICompanyInvitationIdParams extends ICompanyRouteParams {\n invitationId: string;\n}\n\nexport const CompanyFilter = {\n Active: \"active\",\n Pending: \"pending\",\n All: \"all\",\n} as const;\n\nexport type TCompanyFilter = (typeof CompanyFilter)[keyof typeof CompanyFilter];\n\nexport interface IGetCompaniesQuery {\n companyId?: string;\n search?: string;\n filter?: TCompanyFilter;\n}\n\nconst CompanyTypeValues = Object.values(COMPANY_TYPES);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\nconst InviteUserRoleValues = Object.values(ACCOUNT_TYPE).filter(\n (accountType) => accountType !== ACCOUNT_TYPE.TURNDOWN_ADMIN,\n);\n\nexport const CreateCompanyRequestSchema = createValidationSchema({\n displayName: requiredStringField(\"BlankString\"),\n addressLine1: requiredStringField(\"BlankString\"),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(\"BlankString\"),\n stateCode: requiredEnumField(StateCodeValues, \"BlankString\"),\n postalCode: requiredStringField(\"BlankString\"),\n companyType: requiredEnumField(CompanyTypeValues, \"BlankString\"),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type ICreateCompanyRequest = TInferValidationSchemaInput<\n typeof CreateCompanyRequestSchema\n> & {\n stateCode: TUSStateCode;\n companyType: ICompany[\"companyType\"];\n};\n\nexport interface ICreateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport type IGetCompaniesRequest = IEmptyRouteRequest;\nexport type IGetCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport interface IGetCompanyByIdRequest extends ICompanyRouteParams {}\nexport interface IGetCompanyByIdResponse extends ICompanyWithRelationshipStatus {}\n\nexport const UpdateCompanyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n companyType: optionalEnumField(CompanyTypeValues),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type IUpdateCompanyRequest = TInferValidationSchemaInput<\n typeof UpdateCompanyRequestSchema\n> & {\n stateCode?: TUSStateCode;\n companyType?: ICompany[\"companyType\"];\n};\n\nexport interface IUpdateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport const InviteUserToCompanyRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n role: requiredEnumField(InviteUserRoleValues, \"BlankString\"),\n});\n\nexport type IInviteUserToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteUserToCompanyRequestSchema\n> & {\n role: TAccountType;\n};\n\nexport interface IInviteUserToCompanyResponse extends IMessageResponse {}\n\nexport interface IGetCompanyUsersRequest extends ICompanyRouteParams {}\nexport interface ICompanyUserSummary {\n id: string;\n email: string;\n firstName: string;\n lastName: string | null;\n role: TAccountType;\n}\nexport interface ICompanyWithUsers extends ICompanyWithRelationshipStatus {\n users: ICompanyUserSummary[];\n}\nexport interface IGetCompanyUsersResponse extends ICompanyWithUsers {}\n\nexport interface IGetUserCompaniesRequest extends ICompanyUserRouteParams {}\nexport type IGetUserCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport const InviteCompanyToCompanyRequestSchema = createValidationSchema({\n providerCompanyId: requiredUuidField(),\n message: optionalNullableStringField(),\n});\n\nexport type IInviteCompanyToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteCompanyToCompanyRequestSchema\n>;\n\nexport interface IInviteCompanyToCompanyResponse {\n id: string;\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IValidateCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IValidateCompanyInvitationResponse {\n id: string;\n requesterCompanyId: string;\n providerCompanyId: string;\n invitedBy: string;\n message: string | null;\n expiresAt: TDateTimeString;\n requesterCompanyName: string;\n providerCompanyName: string;\n invitedByName: string;\n}\n\nexport interface IAcceptCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IAcceptCompanyInvitationResponse {\n requesterCompanyId: string;\n providerCompanyId: string;\n requesterCompanyName: string;\n providerCompanyName: string;\n}\n\nexport interface IDeclineCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IDeclineCompanyInvitationResponse extends IMessageResponse {}\n\nexport interface IGetPendingCompanyInvitationsRequest extends ICompanyRouteParams {}\nexport interface ICompanyInvitationSummary extends IValidateCompanyInvitationResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport type IGetPendingCompanyInvitationsResponse = ICompanyInvitationSummary[];\n\nexport interface IRevokeCompanyInvitationRequest extends ICompanyInvitationIdParams {}\nexport interface IRevokeCompanyInvitationResponse extends IMessageResponse {}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\n\nexport const DAMAGE_SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n CRITICAL: \"CRITICAL\",\n} as const;\n\nexport type TDamageSeverity = TRecordValue<typeof DAMAGE_SEVERITY>;\n\nexport const DAMAGE_STATUS = {\n OPEN: \"OPEN\",\n IN_REVIEW: \"IN_REVIEW\",\n ASSIGNED: \"ASSIGNED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n RESOLVED: \"RESOLVED\",\n CLOSED: \"CLOSED\",\n ESCALATED: \"ESCALATED\",\n} as const;\n\nexport type TDamageStatus = TRecordValue<typeof DAMAGE_STATUS>;\n\nexport const WORK_ORDER_PRIORITY = {\n LOW: \"LOW\",\n NORMAL: \"NORMAL\",\n HIGH: \"HIGH\",\n URGENT: \"URGENT\",\n} as const;\n\nexport type TWorkOrderPriority = TRecordValue<typeof WORK_ORDER_PRIORITY>;\n\nexport const WORK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n SCHEDULED: \"SCHEDULED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkOrderStatus = TRecordValue<typeof WORK_ORDER_STATUS>;\n\nexport interface IDamageReport {\n id: string;\n propertyId: string;\n roomId: string;\n workSessionId: string | null;\n cleaningSessionId: string | null;\n reportedBy: string;\n reportedAt: TDateTimeString;\n severity: TDamageSeverity;\n status: TDamageStatus;\n title: string;\n description: string;\n locationDetails: string | null;\n estimatedCost: number | null;\n actualCost: number | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n resolvedAt: TDateTimeString | null;\n resolvedBy: string | null;\n resolutionNotes: string | null;\n requiresProfessional: boolean;\n vendorInfo: string | null;\n insuranceClaimNumber: string | null;\n isTenantResponsible: boolean;\n tenantChargeAmount: number | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n photos?: IDamagePhoto[];\n comments?: IDamageComment[];\n}\n\nexport interface IDamageReportPhoto {\n id: string;\n damageReportId: string;\n photoId: string;\n imageUrl: string | null;\n caption: string | null;\n isBeforePhoto: boolean;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IDamagePhoto extends IDamageReportPhoto {}\n\nexport interface IDamageComment {\n id: string;\n damageReportId: string;\n userId: string;\n userName: string | null;\n comment: string;\n isInternal: boolean;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IDamageReportStatusHistory {\n id: string;\n damageReportId: string;\n previousStatus: TDamageStatus | null;\n newStatus: TDamageStatus;\n changedBy: string;\n reason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IWorkOrder {\n id: string;\n damageReportId: string | null;\n propertyId: string;\n roomId: string | null;\n workOrderNumber: string | null;\n priority: TWorkOrderPriority;\n category: string | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n scheduledDate: TDateTimeString | null;\n scheduledTimeStart: string | null;\n scheduledTimeEnd: string | null;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n completedBy: string | null;\n description: string;\n workPerformed: string | null;\n materialsUsed: string | null;\n laborHours: number | null;\n laborCost: number | null;\n materialsCost: number | null;\n totalCost: number | null;\n status: TWorkOrderStatus;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface ICreateDamageReportInput {\n propertyId: string;\n roomId: string;\n workSessionId?: string;\n reportedBy: string;\n severity: TDamageSeverity;\n title: string;\n description: string;\n locationDetails?: string;\n estimatedCost?: number;\n requiresProfessional?: boolean;\n isTenantResponsible?: boolean;\n tenantChargeAmount?: number;\n}\n\nexport interface ICreateWorkOrderInput {\n damageReportId?: string;\n propertyId: string;\n roomId?: string;\n priority?: TWorkOrderPriority;\n category?: string;\n description: string;\n scheduledDate?: TDateTimeString;\n scheduledTimeStart?: string;\n scheduledTimeEnd?: string;\n}\n\nexport * from \"./routes\";\n","/**\n * Error Types\n * Custom error types and validation error structures.\n */\n\nimport { ERROR_CODES } from \"../api\";\nimport type { TErrorCode } from \"../api\";\nimport type { TJsonObject, TJsonValue } from \"../base\";\n\n/**\n * Detailed information about a validation error.\n */\nexport interface IValidationErrorDetail {\n field: string;\n message: string;\n value?: TJsonValue;\n}\n\n/**\n * Information about missing required fields.\n */\nexport interface IMissingFieldsErrorDetail {\n missingFields: string[];\n}\n\n/**\n * Information about rate limiting.\n */\nexport interface IRateLimitErrorDetail {\n retryAfter?: number;\n message: string;\n}\n\nexport type TErrorResponseDetail =\n | IValidationErrorDetail[]\n | IMissingFieldsErrorDetail\n | IRateLimitErrorDetail\n | TJsonObject\n | string;\n\nexport interface ITypedApiError<TDetails = TErrorResponseDetail> {\n message: string;\n code: TErrorCode;\n details?: TDetails;\n}\n\nexport type TValidationError = ITypedApiError<IValidationErrorDetail[]>;\nexport type TMissingFieldsError = ITypedApiError<IMissingFieldsErrorDetail>;\nexport type TRateLimitError = ITypedApiError<IRateLimitErrorDetail>;\n\ntype TErrorLike = {\n code?: string;\n details?: unknown;\n};\n\nconst isErrorLike = (error: unknown): error is TErrorLike => {\n return typeof error === \"object\" && error !== null;\n};\n\n/**\n * Type guard for validation errors.\n */\nexport function isValidationError(error: unknown): error is TValidationError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.VALIDATION_ERROR &&\n Array.isArray(error.details)\n );\n}\n\n/**\n * Type guard for missing-field errors.\n */\nexport function isMissingFieldsError(\n error: unknown,\n): error is TMissingFieldsError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.MISSING_FIELDS &&\n typeof error.details === \"object\" &&\n error.details !== null &&\n \"missingFields\" in error.details &&\n Array.isArray(error.details.missingFields)\n );\n}\n\n/**\n * Type guard for rate-limit errors.\n */\nexport function isRateLimitError(error: unknown): error is TRateLimitError {\n return isErrorLike(error) && error.code === ERROR_CODES.RATE_LIMIT_EXCEEDED;\n}\n\n/**\n * Type guard for authentication errors.\n */\nexport function isAuthError(error: unknown): boolean {\n return (\n isErrorLike(error) &&\n (error.code === ERROR_CODES.UNAUTHORIZED ||\n error.code === ERROR_CODES.INVALID_TOKEN ||\n error.code === ERROR_CODES.INVALID_CREDENTIALS)\n );\n}\n","import type { TDateTimeString, TEnvironment } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const SERVER_STATUS = {\n Healthy: \"Healthy\",\n Unhealthy: \"UnHealthy\",\n} as const;\n\nexport type TServerStatus = (typeof SERVER_STATUS)[keyof typeof SERVER_STATUS];\n\nexport const DATABASE_STATUS = {\n Unknown: \"Unknown\",\n Connected: \"Connected\",\n Disconnected: \"Disconnected\",\n} as const;\n\nexport type TDatabaseStatus =\n (typeof DATABASE_STATUS)[keyof typeof DATABASE_STATUS];\n\nexport interface IHealthCheckResponse {\n status: TServerStatus;\n database: TDatabaseStatus;\n timestamp: TDateTimeString;\n environment: TEnvironment;\n}\n\nexport interface IHealthChecks {\n database: TDatabaseStatus;\n uptime: number;\n memory: {\n rss: number;\n heapTotal: number;\n heapUsed: number;\n external: number;\n arrayBuffers: number;\n };\n timestamp: TDateTimeString;\n databaseError?: string;\n}\n","import type { TDateTimeString } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const IMAGE_ENTITY_TYPE = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TStoredImageEntityType =\n (typeof IMAGE_ENTITY_TYPE)[keyof typeof IMAGE_ENTITY_TYPE];\n\nexport interface IImage {\n id: string;\n entityType: TStoredImageEntityType;\n entityId: string;\n fileName: string;\n mimeType: string;\n fileSizeBytes: number | null;\n width: number | null;\n height: number | null;\n isPublic: boolean;\n category: string | null;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport interface IImageWithUrl extends IImage {\n url: string;\n}\n","import type { IMetaData, TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\nexport const INVENTORY_RESTOCK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n ORDERED: \"ORDERED\",\n SHIPPED: \"SHIPPED\",\n RECEIVED: \"RECEIVED\",\n} as const;\n\nexport type TInventoryRestockOrderStatus = TRecordValue<\n typeof INVENTORY_RESTOCK_ORDER_STATUS\n>;\n\nexport const INVENTORY_UNITS = {\n COUNT: \"COUNT\",\n ROLLS: \"ROLLS\",\n PODS: \"PODS\",\n BOXES: \"BOXES\",\n BOTTLES: \"BOTTLES\",\n PACKS: \"PACKS\",\n BAGS: \"BAGS\",\n GALLONS: \"GALLONS\",\n LITERS: \"LITERS\",\n KILOGRAMS: \"KILOGRAMS\",\n POUNDS: \"POUNDS\",\n OUNCES: \"OUNCES\",\n GRAMS: \"GRAMS\",\n SHEETS: \"SHEETS\",\n CASES: \"CASES\",\n CARTONS: \"CARTONS\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TInventoryUnitType = TRecordValue<typeof INVENTORY_UNITS>;\n\nexport const INVENTORY_ITEM_TYPE = {\n CONSUMABLE: \"CONSUMABLE\",\n FIXED: \"FIXED\",\n} as const;\n\nexport type TInventoryItemType = TRecordValue<typeof INVENTORY_ITEM_TYPE>;\n\nexport interface IInventoryItem extends IMetaData {\n id: string;\n companyId: string;\n name: string;\n description: string | null;\n itemType: TInventoryItemType;\n unit: TInventoryUnitType;\n unitCustom: string | null;\n minimumLevel: number;\n reorderLevel: number;\n maximumLevel: number | null;\n costPerUnit: number | null;\n supplierInfo: string | null;\n sku: string | null;\n barcode: string | null;\n}\n\nexport interface IRoomInventory extends IMetaData {\n id: string;\n roomId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IPropertyInventory extends IMetaData {\n id: string;\n propertyId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IInventoryCount {\n id: string;\n checklistExecutionId: string;\n roomInventoryId: string;\n previousLevel: number;\n countedLevel: number;\n consumedAmount: number;\n restockedAmount: number;\n finalLevel: number;\n countedBy: string;\n countedAt: TDateTimeString;\n needsRestock: boolean;\n notes: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrder {\n id: string;\n companyId: string;\n orderNumber: string | null;\n status: TInventoryRestockOrderStatus;\n totalItems: number | null;\n totalCost: number | null;\n orderedBy: string | null;\n orderedAt: TDateTimeString | null;\n expectedDelivery: TDateTimeString | null;\n receivedBy: string | null;\n receivedAt: TDateTimeString | null;\n supplierInfo: string | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrderItem {\n id: string;\n orderId: string;\n inventoryItemId: string;\n roomInventoryId: string | null;\n propertyInventoryId: string | null;\n quantityOrdered: number;\n quantityReceived: number;\n unitCost: number | null;\n totalCost: number | null;\n createdAt: TDateTimeString;\n}\n","import type { ISelectOption, TRecordValue } from \"../base\";\n\nexport const PROPERTY_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TPropertyStatus = TRecordValue<typeof PROPERTY_STATUS>;\n\nexport const PropertyStatusOptions: ISelectOption<TPropertyStatus>[] = [\n {\n label: \"Active\",\n value: PROPERTY_STATUS.ACTIVE,\n },\n {\n label: \"Inactive\",\n value: PROPERTY_STATUS.INACTIVE,\n },\n];\n\nexport const PROPERTY_TYPES = {\n APARTMENT: \"APARTMENT\",\n COMMERCIAL: \"COMMERCIAL\",\n CONDO: \"CONDO\",\n DUPLEX: \"DUPLEX\",\n HOUSE: \"HOUSE\",\n MULTI_FAMILY: \"MULTI_FAMILY\",\n OFFICE: \"OFFICE\",\n RETAIL: \"RETAIL\",\n TOWNHOUSE: \"TOWNHOUSE\",\n VACATION_RENTAL: \"VACATION_RENTAL\",\n WAREHOUSE: \"WAREHOUSE\",\n} as const;\n\nexport type TPropertyType = TRecordValue<typeof PROPERTY_TYPES>;\n\nexport const PropertyTypeOptions: ISelectOption<TPropertyType>[] = [\n {\n label: \"Apartment\",\n value: PROPERTY_TYPES.APARTMENT,\n },\n {\n label: \"Commercial\",\n value: PROPERTY_TYPES.COMMERCIAL,\n },\n {\n label: \"Condo\",\n value: PROPERTY_TYPES.CONDO,\n },\n {\n label: \"Duplex\",\n value: PROPERTY_TYPES.DUPLEX,\n },\n {\n label: \"House\",\n value: PROPERTY_TYPES.HOUSE,\n },\n {\n label: \"Multi-Family\",\n value: PROPERTY_TYPES.MULTI_FAMILY,\n },\n {\n label: \"Office\",\n value: PROPERTY_TYPES.OFFICE,\n },\n {\n label: \"Retail\",\n value: PROPERTY_TYPES.RETAIL,\n },\n {\n label: \"Townhouse\",\n value: PROPERTY_TYPES.TOWNHOUSE,\n },\n {\n label: \"Vacation Rental\",\n value: PROPERTY_TYPES.VACATION_RENTAL,\n },\n {\n label: \"Warehouse\",\n value: PROPERTY_TYPES.WAREHOUSE,\n },\n];\n","import type {\n IProperty,\n IPropertyAccessInformation,\n IPropertyDetail,\n IPropertySummary,\n TPropertyStatus,\n TPropertyType,\n} from \".\";\nimport { PROPERTY_STATUS, PROPERTY_TYPES } from \"./constants\";\nimport type { IMessageResponse, TUSStateCode } from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableEnumField,\n optionalNullableNonNegativeIntegerField,\n optionalNullableStringField,\n optionalStringField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IPropertyIdParams {\n propertyId: string;\n}\n\nexport interface ICompanyIdParams {\n companyId: string;\n}\n\nconst PropertyTypeValues = Object.values(PROPERTY_TYPES);\nconst PropertyStatusValues = Object.values(PROPERTY_STATUS);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\n\nexport const CreatePropertyRequestSchema = createValidationSchema({\n companyId: requiredStringField(),\n displayName: requiredStringField(),\n propertyType: requiredEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: requiredStringField(),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(),\n stateCode: requiredEnumField(StateCodeValues),\n postalCode: requiredStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type ICreatePropertyRequest = TInferValidationSchemaInput<\n typeof CreatePropertyRequestSchema\n> & {\n companyId: string;\n propertyType: TPropertyType;\n status?: TPropertyStatus | null;\n stateCode: TUSStateCode;\n};\n\nexport const UpdatePropertyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n propertyType: optionalNullableEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type IUpdatePropertyRequest = TInferValidationSchemaInput<\n typeof UpdatePropertyRequestSchema\n> & {\n propertyType?: TPropertyType | null;\n status?: TPropertyStatus | null;\n stateCode?: TUSStateCode;\n};\n\nexport interface IGetPropertiesRequest {\n companyId?: string;\n}\n\nexport interface IGetPropertyByIdRequest extends IPropertyIdParams {}\n\nexport interface IDeletePropertyRequest extends IPropertyIdParams {}\n\nexport type IGetPropertiesResponse = IPropertySummary[];\n\nexport interface IGetPropertyResponse extends IPropertyDetail {}\n\nexport interface ICreatePropertyResponse extends IPropertyDetail {}\n\nexport interface IUpdatePropertyResponse extends IPropertyDetail {}\n\nexport interface IDeletePropertyResponse extends IMessageResponse {}\n\nexport const UpdatePropertyAccessInformationRequestSchema =\n createValidationSchema({\n entryInstructions: optionalNullableStringField(),\n accessCode: optionalNullableStringField(),\n wifiName: optionalNullableStringField(),\n wifiPassword: optionalNullableStringField(),\n alarmCode: optionalNullableStringField(),\n parkingInfo: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n });\n\nexport type IUpdatePropertyAccessInformationRequest =\n TInferValidationSchemaInput<\n typeof UpdatePropertyAccessInformationRequestSchema\n >;\n\nexport interface IUpdatePropertyAccessInformationResponse extends IPropertyAccessInformation {}\n\nexport interface IGetPropertyAccessInformationRequest extends IPropertyIdParams {}\n\nexport type IGetPropertyAccessInformationResponse =\n IPropertyAccessInformation | null;\n\nexport interface IGetPropertyByIdResponse extends IGetPropertyResponse {}\n\nexport interface IGetPropertiesByCompanyIdRequest extends ICompanyIdParams {}\nexport type IGetPropertiesByCompanyIdResponse = IProperty[];\n","import type { TRecordValue } from \"../base\";\n\nexport const ROOM_TYPE = {\n BEDROOM: \"BEDROOM\",\n BATHROOM: \"BATHROOM\",\n KITCHEN: \"KITCHEN\",\n LIVING_ROOM: \"LIVING_ROOM\",\n DINING_ROOM: \"DINING_ROOM\",\n OFFICE: \"OFFICE\",\n GARAGE: \"GARAGE\",\n LAUNDRY_ROOM: \"LAUNDRY_ROOM\",\n BASEMENT: \"BASEMENT\",\n ATTIC: \"ATTIC\",\n BALCONY: \"BALCONY\",\n PORCH: \"PORCH\",\n GARDEN: \"GARDEN\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TRoomType = TRecordValue<typeof ROOM_TYPE>;\n","import type { IRoom } from \".\";\nimport { ROOM_TYPE } from \"./constants\";\nimport type { IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IRoomPropertyRouteParams {\n propertyId: string;\n}\n\nexport interface IRoomRouteParams {\n roomId: string;\n}\n\nconst RoomTypeValues = Object.values(ROOM_TYPE);\n\nexport const CreateRoomRequestSchema = createValidationSchema({\n propertyId: requiredStringField(),\n displayName: requiredStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type ICreateRoomRequest = TInferValidationSchemaInput<\n typeof CreateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface ICreateRoomResponse extends IRoom {}\n\nexport interface IGetRoomsRequest {\n propertyId?: string;\n}\n\nexport interface IGetRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetDetailedRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetDetailedRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetRoomByIdRequest extends IRoomRouteParams {}\nexport interface IGetRoomByIdResponse extends IRoom {}\n\nexport const UpdateRoomRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type IUpdateRoomRequest = TInferValidationSchemaInput<\n typeof UpdateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface IUpdateRoomResponse extends IRoom {}\n\nexport interface IDeleteRoomRequest extends IRoomRouteParams {}\nexport interface IDeleteRoomResponse extends IMessageResponse {}\n","import type {\n ICompanyBillingSummary,\n IEntitlementSnapshot,\n IProviderProduct,\n ISubscriptionProductSummary,\n TSubscriptionProvider,\n} from \".\";\nimport type { IMessageResponse, TJsonObject } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableStringField,\n optionalRecordField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IBillingCompanyRouteParams {\n companyId: string;\n}\n\nexport interface IGetBillingProductsRequest {}\nexport type IGetBillingProductsResponse = ISubscriptionProductSummary[];\n\nexport interface IGetCompanyBillingSummaryRequest\n extends IBillingCompanyRouteParams {}\nexport interface IGetCompanyBillingSummaryResponse\n extends ICompanyBillingSummary {}\n\nexport const CreateStripeCheckoutSessionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n successUrl: requiredStringField(\"BlankString\"),\n cancelUrl: requiredStringField(\"BlankString\"),\n});\n\nexport type ICreateStripeCheckoutSessionRequest =\n TInferValidationSchemaInput<\n typeof CreateStripeCheckoutSessionRequestSchema\n >;\n\nexport interface ICreateStripeCheckoutSessionResponse {\n checkoutUrl: string;\n}\n\nexport const SyncAppleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n transactionId: requiredStringField(\"BlankString\"),\n originalTransactionId: optionalNullableStringField(),\n signedTransactionInfo: requiredStringField(\"BlankString\"),\n});\n\nexport type ISyncAppleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncAppleSubscriptionRequestSchema\n>;\n\nexport const SyncGoogleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n purchaseToken: requiredStringField(\"BlankString\"),\n packageName: requiredStringField(\"BlankString\"),\n providerPriceId: optionalNullableStringField(),\n});\n\nexport type ISyncGoogleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncGoogleSubscriptionRequestSchema\n>;\n\nexport interface ISyncStoreSubscriptionResponse {\n subscription: ICompanyBillingSummary[\"subscription\"];\n entitlement: IEntitlementSnapshot;\n}\n\nexport const BillingProviderWebhookRequestSchema = createValidationSchema({\n providerEventId: requiredStringField(\"BlankString\"),\n eventType: requiredStringField(\"BlankString\"),\n providerSubscriptionId: optionalNullableStringField(),\n providerTransactionId: optionalNullableStringField(),\n providerRefundId: optionalNullableStringField(),\n payload: optionalRecordField(),\n});\n\nexport type IBillingProviderWebhookRequest = TInferValidationSchemaInput<\n typeof BillingProviderWebhookRequestSchema\n> & {\n payload?: TJsonObject;\n};\n\nexport interface IBillingProviderWebhookResponse extends IMessageResponse {}\n\nexport interface IProviderProductLookupRequest {\n provider: TSubscriptionProvider;\n providerProductId: string;\n}\n\nexport interface IProviderProductLookupResponse extends IProviderProduct {}\n\nexport const BillingProviderValues = [\n \"STRIPE\",\n \"APPLE\",\n \"GOOGLE\",\n \"MANUAL\",\n] as const;\n\nexport const ProviderProductLookupRequestSchema = createValidationSchema({\n provider: requiredEnumField(BillingProviderValues, \"BlankString\"),\n providerProductId: requiredStringField(\"BlankString\"),\n});\n","import type {\n IMetaData,\n TDateTimeString,\n TJsonObject,\n TRecordValue,\n} from \"../base\";\n\nexport const SUBSCRIPTION_PLAN = {\n Free: \"FREE\",\n Starter: \"STARTER\",\n Pro: \"PRO\",\n Business: \"BUSINESS\",\n} as const;\n\nexport type TSubscriptionPlan = TRecordValue<typeof SUBSCRIPTION_PLAN>;\n\nexport const SUBSCRIPTION_STATUS = {\n ACTIVE: \"ACTIVE\",\n CANCELED: \"CANCELED\",\n EXPIRED: \"EXPIRED\",\n PAST_DUE: \"PAST_DUE\",\n TRIALING: \"TRIALING\",\n GRACE_PERIOD: \"GRACE_PERIOD\",\n REFUNDED: \"REFUNDED\",\n} as const;\n\nexport type TSubscriptionStatus = TRecordValue<typeof SUBSCRIPTION_STATUS>;\n\nexport const SUBSCRIPTION_PROVIDER = {\n STRIPE: \"STRIPE\",\n APPLE: \"APPLE\",\n GOOGLE: \"GOOGLE\",\n MANUAL: \"MANUAL\",\n} as const;\n\nexport type TSubscriptionProvider = TRecordValue<typeof SUBSCRIPTION_PROVIDER>;\n\nexport const BILLING_PERIOD = {\n MONTHLY: \"MONTHLY\",\n YEARLY: \"YEARLY\",\n} as const;\n\nexport type TBillingPeriod = TRecordValue<typeof BILLING_PERIOD>;\n\nexport const REFUND_STATUS = {\n REQUESTED: \"REQUESTED\",\n APPROVED: \"APPROVED\",\n DECLINED: \"DECLINED\",\n PROCESSED: \"PROCESSED\",\n} as const;\n\nexport type TRefundStatus = TRecordValue<typeof REFUND_STATUS>;\n\nexport const SUBSCRIPTION_FEATURE = {\n CreateProperty: \"CREATE_PROPERTY\",\n InviteTeamMember: \"INVITE_TEAM_MEMBER\",\n CreateChecklistTemplate: \"CREATE_CHECKLIST_TEMPLATE\",\n UploadImage: \"UPLOAD_IMAGE\",\n} as const;\n\nexport type TSubscriptionFeature = TRecordValue<typeof SUBSCRIPTION_FEATURE>;\n\nexport interface ISubscriptionPlan extends IMetaData {\n id: string;\n code: TSubscriptionPlan;\n displayName: string;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n isActive: boolean;\n}\n\nexport interface IProviderProduct extends IMetaData {\n id: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerProductId: string;\n providerPriceId: string | null;\n billingPeriod: TBillingPeriod;\n trialDays: number;\n isActive: boolean;\n}\n\nexport interface ISubscriptionProductSummary {\n plan: ISubscriptionPlan;\n products: IProviderProduct[];\n}\n\nexport interface IBillingAccount extends IMetaData {\n id: string;\n companyId: string;\n billingAdminUserId: string | null;\n}\n\nexport interface ICompanySubscription extends IMetaData {\n id: string;\n billingAccountId: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string | null;\n providerOriginalTransactionId: string | null;\n providerPurchaseToken: string | null;\n providerCustomerId: string | null;\n providerPriceId: string | null;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString | null;\n currentPeriodEnd: TDateTimeString | null;\n trialStart: TDateTimeString | null;\n trialEnd: TDateTimeString | null;\n cancelAtPeriodEnd: boolean;\n canceledAt: TDateTimeString | null;\n refundedAt: TDateTimeString | null;\n latestEventAt: TDateTimeString | null;\n}\n\nexport interface ISubscriptionEvent extends IMetaData {\n id: string;\n subscriptionId: string | null;\n provider: TSubscriptionProvider;\n providerEventId: string;\n eventType: string;\n rawPayload: TJsonObject;\n processedAt: TDateTimeString;\n}\n\nexport interface IEntitlementSnapshot {\n id: string;\n companyId: string;\n subscriptionId: string | null;\n planCode: TSubscriptionPlan;\n status: TSubscriptionStatus;\n effectiveFrom: TDateTimeString;\n effectiveUntil: TDateTimeString | null;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n sourceEventId: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IRefund extends IMetaData {\n id: string;\n subscriptionId: string;\n provider: TSubscriptionProvider;\n providerRefundId: string | null;\n providerTransactionId: string | null;\n amount: number | null;\n currency: string | null;\n reason: string | null;\n status: TRefundStatus;\n refundedAt: TDateTimeString | null;\n rawPayload: TJsonObject | null;\n}\n\nexport interface ICompanyBillingSummary {\n billingAccount: IBillingAccount | null;\n subscription: ICompanySubscription | null;\n entitlement: IEntitlementSnapshot;\n}\n\n/**\n * @deprecated Use ICompanySubscription for company-scoped SaaS access.\n */\nexport interface IUserSubscription {\n id: string;\n userId: string;\n planId: string;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString;\n currentPeriodEnd: TDateTimeString;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string;\n cancelAtPeriodEnd: boolean;\n}\n\nexport * from \"./routes\";\n","import type { IUser, TAccountType } from \".\";\nimport { LANGUAGE } from \"./constants\";\nimport type { IEmptyRouteRequest, IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IUserIdParams {\n id: string;\n}\n\nexport interface IGetUserResponse {\n user: IUser | null;\n}\n\nexport type IGetCurrentUserRequest = IEmptyRouteRequest;\nexport interface IGetCurrentUserResponse extends IGetUserResponse {}\n\nexport interface IGetUserByIdRequest extends IUserIdParams {}\nexport interface IGetUserByIdResponse extends IGetUserResponse {}\n\nexport interface IGetUserByEmailRequest {\n email: string;\n}\nexport interface IGetUserByEmailResponse extends IGetUserResponse {}\n\nexport type IGetStaffRequest = IEmptyRouteRequest;\nexport interface IGetStaffResponse {\n staff: IUser[];\n}\n\nconst LanguageValues = Object.values(LANGUAGE);\n\nexport const UpdateUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalNullableStringField(),\n mi: optionalNullableStringField(),\n username: optionalNullableStringField(),\n email: optionalStringField(),\n phoneNumber: optionalNullableStringField(),\n phoneFormat: optionalNullableStringField(),\n preferredLanguage: optionalEnumField(LanguageValues),\n});\n\nexport type IUpdateUserRequest = TInferValidationSchemaInput<\n typeof UpdateUserRequestSchema\n> & {\n preferredLanguage?: IUser[\"preferredLanguage\"];\n};\n\nexport const UpdateCurrentUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalStringField(),\n});\n\nexport type IUpdateCurrentUserRequest = TInferValidationSchemaInput<\n typeof UpdateCurrentUserRequestSchema\n>;\n\nexport interface IUpdateUserResponse {\n user: IUser;\n}\n\nexport type IDeleteUserRequest = IEmptyRouteRequest;\nexport interface IDeleteUserResponse extends IMessageResponse {}\n\nexport interface IGetUsersByAccountTypeRequest {\n accountType: TAccountType;\n}\nexport interface IGetUsersByAccountTypeResponse {\n users: IUser[];\n}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\n/**\n * Work session status enum.\n */\nexport const WORK_SESSION_STATUS = {\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkSessionStatus = TRecordValue<typeof WORK_SESSION_STATUS>;\n\n/**\n * Checklist execution status enum.\n */\nexport const CHECKLIST_EXECUTION_STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n SKIPPED: \"SKIPPED\",\n} as const;\n\nexport type TChecklistExecutionStatus = TRecordValue<\n typeof CHECKLIST_EXECUTION_STATUS\n>;\n\n/**\n * Work session.\n */\nexport interface IWorkSession {\n id: string;\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n status: TWorkSessionStatus;\n scheduledDate: TDateTimeString | null;\n startedAt: TDateTimeString;\n completedAt: TDateTimeString | null;\n totalTimeMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist execution.\n */\nexport interface IChecklistExecution {\n id: string;\n workSessionId: string;\n roomChecklistId: string;\n roomId: string;\n workerId: string;\n status: TChecklistExecutionStatus;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n timeSpentMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist item completion.\n */\nexport interface IChecklistItemCompletion {\n id: string;\n checklistExecutionId: string;\n roomChecklistItemId: string;\n completedBy: string;\n completedAt: TDateTimeString;\n photoId: string | null;\n notes: string | null;\n skipped: boolean;\n skipReason: string | null;\n createdAt: TDateTimeString;\n}\n\n/**\n * Work session with executions.\n */\nexport interface IWorkSessionWithExecutions extends IWorkSession {\n executions: IChecklistExecution[];\n}\n\n/**\n * Input for creating a work session.\n */\nexport interface ICreateWorkSessionInput {\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n scheduledDate?: TDateTimeString;\n notes?: string;\n}\n\n/**\n * Input for completing a checklist item.\n */\nexport interface ICompleteChecklistItemInput {\n roomChecklistItemId: string;\n completedBy: string;\n photoId?: string;\n notes?: string;\n skipped?: boolean;\n skipReason?: string;\n}\n"],"mappings":";AAOO,IAAM,cAAc;AAAA,EACzB,KAAK;AAAA,EACL,MAAM;AAAA,EACN,KAAK;AAAA,EACL,OAAO;AAAA,EACP,QAAQ;AACV;AAQO,IAAM,cAAc;AAAA,EACzB,aAAa;AAAA,EACb,kBAAkB;AAAA,EAClB,gBAAgB;AAAA,EAChB,cAAc;AAAA,EACd,eAAe;AAAA,EACf,qBAAqB;AAAA,EACrB,WAAW;AAAA,EACX,WAAW;AAAA,EACX,UAAU;AAAA,EACV,gBAAgB;AAAA,EAChB,YAAY;AAAA,EACZ,qBAAqB;AAAA,EACrB,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAQO,IAAM,cAAc;AAAA,EACzB,IAAI;AAAA,EACJ,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,cAAc;AAAA,EACd,WAAW;AAAA,EACX,UAAU;AAAA,EACV,UAAU;AAAA,EACV,qBAAqB;AAAA,EACrB,iBAAiB;AAAA,EACjB,eAAe;AACjB;;;ACeO,IAAM,yBAAyB,CACpC,WACsC;AACtC,QAAM,gBAAgB,OAAO,KAAK,MAAM;AACxC,QAAM,iBAAiB,cAAc,OAAO,CAAC,cAAc;AACzD,WAAO,OAAO,SAAS,EAAE;AAAA,EAC3B,CAAC;AAED,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA,UAAU,CAAC,OAAO,UAAU,CAAC,MAAM;AACjC,UAAI,CAAC,SAAS,KAAK,GAAG;AACpB,eAAO;AAAA,UACL,SAAS;AAAA,UACT,QAAQ;AAAA,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AA,EAC3B,WAAW;AAAA,EACX,UAAU;AAAA,EACV,UAAU;AAAA,EACV,WAAW;AACb;AAIO,IAAM,uBAAuB;AAAA,EAClC,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,yBAAyB;AAAA,EACzB,aAAa;AACf;;;ACvBA,IAAM,iBAAiB,OAAO,OAAO,QAAQ;AAEtC,IAAM,0BAA0B,uBAAuB;AAAA,EAC5D,WAAW,oBAAoB;AAAA,EAC/B,UAAU,4BAA4B;AAAA,EACtC,IAAI,4BAA4B;AAAA,EAChC,UAAU,4BAA4B;AAAA,EACtC,OAAO,oBAAoB;AAAA,EAC3B,aAAa,4BAA4B;AAAA,EACzC,aAAa,4BAA4B;AAAA,EACzC,mBAAmB,kBAAkB,cAAc;AACrD,CAAC;AAQM,IAAM,iCAAiC,uBAAuB;AAAA,EACnE,WAAW,oBAAoB;AAAA,EAC/B,UAAU,oBAAoB;AAChC,CAAC;;;ACnDM,IAAM,sBAAsB;AAAA,EACjC,aAAa;AAAA,EACb,WAAW;AAAA,EACX,WAAW;AACb;AAOO,IAAM,6BAA6B;AAAA,EACxC,SAAS;AAAA,EACT,aAAa;AAAA,EACb,WAAW;AAAA,EACX,SAAS;AACX;","names":["StateCodeValues"]}
|
|
1
|
+
{"version":3,"sources":["../../src/types/api/index.ts","../../src/types/validation/index.ts","../../src/types/user/constants.ts","../../src/types/auth/routes.ts","../../src/types/auth/index.ts","../../src/types/base/paging.types.ts","../../src/types/base/index.ts","../../src/types/company/constants.ts","../../src/types/company/routes.ts","../../src/types/damage-report/index.ts","../../src/types/errors/index.ts","../../src/types/health/index.ts","../../src/types/image/index.ts","../../src/types/inventory/index.ts","../../src/types/property/constants.ts","../../src/types/property/routes.ts","../../src/types/room/constants.ts","../../src/types/room/routes.ts","../../src/types/subscription/routes.ts","../../src/types/subscription/index.ts","../../src/types/user/routes.ts","../../src/types/work-session/index.ts"],"sourcesContent":["/**\n * API Response Types\n * Standard response structure for all API endpoints.\n */\n\nimport type { TDateTimeString, TEnvironment, TJsonValue } from \"../base\";\n\nexport const HTTP_METHOD = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n PATCH: \"PATCH\",\n DELETE: \"DELETE\",\n} as const;\n\nexport type THttpMethod = (typeof HTTP_METHOD)[keyof typeof HTTP_METHOD];\n\n/**\n * Error Codes\n * Standardized error codes used across the platform.\n */\nexport const ERROR_CODES = {\n BAD_REQUEST: \"BAD_REQUEST\",\n VALIDATION_ERROR: \"VALIDATION_ERROR\",\n MISSING_FIELDS: \"MISSING_FIELDS\",\n UNAUTHORIZED: \"UNAUTHORIZED\",\n INVALID_TOKEN: \"INVALID_TOKEN\",\n INVALID_CREDENTIALS: \"INVALID_CREDENTIALS\",\n FORBIDDEN: \"FORBIDDEN\",\n NOT_FOUND: \"NOT_FOUND\",\n CONFLICT: \"CONFLICT\",\n ALREADY_EXISTS: \"ALREADY_EXISTS\",\n RATE_LIMIT: \"RATE_LIMIT\",\n RATE_LIMIT_EXCEEDED: \"RATE_LIMIT_EXCEEDED\",\n INTERNAL_ERROR: \"INTERNAL_ERROR\",\n DATABASE_ERROR: \"DATABASE_ERROR\",\n NOT_IMPLEMENTED: \"NOT_IMPLEMENTED\",\n} as const;\n\nexport type TErrorCode = (typeof ERROR_CODES)[keyof typeof ERROR_CODES];\n\n/**\n * HTTP Status Codes\n * Common status codes used in API responses.\n */\nexport const HTTP_STATUS = {\n Ok: 200,\n Created: 201,\n NoContent: 204,\n BadRequest: 400,\n Unauthorized: 401,\n Forbidden: 403,\n NotFound: 404,\n Conflict: 409,\n UnprocessableEntity: 422,\n TooManyRequests: 429,\n InternalError: 500,\n} as const;\n\nexport type THttpStatusCode = (typeof HTTP_STATUS)[keyof typeof HTTP_STATUS];\n\nexport type TApiErrorDetails = TJsonValue;\n\nexport interface IApiError<TDetails = TApiErrorDetails> {\n message: string;\n code?: TErrorCode;\n details?: TDetails;\n}\n\nexport interface IApiMeta {\n timestamp: TDateTimeString;\n version: string;\n environment: TEnvironment;\n requestId?: string;\n}\n\nexport interface IApiSuccessResponse<TData = null> {\n success: true;\n data: TData;\n meta: IApiMeta;\n}\n\nexport interface IApiErrorResponse<TErrorDetails = TApiErrorDetails> {\n success: false;\n error: IApiError<TErrorDetails>;\n meta: IApiMeta;\n}\n\nexport type IApiResponse<TData = null, TErrorDetails = TApiErrorDetails> =\n | IApiSuccessResponse<TData>\n | IApiErrorResponse<TErrorDetails>;\n","export type TValidationIssueType =\n | \"INVALID_BODY\"\n | \"MISSING_FIELD\"\n | \"INVALID_FIELD\"\n | \"UNSUPPORTED_FIELD\";\n\nexport interface IValidationIssue<TFieldName extends string = string> {\n fieldName: TFieldName;\n type: TValidationIssueType;\n}\n\nexport interface IValidationResult<TValue extends object> {\n success: boolean;\n data?: TValue;\n issues: IValidationIssue[];\n}\n\nexport type TMissingValuePolicy = \"Nullish\" | \"BlankString\";\n\nexport interface IValidationField<TValue, TRequired extends boolean> {\n readonly valueType?: TValue;\n required: TRequired;\n missingValuePolicy: TMissingValuePolicy;\n validate: (value: unknown) => boolean;\n}\n\nexport type TValidationFieldMap = Record<\n string,\n IValidationField<unknown, boolean>\n>;\n\ntype TRequiredSchemaKeys<TFields extends TValidationFieldMap> = {\n [TKey in keyof TFields]: TFields[TKey] extends IValidationField<unknown, true>\n ? TKey\n : never;\n}[keyof TFields];\n\ntype TOptionalSchemaKeys<TFields extends TValidationFieldMap> = Exclude<\n keyof TFields,\n TRequiredSchemaKeys<TFields>\n>;\n\ntype TFieldValue<TField> =\n TField extends IValidationField<infer TValue, boolean> ? TValue : never;\n\nexport type TInferValidationFields<TFields extends TValidationFieldMap> = {\n [TKey in TRequiredSchemaKeys<TFields>]: TFieldValue<TFields[TKey]>;\n} & {\n [TKey in TOptionalSchemaKeys<TFields>]?: TFieldValue<TFields[TKey]>;\n};\n\nexport type TInferValidationSchemaInput<TSchema> =\n TSchema extends IRuntimeValidationSchema<infer TFields>\n ? TInferValidationFields<TFields>\n : never;\n\nexport interface IRuntimeValidationSchema<\n TFields extends TValidationFieldMap = TValidationFieldMap,\n> {\n fields: TFields;\n allowedFields: readonly Extract<keyof TFields, string>[];\n requiredFields: readonly Extract<TRequiredSchemaKeys<TFields>, string>[];\n validate: (\n value: unknown,\n options?: IRuntimeValidationOptions,\n ) => IValidationResult<TInferValidationFields<TFields>>;\n}\n\nexport interface IRuntimeValidationOptions {\n rejectUnknownFields?: boolean;\n}\n\nexport const createValidationSchema = <TFields extends TValidationFieldMap>(\n fields: TFields,\n): IRuntimeValidationSchema<TFields> => {\n const allowedFields = Object.keys(fields) as Extract<keyof TFields, string>[];\n const requiredFields = allowedFields.filter((fieldName) => {\n return fields[fieldName].required;\n }) as Extract<TRequiredSchemaKeys<TFields>, string>[];\n\n return {\n fields,\n allowedFields,\n requiredFields,\n validate: (value, options = {}) => {\n if (!isRecord(value)) {\n return {\n success: false,\n issues: [\n {\n fieldName: \"body\",\n type: \"INVALID_BODY\",\n },\n ],\n };\n }\n\n const issues = getValidationIssues(fields, value, options);\n\n if (issues.length > 0) {\n return {\n success: false,\n issues,\n };\n }\n\n return {\n success: true,\n data: value as TInferValidationFields<TFields>,\n issues: [],\n };\n },\n };\n};\n\nexport const requiredStringField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isNonEmptyString,\n});\n\nexport const optionalStringField = (): IValidationField<string, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isNonEmptyString,\n});\n\nexport const optionalNullableStringField = (): IValidationField<\n string | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is string | null => {\n return value === null || isNonEmptyString(value);\n },\n});\n\nexport const requiredEmailField = (\n missingValuePolicy: TMissingValuePolicy = \"BlankString\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isEmail,\n});\n\nexport const requiredUuidField = (\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<string, true> => ({\n required: true,\n missingValuePolicy,\n validate: isUuid,\n});\n\nexport const optionalNullableNonNegativeIntegerField = (): IValidationField<\n number | null,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is number | null => {\n return value === null || (Number.isInteger(value) && Number(value) >= 0);\n },\n});\n\nexport const optionalRecordField = (): IValidationField<\n Record<string, unknown>,\n false\n> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: isRecord,\n});\n\nexport const requiredEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n missingValuePolicy: TMissingValuePolicy = \"Nullish\",\n): IValidationField<TValue, true> => ({\n required: true,\n missingValuePolicy,\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue => {\n return isAllowedStringValue(value, allowedValues);\n },\n});\n\nexport const optionalNullableEnumField = <TValue extends string>(\n allowedValues: readonly TValue[],\n): IValidationField<TValue | null, false> => ({\n required: false,\n missingValuePolicy: \"Nullish\",\n validate: (value): value is TValue | null => {\n return value === null || isAllowedStringValue(value, allowedValues);\n },\n});\n\nconst getValidationIssues = <TFields extends TValidationFieldMap>(\n fields: TFields,\n value: Record<string, unknown>,\n options: IRuntimeValidationOptions,\n): IValidationIssue[] => {\n const allowedFieldSet = new Set(Object.keys(fields));\n const issues: IValidationIssue[] = [];\n\n Object.entries(fields).forEach(([fieldName, field]) => {\n const fieldValue = value[fieldName];\n\n if (\n field.required &&\n isMissingValue(fieldValue, field.missingValuePolicy)\n ) {\n issues.push({\n fieldName,\n type: \"MISSING_FIELD\",\n });\n return;\n }\n\n if (fieldValue === undefined) {\n return;\n }\n\n if (!field.validate(fieldValue)) {\n issues.push({\n fieldName,\n type: \"INVALID_FIELD\",\n });\n }\n });\n\n if (options.rejectUnknownFields === true) {\n Object.keys(value).forEach((fieldName) => {\n if (!allowedFieldSet.has(fieldName)) {\n issues.push({\n fieldName,\n type: \"UNSUPPORTED_FIELD\",\n });\n }\n });\n }\n\n return issues;\n};\n\nconst isRecord = (value: unknown): value is Record<string, unknown> => {\n return typeof value === \"object\" && value !== null && !Array.isArray(value);\n};\n\nconst isMissingValue = (\n value: unknown,\n missingValuePolicy: TMissingValuePolicy,\n): boolean => {\n if (value === undefined || value === null) {\n return true;\n }\n\n return (\n missingValuePolicy === \"BlankString\" &&\n typeof value === \"string\" &&\n value.trim().length === 0\n );\n};\n\nconst isNonEmptyString = (value: unknown): value is string => {\n return typeof value === \"string\" && value.trim().length > 0;\n};\n\nconst isAllowedStringValue = <TValue extends string>(\n value: unknown,\n allowedValues: readonly TValue[],\n): value is TValue => {\n return typeof value === \"string\" && allowedValues.includes(value as TValue);\n};\n\nconst isEmail = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/.test(value.trim());\n};\n\nconst isUuid = (value: unknown): value is string => {\n if (!isNonEmptyString(value)) {\n return false;\n }\n\n return /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(\n value,\n );\n};\n","import type { TRecordValue } from \"../base\";\n\nexport const ACCOUNT_TYPE = {\n TURNDOWN_ADMIN: \"TURNDOWN_ADMIN\",\n ACCOUNT_ADMIN: \"ACCOUNT_ADMIN\",\n MANAGER: \"MANAGER\",\n STAFF: \"STAFF\",\n GUEST: \"GUEST\",\n} as const;\n\nexport type TAccountType = TRecordValue<typeof ACCOUNT_TYPE>;\n\nexport const ACCOUNT_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n PENDING: \"PENDING\",\n} as const;\n\nexport type TAccountStatus = TRecordValue<typeof ACCOUNT_STATUS>;\n\nexport const LANGUAGE = {\n ENGLISH: \"ENGLISH\",\n FRENCH: \"FRENCH\",\n SPANISH: \"SPANISH\",\n GERMAN: \"GERMAN\",\n} as const;\n\nexport type TLanguage = TRecordValue<typeof LANGUAGE>;\n","import {\n createValidationSchema,\n optionalRecordField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\nimport type { IAuthTokenResponse } from \"./index\";\nimport type { IEmptyRouteRequest, TDateTimeString } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport type { IDeviceInfo } from \"../user\";\nimport type { IGetUserResponse } from \"../user/routes\";\n\n// Route Params\nexport interface IAuthSessionIdParams {\n sessionId: string;\n}\n\nexport interface IAuthInvitationTokenParams {\n token: string;\n}\n\nexport interface IAuthInvitationIdParams {\n invitationId: string;\n}\n\n// Shared Responses\nexport interface IAuthMessageResponse {\n message: string;\n}\n\nexport interface IAuthRefreshTokenResponse extends IAuthTokenResponse {}\n\nexport interface IAuthInvitationBaseResponse {\n id: string;\n companyId: string;\n companyName: string;\n role: TAccountType;\n invitedBy: string;\n invitedByName: string;\n expiresAt: TDateTimeString;\n}\n\nconst AccountTypeValues = Object.values(ACCOUNT_TYPE);\n\n// Core Authentication\nexport const RegisterRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n accountType: requiredEnumField(AccountTypeValues, \"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterResponse extends IAuthTokenResponse {}\n\nexport const LoginRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n password: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type ILoginRequest = Omit<\n TInferValidationSchemaInput<typeof LoginRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface ILoginResponse extends IAuthTokenResponse {\n passwordResetRequired: boolean;\n}\n\nexport const RefreshSessionRequestSchema = createValidationSchema({\n refreshToken: requiredStringField(\"BlankString\"),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRefreshSessionRequest = Omit<\n TInferValidationSchemaInput<typeof RefreshSessionRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRefreshSessionResponse extends IAuthRefreshTokenResponse {}\n\nexport const LogoutRequestSchema = createValidationSchema({\n refreshToken: optionalStringField(),\n});\n\nexport type ILogoutRequest = TInferValidationSchemaInput<\n typeof LogoutRequestSchema\n>;\n\nexport interface ILogoutResponse extends IAuthMessageResponse {}\n\nexport interface ILogoutAllRequest {\n userId: string;\n}\n\nexport interface ILogoutAllResponse extends IAuthMessageResponse {}\n\nexport interface IGetMeRequest {\n userId: string;\n}\n\nexport interface IGetMeResponse extends IGetUserResponse {}\n\n// Session Management\nexport type IGetSessionsRequest = IEmptyRouteRequest;\n\nexport interface IGetSessionsResponse {\n id: string;\n deviceInfo: string;\n createdAt: TDateTimeString;\n lastUsedAt: TDateTimeString;\n}\n\nexport interface IRevokeSessionRequest extends IAuthSessionIdParams {}\n\nexport interface IRevokeSessionResponse extends IAuthMessageResponse {}\n\n// Password Management\nexport const ChangePasswordRequestSchema = createValidationSchema({\n currentPassword: requiredStringField(\"BlankString\"),\n newPassword: requiredStringField(\"BlankString\"),\n});\n\nexport type IChangePasswordRequest = TInferValidationSchemaInput<\n typeof ChangePasswordRequestSchema\n>;\n\nexport interface IChangePasswordResponse extends IGetUserResponse {}\n\nexport const ForgotPasswordRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n});\n\nexport type IForgotPasswordRequest = TInferValidationSchemaInput<\n typeof ForgotPasswordRequestSchema\n>;\n\nexport interface IForgotPasswordResponse extends IAuthMessageResponse {}\n\nexport type IGetLoginHistoryRequest = IEmptyRouteRequest;\n\nexport interface IGetLoginHistoryResponse {\n id: string;\n email: string;\n ipAddress: string;\n userAgent: string;\n success: boolean;\n failureReason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetLoginHistoryListResponse {\n history: IGetLoginHistoryResponse[];\n length: number;\n}\n\n// Invitations\nexport interface IValidateInvitationRequest extends IAuthInvitationTokenParams {}\n\nexport interface IValidateInvitationResponse extends IAuthInvitationBaseResponse {\n email: string;\n userExists: boolean;\n}\n\nexport const RegisterWithInvitationRequestSchema = createValidationSchema({\n token: requiredStringField(\"BlankString\"),\n password: requiredStringField(\"BlankString\"),\n firstName: requiredStringField(\"BlankString\"),\n lastName: optionalStringField(),\n deviceInfo: optionalRecordField(),\n});\n\nexport type IRegisterWithInvitationRequest = Omit<\n TInferValidationSchemaInput<typeof RegisterWithInvitationRequestSchema>,\n \"deviceInfo\"\n> & {\n deviceInfo?: IDeviceInfo;\n};\n\nexport interface IRegisterWithInvitationResponse extends IAuthTokenResponse {}\n\nexport const AcceptInvitationRequestSchema = createValidationSchema({\n userId: optionalStringField(),\n token: requiredStringField(\"BlankString\"),\n});\n\nexport type IAcceptInvitationRequest = TInferValidationSchemaInput<\n typeof AcceptInvitationRequestSchema\n>;\n\nexport interface IAcceptInvitationResponse {\n companyId: string;\n companyName: string;\n role: TAccountType;\n}\n\nexport interface IAcceptInvitationRouteResponse {\n invite: IAcceptInvitationResponse;\n message: string;\n}\n\nexport type IGetPendingInvitationsRequest = IEmptyRouteRequest;\n\nexport interface IGetPendingInvitationsResponse extends IAuthInvitationBaseResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport interface IGetPendingInvitationsListResponse {\n invitations: IGetPendingInvitationsResponse[];\n length: number;\n}\n\nexport interface IRevokeInvitationRequest extends IAuthInvitationIdParams {\n revokedBy?: string;\n}\n\nexport interface IRevokeInvitationResponse extends IAuthMessageResponse {}\n","export * from \"./routes\";\n\nimport type { TDateTimeString, TServiceType } from \"../base\";\nimport type { IUser } from \"../user\";\n\nexport const AUTH_STATUS = {\n Initializing: \"Initializing\",\n Unauthenticated: \"Unauthenticated\",\n Authenticated: \"Authenticated\",\n Refreshing: \"Refreshing\",\n SessionExpired: \"SessionExpired\",\n} as const;\n\nexport type TAuthStatus = (typeof AUTH_STATUS)[keyof typeof AUTH_STATUS];\n\nexport interface IAuthTokenBundle {\n accessToken: string;\n refreshToken: string;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IRefreshTokenData {\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IRefreshTokenPersistenceData extends IRefreshTokenData {\n tokenHash: string;\n tokenFamily: string;\n}\n\nexport interface ITokenPayload {\n userId: string;\n email: string;\n name: string;\n}\n\nexport interface IStoredAuthSession {\n accessToken: string | null;\n refreshToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface IAuthTokenResponse extends IAuthTokenBundle {\n user: IUser | null;\n companyId: string | null;\n}\n\nexport interface IAuthSession {\n user: IUser | null;\n accessToken: string | null;\n expiresAt: TDateTimeString | null;\n}\n\nexport interface ISetAuthSessionParams extends IAuthTokenBundle {\n user: IUser | null;\n}\n\nexport interface ILoginCredentials {\n email: string;\n password: string;\n rememberMe: boolean;\n}\n\nexport interface IRegisterCredentials {\n businessType: TServiceType[];\n firstName: string;\n lastName: string;\n email: string;\n password: string;\n}\n\nexport interface IPasswordValidationRules {\n minLength: number;\n requireUppercase: boolean;\n requireLowercase: boolean;\n requireNumbers: boolean;\n requireSpecialChars: boolean;\n}\n\nexport interface IPasswordValidationResult {\n valid: boolean;\n errors: string[];\n}\n\nexport interface IEmailValidationResult {\n valid: boolean;\n error?: string;\n}\n\nexport interface IRateLimitStatus {\n isLimited: boolean;\n attempts: number;\n maxAttempts: number;\n resetTime: TDateTimeString | null;\n}\n","/**\n * Pagination metadata for a paginated response.\n */\nexport interface IPagingResult {\n hasNextPage: boolean;\n totalPages: number;\n totalRecords: number;\n}\n\n/**\n * Generic wrapper for paginated data.\n */\nexport interface IDataWithPagingResult<TData> {\n data: TData;\n pagination: IPagingResult;\n}\n\nexport const SortDirection = {\n Asc: \"Asc\",\n Desc: \"Desc\",\n} as const;\n\nexport type TSortDirection = (typeof SortDirection)[keyof typeof SortDirection];\n\n/**\n * Sorting condition for query results.\n */\nexport interface ISortCondition {\n name: string;\n direction: TSortDirection;\n}\n\nexport const FilterCondition = {\n Equal: \"=\",\n GreaterThan: \">\",\n LessThan: \"<\",\n NotEqual: \"!=\",\n Like: \"LIKE\",\n In: \"IN\",\n GreaterThanOrEqual: \">=\",\n LessThanOrEqual: \"<=\",\n} as const;\n\nexport type TFilterCondition =\n (typeof FilterCondition)[keyof typeof FilterCondition];\n\nexport interface IFilterConditionBase {\n name: string;\n condition: TFilterCondition;\n useAnd?: boolean;\n}\n\nexport interface IStringFilterCondition extends IFilterConditionBase {\n valueString: string;\n valueNumber?: never;\n valueBoolean?: never;\n}\n\nexport interface INumberFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber: number;\n valueBoolean?: never;\n}\n\nexport interface IBooleanFilterCondition extends IFilterConditionBase {\n valueString?: never;\n valueNumber?: never;\n valueBoolean: boolean;\n}\n\n/**\n * Filter condition for querying data.\n *\n * Exactly one value field should be provided.\n */\nexport type TFilterConditionValue =\n | IStringFilterCondition\n | INumberFilterCondition\n | IBooleanFilterCondition;\n\n/**\n * Kept as an exported alias to preserve the existing public API name.\n */\nexport type IFilterCondition = TFilterConditionValue;\n\n/**\n * Request shape for paginated data with optional sorting and filtering.\n */\nexport interface IPaginationRequest {\n page: number;\n size: number;\n sort?: ISortCondition[];\n filters?: IFilterCondition[];\n}\n\nexport interface IPagingObject {\n pagination: IPaginationRequest;\n}\n\nexport const createPagingObject = (\n page: number,\n size: number,\n sort?: ISortCondition[],\n filters?: IFilterCondition[],\n): IPagingObject => ({\n pagination: {\n page,\n size,\n sort,\n filters,\n },\n});\n","export type TJsonPrimitive = string | number | boolean | null;\n\nexport type TJsonObject = {\n [key: string]: TJsonValue;\n};\n\nexport type TJsonValue = TJsonPrimitive | TJsonValue[] | TJsonObject;\n\nexport type TUnknownRecord = Record<string, unknown>;\n\n/**\n * Serialized ISO-8601 date/time value returned by API JSON contracts.\n */\nexport type TDateTimeString = string;\n\nexport type TurndownObject<TObject extends object = TUnknownRecord> = TObject;\n\nexport type TEmptyObject = Record<string, never>;\n\nexport type IEmptyRouteRequest = TEmptyObject;\n\nexport type IEmptyRouteParams = TEmptyObject;\n\nexport const ENVIRONMENT = {\n Prod: \"Prod\",\n Dev: \"Dev\",\n Local: \"Local\",\n Test: \"Test\",\n} as const;\n\nexport type TEnvironment = (typeof ENVIRONMENT)[keyof typeof ENVIRONMENT];\n\nexport interface IMessageResponse {\n message: string;\n}\n\nexport interface ISuccessResponse {\n success: boolean;\n}\n\nexport interface ICountResponse {\n count: number;\n}\n\nexport interface IMetaData {\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport type TRecordValue<TRecord extends object> = TRecord[keyof TRecord];\n\nexport type TRecordKeys<TRecord extends object> = keyof TRecord;\n\nexport interface IVersion {\n major: number;\n minor: number;\n patch: number;\n}\n\nexport type TVersionInput = string | IVersion;\n\nexport interface ISelectOption<TValue extends string = string> {\n label: string;\n value: TValue;\n}\n\nexport const MODE = {\n Create: \"Create\",\n Edit: \"Edit\",\n Delete: \"Delete\",\n Details: \"Details\",\n} as const;\n\nexport type TMode = TRecordValue<typeof MODE> | null;\n\nexport const IMAGE_ENTITY = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TImageEntityType = TRecordValue<typeof IMAGE_ENTITY>;\n\nexport type TUSStateCode = TRecordKeys<typeof US_JURISDICTIONS>;\n\nexport const US_JURISDICTIONS = {\n // 50 States\n AL: \"Alabama\",\n AK: \"Alaska\",\n AZ: \"Arizona\",\n AR: \"Arkansas\",\n CA: \"California\",\n CO: \"Colorado\",\n CT: \"Connecticut\",\n DE: \"Delaware\",\n FL: \"Florida\",\n GA: \"Georgia\",\n HI: \"Hawaii\",\n ID: \"Idaho\",\n IL: \"Illinois\",\n IN: \"Indiana\",\n IA: \"Iowa\",\n KS: \"Kansas\",\n KY: \"Kentucky\",\n LA: \"Louisiana\",\n ME: \"Maine\",\n MD: \"Maryland\",\n MA: \"Massachusetts\",\n MI: \"Michigan\",\n MN: \"Minnesota\",\n MS: \"Mississippi\",\n MO: \"Missouri\",\n MT: \"Montana\",\n NE: \"Nebraska\",\n NV: \"Nevada\",\n NH: \"New Hampshire\",\n NJ: \"New Jersey\",\n NM: \"New Mexico\",\n NY: \"New York\",\n NC: \"North Carolina\",\n ND: \"North Dakota\",\n OH: \"Ohio\",\n OK: \"Oklahoma\",\n OR: \"Oregon\",\n PA: \"Pennsylvania\",\n RI: \"Rhode Island\",\n SC: \"South Carolina\",\n SD: \"South Dakota\",\n TN: \"Tennessee\",\n TX: \"Texas\",\n UT: \"Utah\",\n VT: \"Vermont\",\n VA: \"Virginia\",\n WA: \"Washington\",\n WV: \"West Virginia\",\n WI: \"Wisconsin\",\n WY: \"Wyoming\",\n\n // Territories\n DC: \"District of Columbia\",\n PR: \"Puerto Rico\",\n GU: \"Guam\",\n VI: \"United States Virgin Islands\",\n AS: \"American Samoa\",\n MP: \"Northern Mariana Islands\",\n} as const;\n\nexport type TUSJurisdiction = TRecordValue<typeof US_JURISDICTIONS>;\n\nexport const STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n OVERDUE: \"OVERDUE\",\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TStatus = TRecordValue<typeof STATUS>;\n\nexport const SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n} as const;\n\nexport type TSeverity = TRecordValue<typeof SEVERITY>;\n\nexport const SERVICE_TYPES = {\n PROPERTY: \"PROPERTY\",\n CLEANING: \"CLEANING\",\n MAINTENANCE: \"MAINTENANCE\",\n INSPECTION: \"INSPECTION\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TServiceType = TRecordValue<typeof SERVICE_TYPES>;\n\nexport const MONTHS = [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n] as const;\n\nexport type TMonths = (typeof MONTHS)[number];\n\nexport const WEEK_DAY = {\n Sunday: \"Sunday\",\n Monday: \"Monday\",\n Tuesday: \"Tuesday\",\n Wednesday: \"Wednesday\",\n Thursday: \"Thursday\",\n Friday: \"Friday\",\n Saturday: \"Saturday\",\n} as const;\n\nexport type TWeekDay = TRecordValue<typeof WEEK_DAY>;\n\nexport const WEEK_DAY_SHORT_LABEL = {\n Sunday: \"Sun\",\n Monday: \"Mon\",\n Tuesday: \"Tue\",\n Wednesday: \"Wed\",\n Thursday: \"Thu\",\n Friday: \"Fri\",\n Saturday: \"Sat\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayShortLabel = TRecordValue<typeof WEEK_DAY_SHORT_LABEL>;\n\nexport const WEEK_DAY_LETTER = {\n Sunday: \"S\",\n Monday: \"M\",\n Tuesday: \"T\",\n Wednesday: \"W\",\n Thursday: \"T\",\n Friday: \"F\",\n Saturday: \"S\",\n} as const satisfies Record<TWeekDay, string>;\n\nexport type TWeekDayLetter = TRecordValue<typeof WEEK_DAY_LETTER>;\n\nexport interface IWeekDay {\n date: Date;\n dayOfMonth: number;\n day: TWeekDay;\n shortLabel: TWeekDayShortLabel;\n letter: TWeekDayLetter;\n isToday: boolean;\n}\n\nconst createSelectOptions = <TValue extends string>(\n values: readonly TValue[],\n): ISelectOption<TValue>[] =>\n values.map((value) => ({\n label: value,\n value,\n }));\n\nconst getRecordValues = <TRecord extends Record<string, string>>(\n record: TRecord,\n): TRecordValue<TRecord>[] => Object.values(record) as TRecordValue<TRecord>[];\n\nexport const UnitedStatesJurisdictionOptions = createSelectOptions(\n getRecordValues(US_JURISDICTIONS),\n);\n\nexport const StatusOptions: ISelectOption<TStatus>[] = [\n { label: \"Pending\", value: STATUS.PENDING },\n { label: \"In Progress\", value: STATUS.IN_PROGRESS },\n { label: \"Completed\", value: STATUS.COMPLETED },\n { label: \"Overdue\", value: STATUS.OVERDUE },\n { label: \"Active\", value: STATUS.ACTIVE },\n { label: \"Inactive\", value: STATUS.INACTIVE },\n];\n\nexport const SeverityOptions: ISelectOption<TSeverity>[] = [\n { label: \"Low\", value: SEVERITY.LOW },\n { label: \"Medium\", value: SEVERITY.MEDIUM },\n { label: \"High\", value: SEVERITY.HIGH },\n];\n\nexport const ServiceTypeOptions: ISelectOption<TServiceType>[] = [\n { label: \"Property\", value: SERVICE_TYPES.PROPERTY },\n { label: \"Cleaning\", value: SERVICE_TYPES.CLEANING },\n { label: \"Maintenance\", value: SERVICE_TYPES.MAINTENANCE },\n { label: \"Inspection\", value: SERVICE_TYPES.INSPECTION },\n { label: \"Other\", value: SERVICE_TYPES.OTHER },\n];\n\nexport * from \"./paging.types\";\n","import type { TRecordValue } from \"../base\";\n\nexport const COMPANY_RELATIONSHIP_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n SUSPENDED: \"SUSPENDED\",\n} as const;\n\nexport const INVITATION_STATUS = {\n PENDING: \"PENDING\",\n ACCEPTED: \"ACCEPTED\",\n EXPIRED: \"EXPIRED\",\n REVOKED: \"REVOKED\",\n DECLINED: \"DECLINED\",\n} as const;\n\nexport type TInvitationStatus = TRecordValue<typeof INVITATION_STATUS>;\n\nexport type TCompanyRelationshipStatus =\n | TRecordValue<typeof COMPANY_RELATIONSHIP_STATUS>\n | typeof INVITATION_STATUS.PENDING\n | null;\n\nexport const COMPANY_TYPES = {\n PROPERTY_MANAGEMENT: \"PROPERTY_MANAGEMENT\",\n MAINTENANCE: \"MAINTENANCE\",\n CLEANER: \"CLEANER\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TCompanyType = TRecordValue<typeof COMPANY_TYPES>;\n","import type { ICompany, ICompanyWithRelationshipStatus } from \".\";\nimport { COMPANY_TYPES } from \"./constants\";\nimport type {\n IEmptyRouteRequest,\n IMessageResponse,\n TDateTimeString,\n TUSStateCode,\n} from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport { ACCOUNT_TYPE, type TAccountType } from \"../user/constants\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredEmailField,\n requiredEnumField,\n requiredStringField,\n requiredUuidField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface ICompanyRouteParams {\n companyId: string;\n}\n\nexport interface ICompanyUserRouteParams {\n userId: string;\n}\n\nexport interface ICompanyInvitationTokenParams {\n token: string;\n}\n\nexport interface ICompanyInvitationIdParams extends ICompanyRouteParams {\n invitationId: string;\n}\n\nexport const CompanyFilter = {\n Active: \"active\",\n Pending: \"pending\",\n All: \"all\",\n} as const;\n\nexport type TCompanyFilter = (typeof CompanyFilter)[keyof typeof CompanyFilter];\n\nexport interface IGetCompaniesQuery {\n companyId?: string;\n search?: string;\n filter?: TCompanyFilter;\n}\n\nconst CompanyTypeValues = Object.values(COMPANY_TYPES);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\nconst InviteUserRoleValues = Object.values(ACCOUNT_TYPE).filter(\n (accountType) => accountType !== ACCOUNT_TYPE.TURNDOWN_ADMIN,\n);\n\nexport const CreateCompanyRequestSchema = createValidationSchema({\n displayName: requiredStringField(\"BlankString\"),\n addressLine1: requiredStringField(\"BlankString\"),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(\"BlankString\"),\n stateCode: requiredEnumField(StateCodeValues, \"BlankString\"),\n postalCode: requiredStringField(\"BlankString\"),\n companyType: requiredEnumField(CompanyTypeValues, \"BlankString\"),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type ICreateCompanyRequest = TInferValidationSchemaInput<\n typeof CreateCompanyRequestSchema\n> & {\n stateCode: TUSStateCode;\n companyType: ICompany[\"companyType\"];\n};\n\nexport interface ICreateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport type IGetCompaniesRequest = IEmptyRouteRequest;\nexport type IGetCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport interface IGetCompanyByIdRequest extends ICompanyRouteParams {}\nexport interface IGetCompanyByIdResponse extends ICompanyWithRelationshipStatus {}\n\nexport const UpdateCompanyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n companyType: optionalEnumField(CompanyTypeValues),\n country: optionalNullableStringField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n});\n\nexport type IUpdateCompanyRequest = TInferValidationSchemaInput<\n typeof UpdateCompanyRequestSchema\n> & {\n stateCode?: TUSStateCode;\n companyType?: ICompany[\"companyType\"];\n};\n\nexport interface IUpdateCompanyResponse extends ICompanyWithRelationshipStatus {}\n\nexport const InviteUserToCompanyRequestSchema = createValidationSchema({\n email: requiredEmailField(),\n role: requiredEnumField(InviteUserRoleValues, \"BlankString\"),\n});\n\nexport type IInviteUserToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteUserToCompanyRequestSchema\n> & {\n role: TAccountType;\n};\n\nexport interface IInviteUserToCompanyResponse extends IMessageResponse {}\n\nexport interface IGetCompanyUsersRequest extends ICompanyRouteParams {}\nexport interface ICompanyUserSummary {\n id: string;\n email: string;\n firstName: string;\n lastName: string | null;\n role: TAccountType;\n}\nexport interface ICompanyWithUsers extends ICompanyWithRelationshipStatus {\n users: ICompanyUserSummary[];\n}\nexport interface IGetCompanyUsersResponse extends ICompanyWithUsers {}\n\nexport interface IGetUserCompaniesRequest extends ICompanyUserRouteParams {}\nexport type IGetUserCompaniesResponse = ICompanyWithRelationshipStatus[];\n\nexport const InviteCompanyToCompanyRequestSchema = createValidationSchema({\n providerCompanyId: requiredUuidField(),\n message: optionalNullableStringField(),\n});\n\nexport type IInviteCompanyToCompanyRequest = TInferValidationSchemaInput<\n typeof InviteCompanyToCompanyRequestSchema\n>;\n\nexport interface IInviteCompanyToCompanyResponse {\n id: string;\n token: string;\n expiresAt: TDateTimeString;\n}\n\nexport interface IValidateCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IValidateCompanyInvitationResponse {\n id: string;\n requesterCompanyId: string;\n providerCompanyId: string;\n invitedBy: string;\n message: string | null;\n expiresAt: TDateTimeString;\n requesterCompanyName: string;\n providerCompanyName: string;\n invitedByName: string;\n}\n\nexport interface IAcceptCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IAcceptCompanyInvitationResponse {\n requesterCompanyId: string;\n providerCompanyId: string;\n requesterCompanyName: string;\n providerCompanyName: string;\n}\n\nexport interface IDeclineCompanyInvitationRequest extends ICompanyInvitationTokenParams {}\nexport interface IDeclineCompanyInvitationResponse extends IMessageResponse {}\n\nexport interface IGetPendingCompanyInvitationsRequest extends ICompanyRouteParams {}\nexport interface ICompanyInvitationSummary extends IValidateCompanyInvitationResponse {\n token: string;\n createdAt: TDateTimeString;\n}\n\nexport type IGetPendingCompanyInvitationsResponse = ICompanyInvitationSummary[];\n\nexport interface IRevokeCompanyInvitationRequest extends ICompanyInvitationIdParams {}\nexport interface IRevokeCompanyInvitationResponse extends IMessageResponse {}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\n\nexport const DAMAGE_SEVERITY = {\n LOW: \"LOW\",\n MEDIUM: \"MEDIUM\",\n HIGH: \"HIGH\",\n CRITICAL: \"CRITICAL\",\n} as const;\n\nexport type TDamageSeverity = TRecordValue<typeof DAMAGE_SEVERITY>;\n\nexport const DAMAGE_STATUS = {\n OPEN: \"OPEN\",\n IN_REVIEW: \"IN_REVIEW\",\n ASSIGNED: \"ASSIGNED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n RESOLVED: \"RESOLVED\",\n CLOSED: \"CLOSED\",\n ESCALATED: \"ESCALATED\",\n} as const;\n\nexport type TDamageStatus = TRecordValue<typeof DAMAGE_STATUS>;\n\nexport const WORK_ORDER_PRIORITY = {\n LOW: \"LOW\",\n NORMAL: \"NORMAL\",\n HIGH: \"HIGH\",\n URGENT: \"URGENT\",\n} as const;\n\nexport type TWorkOrderPriority = TRecordValue<typeof WORK_ORDER_PRIORITY>;\n\nexport const WORK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n SCHEDULED: \"SCHEDULED\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkOrderStatus = TRecordValue<typeof WORK_ORDER_STATUS>;\n\nexport interface IDamageReport {\n id: string;\n propertyId: string;\n roomId: string;\n workSessionId: string | null;\n cleaningSessionId: string | null;\n reportedBy: string;\n reportedAt: TDateTimeString;\n severity: TDamageSeverity;\n status: TDamageStatus;\n title: string;\n description: string;\n locationDetails: string | null;\n estimatedCost: number | null;\n actualCost: number | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n resolvedAt: TDateTimeString | null;\n resolvedBy: string | null;\n resolutionNotes: string | null;\n requiresProfessional: boolean;\n vendorInfo: string | null;\n insuranceClaimNumber: string | null;\n isTenantResponsible: boolean;\n tenantChargeAmount: number | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n photos?: IDamagePhoto[];\n comments?: IDamageComment[];\n}\n\nexport interface IDamageReportPhoto {\n id: string;\n damageReportId: string;\n photoId: string;\n imageUrl: string | null;\n caption: string | null;\n isBeforePhoto: boolean;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IDamagePhoto extends IDamageReportPhoto {}\n\nexport interface IDamageComment {\n id: string;\n damageReportId: string;\n userId: string;\n userName: string | null;\n comment: string;\n isInternal: boolean;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IDamageReportStatusHistory {\n id: string;\n damageReportId: string;\n previousStatus: TDamageStatus | null;\n newStatus: TDamageStatus;\n changedBy: string;\n reason: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IWorkOrder {\n id: string;\n damageReportId: string | null;\n propertyId: string;\n roomId: string | null;\n workOrderNumber: string | null;\n priority: TWorkOrderPriority;\n category: string | null;\n assignedTo: string | null;\n assignedAt: TDateTimeString | null;\n scheduledDate: TDateTimeString | null;\n scheduledTimeStart: string | null;\n scheduledTimeEnd: string | null;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n completedBy: string | null;\n description: string;\n workPerformed: string | null;\n materialsUsed: string | null;\n laborHours: number | null;\n laborCost: number | null;\n materialsCost: number | null;\n totalCost: number | null;\n status: TWorkOrderStatus;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface ICreateDamageReportInput {\n propertyId: string;\n roomId: string;\n workSessionId?: string;\n reportedBy: string;\n severity: TDamageSeverity;\n title: string;\n description: string;\n locationDetails?: string;\n estimatedCost?: number;\n requiresProfessional?: boolean;\n isTenantResponsible?: boolean;\n tenantChargeAmount?: number;\n}\n\nexport interface ICreateWorkOrderInput {\n damageReportId?: string;\n propertyId: string;\n roomId?: string;\n priority?: TWorkOrderPriority;\n category?: string;\n description: string;\n scheduledDate?: TDateTimeString;\n scheduledTimeStart?: string;\n scheduledTimeEnd?: string;\n}\n\nexport * from \"./routes\";\n","/**\n * Error Types\n * Custom error types and validation error structures.\n */\n\nimport { ERROR_CODES } from \"../api\";\nimport type { TErrorCode } from \"../api\";\nimport type { TJsonObject, TJsonValue } from \"../base\";\n\n/**\n * Detailed information about a validation error.\n */\nexport interface IValidationErrorDetail {\n field: string;\n message: string;\n value?: TJsonValue;\n}\n\n/**\n * Information about missing required fields.\n */\nexport interface IMissingFieldsErrorDetail {\n missingFields: string[];\n}\n\n/**\n * Information about rate limiting.\n */\nexport interface IRateLimitErrorDetail {\n retryAfter?: number;\n message: string;\n}\n\nexport type TErrorResponseDetail =\n | IValidationErrorDetail[]\n | IMissingFieldsErrorDetail\n | IRateLimitErrorDetail\n | TJsonObject\n | string;\n\nexport interface ITypedApiError<TDetails = TErrorResponseDetail> {\n message: string;\n code: TErrorCode;\n details?: TDetails;\n}\n\nexport type TValidationError = ITypedApiError<IValidationErrorDetail[]>;\nexport type TMissingFieldsError = ITypedApiError<IMissingFieldsErrorDetail>;\nexport type TRateLimitError = ITypedApiError<IRateLimitErrorDetail>;\n\ntype TErrorLike = {\n code?: string;\n details?: unknown;\n};\n\nconst isErrorLike = (error: unknown): error is TErrorLike => {\n return typeof error === \"object\" && error !== null;\n};\n\n/**\n * Type guard for validation errors.\n */\nexport function isValidationError(error: unknown): error is TValidationError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.VALIDATION_ERROR &&\n Array.isArray(error.details)\n );\n}\n\n/**\n * Type guard for missing-field errors.\n */\nexport function isMissingFieldsError(\n error: unknown,\n): error is TMissingFieldsError {\n return (\n isErrorLike(error) &&\n error.code === ERROR_CODES.MISSING_FIELDS &&\n typeof error.details === \"object\" &&\n error.details !== null &&\n \"missingFields\" in error.details &&\n Array.isArray(error.details.missingFields)\n );\n}\n\n/**\n * Type guard for rate-limit errors.\n */\nexport function isRateLimitError(error: unknown): error is TRateLimitError {\n return isErrorLike(error) && error.code === ERROR_CODES.RATE_LIMIT_EXCEEDED;\n}\n\n/**\n * Type guard for authentication errors.\n */\nexport function isAuthError(error: unknown): boolean {\n return (\n isErrorLike(error) &&\n (error.code === ERROR_CODES.UNAUTHORIZED ||\n error.code === ERROR_CODES.INVALID_TOKEN ||\n error.code === ERROR_CODES.INVALID_CREDENTIALS)\n );\n}\n","import type { TDateTimeString, TEnvironment } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const SERVER_STATUS = {\n Healthy: \"Healthy\",\n Unhealthy: \"UnHealthy\",\n} as const;\n\nexport type TServerStatus = (typeof SERVER_STATUS)[keyof typeof SERVER_STATUS];\n\nexport const DATABASE_STATUS = {\n Unknown: \"Unknown\",\n Connected: \"Connected\",\n Disconnected: \"Disconnected\",\n} as const;\n\nexport type TDatabaseStatus =\n (typeof DATABASE_STATUS)[keyof typeof DATABASE_STATUS];\n\nexport interface IHealthCheckResponse {\n status: TServerStatus;\n database: TDatabaseStatus;\n timestamp: TDateTimeString;\n environment: TEnvironment;\n}\n\nexport interface IHealthChecks {\n database: TDatabaseStatus;\n uptime: number;\n memory: {\n rss: number;\n heapTotal: number;\n heapUsed: number;\n external: number;\n arrayBuffers: number;\n };\n timestamp: TDateTimeString;\n databaseError?: string;\n}\n","import type { TDateTimeString } from \"../base\";\n\nexport * from \"./routes\";\n\nexport const IMAGE_ENTITY_TYPE = {\n USER_PROFILE: \"USER_PROFILE\",\n PROPERTY: \"PROPERTY\",\n COMPANY: \"COMPANY\",\n CHECKLIST_ITEM: \"CHECKLIST_ITEM\",\n PROPERTY_ROOM: \"PROPERTY_ROOM\",\n MAINTENANCE_TICKET: \"MAINTENANCE_TICKET\",\n WORK_REPORT: \"WORK_REPORT\",\n CLEANING_REPORT: \"CLEANING_REPORT\",\n TURNDOWN_DEFAULT: \"TURNDOWN_DEFAULT\",\n} as const;\n\nexport type TStoredImageEntityType =\n (typeof IMAGE_ENTITY_TYPE)[keyof typeof IMAGE_ENTITY_TYPE];\n\nexport interface IImage {\n id: string;\n entityType: TStoredImageEntityType;\n entityId: string;\n fileName: string;\n mimeType: string;\n fileSizeBytes: number | null;\n width: number | null;\n height: number | null;\n isPublic: boolean;\n category: string | null;\n displayOrder: number;\n uploadedBy: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n deletedAt: TDateTimeString | null;\n}\n\nexport interface IImageWithUrl extends IImage {\n url: string;\n}\n","import type { IMetaData, TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\nexport const INVENTORY_RESTOCK_ORDER_STATUS = {\n PENDING: \"PENDING\",\n ORDERED: \"ORDERED\",\n SHIPPED: \"SHIPPED\",\n RECEIVED: \"RECEIVED\",\n} as const;\n\nexport type TInventoryRestockOrderStatus = TRecordValue<\n typeof INVENTORY_RESTOCK_ORDER_STATUS\n>;\n\nexport const INVENTORY_UNITS = {\n COUNT: \"COUNT\",\n ROLLS: \"ROLLS\",\n PODS: \"PODS\",\n BOXES: \"BOXES\",\n BOTTLES: \"BOTTLES\",\n PACKS: \"PACKS\",\n BAGS: \"BAGS\",\n GALLONS: \"GALLONS\",\n LITERS: \"LITERS\",\n KILOGRAMS: \"KILOGRAMS\",\n POUNDS: \"POUNDS\",\n OUNCES: \"OUNCES\",\n GRAMS: \"GRAMS\",\n SHEETS: \"SHEETS\",\n CASES: \"CASES\",\n CARTONS: \"CARTONS\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TInventoryUnitType = TRecordValue<typeof INVENTORY_UNITS>;\n\nexport const INVENTORY_ITEM_TYPE = {\n CONSUMABLE: \"CONSUMABLE\",\n FIXED: \"FIXED\",\n} as const;\n\nexport type TInventoryItemType = TRecordValue<typeof INVENTORY_ITEM_TYPE>;\n\nexport interface IInventoryItem extends IMetaData {\n id: string;\n companyId: string;\n name: string;\n description: string | null;\n itemType: TInventoryItemType;\n unit: TInventoryUnitType;\n unitCustom: string | null;\n minimumLevel: number;\n reorderLevel: number;\n maximumLevel: number | null;\n costPerUnit: number | null;\n supplierInfo: string | null;\n sku: string | null;\n barcode: string | null;\n}\n\nexport interface IRoomInventory extends IMetaData {\n id: string;\n roomId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IPropertyInventory extends IMetaData {\n id: string;\n propertyId: string;\n inventoryItemId: string;\n currentLevel: number;\n minimumLevel: number;\n maximumLevel: number | null;\n parLevel: number | null;\n lastRestockedAt: TDateTimeString | null;\n lastRestockedBy: string | null;\n lastCheckedAt: TDateTimeString | null;\n lastCheckedBy: string | null;\n autoReorder: boolean;\n locationNotes: string | null;\n}\n\nexport interface IInventoryCount {\n id: string;\n checklistExecutionId: string;\n roomInventoryId: string;\n previousLevel: number;\n countedLevel: number;\n consumedAmount: number;\n restockedAmount: number;\n finalLevel: number;\n countedBy: string;\n countedAt: TDateTimeString;\n needsRestock: boolean;\n notes: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrder {\n id: string;\n companyId: string;\n orderNumber: string | null;\n status: TInventoryRestockOrderStatus;\n totalItems: number | null;\n totalCost: number | null;\n orderedBy: string | null;\n orderedAt: TDateTimeString | null;\n expectedDelivery: TDateTimeString | null;\n receivedBy: string | null;\n receivedAt: TDateTimeString | null;\n supplierInfo: string | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\nexport interface IInventoryRestockOrderItem {\n id: string;\n orderId: string;\n inventoryItemId: string;\n roomInventoryId: string | null;\n propertyInventoryId: string | null;\n quantityOrdered: number;\n quantityReceived: number;\n unitCost: number | null;\n totalCost: number | null;\n createdAt: TDateTimeString;\n}\n","import type { ISelectOption, TRecordValue } from \"../base\";\n\nexport const PROPERTY_STATUS = {\n ACTIVE: \"ACTIVE\",\n INACTIVE: \"INACTIVE\",\n} as const;\n\nexport type TPropertyStatus = TRecordValue<typeof PROPERTY_STATUS>;\n\nexport const PropertyStatusOptions: ISelectOption<TPropertyStatus>[] = [\n {\n label: \"Active\",\n value: PROPERTY_STATUS.ACTIVE,\n },\n {\n label: \"Inactive\",\n value: PROPERTY_STATUS.INACTIVE,\n },\n];\n\nexport const PROPERTY_TYPES = {\n APARTMENT: \"APARTMENT\",\n COMMERCIAL: \"COMMERCIAL\",\n CONDO: \"CONDO\",\n DUPLEX: \"DUPLEX\",\n HOUSE: \"HOUSE\",\n MULTI_FAMILY: \"MULTI_FAMILY\",\n OFFICE: \"OFFICE\",\n RETAIL: \"RETAIL\",\n TOWNHOUSE: \"TOWNHOUSE\",\n VACATION_RENTAL: \"VACATION_RENTAL\",\n WAREHOUSE: \"WAREHOUSE\",\n} as const;\n\nexport type TPropertyType = TRecordValue<typeof PROPERTY_TYPES>;\n\nexport const PropertyTypeOptions: ISelectOption<TPropertyType>[] = [\n {\n label: \"Apartment\",\n value: PROPERTY_TYPES.APARTMENT,\n },\n {\n label: \"Commercial\",\n value: PROPERTY_TYPES.COMMERCIAL,\n },\n {\n label: \"Condo\",\n value: PROPERTY_TYPES.CONDO,\n },\n {\n label: \"Duplex\",\n value: PROPERTY_TYPES.DUPLEX,\n },\n {\n label: \"House\",\n value: PROPERTY_TYPES.HOUSE,\n },\n {\n label: \"Multi-Family\",\n value: PROPERTY_TYPES.MULTI_FAMILY,\n },\n {\n label: \"Office\",\n value: PROPERTY_TYPES.OFFICE,\n },\n {\n label: \"Retail\",\n value: PROPERTY_TYPES.RETAIL,\n },\n {\n label: \"Townhouse\",\n value: PROPERTY_TYPES.TOWNHOUSE,\n },\n {\n label: \"Vacation Rental\",\n value: PROPERTY_TYPES.VACATION_RENTAL,\n },\n {\n label: \"Warehouse\",\n value: PROPERTY_TYPES.WAREHOUSE,\n },\n];\n","import type {\n IProperty,\n IPropertyAccessInformation,\n IPropertyDetail,\n IPropertySummary,\n TPropertyStatus,\n TPropertyType,\n} from \".\";\nimport { PROPERTY_STATUS, PROPERTY_TYPES } from \"./constants\";\nimport type { IMessageResponse, TUSStateCode } from \"../base\";\nimport { US_JURISDICTIONS } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableEnumField,\n optionalNullableNonNegativeIntegerField,\n optionalNullableStringField,\n optionalStringField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IPropertyIdParams {\n propertyId: string;\n}\n\nexport interface ICompanyIdParams {\n companyId: string;\n}\n\nconst PropertyTypeValues = Object.values(PROPERTY_TYPES);\nconst PropertyStatusValues = Object.values(PROPERTY_STATUS);\nconst StateCodeValues = Object.keys(US_JURISDICTIONS) as TUSStateCode[];\n\nexport const CreatePropertyRequestSchema = createValidationSchema({\n companyId: requiredStringField(),\n displayName: requiredStringField(),\n propertyType: requiredEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: requiredStringField(),\n addressLine2: optionalNullableStringField(),\n city: requiredStringField(),\n stateCode: requiredEnumField(StateCodeValues),\n postalCode: requiredStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type ICreatePropertyRequest = TInferValidationSchemaInput<\n typeof CreatePropertyRequestSchema\n> & {\n companyId: string;\n propertyType: TPropertyType;\n status?: TPropertyStatus | null;\n stateCode: TUSStateCode;\n};\n\nexport const UpdatePropertyRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n propertyType: optionalNullableEnumField(PropertyTypeValues),\n status: optionalNullableEnumField(PropertyStatusValues),\n addressLine1: optionalStringField(),\n addressLine2: optionalNullableStringField(),\n city: optionalStringField(),\n stateCode: optionalEnumField(StateCodeValues),\n postalCode: optionalStringField(),\n country: optionalNullableStringField(),\n sqft: optionalNullableNonNegativeIntegerField(),\n timezone: optionalNullableStringField(),\n imageUrl: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n});\n\nexport type IUpdatePropertyRequest = TInferValidationSchemaInput<\n typeof UpdatePropertyRequestSchema\n> & {\n propertyType?: TPropertyType | null;\n status?: TPropertyStatus | null;\n stateCode?: TUSStateCode;\n};\n\nexport interface IGetPropertiesRequest {\n companyId?: string;\n}\n\nexport interface IGetPropertyByIdRequest extends IPropertyIdParams {}\n\nexport interface IDeletePropertyRequest extends IPropertyIdParams {}\n\nexport type IGetPropertiesResponse = IPropertySummary[];\n\nexport interface IGetPropertyResponse extends IPropertyDetail {}\n\nexport interface ICreatePropertyResponse extends IPropertyDetail {}\n\nexport interface IUpdatePropertyResponse extends IPropertyDetail {}\n\nexport interface IDeletePropertyResponse extends IMessageResponse {}\n\nexport const UpdatePropertyAccessInformationRequestSchema =\n createValidationSchema({\n entryInstructions: optionalNullableStringField(),\n accessCode: optionalNullableStringField(),\n wifiName: optionalNullableStringField(),\n wifiPassword: optionalNullableStringField(),\n alarmCode: optionalNullableStringField(),\n parkingInfo: optionalNullableStringField(),\n specialNotes: optionalNullableStringField(),\n });\n\nexport type IUpdatePropertyAccessInformationRequest =\n TInferValidationSchemaInput<\n typeof UpdatePropertyAccessInformationRequestSchema\n >;\n\nexport interface IUpdatePropertyAccessInformationResponse extends IPropertyAccessInformation {}\n\nexport interface IGetPropertyAccessInformationRequest extends IPropertyIdParams {}\n\nexport type IGetPropertyAccessInformationResponse =\n IPropertyAccessInformation | null;\n\nexport interface IGetPropertyByIdResponse extends IGetPropertyResponse {}\n\nexport interface IGetPropertiesByCompanyIdRequest extends ICompanyIdParams {}\nexport type IGetPropertiesByCompanyIdResponse = IProperty[];\n","import type { TRecordValue } from \"../base\";\n\nexport const ROOM_TYPE = {\n BEDROOM: \"BEDROOM\",\n BATHROOM: \"BATHROOM\",\n KITCHEN: \"KITCHEN\",\n LIVING_ROOM: \"LIVING_ROOM\",\n DINING_ROOM: \"DINING_ROOM\",\n OFFICE: \"OFFICE\",\n GARAGE: \"GARAGE\",\n LAUNDRY_ROOM: \"LAUNDRY_ROOM\",\n BASEMENT: \"BASEMENT\",\n ATTIC: \"ATTIC\",\n BALCONY: \"BALCONY\",\n PORCH: \"PORCH\",\n GARDEN: \"GARDEN\",\n OTHER: \"OTHER\",\n} as const;\n\nexport type TRoomType = TRecordValue<typeof ROOM_TYPE>;\n","import type { IRoom } from \".\";\nimport { ROOM_TYPE } from \"./constants\";\nimport type { IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableEnumField,\n optionalNullableStringField,\n optionalStringField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IRoomPropertyRouteParams {\n propertyId: string;\n}\n\nexport interface IRoomRouteParams {\n roomId: string;\n}\n\nconst RoomTypeValues = Object.values(ROOM_TYPE);\n\nexport const CreateRoomRequestSchema = createValidationSchema({\n propertyId: requiredStringField(),\n displayName: requiredStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type ICreateRoomRequest = TInferValidationSchemaInput<\n typeof CreateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface ICreateRoomResponse extends IRoom {}\n\nexport interface IGetRoomsRequest {\n propertyId?: string;\n}\n\nexport interface IGetRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetDetailedRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {}\nexport type IGetDetailedRoomsByPropertyIdResponse = IRoom[];\n\nexport interface IGetRoomByIdRequest extends IRoomRouteParams {}\nexport interface IGetRoomByIdResponse extends IRoom {}\n\nexport const UpdateRoomRequestSchema = createValidationSchema({\n displayName: optionalStringField(),\n description: optionalNullableStringField(),\n checklistTemplateId: optionalNullableStringField(),\n roomType: optionalNullableEnumField(RoomTypeValues),\n heroPhoto: optionalNullableStringField(),\n});\n\nexport type IUpdateRoomRequest = TInferValidationSchemaInput<\n typeof UpdateRoomRequestSchema\n> & {\n roomType?: IRoom[\"roomType\"];\n};\n\nexport interface IUpdateRoomResponse extends IRoom {}\n\nexport interface IDeleteRoomRequest extends IRoomRouteParams {}\nexport interface IDeleteRoomResponse extends IMessageResponse {}\n","import type {\n ICompanyBillingSummary,\n IEntitlementSnapshot,\n IProviderProduct,\n ISubscriptionProductSummary,\n TSubscriptionProvider,\n} from \".\";\nimport type { IMessageResponse, TJsonObject } from \"../base\";\nimport {\n createValidationSchema,\n optionalNullableStringField,\n optionalRecordField,\n requiredEnumField,\n requiredStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IBillingCompanyRouteParams {\n companyId: string;\n}\n\nexport interface IGetBillingProductsRequest {}\nexport type IGetBillingProductsResponse = ISubscriptionProductSummary[];\n\nexport interface IGetCompanyBillingSummaryRequest\n extends IBillingCompanyRouteParams {}\nexport interface IGetCompanyBillingSummaryResponse\n extends ICompanyBillingSummary {}\n\nexport const CreateStripeCheckoutSessionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n successUrl: requiredStringField(\"BlankString\"),\n cancelUrl: requiredStringField(\"BlankString\"),\n});\n\nexport type ICreateStripeCheckoutSessionRequest =\n TInferValidationSchemaInput<\n typeof CreateStripeCheckoutSessionRequestSchema\n >;\n\nexport interface ICreateStripeCheckoutSessionResponse {\n checkoutUrl: string;\n}\n\nexport const SyncAppleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n transactionId: requiredStringField(\"BlankString\"),\n originalTransactionId: optionalNullableStringField(),\n signedTransactionInfo: requiredStringField(\"BlankString\"),\n});\n\nexport type ISyncAppleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncAppleSubscriptionRequestSchema\n>;\n\nexport const SyncGoogleSubscriptionRequestSchema = createValidationSchema({\n providerProductId: requiredStringField(\"BlankString\"),\n purchaseToken: requiredStringField(\"BlankString\"),\n packageName: requiredStringField(\"BlankString\"),\n providerPriceId: optionalNullableStringField(),\n});\n\nexport type ISyncGoogleSubscriptionRequest = TInferValidationSchemaInput<\n typeof SyncGoogleSubscriptionRequestSchema\n>;\n\nexport interface ISyncStoreSubscriptionResponse {\n subscription: ICompanyBillingSummary[\"subscription\"];\n entitlement: IEntitlementSnapshot;\n}\n\nexport const BillingProviderWebhookRequestSchema = createValidationSchema({\n providerEventId: requiredStringField(\"BlankString\"),\n eventType: requiredStringField(\"BlankString\"),\n providerSubscriptionId: optionalNullableStringField(),\n providerTransactionId: optionalNullableStringField(),\n providerRefundId: optionalNullableStringField(),\n payload: optionalRecordField(),\n});\n\nexport type IBillingProviderWebhookRequest = TInferValidationSchemaInput<\n typeof BillingProviderWebhookRequestSchema\n> & {\n payload?: TJsonObject;\n};\n\nexport interface IBillingProviderWebhookResponse extends IMessageResponse {}\n\nexport interface IProviderProductLookupRequest {\n provider: TSubscriptionProvider;\n providerProductId: string;\n}\n\nexport interface IProviderProductLookupResponse extends IProviderProduct {}\n\nexport const BillingProviderValues = [\n \"STRIPE\",\n \"APPLE\",\n \"GOOGLE\",\n \"MANUAL\",\n] as const;\n\nexport const ProviderProductLookupRequestSchema = createValidationSchema({\n provider: requiredEnumField(BillingProviderValues, \"BlankString\"),\n providerProductId: requiredStringField(\"BlankString\"),\n});\n","import type {\n IMetaData,\n TDateTimeString,\n TJsonObject,\n TRecordValue,\n} from \"../base\";\n\nexport const SUBSCRIPTION_PLAN = {\n Free: \"FREE\",\n Starter: \"STARTER\",\n Pro: \"PRO\",\n Business: \"BUSINESS\",\n} as const;\n\nexport type TSubscriptionPlan = TRecordValue<typeof SUBSCRIPTION_PLAN>;\n\nexport const SUBSCRIPTION_STATUS = {\n ACTIVE: \"ACTIVE\",\n CANCELED: \"CANCELED\",\n EXPIRED: \"EXPIRED\",\n PAST_DUE: \"PAST_DUE\",\n TRIALING: \"TRIALING\",\n GRACE_PERIOD: \"GRACE_PERIOD\",\n REFUNDED: \"REFUNDED\",\n} as const;\n\nexport type TSubscriptionStatus = TRecordValue<typeof SUBSCRIPTION_STATUS>;\n\nexport const SUBSCRIPTION_PROVIDER = {\n STRIPE: \"STRIPE\",\n APPLE: \"APPLE\",\n GOOGLE: \"GOOGLE\",\n MANUAL: \"MANUAL\",\n} as const;\n\nexport type TSubscriptionProvider = TRecordValue<typeof SUBSCRIPTION_PROVIDER>;\n\nexport const BILLING_PERIOD = {\n MONTHLY: \"MONTHLY\",\n YEARLY: \"YEARLY\",\n} as const;\n\nexport type TBillingPeriod = TRecordValue<typeof BILLING_PERIOD>;\n\nexport const REFUND_STATUS = {\n REQUESTED: \"REQUESTED\",\n APPROVED: \"APPROVED\",\n DECLINED: \"DECLINED\",\n PROCESSED: \"PROCESSED\",\n} as const;\n\nexport type TRefundStatus = TRecordValue<typeof REFUND_STATUS>;\n\nexport const SUBSCRIPTION_FEATURE = {\n CreateProperty: \"CREATE_PROPERTY\",\n InviteTeamMember: \"INVITE_TEAM_MEMBER\",\n CreateChecklistTemplate: \"CREATE_CHECKLIST_TEMPLATE\",\n UploadImage: \"UPLOAD_IMAGE\",\n} as const;\n\nexport type TSubscriptionFeature = TRecordValue<typeof SUBSCRIPTION_FEATURE>;\n\nexport interface ISubscriptionPlan extends IMetaData {\n id: string;\n code: TSubscriptionPlan;\n displayName: string;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n isActive: boolean;\n}\n\nexport interface IProviderProduct extends IMetaData {\n id: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerProductId: string;\n providerPriceId: string | null;\n billingPeriod: TBillingPeriod;\n trialDays: number;\n isActive: boolean;\n}\n\nexport interface ISubscriptionProductSummary {\n plan: ISubscriptionPlan;\n products: IProviderProduct[];\n}\n\nexport interface IBillingAccount extends IMetaData {\n id: string;\n companyId: string;\n billingAdminUserId: string | null;\n}\n\nexport interface ICompanySubscription extends IMetaData {\n id: string;\n billingAccountId: string;\n planId: string;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string | null;\n providerOriginalTransactionId: string | null;\n providerPurchaseToken: string | null;\n providerCustomerId: string | null;\n providerPriceId: string | null;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString | null;\n currentPeriodEnd: TDateTimeString | null;\n trialStart: TDateTimeString | null;\n trialEnd: TDateTimeString | null;\n cancelAtPeriodEnd: boolean;\n canceledAt: TDateTimeString | null;\n refundedAt: TDateTimeString | null;\n latestEventAt: TDateTimeString | null;\n}\n\nexport interface ISubscriptionEvent extends IMetaData {\n id: string;\n subscriptionId: string | null;\n provider: TSubscriptionProvider;\n providerEventId: string;\n eventType: string;\n rawPayload: TJsonObject;\n processedAt: TDateTimeString;\n}\n\nexport interface IEntitlementSnapshot {\n id: string;\n companyId: string;\n subscriptionId: string | null;\n planCode: TSubscriptionPlan;\n status: TSubscriptionStatus;\n effectiveFrom: TDateTimeString;\n effectiveUntil: TDateTimeString | null;\n propertyLimit: number;\n teamMemberLimit: number;\n checklistTemplateLimit: number;\n imageStorageLimitMb: number;\n sourceEventId: string | null;\n createdAt: TDateTimeString;\n}\n\nexport interface IRefund extends IMetaData {\n id: string;\n subscriptionId: string;\n provider: TSubscriptionProvider;\n providerRefundId: string | null;\n providerTransactionId: string | null;\n amount: number | null;\n currency: string | null;\n reason: string | null;\n status: TRefundStatus;\n refundedAt: TDateTimeString | null;\n rawPayload: TJsonObject | null;\n}\n\nexport interface ICompanyBillingSummary {\n billingAccount: IBillingAccount | null;\n subscription: ICompanySubscription | null;\n entitlement: IEntitlementSnapshot;\n}\n\n/**\n * @deprecated Use ICompanySubscription for company-scoped SaaS access.\n */\nexport interface IUserSubscription {\n id: string;\n userId: string;\n planId: string;\n status: TSubscriptionStatus;\n billingPeriod: TBillingPeriod;\n currentPeriodStart: TDateTimeString;\n currentPeriodEnd: TDateTimeString;\n provider: TSubscriptionProvider;\n providerSubscriptionId: string;\n cancelAtPeriodEnd: boolean;\n}\n\nexport * from \"./routes\";\n","import type { IUser, TAccountType } from \".\";\nimport { LANGUAGE } from \"./constants\";\nimport type { IEmptyRouteRequest, IMessageResponse } from \"../base\";\nimport {\n createValidationSchema,\n optionalEnumField,\n optionalNullableStringField,\n optionalStringField,\n type TInferValidationSchemaInput,\n} from \"../validation\";\n\nexport interface IUserIdParams {\n id: string;\n}\n\nexport interface IGetUserResponse {\n user: IUser | null;\n}\n\nexport type IGetCurrentUserRequest = IEmptyRouteRequest;\nexport interface IGetCurrentUserResponse extends IGetUserResponse {}\n\nexport interface IGetUserByIdRequest extends IUserIdParams {}\nexport interface IGetUserByIdResponse extends IGetUserResponse {}\n\nexport interface IGetUserByEmailRequest {\n email: string;\n}\nexport interface IGetUserByEmailResponse extends IGetUserResponse {}\n\nexport type IGetStaffRequest = IEmptyRouteRequest;\nexport interface IGetStaffResponse {\n staff: IUser[];\n}\n\nconst LanguageValues = Object.values(LANGUAGE);\n\nexport const UpdateUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalNullableStringField(),\n mi: optionalNullableStringField(),\n username: optionalNullableStringField(),\n email: optionalStringField(),\n phoneNumber: optionalNullableStringField(),\n phoneFormat: optionalNullableStringField(),\n preferredLanguage: optionalEnumField(LanguageValues),\n});\n\nexport type IUpdateUserRequest = TInferValidationSchemaInput<\n typeof UpdateUserRequestSchema\n> & {\n preferredLanguage?: IUser[\"preferredLanguage\"];\n};\n\nexport const UpdateCurrentUserRequestSchema = createValidationSchema({\n firstName: optionalStringField(),\n lastName: optionalStringField(),\n});\n\nexport type IUpdateCurrentUserRequest = TInferValidationSchemaInput<\n typeof UpdateCurrentUserRequestSchema\n>;\n\nexport interface IUpdateUserResponse {\n user: IUser;\n}\n\nexport type IDeleteUserRequest = IEmptyRouteRequest;\nexport interface IDeleteUserResponse extends IMessageResponse {}\n\nexport interface IGetUsersByAccountTypeRequest {\n accountType: TAccountType;\n}\nexport interface IGetUsersByAccountTypeResponse {\n users: IUser[];\n}\n","import type { TDateTimeString, TRecordValue } from \"../base\";\nexport * from \"./routes\";\n\n/**\n * Work session status enum.\n */\nexport const WORK_SESSION_STATUS = {\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n CANCELLED: \"CANCELLED\",\n} as const;\n\nexport type TWorkSessionStatus = TRecordValue<typeof WORK_SESSION_STATUS>;\n\n/**\n * Checklist execution status enum.\n */\nexport const CHECKLIST_EXECUTION_STATUS = {\n PENDING: \"PENDING\",\n IN_PROGRESS: \"IN_PROGRESS\",\n COMPLETED: \"COMPLETED\",\n SKIPPED: \"SKIPPED\",\n} as const;\n\nexport type TChecklistExecutionStatus = TRecordValue<\n typeof CHECKLIST_EXECUTION_STATUS\n>;\n\n/**\n * Work session.\n */\nexport interface IWorkSession {\n id: string;\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n status: TWorkSessionStatus;\n scheduledDate: TDateTimeString | null;\n startedAt: TDateTimeString;\n completedAt: TDateTimeString | null;\n totalTimeMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist execution.\n */\nexport interface IChecklistExecution {\n id: string;\n workSessionId: string;\n roomChecklistId: string;\n roomId: string;\n workerId: string;\n status: TChecklistExecutionStatus;\n startedAt: TDateTimeString | null;\n completedAt: TDateTimeString | null;\n timeSpentMinutes: number | null;\n notes: string | null;\n createdAt: TDateTimeString;\n updatedAt: TDateTimeString;\n}\n\n/**\n * Checklist item completion.\n */\nexport interface IChecklistItemCompletion {\n id: string;\n checklistExecutionId: string;\n roomChecklistItemId: string;\n completedBy: string;\n completedAt: TDateTimeString;\n photoId: string | null;\n notes: string | null;\n skipped: boolean;\n skipReason: string | null;\n createdAt: TDateTimeString;\n}\n\n/**\n * Work session with executions.\n */\nexport interface IWorkSessionWithExecutions extends IWorkSession {\n executions: IChecklistExecution[];\n}\n\n/**\n * Input for creating a work session.\n */\nexport interface ICreateWorkSessionInput {\n propertyId: string;\n serviceProviderCompanyId: string;\n performedBy: string;\n scheduledDate?: TDateTimeString;\n notes?: string;\n}\n\n/**\n * Input for completing a checklist item.\n */\nexport interface ICompleteChecklistItemInput {\n roomChecklistItemId: string;\n completedBy: string;\n photoId?: string;\n notes?: string;\n skipped?: boolean;\n skipReason?: string;\n}\n"],"mappings":";AAOO,IAAM,cAAc;AAAA,EACzB,KAAK;AAAA,EACL,MAAM;AAAA,EACN,KAAK;AAAA,EACL,OAAO;AAAA,EACP,QAAQ;AACV;AAQO,IAAM,cAAc;AAAA,EACzB,aAAa;AAAA,EACb,kBAAkB;AAAA,EAClB,gBAAgB;AAAA,EAChB,cAAc;AAAA,EACd,eAAe;AAAA,EACf,qBAAqB;AAAA,EACrB,WAAW;AAAA,EACX,WAAW;AAAA,EACX,UAAU;AAAA,EACV,gBAAgB;AAAA,EAChB,YAAY;AAAA,EACZ,qBAAqB;AAAA,EACrB,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,iBAAiB;AACnB;AAQO,IAAM,cAAc;AAAA,EACzB,IAAI;AAAA,EACJ,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,cAAc;AAAA,EACd,WAAW;AAAA,EACX,UAAU;AAAA,EACV,UAAU;AAAA,EACV,qBAAqB;AAAA,EACrB,iBAAiB;AAAA,EACjB,eAAe;AACjB;;;ACeO,IAAM,yBAAyB,CACpC,WACsC;AACtC,QAAM,gBAAgB,OAAO,KAAK,MAAM;AACxC,QAAM,iBAAiB,cAAc,OAAO,CAAC,cAAc;AACzD,WAAO,OAAO,SAAS,EAAE;AAAA,EAC3B,CAAC;AAED,SAAO;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA,UAAU,CAAC,OAAO,UAAU,CAAC,MAAM;AACjC,UAAI,CAAC,SAAS,KAAK,GAAG;AACpB,eAAO;AAAA,UACL,SAAS;AAAA,UACT,QAAQ;AAAA,YACN;AAAA,cACE,WAAW;AAAA,cACX,MAAM;AAAA,YACR;AAAA,UACF;AAAA,QACF;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