@cosmicdrift/kumiko-bundled-features 0.369.0 → 0.370.0
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/account-security/constants.d.ts +4 -0
- package/dist/account-security/constants.js +5 -0
- package/dist/account-security/feature.d.ts +14 -0
- package/dist/account-security/feature.js +62 -0
- package/dist/account-security/i18n.d.ts +6 -0
- package/dist/account-security/i18n.js +6 -0
- package/dist/account-security/index.d.ts +3 -0
- package/dist/account-security/index.js +3 -0
- package/dist/admin-shell/feature.d.ts +1 -1
- package/dist/admin-shell/index.d.ts +4 -4
- package/dist/admin-shell/overview-panels.d.ts +1 -1
- package/dist/admin-shell/web/index.d.ts +1 -1
- package/dist/agent-tools/agent-manifest.d.ts +1 -1
- package/dist/agent-tools/index.d.ts +8 -8
- package/dist/agent-tools/manifest-deny-qns.d.ts +1 -1
- package/dist/agent-tools/tool-catalog.d.ts +1 -1
- package/dist/agent-tools/tool-dispatch.d.ts +1 -1
- package/dist/audit/handlers/resolve-audit-tenant.d.ts +1 -1
- package/dist/audit/index.d.ts +3 -3
- package/dist/audit/web/index.d.ts +1 -1
- package/dist/auth-email-password/bootstrap.d.ts +1 -1
- package/dist/auth-email-password/feature.d.ts +7 -6
- package/dist/auth-email-password/feature.js +3 -1
- package/dist/auth-email-password/handlers/confirm-token-flow.d.ts +1 -1
- package/dist/auth-email-password/handlers/invite-accept-with-login.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/invite-create.write.d.ts +2 -2
- package/dist/auth-email-password/handlers/invite-signup-complete.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/login.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/request-account-unlock.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/request-email-verification.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/request-password-reset.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/signup-confirm.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/signup-request.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/switch-tenant-mfa-gate.write.d.ts +1 -1
- package/dist/auth-email-password/handlers/token-request-handler.d.ts +2 -2
- package/dist/auth-email-password/index.d.ts +13 -13
- package/dist/auth-email-password/lockout-store.d.ts +1 -1
- package/dist/auth-email-password/magic-link-mail.d.ts +1 -1
- package/dist/auth-email-password/seeding.d.ts +3 -3
- package/dist/auth-email-password/signed-token.d.ts +1 -1
- package/dist/auth-email-password/signup-token-store.d.ts +1 -1
- package/dist/auth-email-password/testing.d.ts +1 -1
- package/dist/auth-email-password/web/auth-gate.d.ts +1 -1
- package/dist/auth-email-password/web/client-plugin.d.ts +2 -2
- package/dist/auth-email-password/web/index.d.ts +42 -42
- package/dist/auth-email-password/web/session-bootstrap-error.d.ts +1 -1
- package/dist/auth-email-password/web/session.d.ts +1 -1
- package/dist/auth-email-password/web/signup-complete-screen.d.ts +1 -1
- package/dist/auth-foundation/feature.d.ts +2 -6
- package/dist/auth-foundation/feature.js +0 -2
- package/dist/auth-foundation/index.d.ts +3 -3
- package/dist/auth-foundation/index.js +1 -1
- package/dist/auth-foundation/resolve-anonymous-access.d.ts +1 -1
- package/dist/auth-mfa/env.d.ts +13 -0
- package/dist/auth-mfa/env.js +24 -0
- package/dist/auth-mfa/errors.d.ts +1 -1
- package/dist/auth-mfa/feature-exports.d.ts +12 -0
- package/dist/auth-mfa/feature-exports.js +72 -0
- package/dist/auth-mfa/feature.d.ts +6 -12
- package/dist/auth-mfa/feature.js +53 -70
- package/dist/auth-mfa/handlers/reencrypt.job.d.ts +1 -1
- package/dist/auth-mfa/index.d.ts +12 -9
- package/dist/auth-mfa/index.js +4 -2
- package/dist/auth-mfa/mfa-challenge-token.d.ts +1 -1
- package/dist/auth-mfa/mfa-preauth-setup-token.d.ts +1 -1
- package/dist/auth-mfa/mfa-status-checker.d.ts +1 -1
- package/dist/auth-mfa/mfa-verify-attempts.d.ts +1 -1
- package/dist/auth-mfa/testing.d.ts +1 -1
- package/dist/auth-mfa/token-secrets.d.ts +7 -0
- package/dist/auth-mfa/token-secrets.js +13 -0
- package/dist/auth-mfa/verify-factor.d.ts +1 -1
- package/dist/auth-mfa/web/index.d.ts +15 -15
- package/dist/auth-mfa/web/mfa-client.d.ts +1 -1
- package/dist/auth-mfa-user-data/index.d.ts +0 -4
- package/dist/auth-mfa-user-data/index.js +0 -2
- package/dist/billing-foundation/checkout-core.d.ts +2 -2
- package/dist/billing-foundation/consumer-protection/confirmation-mail.d.ts +2 -2
- package/dist/billing-foundation/consumer-protection/consent-gate.d.ts +1 -1
- package/dist/billing-foundation/consumer-protection/consent-text.d.ts +2 -2
- package/dist/billing-foundation/consumer-protection/issue-confirmation.d.ts +1 -1
- package/dist/billing-foundation/consumer-protection/register-consent.d.ts +1 -1
- package/dist/billing-foundation/consumer-protection/register-termination.d.ts +1 -1
- package/dist/billing-foundation/consumer-protection/termination-mail.d.ts +3 -3
- package/dist/billing-foundation/consumer-protection/termination-notify.d.ts +5 -5
- package/dist/billing-foundation/consumer-protection/termination-pages.d.ts +2 -2
- package/dist/billing-foundation/consumer-protection/termination-record.d.ts +3 -3
- package/dist/billing-foundation/consumer-protection/termination-request.d.ts +2 -2
- package/dist/billing-foundation/consumer-protection/termination-texts.d.ts +2 -2
- package/dist/billing-foundation/feature.d.ts +1 -3
- package/dist/billing-foundation/feature.js +0 -2
- package/dist/billing-foundation/handlers/billing-plans.query.d.ts +1 -1
- package/dist/billing-foundation/handlers/create-checkout-session.write.d.ts +1 -1
- package/dist/billing-foundation/handlers/create-portal-session.write.d.ts +1 -1
- package/dist/billing-foundation/handlers/start-plan-checkout.write.d.ts +1 -1
- package/dist/billing-foundation/handlers/switch-plan.write.d.ts +1 -1
- package/dist/billing-foundation/index.d.ts +16 -16
- package/dist/billing-foundation/index.js +1 -1
- package/dist/billing-foundation/plan-catalog.d.ts +1 -1
- package/dist/billing-foundation/subscription-tier-sync.d.ts +3 -1
- package/dist/billing-foundation/subscription-tier-sync.js +3 -2
- package/dist/billing-foundation/types.d.ts +3 -3
- package/dist/billing-foundation/validate-options.d.ts +1 -1
- package/dist/billing-foundation/web/checkout-consent-dialog.d.ts +1 -1
- package/dist/billing-foundation/web/index.d.ts +6 -6
- package/dist/cap-counter/calendar-cap-usage-reservation.d.ts +4 -4
- package/dist/cap-counter/cap-reservation.d.ts +1 -1
- package/dist/cap-counter/enforce-cap.d.ts +1 -1
- package/dist/cap-counter/feature.d.ts +0 -4
- package/dist/cap-counter/feature.js +0 -2
- package/dist/cap-counter/index.d.ts +13 -13
- package/dist/cap-counter/index.js +1 -1
- package/dist/cap-counter/value-cap-guard.d.ts +1 -1
- package/dist/cap-counter/with-cap-enforcement.d.ts +1 -1
- package/dist/cap-overview/feature.d.ts +1 -1
- package/dist/cap-overview/handlers/caps-usage.query.d.ts +1 -1
- package/dist/cap-overview/handlers/tenant-caps-list.query.d.ts +1 -1
- package/dist/cap-overview/index.d.ts +6 -6
- package/dist/cap-overview/screens.d.ts +1 -1
- package/dist/cap-overview/types.d.ts +1 -1
- package/dist/cap-overview/usage-math.d.ts +1 -1
- package/dist/cap-overview/web/cap-usage-bar.d.ts +1 -1
- package/dist/cap-overview/web/index.d.ts +4 -4
- package/dist/channel-discord/discord-channel.d.ts +1 -1
- package/dist/channel-discord/feature.d.ts +1 -1
- package/dist/channel-discord/index.d.ts +2 -2
- package/dist/channel-email/email-channel.d.ts +2 -2
- package/dist/channel-email/env.d.ts +14 -0
- package/dist/channel-email/env.js +27 -0
- package/dist/channel-email/feature.d.ts +14 -3
- package/dist/channel-email/feature.js +5 -1
- package/dist/channel-email/index.d.ts +6 -5
- package/dist/channel-email/index.js +1 -0
- package/dist/channel-email/pii-guard.d.ts +1 -1
- package/dist/channel-email/smtp-transport.d.ts +1 -1
- package/dist/channel-email/types.d.ts +1 -1
- package/dist/channel-in-app/in-app-channel.d.ts +1 -1
- package/dist/channel-in-app/index.d.ts +4 -4
- package/dist/channel-push/feature.d.ts +1 -1
- package/dist/channel-push/index.d.ts +3 -3
- package/dist/channel-push/push-channel.d.ts +2 -2
- package/dist/channel-slack/feature.d.ts +1 -1
- package/dist/channel-slack/index.d.ts +2 -2
- package/dist/channel-slack/slack-channel.d.ts +1 -1
- package/dist/channel-teams/feature.d.ts +1 -1
- package/dist/channel-teams/index.d.ts +2 -2
- package/dist/channel-teams/teams-channel.d.ts +1 -1
- package/dist/channel-telegram/feature.d.ts +1 -1
- package/dist/channel-telegram/index.d.ts +2 -2
- package/dist/channel-telegram/telegram-channel.d.ts +1 -1
- package/dist/compliance-profiles/feature.d.ts +1 -1
- package/dist/compliance-profiles/index.d.ts +3 -3
- package/dist/compliance-profiles/web/index.d.ts +2 -2
- package/dist/compliance-profiles-ops/index.d.ts +0 -8
- package/dist/compliance-profiles-ops/index.js +0 -2
- package/dist/config/feature.d.ts +1 -1
- package/dist/config/handlers/reencrypt.job.d.ts +1 -1
- package/dist/config/index.d.ts +8 -8
- package/dist/config/web/client-plugin.d.ts +1 -1
- package/dist/config/web/index.d.ts +2 -2
- package/dist/crypto-shredding/env/index.d.ts +21 -0
- package/dist/crypto-shredding/env/index.js +78 -0
- package/dist/crypto-shredding/feature.d.ts +17 -2
- package/dist/crypto-shredding/feature.js +5 -1
- package/dist/crypto-shredding/index.d.ts +4 -3
- package/dist/crypto-shredding/index.js +1 -0
- package/dist/custom-fields/feature.d.ts +0 -17
- package/dist/custom-fields/feature.js +0 -2
- package/dist/custom-fields/index.d.ts +10 -10
- package/dist/custom-fields/index.js +1 -1
- package/dist/custom-fields/lib/define-or-resurrect.d.ts +2 -2
- package/dist/custom-fields/lib/field-access.d.ts +1 -1
- package/dist/custom-fields/lib/field-definition-row.d.ts +1 -1
- package/dist/custom-fields/lib/quota.d.ts +1 -1
- package/dist/custom-fields/web/index.d.ts +3 -3
- package/dist/data-retention/_internal/parse-override.d.ts +1 -1
- package/dist/data-retention/feature.d.ts +7 -7
- package/dist/data-retention/handlers/policy-for.query.d.ts +1 -1
- package/dist/data-retention/index.d.ts +3 -3
- package/dist/data-retention/resolve-for-tenant.d.ts +2 -2
- package/dist/data-retention/resolve-tenant-preset.d.ts +1 -1
- package/dist/data-retention/resolver.d.ts +1 -1
- package/dist/data-retention/run-retention-cleanup.d.ts +2 -2
- package/dist/delivery/attachment-ref.d.ts +1 -1
- package/dist/delivery/attempt-log.d.ts +1 -1
- package/dist/delivery/channel-context.d.ts +2 -2
- package/dist/delivery/chat-webhook-channel.d.ts +2 -2
- package/dist/delivery/constants.d.ts +1 -1
- package/dist/delivery/delivery-service.d.ts +2 -2
- package/dist/delivery/feature.js +2 -0
- package/dist/delivery/handlers/log.query.d.ts +1 -1
- package/dist/delivery/handlers/unsubscribe-page-chrome.query.d.ts +5 -0
- package/dist/delivery/handlers/unsubscribe-page-chrome.query.js +44 -0
- package/dist/delivery/index.d.ts +20 -20
- package/dist/delivery/notify-factory.d.ts +1 -1
- package/dist/delivery/public-names.d.ts +1 -0
- package/dist/delivery/public-names.js +1 -0
- package/dist/delivery/testing.d.ts +3 -3
- package/dist/delivery/types.d.ts +3 -3
- package/dist/delivery/unsubscribe-link.d.ts +1 -1
- package/dist/delivery/unsubscribe-page-strings.d.ts +4 -0
- package/dist/delivery/unsubscribe-page-strings.js +4 -0
- package/dist/delivery/unsubscribe-page.d.ts +27 -0
- package/dist/delivery/unsubscribe-page.js +192 -0
- package/dist/delivery/unsubscribe.d.ts +11 -3
- package/dist/delivery/unsubscribe.js +146 -64
- package/dist/delivery/web/index.d.ts +2 -2
- package/dist/derivatives-sharp/feature.d.ts +0 -4
- package/dist/derivatives-sharp/feature.js +0 -2
- package/dist/derivatives-sharp/index.d.ts +2 -2
- package/dist/derivatives-sharp/index.js +1 -1
- package/dist/document-ingest-foundation/feature.d.ts +0 -7
- package/dist/document-ingest-foundation/feature.js +0 -2
- package/dist/document-ingest-foundation/index.d.ts +7 -7
- package/dist/document-ingest-foundation/index.js +1 -1
- package/dist/document-ingest-foundation/pages.d.ts +1 -1
- package/dist/document-ingest-foundation/providers.d.ts +1 -1
- package/dist/document-ingest-foundation/write-document-extract.d.ts +1 -1
- package/dist/feature-toggles/compose-tier-resolver.d.ts +1 -1
- package/dist/feature-toggles/feature.d.ts +5 -5
- package/dist/feature-toggles/handlers/set.write.d.ts +1 -1
- package/dist/feature-toggles/index.d.ts +3 -3
- package/dist/feature-toggles/toggle-sync-signal.d.ts +1 -1
- package/dist/feature-toggles/web/index.d.ts +1 -1
- package/dist/file-derivatives/feature.d.ts +0 -2
- package/dist/file-derivatives/feature.js +0 -2
- package/dist/file-derivatives/index.d.ts +4 -4
- package/dist/file-derivatives/index.js +1 -1
- package/dist/file-foundation/feature.d.ts +0 -6
- package/dist/file-foundation/feature.js +0 -2
- package/dist/file-foundation/index.d.ts +2 -2
- package/dist/file-foundation/index.js +1 -1
- package/dist/file-provider-inmemory/feature.d.ts +0 -4
- package/dist/file-provider-inmemory/feature.js +0 -2
- package/dist/file-provider-inmemory/index.d.ts +1 -1
- package/dist/file-provider-inmemory/index.js +1 -1
- package/dist/file-provider-s3/env-feature.d.ts +12 -2
- package/dist/file-provider-s3/env-feature.js +9 -6
- package/dist/file-provider-s3/env-schema.d.ts +38 -0
- package/dist/file-provider-s3/env-schema.js +51 -0
- package/dist/file-provider-s3/feature.d.ts +1 -14
- package/dist/file-provider-s3/feature.js +0 -2
- package/dist/file-provider-s3/index.d.ts +2 -1
- package/dist/file-provider-s3/index.js +2 -1
- package/dist/file-provider-s3/lib/env-helper.d.ts +1 -1
- package/dist/file-provider-s3/lib/index.d.ts +3 -3
- package/dist/files/index.d.ts +1 -1
- package/dist/files-tenant-data/index.d.ts +2 -2
- package/dist/folders/feature.d.ts +0 -4
- package/dist/folders/feature.js +0 -2
- package/dist/folders/index.d.ts +7 -7
- package/dist/folders/index.js +1 -1
- package/dist/folders/web/folder-manager.d.ts +1 -1
- package/dist/folders/web/index.d.ts +5 -5
- package/dist/folders-user-data/index.d.ts +0 -4
- package/dist/folders-user-data/index.js +0 -2
- package/dist/form-draft/db/queries/cleanup.d.ts +1 -1
- package/dist/form-draft/feature.d.ts +0 -4
- package/dist/form-draft/feature.js +0 -2
- package/dist/form-draft/handlers/cleanup.job.d.ts +1 -1
- package/dist/form-draft/handlers/get.query.d.ts +1 -1
- package/dist/form-draft/index.d.ts +10 -10
- package/dist/form-draft/index.js +1 -1
- package/dist/form-draft/lookup.d.ts +1 -1
- package/dist/form-draft/release-file-refs.d.ts +1 -1
- package/dist/form-draft-user-data/index.d.ts +0 -4
- package/dist/form-draft-user-data/index.js +0 -2
- package/dist/foundation-shared/build-info-env.d.ts +7 -0
- package/dist/foundation-shared/build-info-env.js +15 -0
- package/dist/foundation-shared/demo-admin-env.d.ts +12 -0
- package/dist/foundation-shared/demo-admin-env.js +21 -0
- package/dist/foundation-shared/index.d.ts +5 -3
- package/dist/foundation-shared/index.js +2 -0
- package/dist/host-routing/constants.d.ts +8 -0
- package/dist/host-routing/constants.js +19 -0
- package/dist/host-routing/dispatch.d.ts +24 -0
- package/dist/host-routing/dispatch.js +102 -0
- package/dist/host-routing/feature.d.ts +3 -0
- package/dist/host-routing/feature.js +102 -0
- package/dist/host-routing/host.d.ts +14 -0
- package/dist/host-routing/host.js +37 -0
- package/dist/host-routing/index.d.ts +5 -0
- package/dist/host-routing/index.js +4 -0
- package/dist/host-routing/options.d.ts +27 -0
- package/dist/host-routing/options.js +1 -0
- package/dist/host-routing/validate-options.d.ts +2 -0
- package/dist/host-routing/validate-options.js +29 -0
- package/dist/inbound-mail-foundation/connect-routes.d.ts +2 -2
- package/dist/inbound-mail-foundation/feature.d.ts +0 -4
- package/dist/inbound-mail-foundation/feature.js +0 -2
- package/dist/inbound-mail-foundation/handlers/account-state.d.ts +1 -1
- package/dist/inbound-mail-foundation/index.d.ts +12 -12
- package/dist/inbound-mail-foundation/index.js +1 -1
- package/dist/inbound-mail-foundation/oauth-access-token.d.ts +1 -1
- package/dist/inbound-mail-foundation/provider-factory.d.ts +1 -1
- package/dist/inbound-mail-foundation/types.d.ts +1 -1
- package/dist/inbound-mail-foundation/watch-supervisor.d.ts +2 -2
- package/dist/inbound-provider-imap/feature.d.ts +1 -5
- package/dist/inbound-provider-imap/feature.js +0 -2
- package/dist/inbound-provider-imap/imap-client.d.ts +1 -1
- package/dist/inbound-provider-imap/index.d.ts +3 -3
- package/dist/inbound-provider-imap/index.js +1 -1
- package/dist/inbound-provider-inmemory/feature.d.ts +0 -4
- package/dist/inbound-provider-inmemory/feature.js +0 -2
- package/dist/inbound-provider-inmemory/index.d.ts +1 -1
- package/dist/inbound-provider-inmemory/index.js +1 -1
- package/dist/jobs/handlers/tenant-runs.query.d.ts +1 -1
- package/dist/jobs/index.d.ts +9 -9
- package/dist/jobs/web/index.d.ts +1 -1
- package/dist/ledger/feature.d.ts +0 -4
- package/dist/ledger/feature.js +0 -2
- package/dist/ledger/index.d.ts +10 -10
- package/dist/ledger/index.js +1 -1
- package/dist/ledger/recurring.d.ts +2 -2
- package/dist/ledger/reports.d.ts +2 -2
- package/dist/ledger/web/index.d.ts +3 -3
- package/dist/legal-pages/constants.d.ts +12 -0
- package/dist/legal-pages/constants.js +16 -0
- package/dist/legal-pages/feature.d.ts +6 -3
- package/dist/legal-pages/feature.js +5 -2
- package/dist/legal-pages/index.d.ts +5 -3
- package/dist/legal-pages/index.js +3 -1
- package/dist/legal-pages/layout.d.ts +10 -0
- package/dist/legal-pages/layout.js +32 -0
- package/dist/legal-pages/lib/boot-check.d.ts +1 -1
- package/dist/legal-pages/lib/validate-routes.d.ts +1 -1
- package/dist/legal-pages/markdown.d.ts +2 -2
- package/dist/legal-pages/seed.d.ts +12 -0
- package/dist/legal-pages/seed.js +38 -0
- package/dist/legal-pages/web/index.d.ts +1 -1
- package/dist/mail-foundation/feature.d.ts +0 -7
- package/dist/mail-foundation/feature.js +0 -2
- package/dist/mail-foundation/index.d.ts +1 -1
- package/dist/mail-foundation/index.js +1 -1
- package/dist/mail-transport-inmemory/feature.d.ts +0 -4
- package/dist/mail-transport-inmemory/feature.js +0 -2
- package/dist/mail-transport-inmemory/index.d.ts +1 -1
- package/dist/mail-transport-inmemory/index.js +1 -1
- package/dist/mail-transport-smtp/feature.d.ts +0 -16
- package/dist/mail-transport-smtp/feature.js +0 -2
- package/dist/mail-transport-smtp/index.d.ts +1 -1
- package/dist/mail-transport-smtp/index.js +1 -1
- package/dist/managed-pages/branding.d.ts +1 -1
- package/dist/managed-pages/feature.d.ts +1 -1
- package/dist/managed-pages/handlers/branding.query.d.ts +1 -1
- package/dist/managed-pages/index.d.ts +5 -5
- package/dist/managed-pages/web/index.d.ts +2 -2
- package/dist/metrics/compute.d.ts +2 -2
- package/dist/metrics/default-metrics.d.ts +9 -9
- package/dist/metrics/feature.d.ts +1 -1
- package/dist/metrics/filters.d.ts +1 -1
- package/dist/metrics/index.d.ts +5 -5
- package/dist/metrics/types.d.ts +1 -1
- package/dist/metrics/validate.d.ts +1 -1
- package/dist/metrics/window.d.ts +2 -2
- package/dist/notes-history/feature.d.ts +0 -4
- package/dist/notes-history/feature.js +0 -2
- package/dist/notes-history/handlers/add-note.write.d.ts +1 -1
- package/dist/notes-history/index.d.ts +6 -6
- package/dist/notes-history/index.js +1 -1
- package/dist/notes-history/web/index.d.ts +3 -3
- package/dist/notes-history-user-data/index.d.ts +1 -5
- package/dist/notes-history-user-data/index.js +0 -2
- package/dist/page-render/index.d.ts +7 -7
- package/dist/page-render/layout.d.ts +1 -1
- package/dist/page-render/web.d.ts +5 -5
- package/dist/personal-access-tokens/feature.d.ts +3 -3
- package/dist/personal-access-tokens/handlers/available-scopes.query.d.ts +1 -1
- package/dist/personal-access-tokens/i18n.d.ts +1 -1
- package/dist/personal-access-tokens/index.d.ts +13 -13
- package/dist/personal-access-tokens/resolver.d.ts +1 -1
- package/dist/personal-access-tokens/screens.d.ts +1 -1
- package/dist/presets/dsgvo-self-service.d.ts +3 -1
- package/dist/presets/dsgvo-self-service.js +2 -0
- package/dist/presets/index.d.ts +2 -2
- package/dist/presets/security-baseline.d.ts +2 -0
- package/dist/presets/security-baseline.js +2 -0
- package/dist/rate-limiting/index.d.ts +2 -2
- package/dist/readiness/feature.d.ts +0 -8
- package/dist/readiness/feature.js +0 -2
- package/dist/readiness/index.d.ts +3 -3
- package/dist/readiness/index.js +1 -1
- package/dist/renderer-foundation/api.d.ts +2 -2
- package/dist/renderer-foundation/constants.d.ts +2 -2
- package/dist/renderer-foundation/feature.d.ts +1 -1
- package/dist/renderer-foundation/index.d.ts +5 -5
- package/dist/renderer-foundation/types.d.ts +24 -2
- package/dist/renderer-pdf/feature.d.ts +1 -1
- package/dist/renderer-pdf/index.d.ts +2 -2
- package/dist/renderer-pdf/render-table-pdf.d.ts +1 -1
- package/dist/secrets/constants.d.ts +7 -0
- package/dist/secrets/constants.js +7 -0
- package/dist/secrets/db/queries/read.d.ts +1 -1
- package/dist/secrets/feature.d.ts +4 -3
- package/dist/secrets/feature.js +4 -2
- package/dist/secrets/handlers/delete.write.js +2 -2
- package/dist/secrets/handlers/rotate.job.d.ts +1 -1
- package/dist/secrets/handlers/set.write.js +2 -2
- package/dist/secrets/index.d.ts +7 -7
- package/dist/secrets/index.js +1 -1
- package/dist/secrets/secrets-context.d.ts +1 -1
- package/dist/seo/feature.d.ts +3 -3
- package/dist/seo/index.d.ts +6 -6
- package/dist/sessions/feature.d.ts +1 -1
- package/dist/sessions/index.d.ts +8 -8
- package/dist/sessions/session-callbacks.d.ts +1 -1
- package/dist/sessions/testing.d.ts +1 -1
- package/dist/shared/index.d.ts +31 -31
- package/dist/step-dispatcher/dispatch-payload.d.ts +2 -2
- package/dist/step-dispatcher/index.d.ts +3 -3
- package/dist/subscription-mollie/feature.d.ts +2 -2
- package/dist/subscription-mollie/index.d.ts +3 -3
- package/dist/subscription-mollie/verify-webhook.d.ts +1 -1
- package/dist/subscription-stripe/feature.d.ts +17 -1
- package/dist/subscription-stripe/feature.js +19 -1
- package/dist/subscription-stripe/index.d.ts +2 -2
- package/dist/subscription-stripe/index.js +1 -1
- package/dist/subscription-stripe/plugin-methods.d.ts +1 -1
- package/dist/subscription-stripe/verify-webhook.d.ts +1 -1
- package/dist/tags/feature.d.ts +0 -4
- package/dist/tags/feature.js +0 -2
- package/dist/tags/handlers/assign-tag.write.d.ts +1 -1
- package/dist/tags/handlers/remove-tag.write.d.ts +1 -1
- package/dist/tags/index.d.ts +11 -11
- package/dist/tags/index.js +1 -1
- package/dist/tags/web/index.d.ts +9 -9
- package/dist/template-resolver/api.d.ts +4 -4
- package/dist/template-resolver/constants.d.ts +1 -1
- package/dist/template-resolver/document-sanitizer.d.ts +1 -1
- package/dist/template-resolver/handlers/bundle-import.d.ts +3 -3
- package/dist/template-resolver/handlers/collection-shared.d.ts +2 -2
- package/dist/template-resolver/handlers/copy-locale.write.d.ts +1 -1
- package/dist/template-resolver/handlers/diff-to-system.query.d.ts +1 -1
- package/dist/template-resolver/handlers/find-by-id.query.d.ts +1 -1
- package/dist/template-resolver/handlers/import-bundle-system.write.d.ts +1 -1
- package/dist/template-resolver/handlers/import-bundle.write.d.ts +1 -1
- package/dist/template-resolver/handlers/layout-source.query.d.ts +3 -3
- package/dist/template-resolver/handlers/override-diff.d.ts +2 -2
- package/dist/template-resolver/handlers/overview.query.d.ts +3 -3
- package/dist/template-resolver/handlers/preview.query.d.ts +1 -1
- package/dist/template-resolver/handlers/resource-link-pdf.write.d.ts +1 -1
- package/dist/template-resolver/handlers/resource-upload.write.d.ts +1 -1
- package/dist/template-resolver/handlers/send-test.write.d.ts +1 -1
- package/dist/template-resolver/handlers/shared.d.ts +1 -1
- package/dist/template-resolver/handlers/template-gates.d.ts +4 -4
- package/dist/template-resolver/handlers/template-write.d.ts +4 -4
- package/dist/template-resolver/handlers/tenant-overrides.query.d.ts +1 -1
- package/dist/template-resolver/handlers/toggle-status.write.d.ts +1 -1
- package/dist/template-resolver/handlers/upsert-system.write.d.ts +1 -1
- package/dist/template-resolver/handlers/upsert-tenant.write.d.ts +1 -1
- package/dist/template-resolver/handlers/usage.query.d.ts +1 -1
- package/dist/template-resolver/handlers/validate.query.d.ts +3 -3
- package/dist/template-resolver/index.d.ts +25 -25
- package/dist/template-resolver/layout-appearance.d.ts +1 -1
- package/dist/template-resolver/layout-regions.d.ts +2 -2
- package/dist/template-resolver/linked-resources.d.ts +1 -1
- package/dist/template-resolver/preview-display-html.d.ts +1 -1
- package/dist/template-resolver/resource-image.d.ts +1 -1
- package/dist/template-resolver/seeding.d.ts +2 -2
- package/dist/template-resolver/store-template-resource.d.ts +1 -1
- package/dist/template-resolver/template-draft.d.ts +2 -2
- package/dist/template-resolver/template-meta.d.ts +2 -2
- package/dist/template-resolver/template-preview.d.ts +7 -6
- package/dist/template-resolver/template-preview.js +19 -12
- package/dist/template-resolver/template-resources.d.ts +1 -1
- package/dist/template-resolver/template-usage.d.ts +3 -1
- package/dist/template-resolver/template-usage.js +1 -0
- package/dist/template-resolver/template-validation.d.ts +1 -1
- package/dist/template-resolver/testing.d.ts +1 -1
- package/dist/template-resolver/user-content-table.d.ts +1 -1
- package/dist/template-resolver/web/document-editor-extensions.d.ts +1 -1
- package/dist/template-resolver/web/document-editor-extensions.js +6 -2
- package/dist/template-resolver/web/document-editor.d.ts +1 -1
- package/dist/template-resolver/web/document-tiptap-editor.d.ts +1 -1
- package/dist/template-resolver/web/document-tiptap-editor.js +13 -10
- package/dist/template-resolver/web/editor-handle.d.ts +1 -1
- package/dist/template-resolver/web/index.d.ts +7 -7
- package/dist/template-resolver/web/placeholder-line-editor-lazy.d.ts +2 -2
- package/dist/template-resolver/web/placeholder-line-editor.d.ts +1 -1
- package/dist/template-resolver-user-data/index.d.ts +0 -4
- package/dist/template-resolver-user-data/index.js +0 -2
- package/dist/tenant/feature.d.ts +1 -1
- package/dist/tenant/index.d.ts +10 -10
- package/dist/tenant/is-tenant-serving-public-content.d.ts +1 -1
- package/dist/tenant/testing.d.ts +1 -1
- package/dist/tenant/web/index.d.ts +3 -3
- package/dist/tenant-handover/feature.d.ts +1 -1
- package/dist/tenant-handover/index.d.ts +3 -3
- package/dist/tenant-handover/signup-handover-provider.d.ts +1 -1
- package/dist/tenant-lifecycle/feature.d.ts +2 -2
- package/dist/tenant-lifecycle/index.d.ts +3 -3
- package/dist/tenant-lifecycle/run-tenant-destroy.d.ts +1 -1
- package/dist/tenant-lifecycle/stages.d.ts +1 -1
- package/dist/tenant-lifecycle/testing.d.ts +1 -1
- package/dist/tenant-settings/feature.d.ts +1 -3
- package/dist/tenant-settings/feature.js +0 -2
- package/dist/tenant-settings/index.d.ts +4 -4
- package/dist/tenant-settings/index.js +1 -1
- package/dist/tier-engine/entity.d.ts +1 -1
- package/dist/tier-engine/feature.d.ts +2 -4
- package/dist/tier-engine/feature.js +0 -2
- package/dist/tier-engine/handlers/get-tenant-tier.query.d.ts +1 -1
- package/dist/tier-engine/i18n.d.ts +0 -2
- package/dist/tier-engine/i18n.js +4 -4
- package/dist/tier-engine/index.d.ts +8 -8
- package/dist/tier-engine/index.js +1 -1
- package/dist/tier-engine/tier-option-gate.d.ts +1 -1
- package/dist/tier-engine/tier-resolver.d.ts +1 -1
- package/dist/tier-engine/web/client-plugin.js +3 -2
- package/dist/tier-engine/web/index.d.ts +1 -1
- package/dist/user/index.d.ts +8 -8
- package/dist/user/invited-global-roles.d.ts +1 -1
- package/dist/user/principal-status.d.ts +1 -1
- package/dist/user/seeding.d.ts +1 -1
- package/dist/user/testing.d.ts +1 -1
- package/dist/user-data-rights/deletion-token.d.ts +1 -1
- package/dist/user-data-rights/feature.d.ts +5 -5
- package/dist/user-data-rights/handlers/request-deletion.write.d.ts +1 -1
- package/dist/user-data-rights/handlers/run-forget-cleanup.write.d.ts +3 -3
- package/dist/user-data-rights/index.d.ts +13 -13
- package/dist/user-data-rights/lib/default-mailers.d.ts +4 -4
- package/dist/user-data-rights/web/client-plugin.d.ts +1 -1
- package/dist/user-data-rights/web/index.d.ts +8 -8
- package/dist/user-data-rights-defaults/index.d.ts +11 -11
- package/dist/user-profile/index.d.ts +2 -2
- package/dist/user-profile/web/index.d.ts +2 -2
- package/dist/waitlist/constants.d.ts +9 -0
- package/dist/waitlist/constants.js +11 -0
- package/dist/waitlist/entity.d.ts +38 -6
- package/dist/waitlist/entity.js +4 -2
- package/dist/waitlist/entries-admin.d.ts +4 -0
- package/dist/waitlist/entries-admin.js +42 -0
- package/dist/waitlist/feature.d.ts +1 -1
- package/dist/waitlist/feature.js +16 -1
- package/dist/waitlist/handlers/export-purge.write.d.ts +12 -0
- package/dist/waitlist/handlers/export-purge.write.js +61 -0
- package/dist/waitlist/handlers/invite.write.d.ts +1 -1
- package/dist/waitlist/handlers/submit.write.d.ts +1 -1
- package/dist/waitlist/i18n.js +4 -0
- package/dist/waitlist/import.d.ts +24 -0
- package/dist/waitlist/import.js +51 -0
- package/dist/waitlist/index.d.ts +7 -5
- package/dist/waitlist/index.js +2 -0
- package/dist/waitlist/legacy-migrate.d.ts +27 -0
- package/dist/waitlist/legacy-migrate.js +173 -0
- package/dist/waitlist/lib.d.ts +2 -2
- package/dist/waitlist/link-on-signup.d.ts +3 -0
- package/dist/waitlist/link-on-signup.js +83 -0
- package/dist/waitlist/options.d.ts +11 -3
- package/dist/waitlist/payloads.d.ts +3 -0
- package/dist/waitlist/payloads.js +1 -0
- package/dist/workflow-runner/feature.d.ts +0 -4
- package/dist/workflow-runner/feature.js +0 -2
- package/dist/workflow-runner/index.d.ts +4 -4
- package/dist/workflow-runner/index.js +1 -1
- package/package.json +43 -27
- package/src/account-security/changes.json +8 -0
- package/src/auth-email-password/changes.json +6 -0
- package/src/auth-foundation/changes.json +8 -0
- package/src/auth-mfa/changes.json +6 -0
- package/src/auth-mfa-user-data/changes.json +10 -1
- package/src/billing-foundation/changes.json +8 -0
- package/src/cap-counter/changes.json +8 -0
- package/src/channel-email/changes.json +6 -0
- package/src/compliance-profiles-ops/changes.json +10 -0
- package/src/crypto-shredding/changes.json +6 -0
- package/src/custom-fields/changes.json +8 -0
- package/src/delivery/changes.json +6 -0
- package/src/derivatives-sharp/changes.json +8 -0
- package/src/document-ingest-foundation/changes.json +8 -0
- package/src/file-derivatives/changes.json +8 -0
- package/src/file-foundation/changes.json +8 -0
- package/src/file-provider-inmemory/changes.json +10 -1
- package/src/file-provider-s3/changes.json +22 -0
- package/src/folders/changes.json +8 -0
- package/src/folders-user-data/changes.json +10 -1
- package/src/form-draft/changes.json +8 -0
- package/src/form-draft-user-data/changes.json +10 -1
- package/src/foundation-shared/changes.json +8 -1
- package/src/host-routing/changes.json +8 -0
- package/src/inbound-mail-foundation/changes.json +8 -0
- package/src/inbound-provider-imap/changes.json +8 -0
- package/src/inbound-provider-inmemory/changes.json +10 -1
- package/src/ledger/changes.json +8 -0
- package/src/legal-pages/changes.json +6 -0
- package/src/mail-foundation/changes.json +10 -1
- package/src/mail-transport-inmemory/changes.json +10 -1
- package/src/mail-transport-smtp/changes.json +8 -0
- package/src/notes-history/changes.json +8 -0
- package/src/notes-history-user-data/changes.json +8 -0
- package/src/presets/changes.json +6 -0
- package/src/readiness/changes.json +10 -1
- package/src/secrets/changes.json +12 -0
- package/src/subscription-stripe/changes.json +6 -0
- package/src/tags/changes.json +8 -0
- package/src/template-resolver/changes.json +6 -0
- package/src/template-resolver-user-data/changes.json +10 -0
- package/src/tenant-settings/changes.json +10 -1
- package/src/tier-engine/changes.json +8 -0
- package/src/waitlist/changes.json +7 -0
- package/src/workflow-runner/changes.json +8 -0
- package/dist/file-provider-s3-env/index.d.ts +0 -8
- package/dist/file-provider-s3-env/index.js +0 -7
- package/dist/files-provider-s3/index.d.ts +0 -5
- package/dist/files-provider-s3/index.js +0 -5
- package/src/file-provider-s3-env/changes.json +0 -1
- package/src/files-provider-s3/changes.json +0 -1
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { defineWriteHandler } from "@cosmicdrift/kumiko-framework/engine";
|
|
2
|
+
import { UnprocessableError, writeFailure } from "@cosmicdrift/kumiko-framework/errors";
|
|
3
|
+
import { generateId } from "@cosmicdrift/kumiko-framework/utils";
|
|
4
|
+
import * as z from "zod";
|
|
5
|
+
import { WAITLIST_AUDIT_AGGREGATE_TYPE, WAITLIST_EXPORTED_EVENT_QN, WAITLIST_PURGED_EVENT_QN, WaitlistErrors, } from "../constants.js";
|
|
6
|
+
import { listAllWaitlistRows, purgeWaitlistRows } from "../entries-admin.js";
|
|
7
|
+
import { adminAccess, waitlistDb } from "../lib.js";
|
|
8
|
+
const PurgeSchema = z.object({ confirmCount: z.number().int().min(0) }).strict();
|
|
9
|
+
const ExportSchema = z.object({}).strict();
|
|
10
|
+
async function appendAudit(ctx, type, count) {
|
|
11
|
+
await ctx.unsafeAppendEvent({
|
|
12
|
+
aggregateId: generateId(),
|
|
13
|
+
aggregateType: WAITLIST_AUDIT_AGGREGATE_TYPE,
|
|
14
|
+
type,
|
|
15
|
+
payload: { count },
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
function exportedRow(row) {
|
|
19
|
+
return {
|
|
20
|
+
id: row["id"],
|
|
21
|
+
name: row["name"],
|
|
22
|
+
email: row["email"],
|
|
23
|
+
company: row["company"],
|
|
24
|
+
portfolio: row["portfolio"],
|
|
25
|
+
message: row["message"],
|
|
26
|
+
locale: row["locale"],
|
|
27
|
+
status: row["status"],
|
|
28
|
+
submittedAt: String(row["submittedAt"] ?? ""),
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
export const exportHandler = defineWriteHandler({
|
|
32
|
+
name: "export",
|
|
33
|
+
schema: ExportSchema,
|
|
34
|
+
access: adminAccess,
|
|
35
|
+
agent: { expose: false, risk: "high" },
|
|
36
|
+
description: "Returns every waitlist entry with its personal data for a hand-over and records the export as an audit event that carries only the count.",
|
|
37
|
+
handler: async (_event, ctx) => {
|
|
38
|
+
const rows = await listAllWaitlistRows(waitlistDb(ctx));
|
|
39
|
+
await appendAudit(ctx, WAITLIST_EXPORTED_EVENT_QN, rows.length);
|
|
40
|
+
return { isSuccess: true, data: { count: rows.length, entries: rows.map(exportedRow) } };
|
|
41
|
+
},
|
|
42
|
+
});
|
|
43
|
+
export const purgeHandler = defineWriteHandler({
|
|
44
|
+
name: "purge",
|
|
45
|
+
schema: PurgeSchema,
|
|
46
|
+
access: adminAccess,
|
|
47
|
+
agent: { expose: false, risk: "high" },
|
|
48
|
+
description: "Erases every waitlist entry and shreds its personal data. confirmCount must equal the current entry count, so a stale export cannot purge newer entries.",
|
|
49
|
+
handler: async (event, ctx) => {
|
|
50
|
+
const db = waitlistDb(ctx);
|
|
51
|
+
const rows = await listAllWaitlistRows(db);
|
|
52
|
+
if (rows.length !== event.payload.confirmCount) {
|
|
53
|
+
return writeFailure(new UnprocessableError(WaitlistErrors.confirmCountMismatch, {
|
|
54
|
+
details: { confirmCount: event.payload.confirmCount, actualCount: rows.length },
|
|
55
|
+
}));
|
|
56
|
+
}
|
|
57
|
+
await purgeWaitlistRows(db, rows, event.user.id);
|
|
58
|
+
await appendAudit(ctx, WAITLIST_PURGED_EVENT_QN, rows.length);
|
|
59
|
+
return { isSuccess: true, data: { purged: rows.length } };
|
|
60
|
+
},
|
|
61
|
+
});
|
package/dist/waitlist/i18n.js
CHANGED
|
@@ -26,6 +26,10 @@ export const WAITLIST_I18N = {
|
|
|
26
26
|
en: "Invited",
|
|
27
27
|
de: "Eingeladen",
|
|
28
28
|
},
|
|
29
|
+
"waitlist:entity:waitlistEntry:field:status:option:provisioned": {
|
|
30
|
+
en: "Provisioned",
|
|
31
|
+
de: "Eingerichtet",
|
|
32
|
+
},
|
|
29
33
|
"waitlist:entity:waitlistEntry:field:status:option:rejected": {
|
|
30
34
|
en: "Rejected",
|
|
31
35
|
de: "Abgelehnt",
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { TenantDb } from "@cosmicdrift/kumiko-framework/db";
|
|
2
|
+
import type { Temporal } from "@cosmicdrift/kumiko-types/temporal";
|
|
3
|
+
import type { WaitlistStatus } from "./constants.ts";
|
|
4
|
+
export type WaitlistImportEntry = {
|
|
5
|
+
/** Stable identity of the source row (e.g. `offlot:<uuid>`); the new entry id derives from it. */
|
|
6
|
+
readonly sourceKey: string;
|
|
7
|
+
readonly name: string;
|
|
8
|
+
readonly email: string;
|
|
9
|
+
readonly locale: string;
|
|
10
|
+
readonly status: WaitlistStatus;
|
|
11
|
+
readonly submittedAt: Temporal.Instant;
|
|
12
|
+
readonly company?: string;
|
|
13
|
+
readonly portfolio?: string;
|
|
14
|
+
readonly message?: string;
|
|
15
|
+
readonly invitedAt?: Temporal.Instant;
|
|
16
|
+
readonly invitedBy?: string;
|
|
17
|
+
readonly provisionedAt?: Temporal.Instant;
|
|
18
|
+
readonly linkedTenantId?: string;
|
|
19
|
+
};
|
|
20
|
+
export type WaitlistImportOutcome = "created" | "skipped";
|
|
21
|
+
export declare function waitlistImportId(sourceKey: string): string;
|
|
22
|
+
export declare function importWaitlistEntry(db: TenantDb, entry: WaitlistImportEntry, options?: {
|
|
23
|
+
readonly dryRun?: boolean;
|
|
24
|
+
}): Promise<WaitlistImportOutcome>;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { createHash } from "node:crypto";
|
|
2
|
+
import { InternalError } from "@cosmicdrift/kumiko-framework/errors";
|
|
3
|
+
import { normalizeEmail, platformActor, waitlistExecutor } from "./lib.js";
|
|
4
|
+
// RFC 4122 name-based UUID (v5 layout, fixed namespace) so a re-run finds the entry
|
|
5
|
+
// it created before without matching on encrypted personal data.
|
|
6
|
+
const IMPORT_NAMESPACE = "kumiko-waitlist-import";
|
|
7
|
+
export function waitlistImportId(sourceKey) {
|
|
8
|
+
const bytes = createHash("sha1").update(`${IMPORT_NAMESPACE}:${sourceKey}`).digest();
|
|
9
|
+
const byte6 = bytes[6] ?? 0;
|
|
10
|
+
const byte8 = bytes[8] ?? 0;
|
|
11
|
+
bytes[6] = (byte6 & 0x0f) | 0x50;
|
|
12
|
+
bytes[8] = (byte8 & 0x3f) | 0x80;
|
|
13
|
+
const hex = bytes.subarray(0, 16).toString("hex");
|
|
14
|
+
return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-${hex.slice(12, 16)}-${hex.slice(16, 20)}-${hex.slice(20, 32)}`;
|
|
15
|
+
}
|
|
16
|
+
function presentOnly(fields) {
|
|
17
|
+
return Object.fromEntries(Object.entries(fields).filter(([, value]) => value !== undefined));
|
|
18
|
+
}
|
|
19
|
+
// Writes through the entity executor, so events, projection and subject encryption
|
|
20
|
+
// behave exactly as for a live submit. No mail, no rate limit, no duplicate-by-email
|
|
21
|
+
// check: the source row is the truth and the id makes the call idempotent.
|
|
22
|
+
export async function importWaitlistEntry(db, entry, options = {}) {
|
|
23
|
+
const id = waitlistImportId(entry.sourceKey);
|
|
24
|
+
const existing = await waitlistExecutor.detail({ id }, platformActor(), db);
|
|
25
|
+
if (existing)
|
|
26
|
+
return "skipped";
|
|
27
|
+
if (options.dryRun === true)
|
|
28
|
+
return "created";
|
|
29
|
+
const created = await waitlistExecutor.create({
|
|
30
|
+
id,
|
|
31
|
+
name: entry.name,
|
|
32
|
+
email: normalizeEmail(entry.email),
|
|
33
|
+
locale: entry.locale,
|
|
34
|
+
status: entry.status,
|
|
35
|
+
submittedAt: entry.submittedAt,
|
|
36
|
+
...presentOnly({
|
|
37
|
+
company: entry.company,
|
|
38
|
+
portfolio: entry.portfolio,
|
|
39
|
+
message: entry.message,
|
|
40
|
+
invitedAt: entry.invitedAt,
|
|
41
|
+
invitedBy: entry.invitedBy,
|
|
42
|
+
provisionedAt: entry.provisionedAt,
|
|
43
|
+
linkedTenantId: entry.linkedTenantId,
|
|
44
|
+
}),
|
|
45
|
+
}, platformActor(), db);
|
|
46
|
+
if (!created.isSuccess)
|
|
47
|
+
throw new InternalError({
|
|
48
|
+
message: `waitlist import failed for ${entry.sourceKey}: ${created.error.code}`,
|
|
49
|
+
});
|
|
50
|
+
return "created";
|
|
51
|
+
}
|
package/dist/waitlist/index.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
export { DEFAULT_OWN_TENANT_INVITE_ROLE, WAITLIST_FEATURE, WAITLIST_FIELD_LIMITS, WAITLIST_NOTIFICATION_TYPES, WAITLIST_STATUS, WaitlistErrors, WaitlistHandlers, WaitlistQueries, type WaitlistStatus, } from "./constants.
|
|
2
|
-
export { isOpenWaitlistStatus, waitlistEntryEntity, waitlistEntryTable } from "./entity.
|
|
3
|
-
export { createWaitlistFeature } from "./feature.
|
|
4
|
-
export type
|
|
5
|
-
export { type
|
|
1
|
+
export { DEFAULT_OWN_TENANT_INVITE_ROLE, WAITLIST_FEATURE, WAITLIST_FIELD_LIMITS, WAITLIST_NOTIFICATION_TYPES, WAITLIST_STATUS, WaitlistErrors, WaitlistHandlers, WaitlistQueries, type WaitlistStatus, } from "./constants.ts";
|
|
2
|
+
export { isOpenWaitlistStatus, waitlistEntryEntity, waitlistEntryTable } from "./entity.ts";
|
|
3
|
+
export { createWaitlistFeature } from "./feature.ts";
|
|
4
|
+
export { importWaitlistEntry, type WaitlistImportEntry, type WaitlistImportOutcome, waitlistImportId, } from "./import.ts";
|
|
5
|
+
export { DEFAULT_IMPORT_LOCALE, DEFAULT_LEGACY_SOURCE_TABLE, isLegacyWaitlistSource, LEGACY_WAITLIST_SOURCES, type LegacyWaitlistMigrateOptions, type LegacyWaitlistMigrateReport, type LegacyWaitlistSource, migrateLegacyWaitlist, offlotLegacyTable, publicstatusLegacyTable, } from "./legacy-migrate.ts";
|
|
6
|
+
export type { WaitlistInviteOptions, WaitlistOptions } from "./options.ts";
|
|
7
|
+
export { type WaitlistSubmitInput, WaitlistSubmitSchema } from "./payloads.ts";
|
package/dist/waitlist/index.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export { DEFAULT_OWN_TENANT_INVITE_ROLE, WAITLIST_FEATURE, WAITLIST_FIELD_LIMITS, WAITLIST_NOTIFICATION_TYPES, WAITLIST_STATUS, WaitlistErrors, WaitlistHandlers, WaitlistQueries, } from "./constants.js";
|
|
2
2
|
export { isOpenWaitlistStatus, waitlistEntryEntity, waitlistEntryTable } from "./entity.js";
|
|
3
3
|
export { createWaitlistFeature } from "./feature.js";
|
|
4
|
+
export { importWaitlistEntry, waitlistImportId, } from "./import.js";
|
|
5
|
+
export { DEFAULT_IMPORT_LOCALE, DEFAULT_LEGACY_SOURCE_TABLE, isLegacyWaitlistSource, LEGACY_WAITLIST_SOURCES, migrateLegacyWaitlist, offlotLegacyTable, publicstatusLegacyTable, } from "./legacy-migrate.js";
|
|
4
6
|
export { WaitlistSubmitSchema } from "./payloads.js";
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { DbConnection } from "@cosmicdrift/kumiko-types/db-connection";
|
|
2
|
+
import { type WaitlistImportEntry } from "./import.ts";
|
|
3
|
+
export declare const LEGACY_WAITLIST_SOURCES: readonly ["offlot", "publicstatus"];
|
|
4
|
+
export type LegacyWaitlistSource = (typeof LEGACY_WAITLIST_SOURCES)[number];
|
|
5
|
+
export declare function isLegacyWaitlistSource(value: string | undefined): value is LegacyWaitlistSource;
|
|
6
|
+
export declare const DEFAULT_LEGACY_SOURCE_TABLE: Readonly<Record<LegacyWaitlistSource, string>>;
|
|
7
|
+
export declare const DEFAULT_IMPORT_LOCALE = "en";
|
|
8
|
+
export type LegacyWaitlistMigrateOptions = {
|
|
9
|
+
readonly from: LegacyWaitlistSource;
|
|
10
|
+
readonly dryRun: boolean;
|
|
11
|
+
readonly sourceTable: string;
|
|
12
|
+
/** publicstatus rows carry no language; every imported entry gets this one. */
|
|
13
|
+
readonly defaultLocale: string;
|
|
14
|
+
};
|
|
15
|
+
export type LegacyWaitlistMigrateReport = {
|
|
16
|
+
readonly read: number;
|
|
17
|
+
readonly created: number;
|
|
18
|
+
readonly skipped: number;
|
|
19
|
+
readonly unreadable: number;
|
|
20
|
+
};
|
|
21
|
+
type LegacyRow = Readonly<Record<string, unknown>>;
|
|
22
|
+
export declare function mapOfflotRow(row: LegacyRow): Promise<WaitlistImportEntry | undefined>;
|
|
23
|
+
export declare function mapPublicstatusRow(row: LegacyRow, defaultLocale: string): WaitlistImportEntry | undefined;
|
|
24
|
+
export declare function publicstatusLegacyTable(sourceTable: string): import("@cosmicdrift/kumiko-types/schema-table-types").SchemaTable;
|
|
25
|
+
export declare function offlotLegacyTable(sourceTable: string): import("@cosmicdrift/kumiko-types/schema-table-types").SchemaTable;
|
|
26
|
+
export declare function migrateLegacyWaitlist(db: DbConnection, options: LegacyWaitlistMigrateOptions): Promise<LegacyWaitlistMigrateReport>;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import { configuredPiiSubjectKms, decryptPiiFieldValues, isPiiCiphertext, PII_ERASED_SENTINEL, } from "@cosmicdrift/kumiko-framework/crypto";
|
|
2
|
+
import { createTenantDb, selectMany, table, text as textColumn, timestamp, transaction, uuid, } from "@cosmicdrift/kumiko-framework/db";
|
|
3
|
+
import { SYSTEM_TENANT_ID } from "@cosmicdrift/kumiko-framework/engine";
|
|
4
|
+
import { Temporal } from "@cosmicdrift/kumiko-types/temporal";
|
|
5
|
+
import { WAITLIST_STATUS } from "./constants.js";
|
|
6
|
+
import { importWaitlistEntry } from "./import.js";
|
|
7
|
+
export const LEGACY_WAITLIST_SOURCES = ["offlot", "publicstatus"];
|
|
8
|
+
export function isLegacyWaitlistSource(value) {
|
|
9
|
+
return LEGACY_WAITLIST_SOURCES.some((known) => known === value);
|
|
10
|
+
}
|
|
11
|
+
export const DEFAULT_LEGACY_SOURCE_TABLE = {
|
|
12
|
+
offlot: "read_waitlist_entries",
|
|
13
|
+
publicstatus: "marketing_waitlist",
|
|
14
|
+
};
|
|
15
|
+
export const DEFAULT_IMPORT_LOCALE = "en";
|
|
16
|
+
function toInstant(value) {
|
|
17
|
+
if (value === null || value === undefined)
|
|
18
|
+
return undefined;
|
|
19
|
+
if (value instanceof Temporal.Instant)
|
|
20
|
+
return value;
|
|
21
|
+
if (value instanceof Date)
|
|
22
|
+
return Temporal.Instant.fromEpochMilliseconds(Number(value));
|
|
23
|
+
if (typeof value !== "string")
|
|
24
|
+
return undefined;
|
|
25
|
+
try {
|
|
26
|
+
return Temporal.Instant.from(value);
|
|
27
|
+
}
|
|
28
|
+
catch {
|
|
29
|
+
// Temporal.Instant.from throws RangeError for a non-ISO string.
|
|
30
|
+
return undefined;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
function nonEmpty(value) {
|
|
34
|
+
return typeof value === "string" && value.trim() !== "" ? value : undefined;
|
|
35
|
+
}
|
|
36
|
+
function isWaitlistStatus(value) {
|
|
37
|
+
return Object.values(WAITLIST_STATUS).some((known) => known === value);
|
|
38
|
+
}
|
|
39
|
+
// Legacy offlot rows may hold subject ciphertext; decryption is self-describing and
|
|
40
|
+
// needs the same KMS the app ran with. Without it the value cannot be read, so the
|
|
41
|
+
// caller counts the row as unreadable instead of importing ciphertext as the name.
|
|
42
|
+
async function readPii(value, field) {
|
|
43
|
+
const raw = nonEmpty(value);
|
|
44
|
+
if (raw === undefined || !isPiiCiphertext(raw))
|
|
45
|
+
return raw;
|
|
46
|
+
const kms = configuredPiiSubjectKms();
|
|
47
|
+
if (!kms)
|
|
48
|
+
return undefined;
|
|
49
|
+
const decrypted = await decryptPiiFieldValues({ [field]: raw }, [field], kms, {
|
|
50
|
+
requestId: "waitlist-migrate",
|
|
51
|
+
});
|
|
52
|
+
const plain = decrypted[field];
|
|
53
|
+
return typeof plain === "string" && plain !== PII_ERASED_SENTINEL ? plain : undefined;
|
|
54
|
+
}
|
|
55
|
+
// Source columns without a FW counterpart (city, stock, country, notes) are kept
|
|
56
|
+
// as labelled lines in `message`, so no information is lost.
|
|
57
|
+
function offlotMessage(row) {
|
|
58
|
+
const lines = [
|
|
59
|
+
["City", nonEmpty(row["city"])],
|
|
60
|
+
["Stock", nonEmpty(row["stock"])],
|
|
61
|
+
["Country", nonEmpty(row["country"])],
|
|
62
|
+
["Notes", nonEmpty(row["notes"])],
|
|
63
|
+
].flatMap(([label, value]) => (value === undefined ? [] : [`${label}: ${value}`]));
|
|
64
|
+
return lines.length === 0 ? undefined : lines.join("\n");
|
|
65
|
+
}
|
|
66
|
+
export async function mapOfflotRow(row) {
|
|
67
|
+
const id = nonEmpty(row["id"]);
|
|
68
|
+
const name = await readPii(row["name"], "name");
|
|
69
|
+
const email = await readPii(row["email"], "email");
|
|
70
|
+
const submittedAt = toInstant(row["submittedAt"]);
|
|
71
|
+
const status = nonEmpty(row["status"]);
|
|
72
|
+
if (!id || !name || !email || !submittedAt || !isWaitlistStatus(status))
|
|
73
|
+
return undefined;
|
|
74
|
+
const company = nonEmpty(row["dealership"]);
|
|
75
|
+
const message = offlotMessage(row);
|
|
76
|
+
const invitedAt = toInstant(row["invitedAt"]);
|
|
77
|
+
const provisionedAt = toInstant(row["provisionedAt"]);
|
|
78
|
+
const invitedBy = nonEmpty(row["invitedBy"]);
|
|
79
|
+
const linkedTenantId = nonEmpty(row["linkedTenantId"]);
|
|
80
|
+
return {
|
|
81
|
+
sourceKey: `offlot:${id}`,
|
|
82
|
+
name,
|
|
83
|
+
email,
|
|
84
|
+
locale: nonEmpty(row["locale"]) ?? DEFAULT_IMPORT_LOCALE,
|
|
85
|
+
status,
|
|
86
|
+
submittedAt,
|
|
87
|
+
...(company !== undefined && { company }),
|
|
88
|
+
...(message !== undefined && { message }),
|
|
89
|
+
...(invitedAt !== undefined && { invitedAt }),
|
|
90
|
+
...(invitedBy !== undefined && { invitedBy }),
|
|
91
|
+
...(provisionedAt !== undefined && { provisionedAt }),
|
|
92
|
+
...(linkedTenantId !== undefined && { linkedTenantId }),
|
|
93
|
+
};
|
|
94
|
+
}
|
|
95
|
+
export function mapPublicstatusRow(row, defaultLocale) {
|
|
96
|
+
const id = nonEmpty(row["id"]);
|
|
97
|
+
const email = nonEmpty(row["email"]);
|
|
98
|
+
const submittedAt = toInstant(row["createdAt"]);
|
|
99
|
+
if (!id || !email || !submittedAt)
|
|
100
|
+
return undefined;
|
|
101
|
+
return {
|
|
102
|
+
sourceKey: `publicstatus:${id}`,
|
|
103
|
+
// The apex form only asked for an address; the FW entry requires a name.
|
|
104
|
+
name: email.split("@")[0] ?? email,
|
|
105
|
+
email,
|
|
106
|
+
locale: defaultLocale,
|
|
107
|
+
status: WAITLIST_STATUS.Pending,
|
|
108
|
+
submittedAt,
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
export function publicstatusLegacyTable(sourceTable) {
|
|
112
|
+
return table(sourceTable, {
|
|
113
|
+
id: uuid("id").primaryKey(),
|
|
114
|
+
email: textColumn("email").notNull(),
|
|
115
|
+
createdAt: timestamp("created_at", { withTimezone: true }).notNull(),
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
export function offlotLegacyTable(sourceTable) {
|
|
119
|
+
return table(sourceTable, {
|
|
120
|
+
id: uuid("id").primaryKey(),
|
|
121
|
+
name: textColumn("name").notNull(),
|
|
122
|
+
email: textColumn("email").notNull(),
|
|
123
|
+
dealership: textColumn("dealership"),
|
|
124
|
+
city: textColumn("city"),
|
|
125
|
+
stock: textColumn("stock"),
|
|
126
|
+
country: textColumn("country"),
|
|
127
|
+
locale: textColumn("locale").notNull(),
|
|
128
|
+
status: textColumn("status").notNull(),
|
|
129
|
+
submittedAt: timestamp("submitted_at", { withTimezone: true }).notNull(),
|
|
130
|
+
invitedAt: timestamp("invited_at", { withTimezone: true }),
|
|
131
|
+
invitedBy: textColumn("invited_by"),
|
|
132
|
+
provisionedAt: timestamp("provisioned_at", { withTimezone: true }),
|
|
133
|
+
linkedTenantId: textColumn("linked_tenant_id"),
|
|
134
|
+
notes: textColumn("notes"),
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
async function readLegacyRows(db, from, sourceTable) {
|
|
138
|
+
if (from === "publicstatus") {
|
|
139
|
+
return await selectMany(db, publicstatusLegacyTable(sourceTable), undefined, {
|
|
140
|
+
orderBy: { col: "createdAt", direction: "asc" },
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
return await selectMany(db, offlotLegacyTable(sourceTable), undefined, {
|
|
144
|
+
orderBy: { col: "submittedAt", direction: "asc" },
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
// Idempotent: the new entry id derives from the source row id, so a re-run finds
|
|
148
|
+
// what an earlier run wrote and skips it. Writes go through the waitlist entity
|
|
149
|
+
// executor (events, projection, subject encryption), never into tables directly.
|
|
150
|
+
export async function migrateLegacyWaitlist(db, options) {
|
|
151
|
+
const rows = await readLegacyRows(db, options.from, options.sourceTable);
|
|
152
|
+
let created = 0;
|
|
153
|
+
let skipped = 0;
|
|
154
|
+
let unreadable = 0;
|
|
155
|
+
for (const row of rows) {
|
|
156
|
+
const entry = options.from === "offlot"
|
|
157
|
+
? await mapOfflotRow(row)
|
|
158
|
+
: mapPublicstatusRow(row, options.defaultLocale);
|
|
159
|
+
if (!entry) {
|
|
160
|
+
unreadable += 1;
|
|
161
|
+
continue;
|
|
162
|
+
}
|
|
163
|
+
await transaction(db, async (tx) => {
|
|
164
|
+
const tenantDb = createTenantDb({ db: tx, tenantId: SYSTEM_TENANT_ID, mode: "system" });
|
|
165
|
+
const outcome = await importWaitlistEntry(tenantDb, entry, { dryRun: options.dryRun });
|
|
166
|
+
if (outcome === "created")
|
|
167
|
+
created += 1;
|
|
168
|
+
else
|
|
169
|
+
skipped += 1;
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
return { read: rows.length, created, skipped, unreadable };
|
|
173
|
+
}
|
package/dist/waitlist/lib.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { type TenantDb } from "@cosmicdrift/kumiko-framework/db";
|
|
2
|
-
import { type
|
|
2
|
+
import { type AppContext, type SessionUser, type TenantId } from "@cosmicdrift/kumiko-framework/engine";
|
|
3
3
|
export declare const WAITLIST_CROSS_TENANT_REASON = "waitlist is platform-wide (systemScope)";
|
|
4
4
|
export declare const adminAccess: {
|
|
5
5
|
readonly roles: readonly string[];
|
|
6
6
|
};
|
|
7
7
|
export declare const waitlistExecutor: import("@cosmicdrift/kumiko-types/event-store-executor-types").EventStoreExecutor;
|
|
8
8
|
export declare function normalizeEmail(email: string): string;
|
|
9
|
-
export declare function waitlistDb(ctx:
|
|
9
|
+
export declare function waitlistDb(ctx: Pick<AppContext, "systemDb">): TenantDb;
|
|
10
10
|
export declare function platformActor(): SessionUser;
|
|
11
11
|
export declare function isTenantMember(db: TenantDb, email: string, tenantId: TenantId): Promise<boolean>;
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { createTenantDb, entityEventName, fetchOne, selectMany, } from "@cosmicdrift/kumiko-framework/db";
|
|
2
|
+
import { SYSTEM_TENANT_ID } from "@cosmicdrift/kumiko-framework/engine";
|
|
3
|
+
import { parseRoles } from "@cosmicdrift/kumiko-framework/utils";
|
|
4
|
+
import { Temporal } from "@cosmicdrift/kumiko-types/temporal";
|
|
5
|
+
import { decryptStoredPii } from "../shared/index.js";
|
|
6
|
+
import { tenantMembershipsTable } from "../tenant/index.js";
|
|
7
|
+
import { userTable } from "../user/index.js";
|
|
8
|
+
import { DEFAULT_OWN_TENANT_INVITE_ROLE, WAITLIST_STATUS } from "./constants.js";
|
|
9
|
+
import { normalizeEmail, platformActor, waitlistExecutor } from "./lib.js";
|
|
10
|
+
const PII_DECRYPT_REASON = "waitlist:link-on-signup";
|
|
11
|
+
export const WAITLIST_MEMBERSHIP_CREATED_EVENT = entityEventName("tenant-membership", "created");
|
|
12
|
+
// Only a TenantAdmin membership can be the signup owner; invite-accept memberships of
|
|
13
|
+
// other roles are not owners.
|
|
14
|
+
function readSignupOwnerMembership(event) {
|
|
15
|
+
const { userId, roles } = event.payload;
|
|
16
|
+
if (typeof userId !== "string")
|
|
17
|
+
return undefined;
|
|
18
|
+
if (!parseRoles(roles).includes(DEFAULT_OWN_TENANT_INVITE_ROLE))
|
|
19
|
+
return undefined;
|
|
20
|
+
return { userId, tenantId: event.tenantId };
|
|
21
|
+
}
|
|
22
|
+
// An unreadable submittedAt sorts last instead of throwing: one bad row must not
|
|
23
|
+
// stall the at-least-once consumer.
|
|
24
|
+
function newestSubmittedFirst(a, b) {
|
|
25
|
+
return submittedAtMillis(b) - submittedAtMillis(a);
|
|
26
|
+
}
|
|
27
|
+
function submittedAtMillis(row) {
|
|
28
|
+
return instantMillis(row["submittedAt"]);
|
|
29
|
+
}
|
|
30
|
+
function instantMillis(value) {
|
|
31
|
+
if (value instanceof Temporal.Instant)
|
|
32
|
+
return value.epochMilliseconds;
|
|
33
|
+
if (typeof value !== "string")
|
|
34
|
+
return 0;
|
|
35
|
+
try {
|
|
36
|
+
return Temporal.Instant.from(value).epochMilliseconds;
|
|
37
|
+
}
|
|
38
|
+
catch {
|
|
39
|
+
// Temporal.Instant.from throws RangeError for a non-ISO string.
|
|
40
|
+
return 0;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
// Runs as a multi-stream consumer (at least once): the hook phase of the signup and
|
|
44
|
+
// invite-accept paths has no system db handle, and a waitlist problem must not roll
|
|
45
|
+
// back the signup. Idempotent because only `invited` entries are updated.
|
|
46
|
+
export const linkWaitlistOnSignup = async (event, tx) => {
|
|
47
|
+
const membership = readSignupOwnerMembership(event);
|
|
48
|
+
// skip: not a TenantAdmin membership, nothing to link.
|
|
49
|
+
if (!membership)
|
|
50
|
+
return;
|
|
51
|
+
// Only the tenant's first membership is the owner; later TenantAdmin invites must not link.
|
|
52
|
+
const [first] = await selectMany(tx, tenantMembershipsTable, { tenantId: membership.tenantId }, { limit: 1, fields: ["id"], orderBy: [{ col: "insertedAt" }, { col: "id" }] });
|
|
53
|
+
// skip: another membership came first.
|
|
54
|
+
if (first && first.id !== event.aggregateId)
|
|
55
|
+
return;
|
|
56
|
+
const db = createTenantDb({ db: tx, tenantId: SYSTEM_TENANT_ID, mode: "system" });
|
|
57
|
+
const user = await fetchOne(tx, userTable, { id: membership.userId });
|
|
58
|
+
// skip: user row unreadable (erased or not projected yet).
|
|
59
|
+
if (typeof user?.email !== "string")
|
|
60
|
+
return;
|
|
61
|
+
const email = normalizeEmail(await decryptStoredPii(user.email, "email", PII_DECRYPT_REASON));
|
|
62
|
+
const found = await waitlistExecutor.list({
|
|
63
|
+
filter: { field: "email", op: "eq", value: email },
|
|
64
|
+
filters: [{ field: "status", op: "in", value: [WAITLIST_STATUS.Invited] }],
|
|
65
|
+
}, platformActor(), db);
|
|
66
|
+
const invited = [...found.rows].sort(newestSubmittedFirst)[0];
|
|
67
|
+
// skip: the signup email has no invited waitlist entry (open signup or stale invite).
|
|
68
|
+
if (!invited)
|
|
69
|
+
return;
|
|
70
|
+
const { id, version } = invited;
|
|
71
|
+
// skip: defensive guard on the row shape.
|
|
72
|
+
if (typeof id !== "string" || typeof version !== "number")
|
|
73
|
+
return;
|
|
74
|
+
await waitlistExecutor.update({
|
|
75
|
+
id,
|
|
76
|
+
version,
|
|
77
|
+
changes: {
|
|
78
|
+
status: WAITLIST_STATUS.Provisioned,
|
|
79
|
+
linkedTenantId: membership.tenantId,
|
|
80
|
+
provisionedAt: Temporal.Now.instant(),
|
|
81
|
+
},
|
|
82
|
+
}, platformActor(), db);
|
|
83
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { HandlerContext, TenantId } from "@cosmicdrift/kumiko-framework/engine";
|
|
2
|
-
import type { PayloadRateLimitOption, RateLimitOption } from "@cosmicdrift/kumiko-types/handlers";
|
|
2
|
+
import type { PayloadRateLimitOption, RateLimitDeclaration, RateLimitOption } from "@cosmicdrift/kumiko-types/handlers";
|
|
3
3
|
export type WaitlistInviteOptions = {
|
|
4
4
|
/** Each invited entry gets its own tenant, named after company or name. */
|
|
5
5
|
readonly mode: "own-tenant";
|
|
@@ -18,11 +18,19 @@ export type WaitlistOptions = {
|
|
|
18
18
|
readonly notifyRecipient?: (ctx: HandlerContext) => string | null | Promise<string | null>;
|
|
19
19
|
/** Default `{ mode: "own-tenant", role: "TenantAdmin" }`. */
|
|
20
20
|
readonly invite?: WaitlistInviteOptions;
|
|
21
|
-
/** Default: 5 submits per IP per 10 minutes.
|
|
22
|
-
|
|
21
|
+
/** Default: 5 submits per IP per 10 minutes. Pass `{ disabled: true, reason }`
|
|
22
|
+
* to turn the per-IP limit off (e.g. when a CDN already throttles the route). */
|
|
23
|
+
readonly rateLimit?: RateLimitDeclaration;
|
|
23
24
|
/** Default: 3 submits per email address per day, across all IPs. Stops a botnet
|
|
24
25
|
* from flooding one address with confirmation mails. Pass `[]` to disable. */
|
|
25
26
|
readonly emailRateLimits?: readonly PayloadRateLimitOption[];
|
|
27
|
+
/** Marks an invited entry `provisioned` and records the tenant when its email
|
|
28
|
+
* becomes the first TenantAdmin member of a tenant (open signup after an
|
|
29
|
+
* invite, or accepting an own-tenant invite). Default false. */
|
|
30
|
+
readonly linkOnSignup?: boolean;
|
|
31
|
+
/** Mounts the SystemAdmin-only `export` and `purge` handlers for handing over
|
|
32
|
+
* and erasing the whole list. Default true; pass false to leave them out. */
|
|
33
|
+
readonly exportPurge?: boolean;
|
|
26
34
|
/** Shown in the confirmation mail; omitted when unset. */
|
|
27
35
|
readonly appName?: string;
|
|
28
36
|
};
|
|
@@ -12,3 +12,6 @@ export type WaitlistSubmitInput = z.infer<typeof WaitlistSubmitSchema>;
|
|
|
12
12
|
export declare const WaitlistIdSchema: z.ZodObject<{
|
|
13
13
|
id: z.ZodUUID;
|
|
14
14
|
}, z.core.$strict>;
|
|
15
|
+
export declare const WaitlistAuditEventSchema: z.ZodObject<{
|
|
16
|
+
count: z.ZodNumber;
|
|
17
|
+
}, z.core.$strip>;
|
|
@@ -1,7 +1,3 @@
|
|
|
1
1
|
export declare function createWorkflowRunnerFeature(): import("@cosmicdrift/kumiko-types/feature").FeatureDefinition & {
|
|
2
2
|
readonly exports: void;
|
|
3
3
|
};
|
|
4
|
-
/** @deprecated Use createWorkflowRunnerFeature(). Run `bun kumiko-upgrade --apply`. Removed in the first release after 2026-10-29. */
|
|
5
|
-
export declare const workflowRunnerFeature: import("@cosmicdrift/kumiko-types/feature").FeatureDefinition & {
|
|
6
|
-
readonly exports: void;
|
|
7
|
-
};
|
|
@@ -76,5 +76,3 @@ export function createWorkflowRunnerFeature() {
|
|
|
76
76
|
});
|
|
77
77
|
}, { dedupeOptions: {} });
|
|
78
78
|
}
|
|
79
|
-
/** @deprecated Use createWorkflowRunnerFeature(). Run `bun kumiko-upgrade --apply`. Removed in the first release after 2026-10-29. */
|
|
80
|
-
export const workflowRunnerFeature = createWorkflowRunnerFeature();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { workflowRunAggregateId } from "./aggregate-id.
|
|
2
|
-
export { registerEventTrigger } from "./event-trigger.
|
|
3
|
-
export { createWorkflowRunnerFeature
|
|
4
|
-
export { startAndRunWorkflow, type WorkflowRunCompletedPayload, type WorkflowRunFailedPayload, type WorkflowRunStartedPayload, WorkflowSuspensionUnsupportedError, } from "./runner.
|
|
1
|
+
export { workflowRunAggregateId } from "./aggregate-id.ts";
|
|
2
|
+
export { registerEventTrigger } from "./event-trigger.ts";
|
|
3
|
+
export { createWorkflowRunnerFeature } from "./feature.ts";
|
|
4
|
+
export { startAndRunWorkflow, type WorkflowRunCompletedPayload, type WorkflowRunFailedPayload, type WorkflowRunStartedPayload, WorkflowSuspensionUnsupportedError, } from "./runner.ts";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Public API of the workflow-runner bundled-feature.
|
|
2
2
|
export { workflowRunAggregateId } from "./aggregate-id.js";
|
|
3
3
|
export { registerEventTrigger } from "./event-trigger.js";
|
|
4
|
-
export { createWorkflowRunnerFeature
|
|
4
|
+
export { createWorkflowRunnerFeature } from "./feature.js";
|
|
5
5
|
export { startAndRunWorkflow, WorkflowSuspensionUnsupportedError, } from "./runner.js";
|