@infuro/cms-core 1.0.57 → 1.0.59

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/index.d.cts CHANGED
@@ -966,6 +966,7 @@ declare function deductInventoryForConfirmedOrder(ds: EmOrDs$1, entityMap: Entit
966
966
  declare function restoreInventoryForCancelledOrder(ds: EmOrDs$1, entityMap: EntityMapLike$3, lines: InventoryOrderLine[]): Promise<string | null>;
967
967
 
968
968
  type EntityMap$2 = Record<string, typeorm.EntityTarget<typeorm.ObjectLiteral>>;
969
+ declare function autoExpireOrderIfPaymentTimeExceeded(dataSource: typeorm.DataSource, entityMap: Record<string, unknown>, order: Record<string, unknown> | null | undefined): Promise<Record<string, unknown> | null | undefined>;
969
970
  interface CrudHandlerOptions {
970
971
  requireAuth: (req: Request) => Promise<Response | null>;
971
972
  json: (body: unknown, init?: {
@@ -4069,8 +4070,9 @@ declare enum UserDevicePlatform {
4069
4070
  }
4070
4071
  declare class UserDeviceToken {
4071
4072
  id: string;
4072
- vendorId: number;
4073
- vendor: unknown;
4073
+ /** Staff/vendor app store. Null for customer/marketplace tokens (membership is `vendor_customers`). */
4074
+ vendorId: number | null;
4075
+ vendor: unknown | null;
4074
4076
  userId: number;
4075
4077
  user: unknown;
4076
4078
  token: string;
@@ -4411,4 +4413,4 @@ type CreateCmsAppWithMessagingOptions = CreateCmsAppOptions & EnsureMessagingPlu
4411
4413
  /** `createCmsApp` + messaging plugins + queue processor registration. */
4412
4414
  declare function createCmsAppWithMessaging(options: CreateCmsAppWithMessagingOptions): Promise<CmsApp>;
4413
4415
 
4414
- export { ADMIN_GROUP_NAME, AUTH_PROVIDERS_SETTINGS_GROUP, Address, type AdminNavItem, type AnalyticsHandlerConfig, type AnalyticsPluginConfig, type AppliedDiscountUsage, Attendee, Attribute, type AuthHandlersConfig, type AuthHelpers, type AuthProvidersDataSource, type AuthProvidersEntityMap, type AuthorizeOtpInput, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, type BlogBySlugConfig, type BlogGeneratorBlogDraft, type BlogGeneratorDraftParseMode, type BlogGeneratorPluginConfig, type BlogGeneratorSeoDraft, BlogGeneratorService, Brand, type BuildNextAuthOptionsConfig, CMS_ENTITY_MAP, type CachePluginConfig, type CacheService, type CaptchaProviderId, type CaptchaPublicConfig, CaptchaService, type CaptchaVerifyResult, Cart, CartItem, Category, type ChangePasswordConfig, ChatConversation, ChatMessage, type ChatPublicConfig, type CmsApiHandlerConfig, type CmsApp, type CmsGetter, type CmsMiddlewareConfig, type CmsMiddlewareRequest, type CmsPlugin, Collection, Combo, ComboItem, Comment, type CompanyDetails, Config, Contact, type CreateCmsAppOptions, type CreateCmsAppWithMessagingOptions, type CreateGoogleCustomerDataSource, type CreateGoogleCustomerEntityMap, type CreateGoogleCustomerInput, type CrudHandlerOptions, Currency, CurrencyExchange, Customer, Customer_Contacts, DEFAULT_ADMIN_NAV, DEFAULT_ORDER_NOTIFICATION_TRIGGER_SEEDS, type DashboardStatsConfig, type DataSourceManager, Discount, DiscountRules, type DiscountUsageEntityMap, type ERPPluginConfig, type ERPPluginInstance, ERPSubmissionService, EVENT_ORDER_MESSAGE_TEMPLATE_DEFAULTS, EVENT_ORDER_TEMPLATE_KEY, EVENT_ORDER_TEMPLATE_VARIABLES, type EcommerceAnalyticsConfig, type EmailAttachment, type EmailData, type EmailJobPayload, type EmailPluginConfig, type EmailQueueProcessorOptions, EmailService, type EmailServiceInterface, type EmailTemplateName, type EmailTemplateResult, type EmitOrderNotificationTriggerDeps, type EnsureCustomerRecordInput, type EnsureCustomerUserInput, type EnsureMessagingPluginsOptions, type EnsureVendorCustomerDetails, type EntityCrudAction, type EntityMap$2 as EntityMap, type EntityPermissionFlags, type ErpContactSyncInput, type ErpCreateContactPayload, type ErpJobPayload, type ErpPaidOrderDataSource, type ErpPaidOrderEntityMap, Event, type EventApprovalStatus, type EventOrderMessageTemplateHandlersConfig, type EventOrderNotificationChannel, type EventOrderNotificationTemplates, type EventOrderTemplateOverride, EventProduct, type ExtraPublicWriteRule, type FacebookMeAccountsResponse, type FacebookPageAccount, type ForgotPasswordConfig, Form, type FormBySlugConfig, FormField, FormSubmission, type GetPublicSettingsGroupConfig, type GetPublicSettingsGroupDataSource, type GetSession, type GoogleAuthConfig, INVOICE_TEMPLATE_IDS, INVOICE_TEMPLATE_OPTIONS, type InventoryOrderLine, type InviteAcceptConfig, type InvoiceAddress, type InvoiceCompany, type InvoiceLineItem, type InvoicePdfInput, type InvoiceTemplateId, JOB_RUNNER_QUEUE, type CmsAppLike as JobRunnerCmsAppLike, type JobRunnerDeps, type JobRunnerPayload, JobSchedule, type JobScheduleApiConfig, JobScheduleRun, KNOWN_NOTIFICATION_TRIGGERS, KnowledgeBaseChunk, KnowledgeBaseDocument, type LatestArticleFromFeed, LlmAgent, type LlmAgentKnowledgeApiConfig, LlmAgentKnowledgeDocument, type LlmAgentOptions, type LlmAgentValidationRulesJson, type LlmChatOptions, type LlmEmbeddingProvider, type LlmMessage, type LlmPluginConfig, LlmService, type LlmServiceEmbedOptions, type LlmServiceInterface, type LocalStoragePluginConfig, type Logger, Media, MessageTemplate, type MetaGraphMutationResponse, type NextAuthOptionsConfig, type NextAuthUser, OPEN_ENDPOINTS, ORDER_NOTIFICATION_TRIGGERS, Order, OrderAddresses, OrderDiscounts, type OrderInventorySnapshot, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, type OrderNotificationTriggerKey, type OrderPlacedEmailPayload, type OrderPlacedLineItem, type OrderTriggerPayload, OtpChallenge, type OtpChannel, type OtpPurpose, PERMISSION_REQUIRED_ENDPOINTS, Page, type ParsedLlmAgentValidation, PasswordResetToken, Payment, type PaymentIntent, type PaymentPluginConfig, type PaymentServiceInterface, Permission, type PgBossPluginConfig, PgBossService, type PipelineNames, type PluginContext, Product, type ProductApprovalStatus, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, type PublicThemeSettingsPayload, type QueuePluginConfig, type QueueService, RBAC_ADMIN_ONLY_ENTITIES, type RefundCalculationResult, RefundPolicy, type RefundPolicyLike, type RefundPolicyTier, RefundRequest, type RenderEmailOptions, type RenderedEmail, type ResolveGoogleAuthConfigInput, type ResolveOrderInvoicePdfError, type ResolvedOrderInvoicePdf, RssArticle, RssFeed, type S3StoragePluginConfig, SUPER_ADMIN_GROUP_ID, type SendVendorOnboardEmailInput, Seo, type SeoLike, type SeoMetadataOverrides, type SessionUser, type SetPasswordConfig, type SettingsApiConfig, type SmsJobPayload, type SmsPluginConfig, type SmsProviderChoice, type SmsProviderId, type SmsServiceConfig, type SmsServiceInterface, type SocialLinkItem, type SocialMediaPluginConfig, type StorageService, type StorefrontApiConfig, type StorefrontOtpFlags, Tag, Tax, type TemplateContext, type UploadHandlerConfig, User, type UserAuthApiConfig, type UserAvatarConfig, UserDeviceToken, UserGroup, type UserInviteStatus, type UserProfileConfig, type UsersApiConfig, VENDOR_ADMIN_GROUP_ID, VENDOR_GROUP_NAME, VENDOR_OWNER_GROUP_NAME, VENDOR_SCOPED_STORE_ENTITIES, VENDOR_STORE_RBAC_ENTITIES, Vendor, type VendorCatalogCreateFlags, VendorCustomer, type VendorDashboardConfig, type VendorOnboardHandlersConfig, type VendorOwnerActivation, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, type WhatsAppJobPayload, type WhatsAppPluginConfig, type WhatsAppServiceConfig, type WhatsAppServiceInterface, Wishlist, WishlistItem, ZIP_MIME_TYPES, activeUniqueValueExists, allowRateLimit, analyticsPlugin, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, blogGeneratorPlugin, buildBlogMetadataUserPrompt, buildCaptchaPublicConfig, buildCronFromSchedule, buildEventOrderTemplateVariables, buildLocalInvoicePdfForOrder, buildNextAuthOptions, buildRssUserPromptFromFeeds, buildStorefrontNextAuthOptions, buildUserInviteLink, buildVendorInviteLink, cachePlugin, calculateOrderRefundPreview, calculateRefundFromPolicy, canManageRoles, canManageVendorRoles, canManageVendorTeam, canOnboardVendors, captchaPlugin, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, cn, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createAuthHelpers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCmsAuthBundle, createCmsMiddleware, createCrudByIdHandler, createCrudHandler, createCustomerUserFromGoogleOAuth, createDashboardStatsHandler, createDataSourceManager, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, customerPhoneForEmail, customerPhoneForUser, daysBeforeEventStart, decrementDiscountUsage, deductInventoryForConfirmedOrder, defaultPublicApiMethods, describeEventTierPolicy, emailPlugin, emailTemplates, emitOrderNotificationTrigger, enrichUserWithVendorContext, ensureCustomerForUser, ensureCustomerRecord, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, erpPlugin, explainSessionEntityAccess, fetchSeoBySlug, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, fireOrderNotificationTrigger, formatDate, formatDateOnly, formatDateTime, formatTierRange, generateLocalInvoicePdf, generateNumericOtp, generateSlug, getCompanyDetailsFromSettings, getNextAuthOptions, getPermissionableEntityKeys, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRequiredPermission, getRssArticleSummaryFromItem, getStorefrontNextAuthOptions, getVendorCatalogCreateFlags, googleOAuthRedirectUri, hasEntityPermission, hashOtpCode, hydrateVendorSessionUser, initWhatsappTriggerDispatcher, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isAuthDebugClientEnabled, isAuthDebugEnabled, isCustomerTypeContact, isGoogleAuthPubliclyEnabled, isMaxPerUserUsageReached, isMaxTotalUsageReached, isOpenEndpoint, isOrderEligibleForInvoiceEmail, isPlatformAdministrator, isPublicMethod, isRbacDebugEnabled, isSuperAdmin, isSuperAdminGroupName, isSyntheticCustomerPhone, isVendorAdmin, isVendorGroupName, isVendorOwner, isVendorPortalUser, isVendorStaff, isZipMedia, joinRecipientsForSend, linkUnclaimedContactToUser, llmAgentToChatAgentOptions, llmPlugin, loadPublicThemeSettings, loadSettingsGroupFromDb, loadUserVendorContext, localStoragePlugin, logAuth, logAuthClient, logEntityAccessDecision, logRbac, mergeEmailLayoutCompanyDetails, mergeGuardrailsIntoSystemPrompt, mergeInventoryLines, mergeSeoBySlug, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, nextAuthCookieDebugInfo, normalizeCustomerPhone, normalizeInvoiceTemplateId, normalizePhoneE164, normalizeRefundTiers, notificationTriggerEmitter, orderInventorySnapshotFromRow, orderStatusHoldsStock, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseEmailRecipientsFromConfig, parseHfInferenceEmbeddingBody, parseLlmAgentValidationRules, paymentPlugin, permissionRowsToRecord, pgBossPlugin, pgBossScheduleNameForId, queueEmail, queueErp, queueErpCreateContactIfEnabled, queueErpPaidOrderForOrderId, queueJobScheduleNow, queueOrderPlacedEmails, queuePlugin, queueSms, queueVendorOnboardEmails, queueWhatsApp, rateLimitCheckoutPost, rateLimitKeyForApiRequest, rateLimitPublicApiIfNeeded, reconcileOrderInventoryBetweenSnapshots, recordDiscountUsage, registerEmailQueueProcessor, registerErpQueueProcessor, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, registerWhatsAppQueueProcessor, relativePathFromMediaParentId, renderEmail, renderLayout, resendOrderNotification, resolveBlogCategoryIdByName, resolveEventOrderTemplate, resolveGoogleAuthConfig, resolveInvoiceAssetUrl, resolveOrderInvoicePdfBytes, resolvePublicMetadata, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, resolveVendorScopeFromSessionUser, restoreInventoryForCancelledOrder, retireSoftDeletedUniqueValue, s3StoragePlugin, sanitizeMediaFolderPath, sanitizeStorageSegment, seedAdministratorPermissions, seedDefaultAdmin, sendOrderPlacedEmailsAfterConfirmation, sendVendorOnboardEmails, serializeEmailRecipients, sessionHasEntityAccess, shouldRateLimitPublicWrite, simpleDecrypt, simpleEncrypt, smsPlugin, socialMediaPlugin, streamOrderInvoicePdf, summarizeEntityPerms, summarizeSessionUserForLog, syncJobScheduleToPgBoss, truncateText, validateInventoryForConfirmedOrderLines, validateInventoryForOrderBecomingConfirmed, validateRefundTiers, validateScheduleInput, validateSlug, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, vendorPortalFlagsFromUser, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, withAdminRlsContext, withVendorRlsContext, wrapGetCmsWithMessaging };
4416
+ export { ADMIN_GROUP_NAME, AUTH_PROVIDERS_SETTINGS_GROUP, Address, type AdminNavItem, type AnalyticsHandlerConfig, type AnalyticsPluginConfig, type AppliedDiscountUsage, Attendee, Attribute, type AuthHandlersConfig, type AuthHelpers, type AuthProvidersDataSource, type AuthProvidersEntityMap, type AuthorizeOtpInput, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, type BlogBySlugConfig, type BlogGeneratorBlogDraft, type BlogGeneratorDraftParseMode, type BlogGeneratorPluginConfig, type BlogGeneratorSeoDraft, BlogGeneratorService, Brand, type BuildNextAuthOptionsConfig, CMS_ENTITY_MAP, type CachePluginConfig, type CacheService, type CaptchaProviderId, type CaptchaPublicConfig, CaptchaService, type CaptchaVerifyResult, Cart, CartItem, Category, type ChangePasswordConfig, ChatConversation, ChatMessage, type ChatPublicConfig, type CmsApiHandlerConfig, type CmsApp, type CmsGetter, type CmsMiddlewareConfig, type CmsMiddlewareRequest, type CmsPlugin, Collection, Combo, ComboItem, Comment, type CompanyDetails, Config, Contact, type CreateCmsAppOptions, type CreateCmsAppWithMessagingOptions, type CreateGoogleCustomerDataSource, type CreateGoogleCustomerEntityMap, type CreateGoogleCustomerInput, type CrudHandlerOptions, Currency, CurrencyExchange, Customer, Customer_Contacts, DEFAULT_ADMIN_NAV, DEFAULT_ORDER_NOTIFICATION_TRIGGER_SEEDS, type DashboardStatsConfig, type DataSourceManager, Discount, DiscountRules, type DiscountUsageEntityMap, type ERPPluginConfig, type ERPPluginInstance, ERPSubmissionService, EVENT_ORDER_MESSAGE_TEMPLATE_DEFAULTS, EVENT_ORDER_TEMPLATE_KEY, EVENT_ORDER_TEMPLATE_VARIABLES, type EcommerceAnalyticsConfig, type EmailAttachment, type EmailData, type EmailJobPayload, type EmailPluginConfig, type EmailQueueProcessorOptions, EmailService, type EmailServiceInterface, type EmailTemplateName, type EmailTemplateResult, type EmitOrderNotificationTriggerDeps, type EnsureCustomerRecordInput, type EnsureCustomerUserInput, type EnsureMessagingPluginsOptions, type EnsureVendorCustomerDetails, type EntityCrudAction, type EntityMap$2 as EntityMap, type EntityPermissionFlags, type ErpContactSyncInput, type ErpCreateContactPayload, type ErpJobPayload, type ErpPaidOrderDataSource, type ErpPaidOrderEntityMap, Event, type EventApprovalStatus, type EventOrderMessageTemplateHandlersConfig, type EventOrderNotificationChannel, type EventOrderNotificationTemplates, type EventOrderTemplateOverride, EventProduct, type ExtraPublicWriteRule, type FacebookMeAccountsResponse, type FacebookPageAccount, type ForgotPasswordConfig, Form, type FormBySlugConfig, FormField, FormSubmission, type GetPublicSettingsGroupConfig, type GetPublicSettingsGroupDataSource, type GetSession, type GoogleAuthConfig, INVOICE_TEMPLATE_IDS, INVOICE_TEMPLATE_OPTIONS, type InventoryOrderLine, type InviteAcceptConfig, type InvoiceAddress, type InvoiceCompany, type InvoiceLineItem, type InvoicePdfInput, type InvoiceTemplateId, JOB_RUNNER_QUEUE, type CmsAppLike as JobRunnerCmsAppLike, type JobRunnerDeps, type JobRunnerPayload, JobSchedule, type JobScheduleApiConfig, JobScheduleRun, KNOWN_NOTIFICATION_TRIGGERS, KnowledgeBaseChunk, KnowledgeBaseDocument, type LatestArticleFromFeed, LlmAgent, type LlmAgentKnowledgeApiConfig, LlmAgentKnowledgeDocument, type LlmAgentOptions, type LlmAgentValidationRulesJson, type LlmChatOptions, type LlmEmbeddingProvider, type LlmMessage, type LlmPluginConfig, LlmService, type LlmServiceEmbedOptions, type LlmServiceInterface, type LocalStoragePluginConfig, type Logger, Media, MessageTemplate, type MetaGraphMutationResponse, type NextAuthOptionsConfig, type NextAuthUser, OPEN_ENDPOINTS, ORDER_NOTIFICATION_TRIGGERS, Order, OrderAddresses, OrderDiscounts, type OrderInventorySnapshot, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, type OrderNotificationTriggerKey, type OrderPlacedEmailPayload, type OrderPlacedLineItem, type OrderTriggerPayload, OtpChallenge, type OtpChannel, type OtpPurpose, PERMISSION_REQUIRED_ENDPOINTS, Page, type ParsedLlmAgentValidation, PasswordResetToken, Payment, type PaymentIntent, type PaymentPluginConfig, type PaymentServiceInterface, Permission, type PgBossPluginConfig, PgBossService, type PipelineNames, type PluginContext, Product, type ProductApprovalStatus, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, type PublicThemeSettingsPayload, type QueuePluginConfig, type QueueService, RBAC_ADMIN_ONLY_ENTITIES, type RefundCalculationResult, RefundPolicy, type RefundPolicyLike, type RefundPolicyTier, RefundRequest, type RenderEmailOptions, type RenderedEmail, type ResolveGoogleAuthConfigInput, type ResolveOrderInvoicePdfError, type ResolvedOrderInvoicePdf, RssArticle, RssFeed, type S3StoragePluginConfig, SUPER_ADMIN_GROUP_ID, type SendVendorOnboardEmailInput, Seo, type SeoLike, type SeoMetadataOverrides, type SessionUser, type SetPasswordConfig, type SettingsApiConfig, type SmsJobPayload, type SmsPluginConfig, type SmsProviderChoice, type SmsProviderId, type SmsServiceConfig, type SmsServiceInterface, type SocialLinkItem, type SocialMediaPluginConfig, type StorageService, type StorefrontApiConfig, type StorefrontOtpFlags, Tag, Tax, type TemplateContext, type UploadHandlerConfig, User, type UserAuthApiConfig, type UserAvatarConfig, UserDeviceToken, UserGroup, type UserInviteStatus, type UserProfileConfig, type UsersApiConfig, VENDOR_ADMIN_GROUP_ID, VENDOR_GROUP_NAME, VENDOR_OWNER_GROUP_NAME, VENDOR_SCOPED_STORE_ENTITIES, VENDOR_STORE_RBAC_ENTITIES, Vendor, type VendorCatalogCreateFlags, VendorCustomer, type VendorDashboardConfig, type VendorOnboardHandlersConfig, type VendorOwnerActivation, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, type WhatsAppJobPayload, type WhatsAppPluginConfig, type WhatsAppServiceConfig, type WhatsAppServiceInterface, Wishlist, WishlistItem, ZIP_MIME_TYPES, activeUniqueValueExists, allowRateLimit, analyticsPlugin, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, autoExpireOrderIfPaymentTimeExceeded, blogGeneratorPlugin, buildBlogMetadataUserPrompt, buildCaptchaPublicConfig, buildCronFromSchedule, buildEventOrderTemplateVariables, buildLocalInvoicePdfForOrder, buildNextAuthOptions, buildRssUserPromptFromFeeds, buildStorefrontNextAuthOptions, buildUserInviteLink, buildVendorInviteLink, cachePlugin, calculateOrderRefundPreview, calculateRefundFromPolicy, canManageRoles, canManageVendorRoles, canManageVendorTeam, canOnboardVendors, captchaPlugin, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, cn, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createAuthHelpers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCmsAuthBundle, createCmsMiddleware, createCrudByIdHandler, createCrudHandler, createCustomerUserFromGoogleOAuth, createDashboardStatsHandler, createDataSourceManager, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, customerPhoneForEmail, customerPhoneForUser, daysBeforeEventStart, decrementDiscountUsage, deductInventoryForConfirmedOrder, defaultPublicApiMethods, describeEventTierPolicy, emailPlugin, emailTemplates, emitOrderNotificationTrigger, enrichUserWithVendorContext, ensureCustomerForUser, ensureCustomerRecord, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, erpPlugin, explainSessionEntityAccess, fetchSeoBySlug, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, fireOrderNotificationTrigger, formatDate, formatDateOnly, formatDateTime, formatTierRange, generateLocalInvoicePdf, generateNumericOtp, generateSlug, getCompanyDetailsFromSettings, getNextAuthOptions, getPermissionableEntityKeys, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRequiredPermission, getRssArticleSummaryFromItem, getStorefrontNextAuthOptions, getVendorCatalogCreateFlags, googleOAuthRedirectUri, hasEntityPermission, hashOtpCode, hydrateVendorSessionUser, initWhatsappTriggerDispatcher, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isAuthDebugClientEnabled, isAuthDebugEnabled, isCustomerTypeContact, isGoogleAuthPubliclyEnabled, isMaxPerUserUsageReached, isMaxTotalUsageReached, isOpenEndpoint, isOrderEligibleForInvoiceEmail, isPlatformAdministrator, isPublicMethod, isRbacDebugEnabled, isSuperAdmin, isSuperAdminGroupName, isSyntheticCustomerPhone, isVendorAdmin, isVendorGroupName, isVendorOwner, isVendorPortalUser, isVendorStaff, isZipMedia, joinRecipientsForSend, linkUnclaimedContactToUser, llmAgentToChatAgentOptions, llmPlugin, loadPublicThemeSettings, loadSettingsGroupFromDb, loadUserVendorContext, localStoragePlugin, logAuth, logAuthClient, logEntityAccessDecision, logRbac, mergeEmailLayoutCompanyDetails, mergeGuardrailsIntoSystemPrompt, mergeInventoryLines, mergeSeoBySlug, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, nextAuthCookieDebugInfo, normalizeCustomerPhone, normalizeInvoiceTemplateId, normalizePhoneE164, normalizeRefundTiers, notificationTriggerEmitter, orderInventorySnapshotFromRow, orderStatusHoldsStock, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseEmailRecipientsFromConfig, parseHfInferenceEmbeddingBody, parseLlmAgentValidationRules, paymentPlugin, permissionRowsToRecord, pgBossPlugin, pgBossScheduleNameForId, queueEmail, queueErp, queueErpCreateContactIfEnabled, queueErpPaidOrderForOrderId, queueJobScheduleNow, queueOrderPlacedEmails, queuePlugin, queueSms, queueVendorOnboardEmails, queueWhatsApp, rateLimitCheckoutPost, rateLimitKeyForApiRequest, rateLimitPublicApiIfNeeded, reconcileOrderInventoryBetweenSnapshots, recordDiscountUsage, registerEmailQueueProcessor, registerErpQueueProcessor, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, registerWhatsAppQueueProcessor, relativePathFromMediaParentId, renderEmail, renderLayout, resendOrderNotification, resolveBlogCategoryIdByName, resolveEventOrderTemplate, resolveGoogleAuthConfig, resolveInvoiceAssetUrl, resolveOrderInvoicePdfBytes, resolvePublicMetadata, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, resolveVendorScopeFromSessionUser, restoreInventoryForCancelledOrder, retireSoftDeletedUniqueValue, s3StoragePlugin, sanitizeMediaFolderPath, sanitizeStorageSegment, seedAdministratorPermissions, seedDefaultAdmin, sendOrderPlacedEmailsAfterConfirmation, sendVendorOnboardEmails, serializeEmailRecipients, sessionHasEntityAccess, shouldRateLimitPublicWrite, simpleDecrypt, simpleEncrypt, smsPlugin, socialMediaPlugin, streamOrderInvoicePdf, summarizeEntityPerms, summarizeSessionUserForLog, syncJobScheduleToPgBoss, truncateText, validateInventoryForConfirmedOrderLines, validateInventoryForOrderBecomingConfirmed, validateRefundTiers, validateScheduleInput, validateSlug, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, vendorPortalFlagsFromUser, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, withAdminRlsContext, withVendorRlsContext, wrapGetCmsWithMessaging };
package/dist/index.d.ts CHANGED
@@ -966,6 +966,7 @@ declare function deductInventoryForConfirmedOrder(ds: EmOrDs$1, entityMap: Entit
966
966
  declare function restoreInventoryForCancelledOrder(ds: EmOrDs$1, entityMap: EntityMapLike$3, lines: InventoryOrderLine[]): Promise<string | null>;
967
967
 
968
968
  type EntityMap$2 = Record<string, typeorm.EntityTarget<typeorm.ObjectLiteral>>;
969
+ declare function autoExpireOrderIfPaymentTimeExceeded(dataSource: typeorm.DataSource, entityMap: Record<string, unknown>, order: Record<string, unknown> | null | undefined): Promise<Record<string, unknown> | null | undefined>;
969
970
  interface CrudHandlerOptions {
970
971
  requireAuth: (req: Request) => Promise<Response | null>;
971
972
  json: (body: unknown, init?: {
@@ -4069,8 +4070,9 @@ declare enum UserDevicePlatform {
4069
4070
  }
4070
4071
  declare class UserDeviceToken {
4071
4072
  id: string;
4072
- vendorId: number;
4073
- vendor: unknown;
4073
+ /** Staff/vendor app store. Null for customer/marketplace tokens (membership is `vendor_customers`). */
4074
+ vendorId: number | null;
4075
+ vendor: unknown | null;
4074
4076
  userId: number;
4075
4077
  user: unknown;
4076
4078
  token: string;
@@ -4411,4 +4413,4 @@ type CreateCmsAppWithMessagingOptions = CreateCmsAppOptions & EnsureMessagingPlu
4411
4413
  /** `createCmsApp` + messaging plugins + queue processor registration. */
4412
4414
  declare function createCmsAppWithMessaging(options: CreateCmsAppWithMessagingOptions): Promise<CmsApp>;
4413
4415
 
4414
- export { ADMIN_GROUP_NAME, AUTH_PROVIDERS_SETTINGS_GROUP, Address, type AdminNavItem, type AnalyticsHandlerConfig, type AnalyticsPluginConfig, type AppliedDiscountUsage, Attendee, Attribute, type AuthHandlersConfig, type AuthHelpers, type AuthProvidersDataSource, type AuthProvidersEntityMap, type AuthorizeOtpInput, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, type BlogBySlugConfig, type BlogGeneratorBlogDraft, type BlogGeneratorDraftParseMode, type BlogGeneratorPluginConfig, type BlogGeneratorSeoDraft, BlogGeneratorService, Brand, type BuildNextAuthOptionsConfig, CMS_ENTITY_MAP, type CachePluginConfig, type CacheService, type CaptchaProviderId, type CaptchaPublicConfig, CaptchaService, type CaptchaVerifyResult, Cart, CartItem, Category, type ChangePasswordConfig, ChatConversation, ChatMessage, type ChatPublicConfig, type CmsApiHandlerConfig, type CmsApp, type CmsGetter, type CmsMiddlewareConfig, type CmsMiddlewareRequest, type CmsPlugin, Collection, Combo, ComboItem, Comment, type CompanyDetails, Config, Contact, type CreateCmsAppOptions, type CreateCmsAppWithMessagingOptions, type CreateGoogleCustomerDataSource, type CreateGoogleCustomerEntityMap, type CreateGoogleCustomerInput, type CrudHandlerOptions, Currency, CurrencyExchange, Customer, Customer_Contacts, DEFAULT_ADMIN_NAV, DEFAULT_ORDER_NOTIFICATION_TRIGGER_SEEDS, type DashboardStatsConfig, type DataSourceManager, Discount, DiscountRules, type DiscountUsageEntityMap, type ERPPluginConfig, type ERPPluginInstance, ERPSubmissionService, EVENT_ORDER_MESSAGE_TEMPLATE_DEFAULTS, EVENT_ORDER_TEMPLATE_KEY, EVENT_ORDER_TEMPLATE_VARIABLES, type EcommerceAnalyticsConfig, type EmailAttachment, type EmailData, type EmailJobPayload, type EmailPluginConfig, type EmailQueueProcessorOptions, EmailService, type EmailServiceInterface, type EmailTemplateName, type EmailTemplateResult, type EmitOrderNotificationTriggerDeps, type EnsureCustomerRecordInput, type EnsureCustomerUserInput, type EnsureMessagingPluginsOptions, type EnsureVendorCustomerDetails, type EntityCrudAction, type EntityMap$2 as EntityMap, type EntityPermissionFlags, type ErpContactSyncInput, type ErpCreateContactPayload, type ErpJobPayload, type ErpPaidOrderDataSource, type ErpPaidOrderEntityMap, Event, type EventApprovalStatus, type EventOrderMessageTemplateHandlersConfig, type EventOrderNotificationChannel, type EventOrderNotificationTemplates, type EventOrderTemplateOverride, EventProduct, type ExtraPublicWriteRule, type FacebookMeAccountsResponse, type FacebookPageAccount, type ForgotPasswordConfig, Form, type FormBySlugConfig, FormField, FormSubmission, type GetPublicSettingsGroupConfig, type GetPublicSettingsGroupDataSource, type GetSession, type GoogleAuthConfig, INVOICE_TEMPLATE_IDS, INVOICE_TEMPLATE_OPTIONS, type InventoryOrderLine, type InviteAcceptConfig, type InvoiceAddress, type InvoiceCompany, type InvoiceLineItem, type InvoicePdfInput, type InvoiceTemplateId, JOB_RUNNER_QUEUE, type CmsAppLike as JobRunnerCmsAppLike, type JobRunnerDeps, type JobRunnerPayload, JobSchedule, type JobScheduleApiConfig, JobScheduleRun, KNOWN_NOTIFICATION_TRIGGERS, KnowledgeBaseChunk, KnowledgeBaseDocument, type LatestArticleFromFeed, LlmAgent, type LlmAgentKnowledgeApiConfig, LlmAgentKnowledgeDocument, type LlmAgentOptions, type LlmAgentValidationRulesJson, type LlmChatOptions, type LlmEmbeddingProvider, type LlmMessage, type LlmPluginConfig, LlmService, type LlmServiceEmbedOptions, type LlmServiceInterface, type LocalStoragePluginConfig, type Logger, Media, MessageTemplate, type MetaGraphMutationResponse, type NextAuthOptionsConfig, type NextAuthUser, OPEN_ENDPOINTS, ORDER_NOTIFICATION_TRIGGERS, Order, OrderAddresses, OrderDiscounts, type OrderInventorySnapshot, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, type OrderNotificationTriggerKey, type OrderPlacedEmailPayload, type OrderPlacedLineItem, type OrderTriggerPayload, OtpChallenge, type OtpChannel, type OtpPurpose, PERMISSION_REQUIRED_ENDPOINTS, Page, type ParsedLlmAgentValidation, PasswordResetToken, Payment, type PaymentIntent, type PaymentPluginConfig, type PaymentServiceInterface, Permission, type PgBossPluginConfig, PgBossService, type PipelineNames, type PluginContext, Product, type ProductApprovalStatus, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, type PublicThemeSettingsPayload, type QueuePluginConfig, type QueueService, RBAC_ADMIN_ONLY_ENTITIES, type RefundCalculationResult, RefundPolicy, type RefundPolicyLike, type RefundPolicyTier, RefundRequest, type RenderEmailOptions, type RenderedEmail, type ResolveGoogleAuthConfigInput, type ResolveOrderInvoicePdfError, type ResolvedOrderInvoicePdf, RssArticle, RssFeed, type S3StoragePluginConfig, SUPER_ADMIN_GROUP_ID, type SendVendorOnboardEmailInput, Seo, type SeoLike, type SeoMetadataOverrides, type SessionUser, type SetPasswordConfig, type SettingsApiConfig, type SmsJobPayload, type SmsPluginConfig, type SmsProviderChoice, type SmsProviderId, type SmsServiceConfig, type SmsServiceInterface, type SocialLinkItem, type SocialMediaPluginConfig, type StorageService, type StorefrontApiConfig, type StorefrontOtpFlags, Tag, Tax, type TemplateContext, type UploadHandlerConfig, User, type UserAuthApiConfig, type UserAvatarConfig, UserDeviceToken, UserGroup, type UserInviteStatus, type UserProfileConfig, type UsersApiConfig, VENDOR_ADMIN_GROUP_ID, VENDOR_GROUP_NAME, VENDOR_OWNER_GROUP_NAME, VENDOR_SCOPED_STORE_ENTITIES, VENDOR_STORE_RBAC_ENTITIES, Vendor, type VendorCatalogCreateFlags, VendorCustomer, type VendorDashboardConfig, type VendorOnboardHandlersConfig, type VendorOwnerActivation, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, type WhatsAppJobPayload, type WhatsAppPluginConfig, type WhatsAppServiceConfig, type WhatsAppServiceInterface, Wishlist, WishlistItem, ZIP_MIME_TYPES, activeUniqueValueExists, allowRateLimit, analyticsPlugin, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, blogGeneratorPlugin, buildBlogMetadataUserPrompt, buildCaptchaPublicConfig, buildCronFromSchedule, buildEventOrderTemplateVariables, buildLocalInvoicePdfForOrder, buildNextAuthOptions, buildRssUserPromptFromFeeds, buildStorefrontNextAuthOptions, buildUserInviteLink, buildVendorInviteLink, cachePlugin, calculateOrderRefundPreview, calculateRefundFromPolicy, canManageRoles, canManageVendorRoles, canManageVendorTeam, canOnboardVendors, captchaPlugin, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, cn, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createAuthHelpers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCmsAuthBundle, createCmsMiddleware, createCrudByIdHandler, createCrudHandler, createCustomerUserFromGoogleOAuth, createDashboardStatsHandler, createDataSourceManager, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, customerPhoneForEmail, customerPhoneForUser, daysBeforeEventStart, decrementDiscountUsage, deductInventoryForConfirmedOrder, defaultPublicApiMethods, describeEventTierPolicy, emailPlugin, emailTemplates, emitOrderNotificationTrigger, enrichUserWithVendorContext, ensureCustomerForUser, ensureCustomerRecord, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, erpPlugin, explainSessionEntityAccess, fetchSeoBySlug, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, fireOrderNotificationTrigger, formatDate, formatDateOnly, formatDateTime, formatTierRange, generateLocalInvoicePdf, generateNumericOtp, generateSlug, getCompanyDetailsFromSettings, getNextAuthOptions, getPermissionableEntityKeys, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRequiredPermission, getRssArticleSummaryFromItem, getStorefrontNextAuthOptions, getVendorCatalogCreateFlags, googleOAuthRedirectUri, hasEntityPermission, hashOtpCode, hydrateVendorSessionUser, initWhatsappTriggerDispatcher, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isAuthDebugClientEnabled, isAuthDebugEnabled, isCustomerTypeContact, isGoogleAuthPubliclyEnabled, isMaxPerUserUsageReached, isMaxTotalUsageReached, isOpenEndpoint, isOrderEligibleForInvoiceEmail, isPlatformAdministrator, isPublicMethod, isRbacDebugEnabled, isSuperAdmin, isSuperAdminGroupName, isSyntheticCustomerPhone, isVendorAdmin, isVendorGroupName, isVendorOwner, isVendorPortalUser, isVendorStaff, isZipMedia, joinRecipientsForSend, linkUnclaimedContactToUser, llmAgentToChatAgentOptions, llmPlugin, loadPublicThemeSettings, loadSettingsGroupFromDb, loadUserVendorContext, localStoragePlugin, logAuth, logAuthClient, logEntityAccessDecision, logRbac, mergeEmailLayoutCompanyDetails, mergeGuardrailsIntoSystemPrompt, mergeInventoryLines, mergeSeoBySlug, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, nextAuthCookieDebugInfo, normalizeCustomerPhone, normalizeInvoiceTemplateId, normalizePhoneE164, normalizeRefundTiers, notificationTriggerEmitter, orderInventorySnapshotFromRow, orderStatusHoldsStock, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseEmailRecipientsFromConfig, parseHfInferenceEmbeddingBody, parseLlmAgentValidationRules, paymentPlugin, permissionRowsToRecord, pgBossPlugin, pgBossScheduleNameForId, queueEmail, queueErp, queueErpCreateContactIfEnabled, queueErpPaidOrderForOrderId, queueJobScheduleNow, queueOrderPlacedEmails, queuePlugin, queueSms, queueVendorOnboardEmails, queueWhatsApp, rateLimitCheckoutPost, rateLimitKeyForApiRequest, rateLimitPublicApiIfNeeded, reconcileOrderInventoryBetweenSnapshots, recordDiscountUsage, registerEmailQueueProcessor, registerErpQueueProcessor, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, registerWhatsAppQueueProcessor, relativePathFromMediaParentId, renderEmail, renderLayout, resendOrderNotification, resolveBlogCategoryIdByName, resolveEventOrderTemplate, resolveGoogleAuthConfig, resolveInvoiceAssetUrl, resolveOrderInvoicePdfBytes, resolvePublicMetadata, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, resolveVendorScopeFromSessionUser, restoreInventoryForCancelledOrder, retireSoftDeletedUniqueValue, s3StoragePlugin, sanitizeMediaFolderPath, sanitizeStorageSegment, seedAdministratorPermissions, seedDefaultAdmin, sendOrderPlacedEmailsAfterConfirmation, sendVendorOnboardEmails, serializeEmailRecipients, sessionHasEntityAccess, shouldRateLimitPublicWrite, simpleDecrypt, simpleEncrypt, smsPlugin, socialMediaPlugin, streamOrderInvoicePdf, summarizeEntityPerms, summarizeSessionUserForLog, syncJobScheduleToPgBoss, truncateText, validateInventoryForConfirmedOrderLines, validateInventoryForOrderBecomingConfirmed, validateRefundTiers, validateScheduleInput, validateSlug, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, vendorPortalFlagsFromUser, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, withAdminRlsContext, withVendorRlsContext, wrapGetCmsWithMessaging };
4416
+ export { ADMIN_GROUP_NAME, AUTH_PROVIDERS_SETTINGS_GROUP, Address, type AdminNavItem, type AnalyticsHandlerConfig, type AnalyticsPluginConfig, type AppliedDiscountUsage, Attendee, Attribute, type AuthHandlersConfig, type AuthHelpers, type AuthProvidersDataSource, type AuthProvidersEntityMap, type AuthorizeOtpInput, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, type BlogBySlugConfig, type BlogGeneratorBlogDraft, type BlogGeneratorDraftParseMode, type BlogGeneratorPluginConfig, type BlogGeneratorSeoDraft, BlogGeneratorService, Brand, type BuildNextAuthOptionsConfig, CMS_ENTITY_MAP, type CachePluginConfig, type CacheService, type CaptchaProviderId, type CaptchaPublicConfig, CaptchaService, type CaptchaVerifyResult, Cart, CartItem, Category, type ChangePasswordConfig, ChatConversation, ChatMessage, type ChatPublicConfig, type CmsApiHandlerConfig, type CmsApp, type CmsGetter, type CmsMiddlewareConfig, type CmsMiddlewareRequest, type CmsPlugin, Collection, Combo, ComboItem, Comment, type CompanyDetails, Config, Contact, type CreateCmsAppOptions, type CreateCmsAppWithMessagingOptions, type CreateGoogleCustomerDataSource, type CreateGoogleCustomerEntityMap, type CreateGoogleCustomerInput, type CrudHandlerOptions, Currency, CurrencyExchange, Customer, Customer_Contacts, DEFAULT_ADMIN_NAV, DEFAULT_ORDER_NOTIFICATION_TRIGGER_SEEDS, type DashboardStatsConfig, type DataSourceManager, Discount, DiscountRules, type DiscountUsageEntityMap, type ERPPluginConfig, type ERPPluginInstance, ERPSubmissionService, EVENT_ORDER_MESSAGE_TEMPLATE_DEFAULTS, EVENT_ORDER_TEMPLATE_KEY, EVENT_ORDER_TEMPLATE_VARIABLES, type EcommerceAnalyticsConfig, type EmailAttachment, type EmailData, type EmailJobPayload, type EmailPluginConfig, type EmailQueueProcessorOptions, EmailService, type EmailServiceInterface, type EmailTemplateName, type EmailTemplateResult, type EmitOrderNotificationTriggerDeps, type EnsureCustomerRecordInput, type EnsureCustomerUserInput, type EnsureMessagingPluginsOptions, type EnsureVendorCustomerDetails, type EntityCrudAction, type EntityMap$2 as EntityMap, type EntityPermissionFlags, type ErpContactSyncInput, type ErpCreateContactPayload, type ErpJobPayload, type ErpPaidOrderDataSource, type ErpPaidOrderEntityMap, Event, type EventApprovalStatus, type EventOrderMessageTemplateHandlersConfig, type EventOrderNotificationChannel, type EventOrderNotificationTemplates, type EventOrderTemplateOverride, EventProduct, type ExtraPublicWriteRule, type FacebookMeAccountsResponse, type FacebookPageAccount, type ForgotPasswordConfig, Form, type FormBySlugConfig, FormField, FormSubmission, type GetPublicSettingsGroupConfig, type GetPublicSettingsGroupDataSource, type GetSession, type GoogleAuthConfig, INVOICE_TEMPLATE_IDS, INVOICE_TEMPLATE_OPTIONS, type InventoryOrderLine, type InviteAcceptConfig, type InvoiceAddress, type InvoiceCompany, type InvoiceLineItem, type InvoicePdfInput, type InvoiceTemplateId, JOB_RUNNER_QUEUE, type CmsAppLike as JobRunnerCmsAppLike, type JobRunnerDeps, type JobRunnerPayload, JobSchedule, type JobScheduleApiConfig, JobScheduleRun, KNOWN_NOTIFICATION_TRIGGERS, KnowledgeBaseChunk, KnowledgeBaseDocument, type LatestArticleFromFeed, LlmAgent, type LlmAgentKnowledgeApiConfig, LlmAgentKnowledgeDocument, type LlmAgentOptions, type LlmAgentValidationRulesJson, type LlmChatOptions, type LlmEmbeddingProvider, type LlmMessage, type LlmPluginConfig, LlmService, type LlmServiceEmbedOptions, type LlmServiceInterface, type LocalStoragePluginConfig, type Logger, Media, MessageTemplate, type MetaGraphMutationResponse, type NextAuthOptionsConfig, type NextAuthUser, OPEN_ENDPOINTS, ORDER_NOTIFICATION_TRIGGERS, Order, OrderAddresses, OrderDiscounts, type OrderInventorySnapshot, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, type OrderNotificationTriggerKey, type OrderPlacedEmailPayload, type OrderPlacedLineItem, type OrderTriggerPayload, OtpChallenge, type OtpChannel, type OtpPurpose, PERMISSION_REQUIRED_ENDPOINTS, Page, type ParsedLlmAgentValidation, PasswordResetToken, Payment, type PaymentIntent, type PaymentPluginConfig, type PaymentServiceInterface, Permission, type PgBossPluginConfig, PgBossService, type PipelineNames, type PluginContext, Product, type ProductApprovalStatus, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, type PublicThemeSettingsPayload, type QueuePluginConfig, type QueueService, RBAC_ADMIN_ONLY_ENTITIES, type RefundCalculationResult, RefundPolicy, type RefundPolicyLike, type RefundPolicyTier, RefundRequest, type RenderEmailOptions, type RenderedEmail, type ResolveGoogleAuthConfigInput, type ResolveOrderInvoicePdfError, type ResolvedOrderInvoicePdf, RssArticle, RssFeed, type S3StoragePluginConfig, SUPER_ADMIN_GROUP_ID, type SendVendorOnboardEmailInput, Seo, type SeoLike, type SeoMetadataOverrides, type SessionUser, type SetPasswordConfig, type SettingsApiConfig, type SmsJobPayload, type SmsPluginConfig, type SmsProviderChoice, type SmsProviderId, type SmsServiceConfig, type SmsServiceInterface, type SocialLinkItem, type SocialMediaPluginConfig, type StorageService, type StorefrontApiConfig, type StorefrontOtpFlags, Tag, Tax, type TemplateContext, type UploadHandlerConfig, User, type UserAuthApiConfig, type UserAvatarConfig, UserDeviceToken, UserGroup, type UserInviteStatus, type UserProfileConfig, type UsersApiConfig, VENDOR_ADMIN_GROUP_ID, VENDOR_GROUP_NAME, VENDOR_OWNER_GROUP_NAME, VENDOR_SCOPED_STORE_ENTITIES, VENDOR_STORE_RBAC_ENTITIES, Vendor, type VendorCatalogCreateFlags, VendorCustomer, type VendorDashboardConfig, type VendorOnboardHandlersConfig, type VendorOwnerActivation, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, type WhatsAppJobPayload, type WhatsAppPluginConfig, type WhatsAppServiceConfig, type WhatsAppServiceInterface, Wishlist, WishlistItem, ZIP_MIME_TYPES, activeUniqueValueExists, allowRateLimit, analyticsPlugin, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, autoExpireOrderIfPaymentTimeExceeded, blogGeneratorPlugin, buildBlogMetadataUserPrompt, buildCaptchaPublicConfig, buildCronFromSchedule, buildEventOrderTemplateVariables, buildLocalInvoicePdfForOrder, buildNextAuthOptions, buildRssUserPromptFromFeeds, buildStorefrontNextAuthOptions, buildUserInviteLink, buildVendorInviteLink, cachePlugin, calculateOrderRefundPreview, calculateRefundFromPolicy, canManageRoles, canManageVendorRoles, canManageVendorTeam, canOnboardVendors, captchaPlugin, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, cn, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createAuthHelpers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCmsAuthBundle, createCmsMiddleware, createCrudByIdHandler, createCrudHandler, createCustomerUserFromGoogleOAuth, createDashboardStatsHandler, createDataSourceManager, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, customerPhoneForEmail, customerPhoneForUser, daysBeforeEventStart, decrementDiscountUsage, deductInventoryForConfirmedOrder, defaultPublicApiMethods, describeEventTierPolicy, emailPlugin, emailTemplates, emitOrderNotificationTrigger, enrichUserWithVendorContext, ensureCustomerForUser, ensureCustomerRecord, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, erpPlugin, explainSessionEntityAccess, fetchSeoBySlug, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, fireOrderNotificationTrigger, formatDate, formatDateOnly, formatDateTime, formatTierRange, generateLocalInvoicePdf, generateNumericOtp, generateSlug, getCompanyDetailsFromSettings, getNextAuthOptions, getPermissionableEntityKeys, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRequiredPermission, getRssArticleSummaryFromItem, getStorefrontNextAuthOptions, getVendorCatalogCreateFlags, googleOAuthRedirectUri, hasEntityPermission, hashOtpCode, hydrateVendorSessionUser, initWhatsappTriggerDispatcher, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isAuthDebugClientEnabled, isAuthDebugEnabled, isCustomerTypeContact, isGoogleAuthPubliclyEnabled, isMaxPerUserUsageReached, isMaxTotalUsageReached, isOpenEndpoint, isOrderEligibleForInvoiceEmail, isPlatformAdministrator, isPublicMethod, isRbacDebugEnabled, isSuperAdmin, isSuperAdminGroupName, isSyntheticCustomerPhone, isVendorAdmin, isVendorGroupName, isVendorOwner, isVendorPortalUser, isVendorStaff, isZipMedia, joinRecipientsForSend, linkUnclaimedContactToUser, llmAgentToChatAgentOptions, llmPlugin, loadPublicThemeSettings, loadSettingsGroupFromDb, loadUserVendorContext, localStoragePlugin, logAuth, logAuthClient, logEntityAccessDecision, logRbac, mergeEmailLayoutCompanyDetails, mergeGuardrailsIntoSystemPrompt, mergeInventoryLines, mergeSeoBySlug, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, nextAuthCookieDebugInfo, normalizeCustomerPhone, normalizeInvoiceTemplateId, normalizePhoneE164, normalizeRefundTiers, notificationTriggerEmitter, orderInventorySnapshotFromRow, orderStatusHoldsStock, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseEmailRecipientsFromConfig, parseHfInferenceEmbeddingBody, parseLlmAgentValidationRules, paymentPlugin, permissionRowsToRecord, pgBossPlugin, pgBossScheduleNameForId, queueEmail, queueErp, queueErpCreateContactIfEnabled, queueErpPaidOrderForOrderId, queueJobScheduleNow, queueOrderPlacedEmails, queuePlugin, queueSms, queueVendorOnboardEmails, queueWhatsApp, rateLimitCheckoutPost, rateLimitKeyForApiRequest, rateLimitPublicApiIfNeeded, reconcileOrderInventoryBetweenSnapshots, recordDiscountUsage, registerEmailQueueProcessor, registerErpQueueProcessor, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, registerWhatsAppQueueProcessor, relativePathFromMediaParentId, renderEmail, renderLayout, resendOrderNotification, resolveBlogCategoryIdByName, resolveEventOrderTemplate, resolveGoogleAuthConfig, resolveInvoiceAssetUrl, resolveOrderInvoicePdfBytes, resolvePublicMetadata, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, resolveVendorScopeFromSessionUser, restoreInventoryForCancelledOrder, retireSoftDeletedUniqueValue, s3StoragePlugin, sanitizeMediaFolderPath, sanitizeStorageSegment, seedAdministratorPermissions, seedDefaultAdmin, sendOrderPlacedEmailsAfterConfirmation, sendVendorOnboardEmails, serializeEmailRecipients, sessionHasEntityAccess, shouldRateLimitPublicWrite, simpleDecrypt, simpleEncrypt, smsPlugin, socialMediaPlugin, streamOrderInvoicePdf, summarizeEntityPerms, summarizeSessionUserForLog, syncJobScheduleToPgBoss, truncateText, validateInventoryForConfirmedOrderLines, validateInventoryForOrderBecomingConfirmed, validateRefundTiers, validateScheduleInput, validateSlug, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, vendorPortalFlagsFromUser, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, withAdminRlsContext, withVendorRlsContext, wrapGetCmsWithMessaging };
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
1
  export { emitOrderNotificationTrigger, fireOrderNotificationTrigger } from './chunk-MXIWUFBP.js';
2
- import { checkMultiVendorEnabled, loadUserVendorContext, getPublicSettingsGroup, BlogGeneratorService } from './chunk-BAUV5FZQ.js';
3
- export { Address, Attendee, Attribute, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, BlogGeneratorService, Brand, CMS_ENTITY_MAP, Cart, CartItem, Category, ChatConversation, ChatMessage, Collection, Combo, ComboItem, Comment, Config, Contact, Currency, CurrencyExchange, Customer, Customer_Contacts, Discount, DiscountRules, Event, EventProduct, Form, FormField, FormSubmission, JobSchedule, JobScheduleRun, KnowledgeBaseChunk, KnowledgeBaseDocument, LlmAgent, LlmAgentKnowledgeDocument, Media, MessageTemplate, Order, OrderAddresses, OrderDiscounts, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, OtpChallenge, Page, PasswordResetToken, Payment, Permission, Product, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, RefundPolicy, RefundRequest, RssArticle, RssFeed, Seo, Tag, Tax, User, UserDeviceToken, UserGroup, Vendor, VendorCustomer, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, Wishlist, WishlistItem, ZIP_MIME_TYPES, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, buildBlogMetadataUserPrompt, buildCronFromSchedule, buildRssUserPromptFromFeeds, buildUserInviteLink, buildVendorInviteLink, calculateOrderRefundPreview, calculateRefundFromPolicy, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCrudByIdHandler, createCrudHandler, createDashboardStatsHandler, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, daysBeforeEventStart, decrementDiscountUsage, describeEventTierPolicy, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, formatTierRange, generateNumericOtp, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRssArticleSummaryFromItem, getVendorCatalogCreateFlags, hashOtpCode, hydrateVendorSessionUser, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isCustomerTypeContact, isMaxPerUserUsageReached, isMaxTotalUsageReached, isZipMedia, llmAgentToChatAgentOptions, loadSettingsGroupFromDb, loadUserVendorContext, mergeGuardrailsIntoSystemPrompt, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, normalizePhoneE164, normalizeRefundTiers, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseLlmAgentValidationRules, pgBossScheduleNameForId, queueErpCreateContactIfEnabled, queueJobScheduleNow, queuePlugin, queueSms, recordDiscountUsage, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, relativePathFromMediaParentId, resolveBlogCategoryIdByName, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, sanitizeMediaFolderPath, sanitizeStorageSegment, sendVendorOnboardEmails, simpleDecrypt, simpleEncrypt, syncJobScheduleToPgBoss, validateRefundTiers, validateScheduleInput, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, wrapGetCmsWithMessaging } from './chunk-BAUV5FZQ.js';
2
+ import { checkMultiVendorEnabled, loadUserVendorContext, getPublicSettingsGroup, BlogGeneratorService } from './chunk-BTUEUA5H.js';
3
+ export { Address, Attendee, Attribute, BLOG_GENERATOR_AGENT_NAME, BLOG_GENERATOR_DEFAULT_SYSTEM_INSTRUCTION, BLOG_GENERATOR_DEFAULT_VALIDATION_RULES, BLOG_GENERATOR_LLM_AGENT_SLUG, BLOG_GENERATOR_MARKDOWN_ARTICLE_SEPARATOR, BLOG_METADATA_ENRICHER_AGENT_NAME, BLOG_METADATA_ENRICHER_DEFAULT_SYSTEM_INSTRUCTION, BLOG_METADATA_ENRICHER_DEFAULT_VALIDATION_RULES, BLOG_METADATA_ENRICHER_LLM_AGENT_SLUG, Blog, BlogGeneratorService, Brand, CMS_ENTITY_MAP, Cart, CartItem, Category, ChatConversation, ChatMessage, Collection, Combo, ComboItem, Comment, Config, Contact, Currency, CurrencyExchange, Customer, Customer_Contacts, Discount, DiscountRules, Event, EventProduct, Form, FormField, FormSubmission, JobSchedule, JobScheduleRun, KnowledgeBaseChunk, KnowledgeBaseDocument, LlmAgent, LlmAgentKnowledgeDocument, Media, MessageTemplate, Order, OrderAddresses, OrderDiscounts, OrderItem, OrderNotificationBinding, OrderNotificationTrigger, OtpChallenge, Page, PasswordResetToken, Payment, Permission, Product, ProductAttribute, ProductCategory, ProductConfig, ProductVariant, RefundPolicy, RefundRequest, RssArticle, RssFeed, Seo, Tag, Tax, User, UserDeviceToken, UserGroup, Vendor, VendorCustomer, VendorRole, VendorRolePermission, VendorUser, VendorUserProfile, Wishlist, WishlistItem, ZIP_MIME_TYPES, applyApprovalStatusSideEffects, applyEventApprovalStatusSideEffects, applyRotatingVendorInvite, applyVendorCustomersContactFilter, applyVendorEventCreateApproval, applyVendorProductCreateApproval, assertCaptchaOk, assertContactAllowedForVendorOrder, assertEventApprovalUpdate, assertProductApprovalUpdate, autoExpireOrderIfPaymentTimeExceeded, buildBlogMetadataUserPrompt, buildCronFromSchedule, buildRssUserPromptFromFeeds, buildUserInviteLink, buildVendorInviteLink, calculateOrderRefundPreview, calculateRefundFromPolicy, checkAndIncrementDiscountUsage, checkEventsEnabled, checkMultiVendorEnabled, completeUserInviteAccept, consumeAppliedDiscountUsages, contactIsVendorCustomer, countDiscountOrdersForContact, countRecentOtpSends, createAnalyticsHandlers, createBlogBySlugHandler, createChangePasswordHandler, createCmsApiHandler, createCmsApp, createCmsAppWithMessaging, createCrudByIdHandler, createCrudHandler, createDashboardStatsHandler, createEcommerceAnalyticsHandler, createEventOrderMessageTemplateHandlers, createForgotPasswordHandler, createFormBySlugHandler, createInviteAcceptHandler, createJobScheduleHandlers, createLlmAgentKnowledgeHandlers, createMediaZipExtractHandler, createMessageTemplateRowLoader, createOtpChallenge, createSetPasswordHandler, createSettingsApiHandlers, createSocialMediaHandlers, createStorefrontApiHandler, createUploadHandler, createUserAuthApiRouter, createUserAvatarHandler, createUserProfileHandler, createUsersApiHandlers, createVendorDashboardHandler, createVendorOnboardHandlers, daysBeforeEventStart, decrementDiscountUsage, describeEventTierPolicy, ensureMessagingPluginsOnCms, ensureScheduleQueueWorker, ensureVendorCustomerForOrderContact, ensureVendorCustomersForOrder, findActiveRefundPolicyForVendor, findUserByInviteToken, findVendorByInviteToken, formatTierRange, generateNumericOtp, getPublicSettingsGroup, getRequireEventApproval, getRequireProductApproval, getRssArticleSummaryFromItem, getVendorCatalogCreateFlags, hashOtpCode, hydrateVendorSessionUser, invalidateEventsCache, invalidateMultiVendorCache, invalidateRequireEventApprovalCache, invalidateRequireProductApprovalCache, invalidateVendorCatalogCreateFlagsCache, isCustomerTypeContact, isMaxPerUserUsageReached, isMaxTotalUsageReached, isZipMedia, llmAgentToChatAgentOptions, loadSettingsGroupFromDb, loadUserVendorContext, mergeGuardrailsIntoSystemPrompt, messagingPlugins, metaFetchUserManagedPages, metaPostPageFeed, metaPostPagePhoto, metaResolvePageAccessToken, newUserInviteToken, normalizePhoneE164, normalizeRefundTiers, overlayCmsPlugins, parseBlogGeneratorAgentContent, parseBlogGeneratorModelOutput, parseBlogMetadataEnrichmentJson, parseLlmAgentValidationRules, pgBossScheduleNameForId, queueErpCreateContactIfEnabled, queueJobScheduleNow, queuePlugin, queueSms, recordDiscountUsage, registerJobRunnerWorker, registerMessagingQueueProcessors, registerSmsQueueProcessor, relativePathFromMediaParentId, resolveBlogCategoryIdByName, resolveSettingsEncryptionKey, resolveVendorIdForContactCheck, sanitizeMediaFolderPath, sanitizeStorageSegment, sendVendorOnboardEmails, simpleDecrypt, simpleEncrypt, syncJobScheduleToPgBoss, validateRefundTiers, validateScheduleInput, validateUserMessageAgainstAgentRules, validateUserMessageAgainstStructuredRules, verifyAndConsumeOtpChallenge, verifyOtpCodeHash, whatsappPlugin, wrapGetCmsWithMessaging } from './chunk-BTUEUA5H.js';
4
4
  import { PgBossService } from './chunk-GO7PPYNU.js';
5
5
  export { JOB_RUNNER_QUEUE, PgBossService } from './chunk-GO7PPYNU.js';
6
6
  export { deductInventoryForConfirmedOrder, mergeInventoryLines, orderInventorySnapshotFromRow, orderStatusHoldsStock, reconcileOrderInventoryBetweenSnapshots, restoreInventoryForCancelledOrder, validateInventoryForConfirmedOrderLines, validateInventoryForOrderBecomingConfirmed } from './chunk-3K5AIEIZ.js';
7
- import { parseEmailRecipientsFromConfig } from './chunk-CTXBYO2J.js';
8
- export { EmailService, buildEventOrderTemplateVariables, emailPlugin, emailTemplates, initWhatsappTriggerDispatcher, joinRecipientsForSend, parseEmailRecipientsFromConfig, queueWhatsApp, registerWhatsAppQueueProcessor, renderEmail, renderLayout, resendOrderNotification, serializeEmailRecipients } from './chunk-CTXBYO2J.js';
7
+ import { parseEmailRecipientsFromConfig } from './chunk-HYW3MUXT.js';
8
+ export { EmailService, buildEventOrderTemplateVariables, emailPlugin, emailTemplates, initWhatsappTriggerDispatcher, joinRecipientsForSend, parseEmailRecipientsFromConfig, queueWhatsApp, registerWhatsAppQueueProcessor, renderEmail, renderLayout, resendOrderNotification, serializeEmailRecipients } from './chunk-HYW3MUXT.js';
9
9
  export { KNOWN_NOTIFICATION_TRIGGERS, notificationTriggerEmitter } from './chunk-HCIRL37O.js';
10
10
  import './chunk-JXF23MPG.js';
11
11
  import { queueOrderPlacedEmails } from './chunk-L3525VXI.js';
@@ -0,0 +1,28 @@
1
+ import type { MigrationInterface, QueryRunner } from 'typeorm';
2
+
3
+ /**
4
+ * Customer/marketplace apps register FCM tokens without a store.
5
+ * Multi-vendor membership stays on `vendor_customers`; staff apps still send vendor_id.
6
+ */
7
+ export class NullableUserDeviceTokenVendorId1782700000000 implements MigrationInterface {
8
+ name = 'NullableUserDeviceTokenVendorId1782700000000';
9
+
10
+ public async up(queryRunner: QueryRunner): Promise<void> {
11
+ await queryRunner.query(`
12
+ ALTER TABLE "user_device_tokens"
13
+ ALTER COLUMN "vendor_id" DROP NOT NULL
14
+ `);
15
+ }
16
+
17
+ public async down(queryRunner: QueryRunner): Promise<void> {
18
+ await queryRunner.query(`
19
+ UPDATE "user_device_tokens"
20
+ SET "vendor_id" = (SELECT v.id FROM "vendors" v WHERE v.deleted = false ORDER BY v.id LIMIT 1)
21
+ WHERE "vendor_id" IS NULL
22
+ `);
23
+ await queryRunner.query(`
24
+ ALTER TABLE "user_device_tokens"
25
+ ALTER COLUMN "vendor_id" SET NOT NULL
26
+ `);
27
+ }
28
+ }
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkJN4AFHZ4_cjs = require('./chunk-JN4AFHZ4.cjs');
3
+ var chunkHXLC56ZK_cjs = require('./chunk-HXLC56ZK.cjs');
4
4
  require('./chunk-UCKN4BBY.cjs');
5
5
  require('./chunk-V25RDUOU.cjs');
6
6
  require('./chunk-BXYZDMTZ.cjs');
@@ -12,13 +12,13 @@ require('./chunk-USNT2KNT.cjs');
12
12
 
13
13
  Object.defineProperty(exports, "getSettingsGroup", {
14
14
  enumerable: true,
15
- get: function () { return chunkJN4AFHZ4_cjs.getSettingsGroup; }
15
+ get: function () { return chunkHXLC56ZK_cjs.getSettingsGroup; }
16
16
  });
17
17
  Object.defineProperty(exports, "initWhatsappTriggerDispatcher", {
18
18
  enumerable: true,
19
- get: function () { return chunkJN4AFHZ4_cjs.initWhatsappTriggerDispatcher; }
19
+ get: function () { return chunkHXLC56ZK_cjs.initWhatsappTriggerDispatcher; }
20
20
  });
21
21
  Object.defineProperty(exports, "resendOrderNotification", {
22
22
  enumerable: true,
23
- get: function () { return chunkJN4AFHZ4_cjs.resendOrderNotification; }
23
+ get: function () { return chunkHXLC56ZK_cjs.resendOrderNotification; }
24
24
  });
@@ -1,4 +1,4 @@
1
- export { getSettingsGroup, initWhatsappTriggerDispatcher, resendOrderNotification } from './chunk-CTXBYO2J.js';
1
+ export { getSettingsGroup, initWhatsappTriggerDispatcher, resendOrderNotification } from './chunk-HYW3MUXT.js';
2
2
  import './chunk-HCIRL37O.js';
3
3
  import './chunk-L3525VXI.js';
4
4
  import './chunk-2KUCQVAQ.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infuro/cms-core",
3
- "version": "1.0.57",
3
+ "version": "1.0.59",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",