tempest-express-sdk 0.29.0 → 0.31.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/index.d.cts CHANGED
@@ -8,7 +8,7 @@ import * as ws from 'ws';
8
8
  import { Server } from 'node:http';
9
9
  import { Readable } from 'node:stream';
10
10
  import { OpenAPIRegistry } from '@asteasolutions/zod-to-openapi';
11
- export { OpenAPIRegistry } from '@asteasolutions/zod-to-openapi';
11
+ export { OpenAPIRegistry, extendZodWithOpenApi } from '@asteasolutions/zod-to-openapi';
12
12
  import { BinaryLike } from 'node:crypto';
13
13
 
14
14
  /**
@@ -324,6 +324,14 @@ declare function defaultMessageCatalog(): MessageCatalog;
324
324
  * module re-exports a `z` already augmented with `.openapi()` (so every schema
325
325
  * can carry OpenAPI metadata) and a {@link toDict} helper matching
326
326
  * `BaseSchema.to_dict` (drop nullish, exclude keys, merge extras).
327
+ *
328
+ * **The `z` this module exports is the augmented instance.** `extendZodWithOpenApi`
329
+ * patches `ZodType.prototype`, and zod v4 copies prototype members into each
330
+ * instance at construction — so only schemas built *after* this module has been
331
+ * evaluated carry `.openapi()`. Importing `z` from here rather than from `zod`
332
+ * makes that ordering automatic. It is not a requirement:
333
+ * `createOpenApiRegistry()` re-tags an un-patched schema on registration, so a
334
+ * project importing `z` straight from `zod` works too.
327
335
  */
328
336
 
329
337
  /** Options for {@link toDict}. */
@@ -2800,6 +2808,26 @@ declare class RabbitBroker implements BrokerManager {
2800
2808
 
2801
2809
  /** A handler for a registered task. */
2802
2810
  type TaskHandler<P = unknown> = (payload: P) => Promise<void> | void;
2811
+ /** One registered task, as the inventory reports it. */
2812
+ interface TaskInventoryEntry {
2813
+ /** The task name handlers are registered under. */
2814
+ name: string;
2815
+ /** A human-readable description, when the registration supplied one. */
2816
+ description: string | null;
2817
+ /** The declared schedule, when the registration supplied one. */
2818
+ schedule: string | null;
2819
+ }
2820
+ /** Optional metadata attached at registration, surfaced by the inventory. */
2821
+ interface TaskRegistrationOptions {
2822
+ /** What the task does, for an operator reading the panel. */
2823
+ description?: string;
2824
+ /**
2825
+ * The schedule this task is expected to run on (a cron expression, an
2826
+ * interval — whatever your scheduler speaks). Recorded and displayed, never
2827
+ * interpreted: the manager consumes a queue, it does not schedule.
2828
+ */
2829
+ schedule?: string;
2830
+ }
2803
2831
  /** Options for {@link TaskManager}. */
2804
2832
  interface TaskManagerOptions {
2805
2833
  /** The broker to publish/consume on. Defaults to a {@link MemoryBroker}. */
@@ -2811,6 +2839,7 @@ declare class TaskManager {
2811
2839
  private readonly broker;
2812
2840
  private readonly queue;
2813
2841
  private readonly handlers;
2842
+ private readonly metadata;
2814
2843
  private unsubscribe;
2815
2844
  /**
2816
2845
  * @param options - Broker and queue name.
@@ -2821,8 +2850,21 @@ declare class TaskManager {
2821
2850
  *
2822
2851
  * @param name - The task name.
2823
2852
  * @param handler - The handler invoked with the task payload.
2853
+ * @param options - Description and declared schedule, surfaced by
2854
+ * {@link TaskManager.inventory} and by the admin panel's tasks page.
2824
2855
  */
2825
- register<P = unknown>(name: string, handler: TaskHandler<P>): void;
2856
+ register<P = unknown>(name: string, handler: TaskHandler<P>, options?: TaskRegistrationOptions): void;
2857
+ /**
2858
+ * Return what this process would run, ordered by name.
2859
+ *
2860
+ * This is the **declared** side of background work — the handlers this
2861
+ * process knows about — not queue state. A broker's pending depth is not
2862
+ * something the manager can see, and a screen that implied otherwise would
2863
+ * be worse than one that says nothing.
2864
+ *
2865
+ * @returns One entry per registered task.
2866
+ */
2867
+ inventory(): TaskInventoryEntry[];
2826
2868
  /**
2827
2869
  * Enqueue a task by name.
2828
2870
  *
@@ -2839,6 +2881,144 @@ declare class TaskManager {
2839
2881
  stop(): Promise<void>;
2840
2882
  }
2841
2883
 
2884
+ /** Lifecycle state of a job row. */
2885
+ declare const JobStatus: {
2886
+ /** Written, not started. */
2887
+ readonly QUEUED: "queued";
2888
+ /** A worker picked it up. */
2889
+ readonly RUNNING: "running";
2890
+ /** Finished cleanly. */
2891
+ readonly SUCCEEDED: "succeeded";
2892
+ /** Finished with an error. */
2893
+ readonly FAILED: "failed";
2894
+ /** An operator stopped it before it finished. */
2895
+ readonly CANCELLED: "cancelled";
2896
+ };
2897
+ /** A {@link JobStatus} value. */
2898
+ type JobStatus = (typeof JobStatus)[keyof typeof JobStatus];
2899
+ /**
2900
+ * Base for a persisted job record. Subclass it, set `tablename`, and index
2901
+ * `name` plus `status` in a migration.
2902
+ *
2903
+ * ```ts
2904
+ * export class JobModel extends BaseJobModel {
2905
+ * static override tablename = "job";
2906
+ * }
2907
+ * ```
2908
+ */
2909
+ declare abstract class BaseJobModel extends BaseModel {
2910
+ /** The task name this run belongs to. */
2911
+ name: tempest_db_js.Column<string, tempest_db_js.ColumnFlags & {
2912
+ notNull: true;
2913
+ }>;
2914
+ /** Lifecycle state — a {@link JobStatus} value. */
2915
+ status: tempest_db_js.Column<string, tempest_db_js.ColumnFlags & {
2916
+ notNull: true;
2917
+ } & {
2918
+ hasDefault: true;
2919
+ }>;
2920
+ /** The payload the run was started with. */
2921
+ payload: tempest_db_js.Column<Record<string, unknown>, tempest_db_js.ColumnFlags>;
2922
+ /** Whatever the run produced, for an operator to read afterwards. */
2923
+ result: tempest_db_js.Column<Record<string, unknown>, tempest_db_js.ColumnFlags>;
2924
+ /** The failure message, when the run failed. */
2925
+ error: tempest_db_js.Column<string, tempest_db_js.ColumnFlags>;
2926
+ /** How many times the run has been attempted. */
2927
+ attempts: tempest_db_js.Column<number, tempest_db_js.ColumnFlags & {
2928
+ notNull: true;
2929
+ } & {
2930
+ hasDefault: true;
2931
+ }>;
2932
+ /** When a worker picked it up. */
2933
+ startedAt: tempest_db_js.Column<Date, tempest_db_js.ColumnFlags>;
2934
+ /** When it reached a terminal state. */
2935
+ finishedAt: tempest_db_js.Column<Date, tempest_db_js.ColumnFlags>;
2936
+ }
2937
+ /**
2938
+ * The small surface workers write job rows through.
2939
+ *
2940
+ * Every transition is a method rather than a raw update, so "finished" always
2941
+ * means the same three columns moved together — a status without a
2942
+ * `finishedAt` is the kind of half-written row that makes a history screen lie.
2943
+ */
2944
+ declare class JobStore<C extends ModelClass = ModelClass> {
2945
+ readonly model: C;
2946
+ private readonly repository;
2947
+ /**
2948
+ * @param model - The concrete {@link BaseJobModel} subclass.
2949
+ * @param session - The session rows are written on.
2950
+ */
2951
+ constructor(model: C, session: AsyncSession);
2952
+ /**
2953
+ * Record a job about to run.
2954
+ *
2955
+ * @param name - The task name.
2956
+ * @param payload - The payload the run was started with.
2957
+ * @returns The created row.
2958
+ */
2959
+ enqueue(name: string, payload?: Record<string, unknown>): Promise<Record<string, unknown>>;
2960
+ /**
2961
+ * Mark a job as picked up, counting the attempt.
2962
+ *
2963
+ * @param id - The job id.
2964
+ * @param attempt - Which attempt this is. Default `1`.
2965
+ * @returns How many rows changed.
2966
+ */
2967
+ start(id: string, attempt?: number): Promise<number>;
2968
+ /**
2969
+ * Mark a job as finished cleanly.
2970
+ *
2971
+ * @param id - The job id.
2972
+ * @param result - Whatever the run produced.
2973
+ * @returns How many rows changed.
2974
+ */
2975
+ succeed(id: string, result?: Record<string, unknown>): Promise<number>;
2976
+ /**
2977
+ * Mark a job as failed.
2978
+ *
2979
+ * @param id - The job id.
2980
+ * @param error - The failure, as an `Error` or a message.
2981
+ * @returns How many rows changed.
2982
+ */
2983
+ fail(id: string, error: unknown): Promise<number>;
2984
+ /**
2985
+ * Ask a job to stop.
2986
+ *
2987
+ * A job already in a terminal state is left alone and reported as not
2988
+ * cancelled, so an operator clicking cancel on a run that just finished sees
2989
+ * the truth rather than a row rewritten under them.
2990
+ *
2991
+ * @param id - The job id.
2992
+ * @returns Whether the row moved to `cancelled`.
2993
+ */
2994
+ cancel(id: string): Promise<boolean>;
2995
+ /**
2996
+ * Read one job row.
2997
+ *
2998
+ * @param id - The job id.
2999
+ * @returns The row, or `null`.
3000
+ */
3001
+ get(id: string): Promise<Record<string, unknown> | null>;
3002
+ /**
3003
+ * Read a page of jobs, newest first.
3004
+ *
3005
+ * @param filter - Page, size and optional `name` / `status` filters.
3006
+ * @returns The page plus its metadata.
3007
+ */
3008
+ list(filter?: {
3009
+ page?: number;
3010
+ pageSize?: number;
3011
+ name?: string;
3012
+ status?: JobStatus;
3013
+ }): Promise<{
3014
+ items: Record<string, unknown>[];
3015
+ total: number;
3016
+ page: number;
3017
+ pageSize: number;
3018
+ pages: number;
3019
+ }>;
3020
+ }
3021
+
2842
3022
  /**
2843
3023
  * Feature-flag backends, mirroring `flags.backends`.
2844
3024
  *
@@ -5112,7 +5292,7 @@ declare class AdminSite {
5112
5292
  * It ships as a string rather than an asset because the package publishes only
5113
5293
  * `dist`: a `.css` file on disk would not survive the build.
5114
5294
  */
5115
- /** The stylesheet text. */
5295
+ /** The stylesheet the panel serves: the ported base plus this SDK's additions. */
5116
5296
  declare const ADMIN_CSS: string;
5117
5297
 
5118
5298
  /**
@@ -5520,6 +5700,85 @@ interface AdminLogsView {
5520
5700
  * @returns The full page.
5521
5701
  */
5522
5702
  declare function renderLogsPage(context: AdminRenderContext, view: AdminLogsView): string;
5703
+ /** The tasks page view model. */
5704
+ interface AdminTasksView {
5705
+ /** Declared tasks this process would run, or `null` when no manager was given. */
5706
+ inventory: {
5707
+ name: string;
5708
+ description: string;
5709
+ schedule: string;
5710
+ }[] | null;
5711
+ /** Persisted runs, or `null` when no job store was given. */
5712
+ runs: {
5713
+ rows: {
5714
+ id: string;
5715
+ name: string;
5716
+ status: string;
5717
+ startedAt: string;
5718
+ finishedAt: string;
5719
+ attempts: string;
5720
+ url: string;
5721
+ }[];
5722
+ total: number;
5723
+ page: number;
5724
+ pages: number;
5725
+ prevUrl: string | null;
5726
+ nextUrl: string | null;
5727
+ statuses: {
5728
+ value: string;
5729
+ label: string;
5730
+ selected: boolean;
5731
+ }[];
5732
+ nameQuery: string;
5733
+ } | null;
5734
+ }
5735
+ /**
5736
+ * Render the background-tasks page.
5737
+ *
5738
+ * Either half may be missing: a service given only a `TaskManager` shows what
5739
+ * is declared, one given only a job store shows what ran. A section with no
5740
+ * source is omitted rather than rendered empty, because an empty table implies
5741
+ * there is nothing to see — and what the panel deliberately cannot show is live
5742
+ * queue depth, which no broker exposes.
5743
+ *
5744
+ * @param context - The shared chrome data.
5745
+ * @param view - The prepared tasks view model.
5746
+ * @returns The full page.
5747
+ */
5748
+ declare function renderTasksPage(context: AdminRenderContext, view: AdminTasksView): string;
5749
+ /** One job run, as the detail page renders it. */
5750
+ interface AdminTaskDetailView {
5751
+ /** The job id. */
5752
+ id: string;
5753
+ /** The task name. */
5754
+ name: string;
5755
+ /** Lifecycle state. */
5756
+ status: string;
5757
+ /** Field rows: timestamps, attempts and the like. */
5758
+ fields: {
5759
+ label: string;
5760
+ value: string;
5761
+ }[];
5762
+ /** The payload, pretty-printed, or `null`. */
5763
+ payload: string | null;
5764
+ /** The result, pretty-printed, or `null`. */
5765
+ result: string | null;
5766
+ /** The failure message, or `null`. */
5767
+ error: string | null;
5768
+ /** URL back to the tasks page. */
5769
+ backUrl: string;
5770
+ /** URL the cancel form posts to, or `null` when the run cannot be cancelled. */
5771
+ cancelUrl: string | null;
5772
+ }
5773
+ /**
5774
+ * Render one job run.
5775
+ *
5776
+ * @param context - The shared chrome data (with an active session).
5777
+ * @param view - The prepared run view model.
5778
+ * @returns The full page.
5779
+ * @throws Error When called without a session, since cancel needs a CSRF token.
5780
+ */
5781
+ declare function renderTaskDetailPage(context: AdminRenderContext, view: AdminTaskDetailView): string;
5523
5782
  /** The view model the SQL console renders. */
5524
5783
  interface AdminSqlView {
5525
5784
  /** The submitted statement, echoed back into the textarea. */
@@ -5654,6 +5913,19 @@ interface AdminRouterOptions {
5654
5913
  * and the boundary that holds is the database user behind `run`.
5655
5914
  */
5656
5915
  sqlConsole?: AdminSqlConsoleOptions;
5916
+ /**
5917
+ * Expose the background-tasks page. Either half may be omitted: with only a
5918
+ * `manager` the page shows what this process declares, with only a `jobs`
5919
+ * store it shows what the workers recorded.
5920
+ */
5921
+ tasks?: AdminTasksOptions;
5922
+ }
5923
+ /** Configuration for the optional tasks page. */
5924
+ interface AdminTasksOptions {
5925
+ /** The task manager whose registry supplies the declared schedule. */
5926
+ manager?: TaskManager;
5927
+ /** Builds a job store on the request's session, supplying the run history. */
5928
+ jobs?: (session: AsyncSession) => JobStore;
5657
5929
  }
5658
5930
  /** Configuration for the optional SQL console. */
5659
5931
  interface AdminSqlConsoleOptions {
@@ -6286,10 +6558,23 @@ declare function requireRoles(...roles: string[]): RequestHandler;
6286
6558
  * OpenAPI document generation from Zod schemas.
6287
6559
  *
6288
6560
  * Thin wrapper over `@asteasolutions/zod-to-openapi`. Register schemas and
6289
- * paths on a {@link OpenAPIRegistry}, then call {@link generateOpenApiDocument}
6290
- * to produce a spec that drives both Swagger UI and Redoc. Because every SDK
6291
- * schema is built from the `.openapi()`-augmented `z`, descriptions, examples
6292
- * and component names flow straight into the document.
6561
+ * paths on a registry, then call {@link generateOpenApiDocument} to produce a
6562
+ * spec that drives both Swagger UI and Redoc.
6563
+ *
6564
+ * ## Why the registry normalizes schemas
6565
+ *
6566
+ * `zod-to-openapi` adds `.openapi()` by patching `ZodType.prototype`. Zod v4
6567
+ * copies prototype members into each instance at construction, so the patch
6568
+ * does **not** reach schemas built *before* this module was evaluated — and
6569
+ * declaring schemas in `schemas/*.ts` while importing the SDK only in the docs
6570
+ * layer is the natural order, which means the failing order is the common one.
6571
+ * The symptom was a `TypeError: zodSchema.openapi is not a function` thrown
6572
+ * from inside `node_modules` at boot.
6573
+ *
6574
+ * {@link createOpenApiRegistry} therefore returns a registry that re-tags such
6575
+ * a schema through `.meta({ id })` — which builds a fresh instance, and so a
6576
+ * patched one — before handing it to the library. The same call site works
6577
+ * whatever order the modules happened to evaluate in.
6293
6578
  */
6294
6579
 
6295
6580
  /** Minimal `info` block for the generated document. */
@@ -6314,9 +6599,10 @@ interface GenerateOpenApiOptions {
6314
6599
  v31?: boolean;
6315
6600
  }
6316
6601
  /**
6317
- * Create a fresh, empty {@link OpenAPIRegistry}.
6602
+ * Create a fresh, empty registry.
6318
6603
  *
6319
- * @returns A registry to register schemas and paths on.
6604
+ * @returns A registry to register schemas and paths on, tolerant of the order
6605
+ * the caller's modules evaluated in.
6320
6606
  */
6321
6607
  declare function createOpenApiRegistry(): OpenAPIRegistry;
6322
6608
  /**
@@ -7490,6 +7776,6 @@ declare function createTestDatabase(models: readonly ModelClass[]): TestDatabase
7490
7776
  declare function withTestDatabase<T>(models: readonly ModelClass[], fn: (db: TestDatabase) => Promise<T>): Promise<T>;
7491
7777
 
7492
7778
  /** The installed SDK version. Single source of truth for the barrel + CLI. */
7493
- declare const VERSION = "0.29.0";
7779
+ declare const VERSION = "0.31.0";
7494
7780
 
7495
- export { ADMIN_CSS, type ActivationInput, ActivationService, type ActivationServiceOptions, type ActivationStore, type AdminAccessPolicy, type AdminAction, type AdminActionCategory, type AdminActionContext, type AdminActionHandler, type AdminActionOptions, type AdminActionResult, type AdminAuditEntryView, type AdminAuditView, type AdminAuthBackend, type AdminAutomapOptions, type AdminBusinessCardView, type AdminDashboardCard, type AdminDashboardMetrics, type AdminDetailView, type AdminFilterKind, type AdminFilterView, type AdminFormField, type AdminFormView, type AdminImportView, type AdminInline, type AdminInlineOptions, type AdminInlineRowView, type AdminInlineView, type AdminJsonField, type AdminJsonListQuery, type AdminJsonListResult, type AdminJsonResource, type AdminJsonRouterOptions, AdminJsonSite, type AdminLens, type AdminLensOptions, type AdminListView, type AdminLogEntry, type AdminLogRowView, type AdminLogsView, type AdminMessage, type AdminMfaVerifier, AdminModel, type AdminModelOptions, type AdminNavEntry, AdminPermission, type AdminRenderContext, type AdminRouterOptions, type AdminRow, type AdminSelectOption, type AdminSession, AdminSessionStore, type AdminSessionStoreOptions, AdminSite, type AdminSiteOptions, type AdminSortView, type AdminSqlConsoleOptions, type AdminSqlView, type AdminTheme, type AdminWidget, AppException, type AppExceptionHandlerOptions, type AppExceptionOptions, type AttachWebSocketOptions, AttemptThrottle, type AttemptThrottleOptions, AuditAction, type AuthResponse, type AuthResultPageOptions, type AuthRouterOptions, type AuthUser, type BackupOptions, type BaseAppSettings, BaseAuditLogModel, BaseController, BaseModel, BaseOAuthClient, BaseOutboxModel, type BaseResponse, BaseService, BaseUserModel, BaseUserRefreshTokenModel, BaseUserTokenModel, type BodySizeLimitOptions, type BroadcastOptions, type BroadcastResult, type BrokerManager, type BuildFormFieldsOptions, type BulkActionOption, CEP_PATTERN, CNPJ_PATTERN, CPF_PATTERN, type CPUMetrics, CSRF_COOKIE_NAME, CSRF_HEADER_NAME, type CacheManager, type CachedOptions, type CachedResponse, type CardCompute, type CardData, type CatalogData, CircuitOpenError, type ClientIpOptions, CompositeFeatureFlagBackend, ConflictException, type CreateAppOpenApi, type CreateAppOptions, type CsrfOptions, type CursorPaginationFilter, DEFAULT_DOCS_FAVICON, DEFAULT_LOCALE, type DownloadOptions, type EmailMessage, type EmailOptions, EmailProvider, type EmailProviderOptions, EmailUtils, type Enum, type EnumHelpers, type EnumSpec, EnvFeatureFlagBackend, EventStream, type EventStreamOptions, type ExceptionDetails, ExpiredTokenException, type FeatureFlagBackend, FeatureFlags, type FieldChange, type FileLoggingHandle, type FileLoggingOptions, type FlagContext, ForbiddenException, type GPUMetrics, type GenerateOpenApiOptions, GitHubOAuthClient, GoogleOAuthClient, GracefulShutdown, type GracefulShutdownOptions, HTTPClient, type HTTPClientOptions, HTTP_500_LOG_FILE, HTTP_500_MARKER, type HandshakeInfo, type HealthCheck, type HealthRouterOptions, HttpMetrics, IDEMPOTENCY_HEADER, type IdempotencyOptions, type IdempotencyRedisLike, type IdempotencyStore, type InboundHandler, type InboundMessage, InvalidTokenException, type IssuedSession, JSONLogger, JWTUtils, type JWTUtilsOptions, type JwtAuthOptions, type JwtClaims, type JwtDecoderLike, LEVEL_LOG_FILES, LocalUploadStorage, type LocalUploadStorageOptions, type LogEntry, type LogExtra, type LogLevel, type LogSink, type LogSource, type LoginInput, type LoginResult, type LogsRouterOptions, type MediaKind, MemoryBroker, MemoryCacheManager, MemoryFeatureFlagBackend, MemoryIdempotencyStore, type MemoryMetrics, MemoryRateLimitStore, MemorySessionStore, MemoryThrottleBackend, MessageCatalog, type MessageHandler, MessagingHub, type MessagingProvider, type MetricCard, type MetricPartition, type MetricTrend, type MetricValue, type MetricsRouterOptions, MetricsUtils, type MfaChallenge, type MfaChallengeInput, type MfaCodeInput, type MfaEnrollment, MfaService, type MfaServiceOptions, type MfaStore, MultipartLimitError, NotFoundException, type OAuthClientOptions, OAuthError, type OAuthTokens, type OAuthUser, OIDCProvider, type OIDCProviderOptions, type OpenApiDocument, type OpenApiInfo, type OutboundMedia, type OutboundResult, type OutboxPublisher, OutboxRelay, type OutboxRelayOptions, OutboxStatus, PHONE_BR_PATTERN, type PaginationFilter, type PaginationLinkOptions, type ParseFormBodyOptions, type ParseMultipartOptions, type ParsedAdminForm, type ParsedMultipart, type PasswordResetConfirmInput, type PasswordResetFormOptions, type PasswordResetRequestInput, PasswordResetService, type PasswordResetServiceOptions, type PasswordResetStore, PasswordUtils, REDOC_CDN_URL, REQUEST_ID_HEADER, RabbitBroker, type RabbitBrokerOptions, type RateLimitKeyFunc, type RateLimitOptions, type RateLimitRedisLike, type RateLimitResult, type RateLimitStore, RedisCacheManager, RedisIdempotencyStore, type RedisLike, type RedisPublisherLike, RedisRateLimitStore, RedisSSEBroker, type RedisSSEBrokerOptions, RedisSessionStore, type RedisSubscriberLike, type RedocBundleSource, type RedocOptions, type RefreshInput, Region, type RegionValue, type RegisterExceptionHandlersOptions, type RequestContext, type RequestTracingOptions, type ResolvedAdminTheme, type ResponseMapper, RetryPolicy, type RunServerOptions, type S3ClientLike, S3UploadStorage, type S3UploadStorageOptions, SSEBroker, type SaveOptions, type SendOptions, ServerSentEvent, type ServerSentEventInit, type Session, type SessionMiddlewareOptions, type SessionRedisLike, SessionService, type SessionServiceOptions, type SessionStore, type SignupInput, type SlowQueryOptions, type SpecProvider, type SqlAnalysis, type SqlAuditEntry, type SqlAuditHook, SqlCapability, type SqlConsolePolicy, type StateBR, type SwaggerOptions, type SyncFilter, type SystemMetrics, TOTPHelper, type TOTPOptions, type TaskHandler, TaskManager, type TaskManagerOptions, TelegramProvider, type TelegramProviderOptions, TenantScopedRepository, type TestDatabase, type ThrottleBackend, type ThrottleStatus, type ToDictOptions, type TokenPair, TooManyRequestsException, type TooManyRequestsOptions, type ToolSpecOptions, TwilioSmsProvider, type TwilioSmsProviderOptions, type TwilioWebhookOptions, UF, type UFValue, UnauthorizedException, type UnhandledExceptionHandlerOptions, type UploadResult, type UploadStorage, type UploadedFile, UserAuthService, type UserAuthServiceOptions, UserModelAuthBackend, type UserModelAuthBackendOptions, type UserPublic, type UserStore, UserTokenPurpose, VERSION, ValidationException, type WSEnvelope, WebPushDispatcher, type WebPushDispatcherOptions, WebPushError, WebPushGoneError, type WebPushKeys, type WebPushPayload, type WebPushSubscription, type WebSocketConnection, WebSocketHub, type WebSocketHubOptions, type WebSocketLike, type WebhookSignatureOptions, WebhookSignatureVerifier, WhatsAppProvider, type WhatsAppProviderOptions, type WhatsAppWebhookOptions, type WidgetSpec, activationSchema, addLogSink, adminAction, adminColumns, adminInline, adminLens, adminThemeCss, analyzeSql, attachWebSocketHub, authResponseSchema, authSettingsShape, backupDatabase, baseAppSettingsSchema, baseAppSettingsShape, baseResponseSchema, bearerToken, bodySizeLimitMiddleware, broadcastText, buildContentDisposition, buildFormFields, buildPaginationLinkHeader, cached, centsField, cepField, checkSqlPolicy, citiesByUf, cnpjField, coerceFlag, configureFileLogging, configureLogging, corsSettingsShape, cpfField, cpfOrCnpjField, createApp, createOpenApiRegistry, createTestDatabase, createdByColumn, csrfMiddleware, csrfTokenMatches, cursorPaginationFilterSchema, cursorPaginationSchema, databaseSettingsShape, decodeCursor, defaultMessageCatalog, defineEnum, deletedAtColumn, diffSnapshots, emailSettingsShape, encodeCursor, looseBoolean as envBoolean, envList, escapeHtml, filterForColumn, filterLogEntries, foreignKeyFields, foreignKeyLabel, foreignKeyTable, formatCellValue, formatFieldValue, generateCsrfToken, generateOAuthState, generateOpaqueToken, generateOpenApiDocument, getAuth, getClientIp, getConditions, getPaginationConditions, getRequestId, getState, groupInlineSubmission, hashOpaqueToken, hexColorField, humanizeField, idempotencyMiddleware, inboundMessageSchema, isColumnOptional, isMultipart, isSearchableColumn, isValidCep, isValidCity, isValidCnpj, isValidCpf, isValidCpfCnpj, isValidPhoneBr, isValidUf, jwtSettingsShape, keyByHeader, keyByIp, keyByJwtClaim, keyByJwtSubject, latitudeField, listStates, loadSettings, loadSqlParser, logEntrySchema, logSettingsShape, loginSchema, longitudeField, looseBoolean, makeAdminJsonRouter, makeAdminRouter, makeAppExceptionHandler, makeAuthRouter, makeFlagGuard, makeHealthRouter, makeJwtAuthMiddleware, makeLogsRouter, makeMetricsRouter, makeSessionMiddleware, makeToolSpecRouter, makeTwilioWebhookRouter, makeUnhandledExceptionHandler, makeWhatsAppWebhookRouter, metricCard, mfaChallengeSchema, mfaCodeSchema, mfaEnrollResponseSchema, minioSettingsShape, modifyDict, mountOpenApiJson, mountRedoc, mountSwaggerUi, nonEmptyStrField, nonNegativeFloatField, nonNegativeIntField, normalizeCep, normalizeCnpj, normalizeCpf, normalizeCpfCnpj, normalizePhoneBr, normalizeUf, notFoundHandler, onlyDigits, paginationFilterSchema, paginationSchema, parseAcceptLanguage, parseCookies, parseCsv, parseFormBody, parseMultipart, partitionTotal, passwordResetConfirmSchema, passwordResetRequestSchema, percentField, phoneBrField, portField, positiveFloatField, positiveIntField, priceField, prometheusMiddleware, rabbitmqSettingsShape, rateLimitMiddleware, ratingField, ratioField, readLogEntries, redisSettingsShape, refreshSchema, registerExceptionHandlers, renderAuthResultPage, renderDashboardPage, renderDetailPage, renderFormPage, renderImportPage, renderLayout, renderListPage, renderLogEntriesJson, renderLogEntriesMarkdown, renderLoginPage, renderLogsPage, renderMfaPage, renderPasswordResetFormPage, renderSqlPage, requestIdMiddleware, requestTracingMiddleware, requireRoles, resolveAdminTheme, resolveDownloadPath, resolveRedocBundle, runServer, runWithRequestContext, sendBytesDownload, sendFileDownload, serverSettingsShape, sessionCookie, sessionSettingsShape, setRequestId, signupSchema, slugField, snapshot, sseResponse, statesByRegion, syncFilterSchema, syncPaginationSchema, tableNameFor, toDict, toLogEntry, toUtc, tokenFromUrl, tokenPairSchema, tokenSettingsShape, trendDirection, trendPercent, ufField, updatedByColumn, uploadSettingsShape, userPublicSchema, utcnow, validateTwilioSignature, verifyOpaqueToken, webPushKeysSchema, webPushPayloadSchema, webPushSettingsShape, webPushSubscriptionSchema, webSocketSettingsShape, widgetForColumn, withTestDatabase, wrapWithSlowQueryLog, wsEnvelopeSchema };
7781
+ export { ADMIN_CSS, type ActivationInput, ActivationService, type ActivationServiceOptions, type ActivationStore, type AdminAccessPolicy, type AdminAction, type AdminActionCategory, type AdminActionContext, type AdminActionHandler, type AdminActionOptions, type AdminActionResult, type AdminAuditEntryView, type AdminAuditView, type AdminAuthBackend, type AdminAutomapOptions, type AdminBusinessCardView, type AdminDashboardCard, type AdminDashboardMetrics, type AdminDetailView, type AdminFilterKind, type AdminFilterView, type AdminFormField, type AdminFormView, type AdminImportView, type AdminInline, type AdminInlineOptions, type AdminInlineRowView, type AdminInlineView, type AdminJsonField, type AdminJsonListQuery, type AdminJsonListResult, type AdminJsonResource, type AdminJsonRouterOptions, AdminJsonSite, type AdminLens, type AdminLensOptions, type AdminListView, type AdminLogEntry, type AdminLogRowView, type AdminLogsView, type AdminMessage, type AdminMfaVerifier, AdminModel, type AdminModelOptions, type AdminNavEntry, AdminPermission, type AdminRenderContext, type AdminRouterOptions, type AdminRow, type AdminSelectOption, type AdminSession, AdminSessionStore, type AdminSessionStoreOptions, AdminSite, type AdminSiteOptions, type AdminSortView, type AdminSqlConsoleOptions, type AdminSqlView, type AdminTaskDetailView, type AdminTasksOptions, type AdminTasksView, type AdminTheme, type AdminWidget, AppException, type AppExceptionHandlerOptions, type AppExceptionOptions, type AttachWebSocketOptions, AttemptThrottle, type AttemptThrottleOptions, AuditAction, type AuthResponse, type AuthResultPageOptions, type AuthRouterOptions, type AuthUser, type BackupOptions, type BaseAppSettings, BaseAuditLogModel, BaseController, BaseJobModel, BaseModel, BaseOAuthClient, BaseOutboxModel, type BaseResponse, BaseService, BaseUserModel, BaseUserRefreshTokenModel, BaseUserTokenModel, type BodySizeLimitOptions, type BroadcastOptions, type BroadcastResult, type BrokerManager, type BuildFormFieldsOptions, type BulkActionOption, CEP_PATTERN, CNPJ_PATTERN, CPF_PATTERN, type CPUMetrics, CSRF_COOKIE_NAME, CSRF_HEADER_NAME, type CacheManager, type CachedOptions, type CachedResponse, type CardCompute, type CardData, type CatalogData, CircuitOpenError, type ClientIpOptions, CompositeFeatureFlagBackend, ConflictException, type CreateAppOpenApi, type CreateAppOptions, type CsrfOptions, type CursorPaginationFilter, DEFAULT_DOCS_FAVICON, DEFAULT_LOCALE, type DownloadOptions, type EmailMessage, type EmailOptions, EmailProvider, type EmailProviderOptions, EmailUtils, type Enum, type EnumHelpers, type EnumSpec, EnvFeatureFlagBackend, EventStream, type EventStreamOptions, type ExceptionDetails, ExpiredTokenException, type FeatureFlagBackend, FeatureFlags, type FieldChange, type FileLoggingHandle, type FileLoggingOptions, type FlagContext, ForbiddenException, type GPUMetrics, type GenerateOpenApiOptions, GitHubOAuthClient, GoogleOAuthClient, GracefulShutdown, type GracefulShutdownOptions, HTTPClient, type HTTPClientOptions, HTTP_500_LOG_FILE, HTTP_500_MARKER, type HandshakeInfo, type HealthCheck, type HealthRouterOptions, HttpMetrics, IDEMPOTENCY_HEADER, type IdempotencyOptions, type IdempotencyRedisLike, type IdempotencyStore, type InboundHandler, type InboundMessage, InvalidTokenException, type IssuedSession, JSONLogger, JWTUtils, type JWTUtilsOptions, JobStatus, JobStore, type JwtAuthOptions, type JwtClaims, type JwtDecoderLike, LEVEL_LOG_FILES, LocalUploadStorage, type LocalUploadStorageOptions, type LogEntry, type LogExtra, type LogLevel, type LogSink, type LogSource, type LoginInput, type LoginResult, type LogsRouterOptions, type MediaKind, MemoryBroker, MemoryCacheManager, MemoryFeatureFlagBackend, MemoryIdempotencyStore, type MemoryMetrics, MemoryRateLimitStore, MemorySessionStore, MemoryThrottleBackend, MessageCatalog, type MessageHandler, MessagingHub, type MessagingProvider, type MetricCard, type MetricPartition, type MetricTrend, type MetricValue, type MetricsRouterOptions, MetricsUtils, type MfaChallenge, type MfaChallengeInput, type MfaCodeInput, type MfaEnrollment, MfaService, type MfaServiceOptions, type MfaStore, MultipartLimitError, NotFoundException, type OAuthClientOptions, OAuthError, type OAuthTokens, type OAuthUser, OIDCProvider, type OIDCProviderOptions, type OpenApiDocument, type OpenApiInfo, type OutboundMedia, type OutboundResult, type OutboxPublisher, OutboxRelay, type OutboxRelayOptions, OutboxStatus, PHONE_BR_PATTERN, type PaginationFilter, type PaginationLinkOptions, type ParseFormBodyOptions, type ParseMultipartOptions, type ParsedAdminForm, type ParsedMultipart, type PasswordResetConfirmInput, type PasswordResetFormOptions, type PasswordResetRequestInput, PasswordResetService, type PasswordResetServiceOptions, type PasswordResetStore, PasswordUtils, REDOC_CDN_URL, REQUEST_ID_HEADER, RabbitBroker, type RabbitBrokerOptions, type RateLimitKeyFunc, type RateLimitOptions, type RateLimitRedisLike, type RateLimitResult, type RateLimitStore, RedisCacheManager, RedisIdempotencyStore, type RedisLike, type RedisPublisherLike, RedisRateLimitStore, RedisSSEBroker, type RedisSSEBrokerOptions, RedisSessionStore, type RedisSubscriberLike, type RedocBundleSource, type RedocOptions, type RefreshInput, Region, type RegionValue, type RegisterExceptionHandlersOptions, type RequestContext, type RequestTracingOptions, type ResolvedAdminTheme, type ResponseMapper, RetryPolicy, type RunServerOptions, type S3ClientLike, S3UploadStorage, type S3UploadStorageOptions, SSEBroker, type SaveOptions, type SendOptions, ServerSentEvent, type ServerSentEventInit, type Session, type SessionMiddlewareOptions, type SessionRedisLike, SessionService, type SessionServiceOptions, type SessionStore, type SignupInput, type SlowQueryOptions, type SpecProvider, type SqlAnalysis, type SqlAuditEntry, type SqlAuditHook, SqlCapability, type SqlConsolePolicy, type StateBR, type SwaggerOptions, type SyncFilter, type SystemMetrics, TOTPHelper, type TOTPOptions, type TaskHandler, type TaskInventoryEntry, TaskManager, type TaskManagerOptions, type TaskRegistrationOptions, TelegramProvider, type TelegramProviderOptions, TenantScopedRepository, type TestDatabase, type ThrottleBackend, type ThrottleStatus, type ToDictOptions, type TokenPair, TooManyRequestsException, type TooManyRequestsOptions, type ToolSpecOptions, TwilioSmsProvider, type TwilioSmsProviderOptions, type TwilioWebhookOptions, UF, type UFValue, UnauthorizedException, type UnhandledExceptionHandlerOptions, type UploadResult, type UploadStorage, type UploadedFile, UserAuthService, type UserAuthServiceOptions, UserModelAuthBackend, type UserModelAuthBackendOptions, type UserPublic, type UserStore, UserTokenPurpose, VERSION, ValidationException, type WSEnvelope, WebPushDispatcher, type WebPushDispatcherOptions, WebPushError, WebPushGoneError, type WebPushKeys, type WebPushPayload, type WebPushSubscription, type WebSocketConnection, WebSocketHub, type WebSocketHubOptions, type WebSocketLike, type WebhookSignatureOptions, WebhookSignatureVerifier, WhatsAppProvider, type WhatsAppProviderOptions, type WhatsAppWebhookOptions, type WidgetSpec, activationSchema, addLogSink, adminAction, adminColumns, adminInline, adminLens, adminThemeCss, analyzeSql, attachWebSocketHub, authResponseSchema, authSettingsShape, backupDatabase, baseAppSettingsSchema, baseAppSettingsShape, baseResponseSchema, bearerToken, bodySizeLimitMiddleware, broadcastText, buildContentDisposition, buildFormFields, buildPaginationLinkHeader, cached, centsField, cepField, checkSqlPolicy, citiesByUf, cnpjField, coerceFlag, configureFileLogging, configureLogging, corsSettingsShape, cpfField, cpfOrCnpjField, createApp, createOpenApiRegistry, createTestDatabase, createdByColumn, csrfMiddleware, csrfTokenMatches, cursorPaginationFilterSchema, cursorPaginationSchema, databaseSettingsShape, decodeCursor, defaultMessageCatalog, defineEnum, deletedAtColumn, diffSnapshots, emailSettingsShape, encodeCursor, looseBoolean as envBoolean, envList, escapeHtml, filterForColumn, filterLogEntries, foreignKeyFields, foreignKeyLabel, foreignKeyTable, formatCellValue, formatFieldValue, generateCsrfToken, generateOAuthState, generateOpaqueToken, generateOpenApiDocument, getAuth, getClientIp, getConditions, getPaginationConditions, getRequestId, getState, groupInlineSubmission, hashOpaqueToken, hexColorField, humanizeField, idempotencyMiddleware, inboundMessageSchema, isColumnOptional, isMultipart, isSearchableColumn, isValidCep, isValidCity, isValidCnpj, isValidCpf, isValidCpfCnpj, isValidPhoneBr, isValidUf, jwtSettingsShape, keyByHeader, keyByIp, keyByJwtClaim, keyByJwtSubject, latitudeField, listStates, loadSettings, loadSqlParser, logEntrySchema, logSettingsShape, loginSchema, longitudeField, looseBoolean, makeAdminJsonRouter, makeAdminRouter, makeAppExceptionHandler, makeAuthRouter, makeFlagGuard, makeHealthRouter, makeJwtAuthMiddleware, makeLogsRouter, makeMetricsRouter, makeSessionMiddleware, makeToolSpecRouter, makeTwilioWebhookRouter, makeUnhandledExceptionHandler, makeWhatsAppWebhookRouter, metricCard, mfaChallengeSchema, mfaCodeSchema, mfaEnrollResponseSchema, minioSettingsShape, modifyDict, mountOpenApiJson, mountRedoc, mountSwaggerUi, nonEmptyStrField, nonNegativeFloatField, nonNegativeIntField, normalizeCep, normalizeCnpj, normalizeCpf, normalizeCpfCnpj, normalizePhoneBr, normalizeUf, notFoundHandler, onlyDigits, paginationFilterSchema, paginationSchema, parseAcceptLanguage, parseCookies, parseCsv, parseFormBody, parseMultipart, partitionTotal, passwordResetConfirmSchema, passwordResetRequestSchema, percentField, phoneBrField, portField, positiveFloatField, positiveIntField, priceField, prometheusMiddleware, rabbitmqSettingsShape, rateLimitMiddleware, ratingField, ratioField, readLogEntries, redisSettingsShape, refreshSchema, registerExceptionHandlers, renderAuthResultPage, renderDashboardPage, renderDetailPage, renderFormPage, renderImportPage, renderLayout, renderListPage, renderLogEntriesJson, renderLogEntriesMarkdown, renderLoginPage, renderLogsPage, renderMfaPage, renderPasswordResetFormPage, renderSqlPage, renderTaskDetailPage, renderTasksPage, requestIdMiddleware, requestTracingMiddleware, requireRoles, resolveAdminTheme, resolveDownloadPath, resolveRedocBundle, runServer, runWithRequestContext, sendBytesDownload, sendFileDownload, serverSettingsShape, sessionCookie, sessionSettingsShape, setRequestId, signupSchema, slugField, snapshot, sseResponse, statesByRegion, syncFilterSchema, syncPaginationSchema, tableNameFor, toDict, toLogEntry, toUtc, tokenFromUrl, tokenPairSchema, tokenSettingsShape, trendDirection, trendPercent, ufField, updatedByColumn, uploadSettingsShape, userPublicSchema, utcnow, validateTwilioSignature, verifyOpaqueToken, webPushKeysSchema, webPushPayloadSchema, webPushSettingsShape, webPushSubscriptionSchema, webSocketSettingsShape, widgetForColumn, withTestDatabase, wrapWithSlowQueryLog, wsEnvelopeSchema };