@orieljs/framework 0.1.0-alpha.2 → 0.1.0-alpha.4

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.ts CHANGED
@@ -1,14 +1,15 @@
1
- import { C as ClassRegistry$3, a as Class$j, S as ServiceProvider$u, A as Application$c, b as Abstract$j, c as ConfigRepository$3 } from './jsx-runtime-CZ6JqBQo.js';
2
- export { d as ClassValue, e as Component, E as ELEMENT, F as FileViewFinder, f as Fragment, H as HtmlAttributes, g as HtmlString, I as InvalidViewError, O as OrielElement, P as Props, R as Renderable, h as StyleObject, T as TsxView, V as View, i as ViewEnvironment, j as ViewFactoryImpl, k as ViewNotFoundError, l as ViewRenderError, m as ViewServiceProvider, n as classNames, o as createElement, p as csrfField, q as e, r as isElement, s as isHtmlable, t as methodField, u as raw, v as renderToStream, w as renderToString, x as styleString, y as view } from './jsx-runtime-CZ6JqBQo.js';
3
- import { Token as Token$j, BusDispatcher as BusDispatcher$1, EventDispatcher as EventDispatcher$1, MailManager as MailManager$2, QueueManager as QueueManager$2, FilesystemManager as FilesystemManager$2, ServiceProviderClass as ServiceProviderClass$a } from './contracts.js';
4
- export { RouteList, RouteName } from './contracts.js';
5
- import { Target, BusFake, EventFake, MailFake, NotificationFake, QueueFake, FakeDisk } from './testing.js';
1
+ import { C as ClassRegistry$3, a as Class$j, S as ServiceProvider$u, A as Application$c, b as Abstract$j, c as ConfigRepository$3 } from './index.d-DOlTeG-8.js';
2
+ import { Token as Token$j, ServiceProviderClass as ServiceProviderClass$a } from './contracts.js';
3
+ export { InertiaPage, RouteList, RouteName } from './contracts.js';
4
+ import { T as Target, B as BusFake, E as EventFake, M as MailFake, N as NotificationFake, Q as QueueFake, F as FakeDisk } from './testing-D3dCOkTm.js';
5
+ export { C as Component, a as ComponentResult, b as Computed, c as CorruptComponentPayloadError, d as ErrorBag, I as InvalidLiveRequestError, L as Live, e as LiveComponentManager, f as LiveComponentNotFoundError, g as LiveError, h as LiveProps, i as LiveServiceProvider, j as Locked, k as MethodNotCallableError, O as On, P as PERSISTENT_MIDDLEWARE, l as PendingEvent, m as PersistentMiddleware, n as PropertyNotUpdatableError, o as TestRequestScope, p as Testable, U as UPDATE_URI, q as componentName, r as live, s as persistentMiddleware } from './testing-D3dCOkTm.js';
6
6
  import { IncomingMessage, ServerResponse } from 'node:http';
7
7
  import { Kysely, RawBuilder, CompiledQuery, QueryResult, SqliteDatabase, SqliteStatement, Dialect } from 'kysely';
8
8
  import Redis$1, { Redis } from 'ioredis';
9
9
  import pino from 'pino';
10
10
  import { WriteStream } from 'node:fs';
11
11
  import { Writable } from 'node:stream';
12
+ export { C as ClassValue, E as ELEMENT, F as FileViewFinder, a as Fragment, H as HtmlAttributes, b as HtmlString, I as InvalidViewError, O as OrielElement, P as Props, R as Renderable, S as StyleObject, T as TsxView, V as View, c as ViewComponent, d as ViewEnvironment, e as ViewFactoryImpl, f as ViewNotFoundError, g as ViewRenderError, h as ViewServiceProvider, i as classNames, j as createElement, k as csrfField, l as e, m as isElement, n as isHtmlable, o as methodField, r as raw, p as renderToStream, q as renderToString, s as styleString, v as view } from './jsx-runtime-WKTl3EEw.js';
12
13
 
13
14
  /** A typed, runtime-unique key for container bindings. */
14
15
  interface Token$i<T> {
@@ -356,6 +357,13 @@ declare function tap<T>(target: T, callback: (target: T) => void): T;
356
357
  /** Calls fn up to `times` times (attempt numbers are 1-based). Rethrows the last error, or the first one `when` rejects. */
357
358
  declare function retry<T>(times: number, fn: (attempt: number) => T | Promise<T>, sleepMs?: number | ((attempt: number) => number), when?: (error: unknown) => boolean): Promise<T>;
358
359
 
360
+ /**
361
+ * Laravel's __(): the line for `key` with `:placeholders` filled (`:name`, `:Name` capitalized, `:NAME` upper-cased),
362
+ * longest placeholder first. A key with no line comes back as is, so a sentence can be its own key:
363
+ * __('auth.failed'), __('auth.throttle', { seconds: 30 }), __('A reset link will be sent if the account exists.').
364
+ */
365
+ declare function __(key: string, replace?: Record<string, string | number>): string;
366
+
359
367
  interface ConfigRepository$2 {
360
368
  has(key: string): boolean;
361
369
  /** Dot notation: get('database.connections.sqlite.database'). */
@@ -416,59 +424,6 @@ interface Container$i {
416
424
  }
417
425
  declare const Container$i: Token$h<Container$i>;
418
426
 
419
- interface ServiceProvider$s {
420
- /** Bind things into the container. Synchronous. Don't resolve other services here. */
421
- register?(): void;
422
- /** Runs after every provider is registered. May be async (e.g. importing route files). */
423
- boot?(): void | Promise<void>;
424
- }
425
- type ServiceProviderClass$9 = new (app: Application$b) => ServiceProvider$s;
426
- interface Application$b extends Container$i {
427
- readonly version: string;
428
- basePath(path?: string): string;
429
- appPath(path?: string): string;
430
- bootstrapPath(path?: string): string;
431
- configPath(path?: string): string;
432
- databasePath(path?: string): string;
433
- publicPath(path?: string): string;
434
- resourcePath(path?: string): string;
435
- storagePath(path?: string): string;
436
- /** With no args returns the environment name. With args returns whether it matches any of them. */
437
- environment(): string;
438
- environment(...environments: string[]): boolean;
439
- isProduction(): boolean;
440
- isLocal(): boolean;
441
- runningInConsole(): boolean;
442
- /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
443
- setRunningInConsole(value?: boolean): void;
444
- runningUnitTests(): boolean;
445
- /** Registers the provider. If the app is already booted, the provider is booted immediately. */
446
- register(provider: ServiceProvider$s | ServiceProviderClass$9): Promise<ServiceProvider$s>;
447
- getProviders(): ServiceProvider$s[];
448
- boot(): Promise<void>;
449
- isBooted(): boolean;
450
- booting(callback: (app: Application$b) => void | Promise<void>): void;
451
- booted(callback: (app: Application$b) => void | Promise<void>): void;
452
- /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
453
- handle(request: Request): Promise<Response>;
454
- /** Register a callback that terminate() runs, in registration order. */
455
- terminating(callback: () => void | Promise<void>): void;
456
- terminate(): Promise<void>;
457
- }
458
- declare const Application$b: Token$j<Application$b>;
459
- /** The object passed to Application.configure().withExceptions(e => …), like Laravel's Exceptions class. */
460
- interface ExceptionsConfigurator$1 {
461
- /** Custom reporting. Return false to stop the default logging. */
462
- report(callback: (error: unknown) => void | boolean | Promise<void | boolean>): this;
463
- /** Custom rendering. Return undefined to fall through to the default rendering. */
464
- render(callback: (error: unknown, request: unknown) => Response | undefined | Promise<Response | undefined>): this;
465
- /** Never report errors of these classes. */
466
- dontReport(...classes: Array<abstract new (...args: never[]) => Error>): this;
467
- }
468
- interface Htmlable$1 {
469
- toHtml(): string;
470
- }
471
-
472
427
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
473
428
  interface Session$6 {
474
429
  getId(): string;
@@ -531,6 +486,8 @@ interface HttpRequest$6 {
531
486
  header(name: string, defaultValue: string): string;
532
487
  bearerToken(): string | undefined;
533
488
  ip(): string | undefined;
489
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
490
+ content(): string;
534
491
  expectsJson(): boolean;
535
492
  ajax(): boolean;
536
493
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -590,6 +547,61 @@ interface HttpKernel$1 {
590
547
  }
591
548
  declare const HttpKernel$1: Token$j<HttpKernel$1>;
592
549
 
550
+ interface ServiceProvider$s {
551
+ /** Bind things into the container. Synchronous. Don't resolve other services here. */
552
+ register?(): void;
553
+ /** Runs after every provider is registered. May be async (e.g. importing route files). */
554
+ boot?(): void | Promise<void>;
555
+ }
556
+ type ServiceProviderClass$9 = new (app: Application$b) => ServiceProvider$s;
557
+ interface Application$b extends Container$i {
558
+ readonly version: string;
559
+ basePath(path?: string): string;
560
+ appPath(path?: string): string;
561
+ bootstrapPath(path?: string): string;
562
+ configPath(path?: string): string;
563
+ databasePath(path?: string): string;
564
+ publicPath(path?: string): string;
565
+ resourcePath(path?: string): string;
566
+ storagePath(path?: string): string;
567
+ /** With no args returns the environment name. With args returns whether it matches any of them. */
568
+ environment(): string;
569
+ environment(...environments: string[]): boolean;
570
+ isProduction(): boolean;
571
+ isLocal(): boolean;
572
+ runningInConsole(): boolean;
573
+ /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
574
+ setRunningInConsole(value?: boolean): void;
575
+ runningUnitTests(): boolean;
576
+ /** Registers the provider. If the app is already booted, the provider is booted immediately. */
577
+ register(provider: ServiceProvider$s | ServiceProviderClass$9): Promise<ServiceProvider$s>;
578
+ getProviders(): ServiceProvider$s[];
579
+ boot(): Promise<void>;
580
+ isBooted(): boolean;
581
+ booting(callback: (app: Application$b) => void | Promise<void>): void;
582
+ booted(callback: (app: Application$b) => void | Promise<void>): void;
583
+ /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
584
+ handle(request: Request): Promise<Response>;
585
+ /** Register a callback that terminate() runs, in registration order. */
586
+ terminating(callback: () => void | Promise<void>): void;
587
+ terminate(): Promise<void>;
588
+ }
589
+ declare const Application$b: Token$j<Application$b>;
590
+ /** The object passed to Application.configure().withExceptions(e => …), like Laravel's Exceptions class. */
591
+ interface ExceptionsConfigurator$1 {
592
+ /** Custom reporting. Return false to stop the default logging. */
593
+ report(callback: (error: unknown) => void | boolean | Promise<void | boolean>): this;
594
+ /** Custom rendering. Return undefined to fall through to the default rendering. */
595
+ render(callback: (error: unknown, request: unknown) => Response | undefined | Promise<Response | undefined>): this;
596
+ /** Never report errors of these classes. */
597
+ dontReport(...classes: Array<abstract new (...args: never[]) => Error>): this;
598
+ /** Render errors as JSON when the callback returns true, whatever the Accept header. */
599
+ shouldRenderJsonWhen(callback: (request: HttpRequest$6, error: unknown) => boolean): this;
600
+ }
601
+ interface Htmlable$1 {
602
+ toHtml(): string;
603
+ }
604
+
593
605
  type ErrorKind$j = 'Http' | 'Server' | 'ModelNotFound' | 'Validation' | 'Authentication' | 'Authorization' | 'TokenMismatch' | 'BindingResolution' | 'CircularDependency' | 'ContainerNotAvailable';
594
606
  /** Every error thrown by the framework implements this. The exception handler switches on `kind`. */
595
607
  interface OrielError$j extends Error {
@@ -639,8 +651,9 @@ declare class Container$h implements Container$k {
639
651
  }
640
652
 
641
653
  interface RoutingOptions {
642
- web?: string;
643
- api?: string;
654
+ /** One route file or several, loaded in order: web: ['routes/web.ts', 'routes/settings.ts', 'routes/auth.ts']. */
655
+ web?: string | string[];
656
+ api?: string | string[];
644
657
  console?: string;
645
658
  /** A URI such as '/up', not a file. */
646
659
  health?: string;
@@ -666,7 +679,7 @@ declare class ApplicationBuilder {
666
679
  type LifecycleCallback = (app: Application$b) => void | Promise<void>;
667
680
  declare class Application$a extends Container$h implements Application$b {
668
681
  private readonly base;
669
- readonly version = "0.1.0-alpha.1";
682
+ readonly version = "0.1.0-alpha.4";
670
683
  private readonly providers;
671
684
  private readonly bootingCallbacks;
672
685
  private readonly bootedCallbacks;
@@ -999,7 +1012,8 @@ declare class MailMessage {
999
1012
  introLines: string[];
1000
1013
  actionData?: MailMessageAction;
1001
1014
  outroLines: string[];
1002
- salutationLine: string;
1015
+ /** Unset: "Regards," and config('app.name'), as Laravel's template. */
1016
+ salutationLine?: string;
1003
1017
  toAddresses: MailRecipient$1[];
1004
1018
  ccAddresses: MailRecipient$1[];
1005
1019
  bccAddresses: MailRecipient$1[];
@@ -1178,19 +1192,19 @@ declare class NotificationsServiceProvider extends ServiceProvider$r {
1178
1192
  boot(): void;
1179
1193
  }
1180
1194
 
1181
- declare const Mail: Facade$c<MailManager$2, {
1195
+ declare const Mail: Facade$c<object, {
1182
1196
  fake: () => MailFake;
1183
1197
  }>;
1184
- declare const Queue$1: Facade$c<QueueManager$2, {
1198
+ declare const Queue$1: Facade$c<object, {
1185
1199
  fake: (jobsToFake?: Target<unknown> | Target<unknown>[] | undefined) => QueueFake;
1186
1200
  }>;
1187
- declare const Bus: Facade$c<BusDispatcher$1, {
1201
+ declare const Bus: Facade$c<object, {
1188
1202
  fake: (jobsToFake?: Target<unknown> | Target<unknown>[] | undefined) => BusFake;
1189
1203
  }>;
1190
- declare const Event: Facade$c<EventDispatcher$1, {
1204
+ declare const Event: Facade$c<object, {
1191
1205
  fake: (eventsToFake?: Target<unknown> | Target<unknown>[] | undefined) => EventFake;
1192
1206
  }>;
1193
- declare const Storage: Facade$c<FilesystemManager$2, {
1207
+ declare const Storage: Facade$c<object, {
1194
1208
  fake: (disk?: string | undefined) => FakeDisk;
1195
1209
  }>;
1196
1210
  /** The notification base class with Laravel's Notification::fake(). */
@@ -1384,47 +1398,6 @@ interface Container$e {
1384
1398
  }
1385
1399
  declare const Container$e: Token$e<Container$e>;
1386
1400
 
1387
- interface ServiceProvider$p {
1388
- /** Bind things into the container. Synchronous. Don't resolve other services here. */
1389
- register?(): void;
1390
- /** Runs after every provider is registered. May be async (e.g. importing route files). */
1391
- boot?(): void | Promise<void>;
1392
- }
1393
- type ServiceProviderClass$7 = new (app: Application$7) => ServiceProvider$p;
1394
- interface Application$7 extends Container$e {
1395
- readonly version: string;
1396
- basePath(path?: string): string;
1397
- appPath(path?: string): string;
1398
- bootstrapPath(path?: string): string;
1399
- configPath(path?: string): string;
1400
- databasePath(path?: string): string;
1401
- publicPath(path?: string): string;
1402
- resourcePath(path?: string): string;
1403
- storagePath(path?: string): string;
1404
- /** With no args returns the environment name. With args returns whether it matches any of them. */
1405
- environment(): string;
1406
- environment(...environments: string[]): boolean;
1407
- isProduction(): boolean;
1408
- isLocal(): boolean;
1409
- runningInConsole(): boolean;
1410
- /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
1411
- setRunningInConsole(value?: boolean): void;
1412
- runningUnitTests(): boolean;
1413
- /** Registers the provider. If the app is already booted, the provider is booted immediately. */
1414
- register(provider: ServiceProvider$p | ServiceProviderClass$7): Promise<ServiceProvider$p>;
1415
- getProviders(): ServiceProvider$p[];
1416
- boot(): Promise<void>;
1417
- isBooted(): boolean;
1418
- booting(callback: (app: Application$7) => void | Promise<void>): void;
1419
- booted(callback: (app: Application$7) => void | Promise<void>): void;
1420
- /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
1421
- handle(request: Request): Promise<Response>;
1422
- /** Register a callback that terminate() runs, in registration order. */
1423
- terminating(callback: () => void | Promise<void>): void;
1424
- terminate(): Promise<void>;
1425
- }
1426
- declare const Application$7: Token$j<Application$7>;
1427
-
1428
1401
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
1429
1402
  interface Session$5 {
1430
1403
  getId(): string;
@@ -1487,6 +1460,8 @@ interface HttpRequest$5 {
1487
1460
  header(name: string, defaultValue: string): string;
1488
1461
  bearerToken(): string | undefined;
1489
1462
  ip(): string | undefined;
1463
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
1464
+ content(): string;
1490
1465
  expectsJson(): boolean;
1491
1466
  ajax(): boolean;
1492
1467
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -1520,20 +1495,65 @@ interface Middleware$5 {
1520
1495
  }
1521
1496
  type MiddlewareClass$1 = new (...args: any[]) => Middleware$5;
1522
1497
 
1498
+ interface ServiceProvider$p {
1499
+ /** Bind things into the container. Synchronous. Don't resolve other services here. */
1500
+ register?(): void;
1501
+ /** Runs after every provider is registered. May be async (e.g. importing route files). */
1502
+ boot?(): void | Promise<void>;
1503
+ }
1504
+ type ServiceProviderClass$7 = new (app: Application$7) => ServiceProvider$p;
1505
+ interface Application$7 extends Container$e {
1506
+ readonly version: string;
1507
+ basePath(path?: string): string;
1508
+ appPath(path?: string): string;
1509
+ bootstrapPath(path?: string): string;
1510
+ configPath(path?: string): string;
1511
+ databasePath(path?: string): string;
1512
+ publicPath(path?: string): string;
1513
+ resourcePath(path?: string): string;
1514
+ storagePath(path?: string): string;
1515
+ /** With no args returns the environment name. With args returns whether it matches any of them. */
1516
+ environment(): string;
1517
+ environment(...environments: string[]): boolean;
1518
+ isProduction(): boolean;
1519
+ isLocal(): boolean;
1520
+ runningInConsole(): boolean;
1521
+ /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
1522
+ setRunningInConsole(value?: boolean): void;
1523
+ runningUnitTests(): boolean;
1524
+ /** Registers the provider. If the app is already booted, the provider is booted immediately. */
1525
+ register(provider: ServiceProvider$p | ServiceProviderClass$7): Promise<ServiceProvider$p>;
1526
+ getProviders(): ServiceProvider$p[];
1527
+ boot(): Promise<void>;
1528
+ isBooted(): boolean;
1529
+ booting(callback: (app: Application$7) => void | Promise<void>): void;
1530
+ booted(callback: (app: Application$7) => void | Promise<void>): void;
1531
+ /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
1532
+ handle(request: Request): Promise<Response>;
1533
+ /** Register a callback that terminate() runs, in registration order. */
1534
+ terminating(callback: () => void | Promise<void>): void;
1535
+ terminate(): Promise<void>;
1536
+ }
1537
+ declare const Application$7: Token$j<Application$7>;
1538
+
1523
1539
  /** Public method names of a controller (excludes non-function members). */
1524
1540
  type ActionMethods$1<C> = {
1525
1541
  [K in keyof C]: C[K] extends (...args: any[]) => unknown ? K : never;
1526
1542
  }[keyof C] & string;
1527
1543
  type ControllerAction$1<C> = readonly [Class$e<C>, ActionMethods$1<C>];
1528
1544
  type RouteClosure$1 = (...args: any[]) => unknown;
1529
- type RouteAction$1 = RouteClosure$1 | ControllerAction$1<any>;
1545
+ /** A class with __invoke(): Route.get('/counter', Counter) (single-action controllers, full-page Live components). */
1546
+ type InvokableClass$1 = Class$e<{
1547
+ __invoke(...args: any[]): unknown;
1548
+ }>;
1549
+ type RouteAction$1 = RouteClosure$1 | ControllerAction$1<any> | InvokableClass$1;
1530
1550
  type MiddlewareReference$1 = string | MiddlewareClass$1;
1531
1551
  interface Route$2 {
1532
1552
  readonly methods: readonly string[];
1533
1553
  readonly uri: string;
1534
1554
  getName(): string | undefined;
1535
1555
  name(name: string): this;
1536
- middleware(...middleware: MiddlewareReference$1[]): this;
1556
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): this;
1537
1557
  withoutMiddleware(...middleware: MiddlewareReference$1[]): this;
1538
1558
  where(parameter: string, pattern: string): this;
1539
1559
  where(patterns: Record<string, string>): this;
@@ -1541,7 +1561,7 @@ interface Route$2 {
1541
1561
  interface RouteRegistrar$1 {
1542
1562
  prefix(prefix: string): RouteRegistrar$1;
1543
1563
  name(prefix: string): RouteRegistrar$1;
1544
- middleware(...middleware: MiddlewareReference$1[]): RouteRegistrar$1;
1564
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): RouteRegistrar$1;
1545
1565
  controller(controller: Class$e<unknown>): RouteRegistrar$1;
1546
1566
  group(routes: () => void | Promise<void>): Promise<void>;
1547
1567
  }
@@ -1552,14 +1572,14 @@ interface ResourceOptions$1 {
1552
1572
  names?: Record<string, string>;
1553
1573
  }
1554
1574
  interface Router$1 {
1555
- get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1556
- post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1557
- put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1558
- patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1559
- delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1560
- options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1561
- any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1562
- match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): Route$2;
1575
+ get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1576
+ post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1577
+ put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1578
+ patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1579
+ delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1580
+ options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1581
+ any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1582
+ match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): Route$2;
1563
1583
  redirect(from: string, to: string, status?: number): Route$2;
1564
1584
  view(uri: string, view: string, data?: Record<string, unknown>): Route$2;
1565
1585
  /** Route.inertia('/about', 'About', props): a GET route that renders an Inertia page (Laravel's Route::inertia). */
@@ -1569,7 +1589,7 @@ interface Router$1 {
1569
1589
  fallback(action: RouteAction$1): Route$2;
1570
1590
  prefix(prefix: string): RouteRegistrar$1;
1571
1591
  name(prefix: string): RouteRegistrar$1;
1572
- middleware(...middleware: MiddlewareReference$1[]): RouteRegistrar$1;
1592
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): RouteRegistrar$1;
1573
1593
  controller(controller: Class$e<unknown>): RouteRegistrar$1;
1574
1594
  /** Explicit model binding: Route.model('author', User). */
1575
1595
  model(parameter: string, model: Class$e<unknown>): void;
@@ -1596,6 +1616,12 @@ interface UrlGenerator$1 {
1596
1616
  current(): string;
1597
1617
  previous(fallback?: string): string;
1598
1618
  hasRoute(name: string): boolean;
1619
+ /** A URL to a named route with a `signature` query (HMAC-SHA256 keyed by APP_KEY); `expiration` adds `expires`. */
1620
+ signedRoute(name: string, parameters?: unknown, expiration?: Date | number, absolute?: boolean): string;
1621
+ /** signedRoute() that expires: a Date, or seconds from now. */
1622
+ temporarySignedRoute(name: string, expiration: Date | number, parameters?: unknown, absolute?: boolean): string;
1623
+ /** Whether the request URL carries a valid, unexpired signature (`absolute: false` signs the path only). */
1624
+ hasValidSignature(request: HttpRequest$5, absolute?: boolean): boolean;
1599
1625
  }
1600
1626
  declare const UrlGenerator$1: Token$j<UrlGenerator$1>;
1601
1627
 
@@ -1665,7 +1691,8 @@ declare class RouteDefinition implements Route$2 {
1665
1691
  getName(): string | undefined;
1666
1692
  /** Appends, like Laravel's $action['as'] .= $name. */
1667
1693
  name(name: string): this;
1668
- middleware(...middleware: MiddlewareReference$1[]): this;
1694
+ /** middleware('auth', 'verified') or middleware(['auth', 'verified']). */
1695
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): this;
1669
1696
  withoutMiddleware(...middleware: MiddlewareReference$1[]): this;
1670
1697
  where(parameter: string | Record<string, string>, pattern?: string): this;
1671
1698
  gatherMiddleware(): MiddlewareReference$1[];
@@ -1705,17 +1732,17 @@ declare class GroupRegistrar implements RouteRegistrar$1 {
1705
1732
  constructor(router: GroupHost);
1706
1733
  prefix(prefix: string): this;
1707
1734
  name(prefix: string): this;
1708
- middleware(...middleware: MiddlewareReference$1[]): this;
1735
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): this;
1709
1736
  controller(controller: Class$e<unknown>): this;
1710
1737
  group(routes: () => void | Promise<void>): Promise<void>;
1711
- get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1712
- post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1713
- put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1714
- patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1715
- delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1716
- options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1717
- any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1718
- match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1738
+ get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1739
+ post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1740
+ put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1741
+ patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1742
+ delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1743
+ options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1744
+ any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1745
+ match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1719
1746
  resource(name: string, controller: Class$e<unknown>, options?: ResourceOptions$1): void;
1720
1747
  apiResource(name: string, controller: Class$e<unknown>, options?: ResourceOptions$1): void;
1721
1748
  }
@@ -1727,14 +1754,14 @@ declare class BaseRouter implements Router$1 {
1727
1754
  protected readonly container?: Container$e | undefined;
1728
1755
  /** `container` is the application; request-time lookups use the current (request) container first. */
1729
1756
  constructor(container?: Container$e | undefined);
1730
- get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1731
- post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1732
- put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1733
- patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1734
- delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1735
- options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1736
- any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1737
- match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | string): RouteDefinition;
1757
+ get<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1758
+ post<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1759
+ put<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1760
+ patch<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1761
+ delete<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1762
+ options<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1763
+ any<C>(uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1764
+ match<C>(methods: string[], uri: string, action: ControllerAction$1<C> | RouteClosure$1 | InvokableClass$1 | string): RouteDefinition;
1738
1765
  /** Registers a route with the current group's prefix, name prefix, middleware and controller. GET implies HEAD. */
1739
1766
  addRoute(methods: readonly string[], uri: string, action: RouteHandler, options?: {
1740
1767
  fallback?: boolean;
@@ -1755,7 +1782,7 @@ declare class BaseRouter implements Router$1 {
1755
1782
  fallback(action: RouteAction$1): RouteDefinition;
1756
1783
  prefix(prefix: string): GroupRegistrar;
1757
1784
  name(prefix: string): GroupRegistrar;
1758
- middleware(...middleware: MiddlewareReference$1[]): GroupRegistrar;
1785
+ middleware(...middleware: Array<MiddlewareReference$1 | readonly MiddlewareReference$1[]>): GroupRegistrar;
1759
1786
  controller(controller: Class$e<unknown>): GroupRegistrar;
1760
1787
  /**
1761
1788
  * Laravel's Route::group(attributes, callback). A synchronous callback's attributes are popped before this
@@ -1815,6 +1842,20 @@ declare class BaseUrlGenerator implements UrlGenerator$1 {
1815
1842
  /** The Referer header, then the session's previous URL, then `fallback`, then the root (Laravel's order). */
1816
1843
  previous(fallback?: string): string;
1817
1844
  hasRoute(name: string): boolean;
1845
+ /**
1846
+ * Laravel's URL::signedRoute(): the route URL with its parameters sorted by name, then a `signature` query (the
1847
+ * HMAC-SHA256 of that URL, keyed by APP_KEY). `expiration` (a Date, or seconds from now) adds `expires`.
1848
+ * `absolute: false` signs the path only (checked by `signed:relative`).
1849
+ */
1850
+ signedRoute(name: string, parameters?: unknown, expiration?: Date | number, absolute?: boolean): string;
1851
+ /** Laravel's URL::temporarySignedRoute(): a signed URL that expires at `expiration` (a Date, or seconds from now). */
1852
+ temporarySignedRoute(name: string, expiration: Date | number, parameters?: unknown, absolute?: boolean): string;
1853
+ /** The request URL carries a correct signature (current or previous APP_KEY) that hasn't expired. */
1854
+ hasValidSignature(request: HttpRequest$5, absolute?: boolean): boolean;
1855
+ /** The signature matches the URL without its `signature` query, in a constant-time comparison. */
1856
+ hasCorrectSignature(request: HttpRequest$5, absolute?: boolean): boolean;
1857
+ /** No `expires` query, or one that is still in the future. */
1858
+ signatureHasNotExpired(request: HttpRequest$5): boolean;
1818
1859
  }
1819
1860
 
1820
1861
  /** A middleware reference after alias and group expansion: 'throttle:60,1' → { cls: Throttle, parameters: ['60', '1'] }. */
@@ -1929,6 +1970,21 @@ declare class RoutingError extends Error implements OrielError$g {
1929
1970
  readonly status = 500;
1930
1971
  readonly name = "RoutingError";
1931
1972
  }
1973
+ /** A signed URL whose signature is missing, wrong or expired (Laravel's InvalidSignatureException). */
1974
+ declare class InvalidUrlSignatureError extends Error implements OrielError$g {
1975
+ readonly kind: "Http";
1976
+ readonly status = 403;
1977
+ readonly name = "InvalidUrlSignatureError";
1978
+ constructor();
1979
+ }
1980
+ /** Too many requests in the window (Laravel's ThrottleRequestsException): 429 with Retry-After and X-RateLimit-*. */
1981
+ declare class ThrottleRequestsError extends Error implements OrielError$g {
1982
+ readonly headers: Record<string, string>;
1983
+ readonly kind: "Http";
1984
+ readonly status = 429;
1985
+ readonly name = "ThrottleRequestsError";
1986
+ constructor(headers?: Record<string, string>);
1987
+ }
1932
1988
 
1933
1989
  type ResourceMethod = 'index' | 'create' | 'store' | 'show' | 'edit' | 'update' | 'destroy';
1934
1990
  interface ResourceRoute {
@@ -1964,11 +2020,12 @@ declare function loadRoutesFrom(app: Application$7, router: Router$1, file: stri
1964
2020
  declare function healthResponse(): Response;
1965
2021
 
1966
2022
  /**
1967
- * Binds the Router and the UrlGenerator, and once the app has booted loads the files given to withRouting(): the health URI,
1968
- * then routes/web.ts in the `web` middleware group, then routes/api.ts under the api prefix in the `api` group
1969
- * (Laravel's ApplicationBuilder::withRouting).
2023
+ * Binds the Router and the UrlGenerator, registers the `signed` and `throttle` middleware, and once the app has booted
2024
+ * loads the files given to withRouting(): the health URI, then the web files in the `web` middleware group, then the
2025
+ * api files under the api prefix in the `api` group (Laravel's ApplicationBuilder::withRouting).
1970
2026
  */
1971
2027
  declare class RoutingServiceProvider extends ServiceProvider$o {
2028
+ #private;
1972
2029
  register(): void;
1973
2030
  /**
1974
2031
  * The files load in a booted() callback, after every provider's boot() (Laravel's withRouting does the same), so
@@ -1978,6 +2035,25 @@ declare class RoutingServiceProvider extends ServiceProvider$o {
1978
2035
  boot(): void;
1979
2036
  }
1980
2037
 
2038
+ /**
2039
+ * Laravel's ThrottleRequests (`throttle:<maxAttempts>,<decayMinutes>[,<prefix>]`): counts the client's requests
2040
+ * (the signed-in user, else the IP) in a window and answers 429 once there are too many. Responses carry
2041
+ * X-RateLimit-Limit and X-RateLimit-Remaining; the 429 adds Retry-After and X-RateLimit-Reset.
2042
+ */
2043
+ declare class ThrottleRequests implements Middleware$5 {
2044
+ handle(request: HttpRequest$5, next: Next$6, maxAttempts?: string, decayMinutes?: string, prefix?: string): Promise<Response>;
2045
+ /** The signed-in user's identifier, else the client IP, hashed (Laravel's resolveRequestSignature()). */
2046
+ protected resolveRequestSignature(request: HttpRequest$5): string;
2047
+ }
2048
+
2049
+ /**
2050
+ * Laravel's ValidateSignature (`signed`, `signed:relative`): the request URL must carry a valid, unexpired
2051
+ * signature from URL.signedRoute()/temporarySignedRoute(), else 403. `relative` checks a path-only signature.
2052
+ */
2053
+ declare class ValidateSignature implements Middleware$5 {
2054
+ handle(request: HttpRequest$5, next: Next$6, ...parameters: string[]): Promise<Response>;
2055
+ }
2056
+
1981
2057
  /** A typed, runtime-unique key for container bindings. */
1982
2058
  interface Token$d<T> {
1983
2059
  readonly id: symbol;
@@ -2014,78 +2090,6 @@ interface Container$d {
2014
2090
  }
2015
2091
  declare const Container$d: Token$d<Container$d>;
2016
2092
 
2017
- interface ServiceProvider$n {
2018
- /** Bind things into the container. Synchronous. Don't resolve other services here. */
2019
- register?(): void;
2020
- /** Runs after every provider is registered. May be async (e.g. importing route files). */
2021
- boot?(): void | Promise<void>;
2022
- }
2023
- type ServiceProviderClass$6 = new (app: Application$6) => ServiceProvider$n;
2024
- interface Application$6 extends Container$d {
2025
- readonly version: string;
2026
- basePath(path?: string): string;
2027
- appPath(path?: string): string;
2028
- bootstrapPath(path?: string): string;
2029
- configPath(path?: string): string;
2030
- databasePath(path?: string): string;
2031
- publicPath(path?: string): string;
2032
- resourcePath(path?: string): string;
2033
- storagePath(path?: string): string;
2034
- /** With no args returns the environment name. With args returns whether it matches any of them. */
2035
- environment(): string;
2036
- environment(...environments: string[]): boolean;
2037
- isProduction(): boolean;
2038
- isLocal(): boolean;
2039
- runningInConsole(): boolean;
2040
- /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
2041
- setRunningInConsole(value?: boolean): void;
2042
- runningUnitTests(): boolean;
2043
- /** Registers the provider. If the app is already booted, the provider is booted immediately. */
2044
- register(provider: ServiceProvider$n | ServiceProviderClass$6): Promise<ServiceProvider$n>;
2045
- getProviders(): ServiceProvider$n[];
2046
- boot(): Promise<void>;
2047
- isBooted(): boolean;
2048
- booting(callback: (app: Application$6) => void | Promise<void>): void;
2049
- booted(callback: (app: Application$6) => void | Promise<void>): void;
2050
- /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
2051
- handle(request: Request): Promise<Response>;
2052
- /** Register a callback that terminate() runs, in registration order. */
2053
- terminating(callback: () => void | Promise<void>): void;
2054
- terminate(): Promise<void>;
2055
- }
2056
- declare const Application$6: Token$j<Application$6>;
2057
- interface ExceptionHandler {
2058
- report(error: unknown): Promise<void>;
2059
- shouldReport(error: unknown): boolean;
2060
- /** `request` is the scoped HttpRequest (Contracts/Http) when available, else the raw Request. */
2061
- render(request: unknown, error: unknown): Promise<Response>;
2062
- }
2063
- declare const ExceptionHandler: Token$j<ExceptionHandler>;
2064
- /** The object passed to Application.configure().withExceptions(e => …), like Laravel's Exceptions class. */
2065
- interface ExceptionsConfigurator {
2066
- /** Custom reporting. Return false to stop the default logging. */
2067
- report(callback: (error: unknown) => void | boolean | Promise<void | boolean>): this;
2068
- /** Custom rendering. Return undefined to fall through to the default rendering. */
2069
- render(callback: (error: unknown, request: unknown) => Response | undefined | Promise<Response | undefined>): this;
2070
- /** Never report errors of these classes. */
2071
- dontReport(...classes: Array<abstract new (...args: never[]) => Error>): this;
2072
- }
2073
-
2074
- interface ConfigRepository$1 {
2075
- has(key: string): boolean;
2076
- /** Dot notation: get('database.connections.sqlite.database'). */
2077
- get<T = unknown>(key: string, defaultValue?: T): T;
2078
- set(key: string, value: unknown): void;
2079
- set(values: Record<string, unknown>): void;
2080
- push(key: string, value: unknown): void;
2081
- all(): Record<string, unknown>;
2082
- }
2083
- declare const ConfigRepository$1: Token$j<ConfigRepository$1>;
2084
- /** Anything a controller can return that knows how to become a Response. */
2085
- interface Responsable$1 {
2086
- toResponse(request: unknown): Response | Promise<Response>;
2087
- }
2088
-
2089
2093
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
2090
2094
  interface Session$4 {
2091
2095
  getId(): string;
@@ -2152,6 +2156,8 @@ interface HttpRequest$4 {
2152
2156
  header(name: string, defaultValue: string): string;
2153
2157
  bearerToken(): string | undefined;
2154
2158
  ip(): string | undefined;
2159
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
2160
+ content(): string;
2155
2161
  expectsJson(): boolean;
2156
2162
  ajax(): boolean;
2157
2163
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -2209,15 +2215,89 @@ interface HttpKernel {
2209
2215
  handle(request: Request): Promise<Response>;
2210
2216
  terminate?(request: Request, response: Response): Promise<void>;
2211
2217
  }
2212
- declare const HttpKernel: Token$j<HttpKernel>;
2213
- interface ResponseFactory$1 {
2214
- make(content?: BodyInit | null, status?: number, headers?: HeadersInit): Response;
2215
- json(data: unknown, status?: number, headers?: HeadersInit): Response;
2216
- noContent(status?: number): Response;
2217
- download(path: string, name?: string, headers?: HeadersInit): Promise<Response>;
2218
- stream(body: ReadableStream, status?: number, headers?: HeadersInit): Response;
2218
+ declare const HttpKernel: Token$j<HttpKernel>;
2219
+ interface ResponseFactory$1 {
2220
+ make(content?: BodyInit | null, status?: number, headers?: HeadersInit): Response;
2221
+ json(data: unknown, status?: number, headers?: HeadersInit): Response;
2222
+ noContent(status?: number): Response;
2223
+ download(path: string, name?: string, headers?: HeadersInit): Promise<Response>;
2224
+ stream(body: ReadableStream, status?: number, headers?: HeadersInit): Response;
2225
+ }
2226
+ declare const ResponseFactory$1: Token$j<ResponseFactory$1>;
2227
+
2228
+ interface ServiceProvider$n {
2229
+ /** Bind things into the container. Synchronous. Don't resolve other services here. */
2230
+ register?(): void;
2231
+ /** Runs after every provider is registered. May be async (e.g. importing route files). */
2232
+ boot?(): void | Promise<void>;
2233
+ }
2234
+ type ServiceProviderClass$6 = new (app: Application$6) => ServiceProvider$n;
2235
+ interface Application$6 extends Container$d {
2236
+ readonly version: string;
2237
+ basePath(path?: string): string;
2238
+ appPath(path?: string): string;
2239
+ bootstrapPath(path?: string): string;
2240
+ configPath(path?: string): string;
2241
+ databasePath(path?: string): string;
2242
+ publicPath(path?: string): string;
2243
+ resourcePath(path?: string): string;
2244
+ storagePath(path?: string): string;
2245
+ /** With no args returns the environment name. With args returns whether it matches any of them. */
2246
+ environment(): string;
2247
+ environment(...environments: string[]): boolean;
2248
+ isProduction(): boolean;
2249
+ isLocal(): boolean;
2250
+ runningInConsole(): boolean;
2251
+ /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
2252
+ setRunningInConsole(value?: boolean): void;
2253
+ runningUnitTests(): boolean;
2254
+ /** Registers the provider. If the app is already booted, the provider is booted immediately. */
2255
+ register(provider: ServiceProvider$n | ServiceProviderClass$6): Promise<ServiceProvider$n>;
2256
+ getProviders(): ServiceProvider$n[];
2257
+ boot(): Promise<void>;
2258
+ isBooted(): boolean;
2259
+ booting(callback: (app: Application$6) => void | Promise<void>): void;
2260
+ booted(callback: (app: Application$6) => void | Promise<void>): void;
2261
+ /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
2262
+ handle(request: Request): Promise<Response>;
2263
+ /** Register a callback that terminate() runs, in registration order. */
2264
+ terminating(callback: () => void | Promise<void>): void;
2265
+ terminate(): Promise<void>;
2266
+ }
2267
+ declare const Application$6: Token$j<Application$6>;
2268
+ interface ExceptionHandler {
2269
+ report(error: unknown): Promise<void>;
2270
+ shouldReport(error: unknown): boolean;
2271
+ /** `request` is the scoped HttpRequest (Contracts/Http) when available, else the raw Request. */
2272
+ render(request: unknown, error: unknown): Promise<Response>;
2273
+ }
2274
+ declare const ExceptionHandler: Token$j<ExceptionHandler>;
2275
+ /** The object passed to Application.configure().withExceptions(e => …), like Laravel's Exceptions class. */
2276
+ interface ExceptionsConfigurator {
2277
+ /** Custom reporting. Return false to stop the default logging. */
2278
+ report(callback: (error: unknown) => void | boolean | Promise<void | boolean>): this;
2279
+ /** Custom rendering. Return undefined to fall through to the default rendering. */
2280
+ render(callback: (error: unknown, request: unknown) => Response | undefined | Promise<Response | undefined>): this;
2281
+ /** Never report errors of these classes. */
2282
+ dontReport(...classes: Array<abstract new (...args: never[]) => Error>): this;
2283
+ /** Render errors as JSON when the callback returns true, whatever the Accept header. */
2284
+ shouldRenderJsonWhen(callback: (request: HttpRequest$4, error: unknown) => boolean): this;
2285
+ }
2286
+
2287
+ interface ConfigRepository$1 {
2288
+ has(key: string): boolean;
2289
+ /** Dot notation: get('database.connections.sqlite.database'). */
2290
+ get<T = unknown>(key: string, defaultValue?: T): T;
2291
+ set(key: string, value: unknown): void;
2292
+ set(values: Record<string, unknown>): void;
2293
+ push(key: string, value: unknown): void;
2294
+ all(): Record<string, unknown>;
2295
+ }
2296
+ declare const ConfigRepository$1: Token$j<ConfigRepository$1>;
2297
+ /** Anything a controller can return that knows how to become a Response. */
2298
+ interface Responsable$1 {
2299
+ toResponse(request: unknown): Response | Promise<Response>;
2219
2300
  }
2220
- declare const ResponseFactory$1: Token$j<ResponseFactory$1>;
2221
2301
 
2222
2302
  /** Public method names of a controller (excludes non-function members). */
2223
2303
  type ActionMethods<C> = {
@@ -2225,14 +2305,18 @@ type ActionMethods<C> = {
2225
2305
  }[keyof C] & string;
2226
2306
  type ControllerAction<C> = readonly [Class$d<C>, ActionMethods<C>];
2227
2307
  type RouteClosure = (...args: any[]) => unknown;
2228
- type RouteAction = RouteClosure | ControllerAction<any>;
2308
+ /** A class with __invoke(): Route.get('/counter', Counter) (single-action controllers, full-page Live components). */
2309
+ type InvokableClass = Class$d<{
2310
+ __invoke(...args: any[]): unknown;
2311
+ }>;
2312
+ type RouteAction = RouteClosure | ControllerAction<any> | InvokableClass;
2229
2313
  type MiddlewareReference = string | MiddlewareClass;
2230
2314
  interface Route {
2231
2315
  readonly methods: readonly string[];
2232
2316
  readonly uri: string;
2233
2317
  getName(): string | undefined;
2234
2318
  name(name: string): this;
2235
- middleware(...middleware: MiddlewareReference[]): this;
2319
+ middleware(...middleware: Array<MiddlewareReference | readonly MiddlewareReference[]>): this;
2236
2320
  withoutMiddleware(...middleware: MiddlewareReference[]): this;
2237
2321
  where(parameter: string, pattern: string): this;
2238
2322
  where(patterns: Record<string, string>): this;
@@ -2240,7 +2324,7 @@ interface Route {
2240
2324
  interface RouteRegistrar {
2241
2325
  prefix(prefix: string): RouteRegistrar;
2242
2326
  name(prefix: string): RouteRegistrar;
2243
- middleware(...middleware: MiddlewareReference[]): RouteRegistrar;
2327
+ middleware(...middleware: Array<MiddlewareReference | readonly MiddlewareReference[]>): RouteRegistrar;
2244
2328
  controller(controller: Class$d<unknown>): RouteRegistrar;
2245
2329
  group(routes: () => void | Promise<void>): Promise<void>;
2246
2330
  }
@@ -2251,14 +2335,14 @@ interface ResourceOptions {
2251
2335
  names?: Record<string, string>;
2252
2336
  }
2253
2337
  interface Router {
2254
- get<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2255
- post<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2256
- put<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2257
- patch<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2258
- delete<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2259
- options<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2260
- any<C>(uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2261
- match<C>(methods: string[], uri: string, action: ControllerAction<C> | RouteClosure | string): Route;
2338
+ get<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2339
+ post<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2340
+ put<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2341
+ patch<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2342
+ delete<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2343
+ options<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2344
+ any<C>(uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2345
+ match<C>(methods: string[], uri: string, action: ControllerAction<C> | RouteClosure | InvokableClass | string): Route;
2262
2346
  redirect(from: string, to: string, status?: number): Route;
2263
2347
  view(uri: string, view: string, data?: Record<string, unknown>): Route;
2264
2348
  /** Route.inertia('/about', 'About', props): a GET route that renders an Inertia page (Laravel's Route::inertia). */
@@ -2268,7 +2352,7 @@ interface Router {
2268
2352
  fallback(action: RouteAction): Route;
2269
2353
  prefix(prefix: string): RouteRegistrar;
2270
2354
  name(prefix: string): RouteRegistrar;
2271
- middleware(...middleware: MiddlewareReference[]): RouteRegistrar;
2355
+ middleware(...middleware: Array<MiddlewareReference | readonly MiddlewareReference[]>): RouteRegistrar;
2272
2356
  controller(controller: Class$d<unknown>): RouteRegistrar;
2273
2357
  /** Explicit model binding: Route.model('author', User). */
2274
2358
  model(parameter: string, model: Class$d<unknown>): void;
@@ -2304,6 +2388,12 @@ interface UrlGenerator {
2304
2388
  current(): string;
2305
2389
  previous(fallback?: string): string;
2306
2390
  hasRoute(name: string): boolean;
2391
+ /** A URL to a named route with a `signature` query (HMAC-SHA256 keyed by APP_KEY); `expiration` adds `expires`. */
2392
+ signedRoute(name: string, parameters?: unknown, expiration?: Date | number, absolute?: boolean): string;
2393
+ /** signedRoute() that expires: a Date, or seconds from now. */
2394
+ temporarySignedRoute(name: string, expiration: Date | number, parameters?: unknown, absolute?: boolean): string;
2395
+ /** Whether the request URL carries a valid, unexpired signature (`absolute: false` signs the path only). */
2396
+ hasValidSignature(request: HttpRequest$4, absolute?: boolean): boolean;
2307
2397
  }
2308
2398
  declare const UrlGenerator: Token$j<UrlGenerator>;
2309
2399
  interface RedirectResponse$1 extends Responsable$1 {
@@ -2404,6 +2494,13 @@ declare abstract class ServiceProvider$m implements ServiceProvider$u {
2404
2494
  protected mergeConfigFrom(defaults: Record<string, unknown>, key: string): void;
2405
2495
  }
2406
2496
 
2497
+ /**
2498
+ * Whether a JSON text nests objects and arrays deeper than `maxDepth`, found by scanning (no parsing, no recursion):
2499
+ * brackets inside strings don't count. The kernel answers 400 for such bodies (http.max_json_depth) before the
2500
+ * recursive input handling (sanitizing, TrimStrings, validation) could overflow the stack.
2501
+ */
2502
+ declare function exceedsJsonDepth(text: string, maxDepth: number): boolean;
2503
+
2407
2504
  /** The current container, only when it is a request scope (the kernel binds HttpRequest there). */
2408
2505
  declare function requestScope(): Container$d | undefined;
2409
2506
  declare function currentRequest(): HttpRequest$4 | undefined;
@@ -2445,7 +2542,10 @@ declare class HttpRedirector implements Redirector {
2445
2542
  /** Pulls url.intended from the session (put there by guest()), else goes to `fallback`. */
2446
2543
  intended(fallback?: string, status?: number): HttpRedirectResponse;
2447
2544
  away(url: string, status?: number): HttpRedirectResponse;
2448
- /** Remembers where a guest was going (a GET page, else the previous URL), then redirects to `path`. */
2545
+ /**
2546
+ * Remembers where a guest was going (a GET page, else the previous URL), then redirects to `path`. Only the path
2547
+ * is stored, so intended() goes back on whichever host serves the app, and never to another site's Referer.
2548
+ */
2449
2549
  guest(path: string, status?: number): HttpRedirectResponse;
2450
2550
  setIntendedUrl(url: string): void;
2451
2551
  refresh(status?: number): HttpRedirectResponse;
@@ -2480,6 +2580,8 @@ interface IncomingRequestOptions {
2480
2580
  trustedProxies?: readonly string[];
2481
2581
  /** Largest request body in bytes before a 413 (config http.max_body_size); null is unlimited. Default 8 MB. */
2482
2582
  maxBodySize?: number | null;
2583
+ /** Deepest nesting of objects and arrays in a JSON body before a 400 (config http.max_json_depth); null is unlimited. Default 512. */
2584
+ maxJsonDepth?: number | null;
2483
2585
  }
2484
2586
  /** Exact match, IPv4 CIDR ('10.0.0.0/8') or '*'. */
2485
2587
  declare function ipMatches(ip: string, patterns: readonly string[]): boolean;
@@ -2712,6 +2814,7 @@ declare function applyMiddlewareCallbacks(app: Application$6, kernel: Kernel$1):
2712
2814
  type ReportCallback = (error: unknown) => void | boolean | Promise<void | boolean>;
2713
2815
  type RenderCallback = (error: unknown, request: unknown) => Response | undefined | Promise<Response | undefined>;
2714
2816
  type ErrorClass = abstract new (...args: never[]) => Error;
2817
+ type JsonWhenCallback = (request: HttpRequest$4, error: unknown) => boolean;
2715
2818
  /** HTTP status for an error (spec §7). */
2716
2819
  declare function statusFor(error: unknown): number;
2717
2820
  /** "The title field is required. (and 2 more errors)" (Laravel's ValidationException::summarize). */
@@ -2726,6 +2829,10 @@ declare class ErrorHandler implements ExceptionHandler {
2726
2829
  reportUsing(callback: ReportCallback): void;
2727
2830
  renderUsing(callback: RenderCallback): void;
2728
2831
  ignore(...classes: ErrorClass[]): void;
2832
+ /** Laravel's shouldRenderJsonWhen(): the callback decides JSON or HTML instead of the Accept header. */
2833
+ shouldRenderJsonWhen(callback: JsonWhenCallback): void;
2834
+ /** Laravel's shouldReturnJson(): the shouldRenderJsonWhen() callback when set, else request.expectsJson(). */
2835
+ protected shouldReturnJson(request: HttpRequest$4, error: unknown): boolean;
2729
2836
  shouldReport(error: unknown): boolean;
2730
2837
  /** Report callbacks first (returning false stops the default log), then LogManager.error(), else console.error. Once per error. */
2731
2838
  report(error: unknown): Promise<void>;
@@ -2739,6 +2846,8 @@ declare class ExceptionsConfiguration implements ExceptionsConfigurator {
2739
2846
  report(callback: ReportCallback): this;
2740
2847
  render(callback: RenderCallback): this;
2741
2848
  dontReport(...classes: ErrorClass[]): this;
2849
+ /** shouldRenderJsonWhen((request) => request.is('api/*')): JSON errors for those requests, whatever they accept. */
2850
+ shouldRenderJsonWhen(callback: (request: HttpRequest$4, error: unknown) => boolean): this;
2742
2851
  }
2743
2852
  /** Runs the withExceptions() callbacks against a handler (the provider does this when the handler is built). */
2744
2853
  declare function applyExceptionCallbacks(app: Application$6, handler: ErrorHandler): void;
@@ -5349,6 +5458,15 @@ interface StateContext {
5349
5458
  }
5350
5459
  type State = Row$4 | ((attributes: Row$4, context: StateContext) => Row$4);
5351
5460
  type AnyFactory = Factory$b<any>;
5461
+ /**
5462
+ * A model's factory() typed as its own factory class (Laravel's `@use HasFactory<UserFactory>`): declare it in the
5463
+ * model, `declare static factory: HasFactory<UserFactory>` (with `import type`), and User.factory().unverified()
5464
+ * type-checks. The factory is still found at run time by name (database/factories/UserFactory.ts).
5465
+ */
5466
+ type HasFactory<F> = {
5467
+ (): F;
5468
+ (count: number, state?: State): F & Many;
5469
+ } & (typeof Model)['factory'];
5352
5470
  interface HasRelationship {
5353
5471
  factory: AnyFactory;
5354
5472
  relationship: string;
@@ -6505,6 +6623,16 @@ declare class ValidationErrorImpl extends Error implements ValidationError {
6505
6623
  readonly name = "ValidationError";
6506
6624
  constructor(errors: Record<string, string[]>, errorBag?: string, redirectTo?: string | undefined);
6507
6625
  }
6626
+ /**
6627
+ * Laravel's ValidationException, for failing a request by hand:
6628
+ * `throw ValidationException.withMessages({ email: __('auth.failed') })`. Rendered like any validation error: 422 JSON,
6629
+ * or a redirect back with the errors.
6630
+ */
6631
+ declare class ValidationException extends ValidationErrorImpl {
6632
+ /** Messages per field, each a string or a list. */
6633
+ static withMessages(messages: Record<string, string | readonly string[]>): ValidationException;
6634
+ constructor(errors: Record<string, string[]>, errorBag?: string, redirectTo?: string);
6635
+ }
6508
6636
  declare class AuthorizationErrorImpl extends Error implements OrielError$c {
6509
6637
  readonly kind: "Authorization";
6510
6638
  readonly status = 403;
@@ -6583,6 +6711,8 @@ interface BuiltinRule {
6583
6711
  replacements?(ctx: RuleContext): Record<string, string>;
6584
6712
  /** Used when messageKey() isn't in DEFAULT_MESSAGES (e.g. an extend()ed rule with a custom message). */
6585
6713
  defaultMessage?: string;
6714
+ /** An extend()ed rule's own message: it wins over the default lines, as Laravel's fallback messages do. */
6715
+ message?: string;
6586
6716
  /** Runs even when the value is missing, blank, or null under nullable (the required* family, and accepted); a failure stops the field. */
6587
6717
  implicit?: boolean;
6588
6718
  }
@@ -6617,6 +6747,36 @@ declare function expandWildcardKeys(pattern: string, data: Record<string, unknow
6617
6747
  /** Every built-in rule, merged. Later tasks (database rules) add their own spread here. */
6618
6748
  declare const builtinRules: Record<string, BuiltinRule>;
6619
6749
 
6750
+ /**
6751
+ * Laravel's Illuminate\Validation\Rules\Password: a string of at least `min` characters (8 by default), plus the
6752
+ * checks you add: letters(), mixedCase(), numbers(), symbols(), max(). Every failing check adds its own message.
6753
+ * Rule.password() returns the application default (PasswordRule.defaults()). (Laravel's uncompromised() is not
6754
+ * ported: it calls an outside service.)
6755
+ */
6756
+ declare class PasswordRule implements ValidationRule$4 {
6757
+ #private;
6758
+ constructor(min?: number);
6759
+ /** A password rule of at least `size` characters: PasswordRule.min(12).mixedCase(). */
6760
+ static min(size: number): PasswordRule;
6761
+ /**
6762
+ * With an argument, sets the default (Laravel's Password::defaults(fn () => ...), in a provider's boot());
6763
+ * `null` resets it. Without one, returns a copy of the default: PasswordRule.min(8) unless set.
6764
+ */
6765
+ static defaults(): PasswordRule;
6766
+ static defaults(rule: PasswordRule | (() => PasswordRule) | null): void;
6767
+ min(size: number): this;
6768
+ max(size: number): this;
6769
+ /** At least one letter. */
6770
+ letters(): this;
6771
+ /** At least one uppercase and one lowercase letter. */
6772
+ mixedCase(): this;
6773
+ /** At least one number. */
6774
+ numbers(): this;
6775
+ /** At least one symbol (punctuation, a symbol or a space). */
6776
+ symbols(): this;
6777
+ validate(attribute: string, value: unknown, fail: (message: string) => void): void;
6778
+ }
6779
+
6620
6780
  /**
6621
6781
  * Base for the fluent builders. Each one reports under a built-in rule name (`in`, `unique`, `exists`), so when it
6622
6782
  * runs inside a Validator its failure goes through exactly the same lookup as the string rule: custom messages
@@ -6663,6 +6823,8 @@ declare const Rule: {
6663
6823
  in: (values: readonly unknown[]) => InRule;
6664
6824
  unique: (table: string, column?: string) => UniqueRule;
6665
6825
  exists: (table: string, column?: string) => ExistsRule;
6826
+ /** Laravel's Password::defaults(): the application's password rule (at least 8 characters unless PasswordRule.defaults() changed it). */
6827
+ password: () => PasswordRule;
6666
6828
  };
6667
6829
 
6668
6830
  /** See Task 9's writeup in the plan for exactly what this does and doesn't infer. */
@@ -7158,6 +7320,8 @@ interface HttpRequest$3 {
7158
7320
  header(name: string, defaultValue: string): string;
7159
7321
  bearerToken(): string | undefined;
7160
7322
  ip(): string | undefined;
7323
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
7324
+ content(): string;
7161
7325
  expectsJson(): boolean;
7162
7326
  ajax(): boolean;
7163
7327
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -7361,16 +7525,6 @@ interface Container$9 {
7361
7525
  }
7362
7526
  declare const Container$9: Token$9<Container$9>;
7363
7527
 
7364
- interface Arrayable$3<T = unknown> {
7365
- toArray(): T;
7366
- }
7367
- /** The minimal collection surface contracts rely on (implemented by @orieljs/collections). */
7368
- interface Enumerable$3<T> extends Iterable<T>, Arrayable$3<unknown[]> {
7369
- all(): T[];
7370
- count(): number;
7371
- isEmpty(): boolean;
7372
- }
7373
-
7374
7528
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
7375
7529
  interface Session$2 {
7376
7530
  getId(): string;
@@ -7449,6 +7603,8 @@ interface HttpRequest$2 {
7449
7603
  header(name: string, defaultValue: string): string;
7450
7604
  bearerToken(): string | undefined;
7451
7605
  ip(): string | undefined;
7606
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
7607
+ content(): string;
7452
7608
  expectsJson(): boolean;
7453
7609
  ajax(): boolean;
7454
7610
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -7481,6 +7637,16 @@ interface Middleware$2 {
7481
7637
  terminate?(request: HttpRequest$2, response: Response): Promise<void>;
7482
7638
  }
7483
7639
 
7640
+ interface Arrayable$3<T = unknown> {
7641
+ toArray(): T;
7642
+ }
7643
+ /** The minimal collection surface contracts rely on (implemented by @orieljs/collections). */
7644
+ interface Enumerable$3<T> extends Iterable<T>, Arrayable$3<unknown[]> {
7645
+ all(): T[];
7646
+ count(): number;
7647
+ isEmpty(): boolean;
7648
+ }
7649
+
7484
7650
  interface Cookie {
7485
7651
  name: string;
7486
7652
  value: string;
@@ -7905,27 +8071,6 @@ interface Container$8 {
7905
8071
  }
7906
8072
  declare const Container$8: Token$8<Container$8>;
7907
8073
 
7908
- interface ConfigRepository {
7909
- has(key: string): boolean;
7910
- /** Dot notation: get('database.connections.sqlite.database'). */
7911
- get<T = unknown>(key: string, defaultValue?: T): T;
7912
- set(key: string, value: unknown): void;
7913
- set(values: Record<string, unknown>): void;
7914
- push(key: string, value: unknown): void;
7915
- all(): Record<string, unknown>;
7916
- }
7917
- declare const ConfigRepository: Token$j<ConfigRepository>;
7918
-
7919
- interface Arrayable$2<T = unknown> {
7920
- toArray(): T;
7921
- }
7922
- /** The minimal collection surface contracts rely on (implemented by @orieljs/collections). */
7923
- interface Enumerable$2<T> extends Iterable<T>, Arrayable$2<unknown[]> {
7924
- all(): T[];
7925
- count(): number;
7926
- isEmpty(): boolean;
7927
- }
7928
-
7929
8074
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
7930
8075
  interface Session$1 {
7931
8076
  getId(): string;
@@ -7988,6 +8133,8 @@ interface HttpRequest$1 {
7988
8133
  header(name: string, defaultValue: string): string;
7989
8134
  bearerToken(): string | undefined;
7990
8135
  ip(): string | undefined;
8136
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
8137
+ content(): string;
7991
8138
  expectsJson(): boolean;
7992
8139
  ajax(): boolean;
7993
8140
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -8020,6 +8167,27 @@ interface Middleware$1 {
8020
8167
  terminate?(request: HttpRequest$1, response: Response): Promise<void>;
8021
8168
  }
8022
8169
 
8170
+ interface ConfigRepository {
8171
+ has(key: string): boolean;
8172
+ /** Dot notation: get('database.connections.sqlite.database'). */
8173
+ get<T = unknown>(key: string, defaultValue?: T): T;
8174
+ set(key: string, value: unknown): void;
8175
+ set(values: Record<string, unknown>): void;
8176
+ push(key: string, value: unknown): void;
8177
+ all(): Record<string, unknown>;
8178
+ }
8179
+ declare const ConfigRepository: Token$j<ConfigRepository>;
8180
+
8181
+ interface Arrayable$2<T = unknown> {
8182
+ toArray(): T;
8183
+ }
8184
+ /** The minimal collection surface contracts rely on (implemented by @orieljs/collections). */
8185
+ interface Enumerable$2<T> extends Iterable<T>, Arrayable$2<unknown[]> {
8186
+ all(): T[];
8187
+ count(): number;
8188
+ isEmpty(): boolean;
8189
+ }
8190
+
8023
8191
  interface Hasher {
8024
8192
  make(value: string): Promise<string>;
8025
8193
  check(value: string, hashed: string): Promise<boolean>;
@@ -8278,6 +8446,21 @@ declare class PasswordReset {
8278
8446
  readonly user: Authenticatable;
8279
8447
  constructor(user: Authenticatable);
8280
8448
  }
8449
+ /** Fired by the registration action after a user signs up; the default listener sends the verification mail. */
8450
+ declare class Registered {
8451
+ readonly user: Authenticatable;
8452
+ constructor(user: Authenticatable);
8453
+ }
8454
+ /** Fired when a user verifies their email address. */
8455
+ declare class Verified {
8456
+ readonly user: Authenticatable & MustVerifyEmail;
8457
+ constructor(user: Authenticatable & MustVerifyEmail);
8458
+ }
8459
+ /** Fired when a login is refused for too many attempts (the starter kits' LoginRequest). */
8460
+ declare class Lockout {
8461
+ readonly request: HttpRequest$1;
8462
+ constructor(request: HttpRequest$1);
8463
+ }
8281
8464
 
8282
8465
  /** What the default toMail() returns: Laravel's reset mail, as plain data (see the plan's notes). */
8283
8466
  interface ResetPasswordMail {
@@ -8304,6 +8487,54 @@ declare class ResetPassword implements Notification {
8304
8487
  resetUrl(notifiable: CanResetPassword): string;
8305
8488
  }
8306
8489
 
8490
+ /** What the default toMail() returns: Laravel's verification mail, as plain data (the mail channel renders it). */
8491
+ interface VerifyEmailMail {
8492
+ subject: string;
8493
+ lines: string[];
8494
+ actionText: string;
8495
+ actionUrl: string;
8496
+ outroLines: string[];
8497
+ }
8498
+ /** The user the notification is for (AuthenticatableModel provides this). */
8499
+ type VerifiableUser = MustVerifyEmail & {
8500
+ getKey?(): unknown;
8501
+ getAuthIdentifier?(): unknown;
8502
+ };
8503
+ /**
8504
+ * Laravel's VerifyEmail notification: a link to the `verification.verify` route signed for
8505
+ * config('auth.verification.expire', 60) minutes, with the user's key as {id} and the sha1 of their email as {hash}.
8506
+ */
8507
+ declare class VerifyEmail implements Notification {
8508
+ /** Build the verification URL yourself (e.g. for a SPA front end). */
8509
+ static createUrlUsing(callback: ((notifiable: VerifiableUser) => string) | undefined): void;
8510
+ /** Build the mail yourself (e.g. a MailMessage from the Notifications component). */
8511
+ static toMailUsing(callback: ((notifiable: VerifiableUser, url: string) => unknown) | undefined): void;
8512
+ via(): string[];
8513
+ toMail(notifiable: object): unknown;
8514
+ verificationUrl(notifiable: VerifiableUser): string;
8515
+ }
8516
+
8517
+ /**
8518
+ * Laravel's SendEmailVerificationNotification, listening for Registered (AuthServiceProvider registers it): a new
8519
+ * user who must verify their email, and hasn't, gets the VerifyEmail mail.
8520
+ */
8521
+ declare class SendEmailVerificationNotification {
8522
+ handle(event: Registered): Promise<void>;
8523
+ }
8524
+
8525
+ /**
8526
+ * Laravel's EmailVerificationRequest, for the verification link's route (`auth` and `signed` middleware): the
8527
+ * signed-in user's key must equal the {id} parameter and the sha1 of their email the {hash} parameter, else 403.
8528
+ * `await EmailVerificationRequest.validate()` in the action, like a FormRequest.
8529
+ */
8530
+ declare class EmailVerificationRequest {
8531
+ static validate(): Promise<Record<string, never>>;
8532
+ authorize(): boolean;
8533
+ rules(): Record<string, never>;
8534
+ /** Marks the signed-in user's email as verified and fires Verified, unless it already was. */
8535
+ fulfill(): Promise<void>;
8536
+ }
8537
+
8307
8538
  /** The part of a model (Contracts/Database ModelInstance) the mixin needs. */
8308
8539
  interface AuthModelBase {
8309
8540
  getKey(): unknown;
@@ -8313,7 +8544,7 @@ interface AuthModelBase {
8313
8544
  save(): Promise<boolean>;
8314
8545
  }
8315
8546
  type AuthModelConstructor = new (...args: any[]) => AuthModelBase;
8316
- /** Configure how the email verification notification is sent (signed URLs are not in v1's UrlGenerator). */
8547
+ /** Send the email verification yourself instead of the VerifyEmail notification (undefined restores the default). */
8317
8548
  declare function sendEmailVerificationUsing(callback: ((user: MustVerifyEmail) => Promise<void>) | undefined): void;
8318
8549
  /** Sends a notification through user.notify() (the Notifications mixin), else the NotificationDispatcher token. */
8319
8550
  declare function sendNotification(user: unknown, notification: Notification): Promise<void>;
@@ -8336,6 +8567,7 @@ declare function AuthenticatableModel<TBase extends AuthModelConstructor>(Base:
8336
8567
  hasVerifiedEmail(): boolean;
8337
8568
  markEmailAsVerified(): Promise<boolean>;
8338
8569
  getEmailForVerification(): string;
8570
+ /** Sends the VerifyEmail notification (a signed link), or what sendEmailVerificationUsing() configured. */
8339
8571
  sendEmailVerificationNotification(): Promise<void>;
8340
8572
  getKey(): unknown;
8341
8573
  getKeyName(): string;
@@ -9396,6 +9628,18 @@ interface CacheManager$2 extends CacheRepository$1 {
9396
9628
  extend(driver: string, factory: (config: Record<string, unknown>) => CacheRepository$1): void;
9397
9629
  }
9398
9630
  declare const CacheManager$2: Token$j<CacheManager$2>;
9631
+ /** Laravel's RateLimiter: hits per key, kept in the default cache store. */
9632
+ interface RateLimiter$1 {
9633
+ tooManyAttempts(key: string, maxAttempts: number): Promise<boolean>;
9634
+ /** Adds a hit; the window starts at the first hit and lasts `decaySeconds` (default 60). Returns the hit count. */
9635
+ hit(key: string, decaySeconds?: number): Promise<number>;
9636
+ attempts(key: string): Promise<number>;
9637
+ remaining(key: string, maxAttempts: number): Promise<number>;
9638
+ /** Seconds until the key's window resets. */
9639
+ availableIn(key: string): Promise<number>;
9640
+ clear(key: string): Promise<void>;
9641
+ }
9642
+ declare const RateLimiter$1: Token$j<RateLimiter$1>;
9399
9643
 
9400
9644
  declare abstract class ServiceProvider$8 implements ServiceProvider$u {
9401
9645
  protected readonly app: Application$c;
@@ -9762,7 +10006,28 @@ declare class CacheManager$1 implements CacheManager$2 {
9762
10006
  tags(names: string | string[]): CacheRepository$1;
9763
10007
  }
9764
10008
 
10009
+ /**
10010
+ * Laravel's Illuminate\Cache\RateLimiter over a cache store: `<key>` holds the hit count and `<key>:timer` the unix
10011
+ * time the window ends, both expiring with the window. The store is resolved on every call, so a store swapped in
10012
+ * a test (or config changed at run time) is the one used.
10013
+ */
10014
+ declare class CacheRateLimiter implements RateLimiter$1 {
10015
+ #private;
10016
+ private readonly store;
10017
+ constructor(store: () => CacheRepository$1);
10018
+ tooManyAttempts(key: string, maxAttempts: number): Promise<boolean>;
10019
+ hit(key: string, decaySeconds?: number): Promise<number>;
10020
+ attempts(key: string): Promise<number>;
10021
+ remaining(key: string, maxAttempts: number): Promise<number>;
10022
+ availableIn(key: string): Promise<number>;
10023
+ clear(key: string): Promise<void>;
10024
+ /** Laravel's cleanRateLimiterKey(): accented letters become their plain letter ('zoë' and 'zoe' share a key). */
10025
+ protected cleanKey(key: string): string;
10026
+ }
10027
+
9765
10028
  declare const Cache: Facade<CacheManager$2, object>;
10029
+ /** The RateLimiter facade: RateLimiter.tooManyAttempts(key, 5), RateLimiter.hit(key), RateLimiter.clear(key). */
10030
+ declare const RateLimiter: Facade<RateLimiter$1, object>;
9766
10031
  declare function cache(): CacheManager$2;
9767
10032
  declare function cache(key: string): Promise<unknown>;
9768
10033
  declare function cache(values: Record<string, unknown>, ttlSeconds?: number): Promise<boolean>;
@@ -9806,6 +10071,16 @@ interface Container$4 {
9806
10071
  run<R>(fn: () => R): R;
9807
10072
  }
9808
10073
  declare const Container$4: Token$4<Container$4>;
10074
+ interface UploadedFile$1 {
10075
+ readonly clientName: string;
10076
+ readonly mimeType: string;
10077
+ readonly size: number;
10078
+ extension(): string;
10079
+ arrayBuffer(): Promise<ArrayBuffer>;
10080
+ /** Stores on a Filesystem disk. Returns the stored path. */
10081
+ store(directory: string, disk?: string): Promise<string>;
10082
+ storeAs(directory: string, name: string, disk?: string): Promise<string>;
10083
+ }
9809
10084
 
9810
10085
  interface ServiceProvider$7 {
9811
10086
  /** Bind things into the container. Synchronous. Don't resolve other services here. */
@@ -9847,16 +10122,6 @@ interface Application$2 extends Container$4 {
9847
10122
  terminate(): Promise<void>;
9848
10123
  }
9849
10124
  declare const Application$2: Token$j<Application$2>;
9850
- interface UploadedFile$1 {
9851
- readonly clientName: string;
9852
- readonly mimeType: string;
9853
- readonly size: number;
9854
- extension(): string;
9855
- arrayBuffer(): Promise<ArrayBuffer>;
9856
- /** Stores on a Filesystem disk. Returns the stored path. */
9857
- store(directory: string, disk?: string): Promise<string>;
9858
- storeAs(directory: string, name: string, disk?: string): Promise<string>;
9859
- }
9860
10125
 
9861
10126
  type ErrorKind$4 = 'Http' | 'Server' | 'ModelNotFound' | 'Validation' | 'Authentication' | 'Authorization' | 'TokenMismatch' | 'BindingResolution' | 'CircularDependency' | 'ContainerNotAvailable';
9862
10127
  /** Every error thrown by the framework implements this. The exception handler switches on `kind`. */
@@ -11906,54 +12171,6 @@ interface Container {
11906
12171
  }
11907
12172
  declare const Container: Token<Container>;
11908
12173
 
11909
- interface ServiceProvider$1 {
11910
- /** Bind things into the container. Synchronous. Don't resolve other services here. */
11911
- register?(): void;
11912
- /** Runs after every provider is registered. May be async (e.g. importing route files). */
11913
- boot?(): void | Promise<void>;
11914
- }
11915
- type ServiceProviderClass = new (app: Application) => ServiceProvider$1;
11916
- interface Application extends Container {
11917
- readonly version: string;
11918
- basePath(path?: string): string;
11919
- appPath(path?: string): string;
11920
- bootstrapPath(path?: string): string;
11921
- configPath(path?: string): string;
11922
- databasePath(path?: string): string;
11923
- publicPath(path?: string): string;
11924
- resourcePath(path?: string): string;
11925
- storagePath(path?: string): string;
11926
- /** With no args returns the environment name. With args returns whether it matches any of them. */
11927
- environment(): string;
11928
- environment(...environments: string[]): boolean;
11929
- isProduction(): boolean;
11930
- isLocal(): boolean;
11931
- runningInConsole(): boolean;
11932
- /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
11933
- setRunningInConsole(value?: boolean): void;
11934
- runningUnitTests(): boolean;
11935
- /** Registers the provider. If the app is already booted, the provider is booted immediately. */
11936
- register(provider: ServiceProvider$1 | ServiceProviderClass): Promise<ServiceProvider$1>;
11937
- getProviders(): ServiceProvider$1[];
11938
- boot(): Promise<void>;
11939
- isBooted(): boolean;
11940
- booting(callback: (app: Application) => void | Promise<void>): void;
11941
- booted(callback: (app: Application) => void | Promise<void>): void;
11942
- /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
11943
- handle(request: Request): Promise<Response>;
11944
- /** Register a callback that terminate() runs, in registration order. */
11945
- terminating(callback: () => void | Promise<void>): void;
11946
- terminate(): Promise<void>;
11947
- }
11948
- declare const Application: Token$j<Application>;
11949
- interface Htmlable {
11950
- toHtml(): string;
11951
- }
11952
- /** Anything a controller can return that knows how to become a Response. */
11953
- interface Responsable {
11954
- toResponse(request: unknown): Response | Promise<Response>;
11955
- }
11956
-
11957
12174
  /** The session of the current request (scoped). Loaded and saved by the StartSession middleware. */
11958
12175
  interface Session {
11959
12176
  getId(): string;
@@ -12016,6 +12233,8 @@ interface HttpRequest {
12016
12233
  header(name: string, defaultValue: string): string;
12017
12234
  bearerToken(): string | undefined;
12018
12235
  ip(): string | undefined;
12236
+ /** The raw body as text (Laravel's getContent()); '' when there is none. */
12237
+ content(): string;
12019
12238
  expectsJson(): boolean;
12020
12239
  ajax(): boolean;
12021
12240
  query<T = unknown>(key?: string, defaultValue?: T): T;
@@ -12047,6 +12266,54 @@ interface Middleware {
12047
12266
  handle(request: HttpRequest, next: Next, ...parameters: string[]): Promise<Response>;
12048
12267
  terminate?(request: HttpRequest, response: Response): Promise<void>;
12049
12268
  }
12269
+
12270
+ interface ServiceProvider$1 {
12271
+ /** Bind things into the container. Synchronous. Don't resolve other services here. */
12272
+ register?(): void;
12273
+ /** Runs after every provider is registered. May be async (e.g. importing route files). */
12274
+ boot?(): void | Promise<void>;
12275
+ }
12276
+ type ServiceProviderClass = new (app: Application) => ServiceProvider$1;
12277
+ interface Application extends Container {
12278
+ readonly version: string;
12279
+ basePath(path?: string): string;
12280
+ appPath(path?: string): string;
12281
+ bootstrapPath(path?: string): string;
12282
+ configPath(path?: string): string;
12283
+ databasePath(path?: string): string;
12284
+ publicPath(path?: string): string;
12285
+ resourcePath(path?: string): string;
12286
+ storagePath(path?: string): string;
12287
+ /** With no args returns the environment name. With args returns whether it matches any of them. */
12288
+ environment(): string;
12289
+ environment(...environments: string[]): boolean;
12290
+ isProduction(): boolean;
12291
+ isLocal(): boolean;
12292
+ runningInConsole(): boolean;
12293
+ /** Mark the app as running in the console (the CLI entry point calls this). Defaults to true. */
12294
+ setRunningInConsole(value?: boolean): void;
12295
+ runningUnitTests(): boolean;
12296
+ /** Registers the provider. If the app is already booted, the provider is booted immediately. */
12297
+ register(provider: ServiceProvider$1 | ServiceProviderClass): Promise<ServiceProvider$1>;
12298
+ getProviders(): ServiceProvider$1[];
12299
+ boot(): Promise<void>;
12300
+ isBooted(): boolean;
12301
+ booting(callback: (app: Application) => void | Promise<void>): void;
12302
+ booted(callback: (app: Application) => void | Promise<void>): void;
12303
+ /** Handle one HTTP request in a fresh request scope via the bound HttpKernel. */
12304
+ handle(request: Request): Promise<Response>;
12305
+ /** Register a callback that terminate() runs, in registration order. */
12306
+ terminating(callback: () => void | Promise<void>): void;
12307
+ terminate(): Promise<void>;
12308
+ }
12309
+ declare const Application: Token$j<Application>;
12310
+ interface Htmlable {
12311
+ toHtml(): string;
12312
+ }
12313
+ /** Anything a controller can return that knows how to become a Response. */
12314
+ interface Responsable {
12315
+ toResponse(request: unknown): Response | Promise<Response>;
12316
+ }
12050
12317
  interface RedirectResponse extends Responsable {
12051
12318
  readonly targetUrl: string;
12052
12319
  with(key: string | Record<string, unknown>, value?: unknown): this;
@@ -12654,4 +12921,4 @@ type SharedPropsFrom<M> = M extends {
12654
12921
  share(...args: never[]): infer R;
12655
12922
  } ? SerializedObject<Awaited<R>> : Record<never, never>;
12656
12923
 
12657
- export { API_ROUTES_STUB, AboutCommand, AbstractPaginator, AccessGate, AddQueuedCookiesToResponse, type AfterCallback, AllMailersFailedError, AlwaysProp, AnonymousNotifiable, Application$9 as Application, ApplicationBuilder, ArgonHasher, type ArgonOptions, type ArgumentDefinition, Arr, ArraySessionHandler, ArrayTransport, Artisan, Attempting, type Attributes$1 as Attributes, type AttributesResolver, Auth, AuthManager, type AuthModel, type AuthModelBase, type AuthModelConstructor, AuthServiceProvider, AuthenticatableModel, Authenticate, AuthenticationError, AuthorizationError, AuthorizationErrorImpl, Authorize, BaseJob, BaseLogger, BasePipeline, BaseRouter, BaseUrlGenerator, Batch$1 as Batch, type BatchAttributes, BatchingUnavailableError, BcryptHasher, type BcryptOptions, type BeforeCallback, BelongsTo, BelongsToMany, BindingResolutionError, Blueprint, type BlueprintCommand, BufferedConsoleOutput, Builder, type BuiltInCast, type BuiltinRule, BuiltinRuleObject, type BunDatabase, BunSqliteDatabase, type BunStatement, Bus, Dispatcher as BusDispatcherImpl, BusError, BusServiceProvider, CACHE_TABLE_MIGRATION, CHAIN, Cache, CacheManager$1 as CacheManager, Repository as CacheRepositoryImpl, CacheServiceProvider, type Store as CacheStore, CallQueuedHandler, CallQueuedListener, type CanResetPassword, type CanResetPasswordUser, type CastDefinition, type CastsAttributes, type ChainSpec, type CipherName, CircularDependencyError, ClassRegistry$2 as ClassRegistry, ClosureCommand$4 as ClosureCommand, ClosureKernel, Collection$2 as Collection, type Column, type ColumnAttributes, ColumnDefinition, type ColumnInfo, type ColumnRef, type ColumnType, Command$4 as Command, CommandNotFoundError, ComponentNotFoundError, Connection, type ConsoleInput, type ConsoleIo, Kernel as ConsoleKernelImpl, type ConsoleOutput, ConsoleServiceProvider, Container$j as Container, ContainerNotAvailableError, ControllerMethodNotFoundError, ConvertEmptyStringsToNull, Cookie$1 as Cookie, type CookieDefaults, CookieJar$1 as CookieJar, CookieServiceProvider, CookieSessionHandler, CookieValuePrefix, type CreateMigrationOptions, Crypt, Cursor, type CursorPage, CursorPaginator, type CursorPaginatorOptions, DB, DEFAULT_MESSAGES, DailyRotatingStream, DatabaseBatchRepository, type DatabaseCommandContext, type DatabaseConfig, DatabaseConfigError, DatabaseError, DatabaseFailedJobProvider, DatabaseJob, type DatabaseJobRecord, DatabaseLock, DatabaseManagerImpl, DatabaseNotificationChannel, type DatabaseNotificationRecord, DatabaseQueue, type DatabaseQueueOptions, DatabaseServiceProvider, DatabaseSessionHandler, DatabaseStore, DatabaseTokenRepository, DatabaseUnavailableError, DecryptError, DeferProp, type Direction, Dispatchable, type EagerLoadSpec, EloquentUserProvider, type Encoded, EncryptCookies, EncryptError, EncryptHistory, Encrypter$2 as Encrypter, EncryptionServiceProvider, EnsureEmailIsVerified, type EnumLike, type ErrorClass, ErrorHandler, Event, Dispatcher$1 as EventDispatcherImpl, type EventKey, type EventListenMap, EventServiceProvider, EventsNeedBusDispatcherError, EventsNeedClassRegistryError, ExceptionsConfiguration, Expression, type Facade$c as Facade, type FacadeStatics$c as FacadeStatics, Factory$b as Factory, type FactoryResult, Failed, FailoverTransport, Faker, FakerOverflowError, FileNotFoundError, FileSessionHandler, FileStore, FilesystemManager, FilesystemServiceProvider, ForeignIdColumnDefinition, ForeignKeyDefinition, FormRequest, FormUploadedFile, Gate, type GateAbility, GateResponse, GeneratorCommand, GenericLock, type GlobalScope, Grammar, type GroupAttributes, type GroupHost, GroupRegistrar, type GuardFactory, HasApiTokens, HasMany, HasManyThrough, HasOne, HasOneOrMany, Hash, HashAlgorithmError, type HashInfo, HashManager, type HasherFactory, type HashingConfig, HashingServiceProvider, type Having, HelpCommand, type HttpCommandOptions, HttpException, Kernel$1 as HttpKernelImpl, HttpRedirectResponse, HttpRedirector, HttpResponseException, HttpResponseFactory, HttpServerError, HttpServiceProvider, Hub, IncomingRequest, type IncomingRequestOptions, type IndexType, Inertia, InertiaError, InertiaHtml, InertiaMiddleware, Response$1 as InertiaPageResponse, ResponseFactory as InertiaResponseFactory, InertiaServiceProvider, type ValidationErrors as InertiaValidationErrors, type InferRuleType, type InferValidatedType, InvalidCacheConfigError, InvalidCastError, InvalidListenerError, InvalidLogLevelError, InvalidRuleParameterError, InvalidSignatureError, JOBS_TABLE_MIGRATION, JobClassNotFoundError, type JobContext, type JobMiddleware, JobSerializationError, JoinClause, type JoinType, KEY_GENERATE_SIGNATURE, type KernelApp, type KeyGenerateIO, LEVEL_SEVERITY, LazyCollection$1 as LazyCollection, type LengthAwarePage, LengthAwarePaginator, ListCommand, type ListenerTuple, type LocalDiskConfig, LocalFilesystem, type LockFactory, LockTimeoutError, Log, LogChannelCycleError, LogManager, LogServiceProvider, LogTransport, type LoggedQuery, LogicError, Login, Logout, MIGRATION_CREATE_STUB, MIGRATION_STUB, MIGRATION_UPDATE_STUB, MODEL_EVENTS, Mail, MailManager, MailMessage, type MailMessageAction, MailNotificationChannel, MailQueueUnavailableError, MailServiceProvider, type MailTransporter, MailUnavailableError, Mailable, MailerImpl, MakeCastCommand, MakeCommandCommand, MakeControllerCommand, MakeEventCommand, MakeFactoryCommand, MakeJobCommand, MakeListenerCommand, MakeMailCommand, MakeMiddlewareCommand, MakeModelCommand, MakeNotificationCommand, MakeObserverCommand, MakePolicyCommand, MakeProviderCommand, MakeRequestCommand, MakeResourceCommand, MakeRuleCommand, MakeSeederCommand, MakeTestCommand, type Manifest, type ManifestChunk, ManuallyFailedError, type Many, MassAssignmentError, MaxAttemptsExceededError, MemoryStore, MergeProp, MessageBagImpl, MethodNotAllowedHttpError, MiddlewareConfiguration, MiddlewareNotFoundError, Migration, MigrationCreator, type MigrationRecord, MigrationRepository, type MigrationStatus, Migrator, type MigratorOptions, MissingAppKeyError, MissingModelError, MissingRecipientError, Model, type ModelBuilder, type ModelClass, type ModelEvent, type ModelListener, ModelNotFoundError$1 as ModelNotFoundError, ModelRegistry, type MorphConstraint, MorphMany, MorphOne, MorphTo, MySqlSchemaGrammar, NOTIFICATIONS_TABLE, NOTIFICATIONS_TABLE_MIGRATION, type NewAccessToken, NodeConsoleInput, NodeConsoleOutput, NotDatabaseNotifiableError, NotFoundHttpError, Notifiable$1 as Notifiable, type NotifiableConstructor, Notification$1 as Notification, Dispatcher$2 as NotificationDispatcherImpl, NotificationDispatcherUnavailableError, NotificationFacade, NotificationQueueUnavailableError, NotificationsServiceProvider, NullFailedJobProvider, NullLogger, NullQueue, OPERATORS, OnceProp, type OptionDefinition, type OptionValue$4 as OptionValue, OptionalProp, type Order, PERSONAL_ACCESS_TOKENS_MIGRATION, type PagePropsFrom, type PaginationLink, Paginator, type PaginatorOptions, type ParsedInput, type ParsedRule, type ParsedSetCookie, type ParsedSignature, Password, PasswordBroker, PasswordBrokerManager, PasswordReset, PathTraversalError, PendingBatch, PendingChain, PendingDispatch, PersonalAccessToken, PinoLogger, PipelineError, PipelineServiceProvider, Pivot, type PivotIds, type PlainNotificationMail, type PolicyClass, PostgresSchemaGrammar, type PreloadAttributesResolver, PropsResolver, ProviderBootError, ProviderRegisterError, QUEUE_JOB, Builder$1 as QueryBuilder, QueryError, Queue$1 as Queue, QueueBase, type QueueCommandContext, QueueError, type QueueJobPayload, QueueManager, QueueServiceProvider, QueueUnavailableError, Queueable, QueuedConsoleInput, QueuedMailSender, type QueuedMailableFactory, RESTART_CACHE_KEY, type RawResult, type RecipientOverrides, RedirectIfAuthenticated, RedisJob, RedisLock, RedisQueue, type RedisQueueOptions, RedisRepository, type RedisSessionClient, RedisSessionHandler, RedisStore, RedisTaggedStore, type ReferentialAction, type RegisteredModel, Relation, type RelationConstraint, type RelationNames, RelationNotFoundError, RelationNotLoadedError, type RelationValue, type RenderCallback, type RenderedContent, type ReplStarter, type ReportCallback, Repository$1 as Repository, ResetPassword, type ResetPasswordMail, type ResolvedMiddleware, type ResolvedServeOptions, type ResourceMethod, type ResourceRoute, type RollbackOptions, Route$1 as Route, type RouteAttributes, type RouteBinder, RouteDefinition, type RouteFileCallback, type RouteHandler, type RouteListFilters, type RouteListRow, RouteModelNotFoundError, RouteModelResolverImpl, RouteNotDefinedError, type RouteStage, RoutingError, type RoutingOptions, RoutingServiceProvider, Rule, type RuleContext, type RunningServer, type Runtime, type S3ClientLike, type S3DiskConfig, S3Filesystem, SSR_RENDER_FAILED, STORAGE_LINK_SIGNATURE, Schedule, ScheduleImpl, ScheduleListCommand, ScheduleNameRequiredError, ScheduleRunCommand, ScheduleWorkCommand, type ScheduleWorkOptions, ScheduledEventImpl, Schema, SchemaBuilder, SchemaBuilderToken, SchemaGrammar, type Scope, type ScopeCallback, type ScopeStatic, type Scopes, type ScrollMetadata, ScrollProp, Seeder, type SeederClass, type SelectColumn, SendQueuedMailable, SendQueuedNotifications, type Serialized, type SerializedObject, type ServeOptions, ServiceProvider$t as ServiceProvider, SessionFacade as Session, type SessionConfig, SessionGuard, type SessionGuardOptions, type SessionHandlerFactory, SessionManager, SessionMessageBag, SessionServiceProvider, Store$1 as SessionStore, type SharedPropsFrom, type SimplePage, type SmtpConfig, SmtpTransport, SoftDeletingScope, type SpawnResult, type Spawner, SqliteSchemaGrammar, SsrError, type SsrFailure, HttpGateway as SsrHttpGateway, type StackFrame, StackLogger, StartSession, type State, type StateContext, Storage, type StoredBatchOptions, Str, type StringPipeResolver, type SyncChanges, SyncJob, SyncQueue, type TagAttributes, TagsNotSupportedError, TestCommand, TimeoutExceededError, TinkerCommand, type TinkerOptions, type TinkerRepl, TokenGuard, type TokenGuardOptions, TokenMismatchError, TokenRepository, type TransporterFactory, TrimStrings, TypeGenerator, type TypeGeneratorOptions, type TypedRedirector, UNIQUE_LOCK, USERS_TABLE_MIGRATION, UniqueJobsNeedCacheError, UniqueLock, type UniqueLockSpec, UnknownCacheDriverError, UnknownCacheStoreError, UnknownDiskError, UnknownFilesystemDriverError, UnknownLogChannelError, UnknownLogDriverError, UnknownMailTransportError, UnknownMailerError, UnknownNotificationChannelError, UnknownQueueConnectionError, UnknownQueueDriverError, UnknownValidationRuleError, UnrenderableNotificationDataError, UnrenderableNotificationMailError, UnsupportedCipherError, UnsupportedOperationError, type UriParameter, UrlGenerationError, type UrlResolver, type UserProviderFactory, Validated, ValidationErrorImpl, ValidationFactoryImpl, ValidationServiceProvider, Validator, ValidatorImpl, VerifyCsrfToken, ViewFactoryUnavailableError, Vite, ViteError, ViteHtml, WORKER_DISCOVERY_DIRECTORIES, type Where, type WhereArgs, type WhereBoolean, WithoutOverlapping, Worker, type WorkerListener, type WorkerOptions, abort, abortIf, abortUnless, addApiRouting, allowGuests, app, applyExceptionCallbacks, applyMiddlewareCallbacks, applyReplacements, auth, back, bcrypt, builtinRules, bunRuntime, cache, castGet, castSet, classNameOf, clientAddress, collect, columnKey, compareRoutes, config, contentDisposition, cookie, createDailyChannel, createDialect, createPayload, createSingleChannel, createStderrChannel, createToken, csrfToken, currentContainer, currentLogContext, currentRequest, currentVite, databaseConfigDefaults, debugPage, decodePayload, decrypt, defaultAttributeName, defaultLockFactory, defaultProviders, defaultWorkerOptions, delaySeconds, describeError, deserialize, detectRuntime, discoverClasses, discoverFactories, discoverJobs, discoverListeners, discoverPolicies, dispatch, dispatchRoute, dispatchSync, encodePayload, encrypt, enumValues, env, errorBagFrom, errors, escapeHtml, event, expandWildcardKeys, extensionFromMime, facade, fake, fetchNotifications, filterRouteList, formatAddress, formatDate, formatDateTime, formatRouteList, formatTimestamp, fromEntries, generateAppKey, generateModelTypes, getMorphAlias, getMorphedModel, guessTable, hashInfo, healthResponse, inertia, inertiaBody, inertiaHead, inject, ipMatches, isBlank, isBun, isDateCast, isEmptyValue, isEquivalent, isJsonCast, isListenerClass, isListenerTuple, isModel, isQueueable, isQueueableListener, isUnique, isUploadedFileLike, joinDiskPath, keyGenerateHandler, loadRelations, loadRoutesFrom, logger, makeFailedJobProvider, meetsLevel, mergeGroup, mergeLogContext, mergeRecursive, migrationDatePrefix, minimalPage, modelEventName, morphMap, normalizeAddress, normalizeAddresses, normalizeBackoff, normalizeLists, normalizePath, normalizeUri, now, old, openSqlite, optionalCookieJar, optionalSession, orderForBindings, parseArgv, parseBracketKey, parseCookieHeader, parseDateTime, parseKey, parseParameters, parseRuleSpec, parseSignature, passwordVerify, prepareValue, queueConfigDefaults, queueOptionsOf, raw as rawSql, rawWithBindings, redirect, registerHttpCommands, registerKeyGenerateCommand, registerMigrationCommands, registerModelTypesCommand, registerQueueCommands, registerStorageLinkCommand, renderContent, renderError, request, requestScope, resolveArguments, resolveDiskPath, resolveMiddleware, resolveMorphClass, resolveOptions, resourceRoutes, response, restoreJob, restoreValue, retry, roundTrip, route, routeListRows, runConsole, runConsoleAndExit, runMiddleware, runSeeder, sanitize, sendEmailVerificationUsing, sendNotification, serialize, serializeContext, serializeCookie, serializeDate, serializeValue, serve, serveBun, serveNode, servePublicFile, session, setClientAddress, stackFrames, statusFor, statusText, storageLinkHandler, substituteBindings, suggest, summarizeValidation, tap, toNotifiableList, toResponse, toWebRequest, tokenableType, transformLeaves, url, usePaginationResolvers, validateRequiredArguments, value, vite, viteReactRefresh, withHeaders, workerOptionsFrom, writeResponse };
12924
+ export { API_ROUTES_STUB, AboutCommand, AbstractPaginator, AccessGate, AddQueuedCookiesToResponse, type AfterCallback, AllMailersFailedError, AlwaysProp, AnonymousNotifiable, Application$9 as Application, ApplicationBuilder, ArgonHasher, type ArgonOptions, type ArgumentDefinition, Arr, ArraySessionHandler, ArrayTransport, Artisan, Attempting, type Attributes$1 as Attributes, type AttributesResolver, Auth, AuthManager, type AuthModel, type AuthModelBase, type AuthModelConstructor, AuthServiceProvider, AuthenticatableModel, Authenticate, AuthenticationError, AuthorizationError, AuthorizationErrorImpl, Authorize, BaseJob, BaseLogger, BasePipeline, BaseRouter, BaseUrlGenerator, Batch$1 as Batch, type BatchAttributes, BatchingUnavailableError, BcryptHasher, type BcryptOptions, type BeforeCallback, BelongsTo, BelongsToMany, BindingResolutionError, Blueprint, type BlueprintCommand, BufferedConsoleOutput, Builder, type BuiltInCast, type BuiltinRule, BuiltinRuleObject, type BunDatabase, BunSqliteDatabase, type BunStatement, Bus, Dispatcher as BusDispatcherImpl, BusError, BusServiceProvider, CACHE_TABLE_MIGRATION, CHAIN, Cache, CacheManager$1 as CacheManager, CacheRateLimiter, Repository as CacheRepositoryImpl, CacheServiceProvider, type Store as CacheStore, CallQueuedHandler, CallQueuedListener, type CanResetPassword, type CanResetPasswordUser, type CastDefinition, type CastsAttributes, type ChainSpec, type CipherName, CircularDependencyError, ClassRegistry$2 as ClassRegistry, ClosureCommand$4 as ClosureCommand, ClosureKernel, Collection$2 as Collection, type Column, type ColumnAttributes, ColumnDefinition, type ColumnInfo, type ColumnRef, type ColumnType, Command$4 as Command, CommandNotFoundError, ComponentNotFoundError, Connection, type ConsoleInput, type ConsoleIo, Kernel as ConsoleKernelImpl, type ConsoleOutput, ConsoleServiceProvider, Container$j as Container, ContainerNotAvailableError, ControllerMethodNotFoundError, ConvertEmptyStringsToNull, Cookie$1 as Cookie, type CookieDefaults, CookieJar$1 as CookieJar, CookieServiceProvider, CookieSessionHandler, CookieValuePrefix, type CreateMigrationOptions, Crypt, Cursor, type CursorPage, CursorPaginator, type CursorPaginatorOptions, DB, DEFAULT_MESSAGES, DailyRotatingStream, DatabaseBatchRepository, type DatabaseCommandContext, type DatabaseConfig, DatabaseConfigError, DatabaseError, DatabaseFailedJobProvider, DatabaseJob, type DatabaseJobRecord, DatabaseLock, DatabaseManagerImpl, DatabaseNotificationChannel, type DatabaseNotificationRecord, DatabaseQueue, type DatabaseQueueOptions, DatabaseServiceProvider, DatabaseSessionHandler, DatabaseStore, DatabaseTokenRepository, DatabaseUnavailableError, DecryptError, DeferProp, type Direction, Dispatchable, type EagerLoadSpec, EloquentUserProvider, EmailVerificationRequest, type Encoded, EncryptCookies, EncryptError, EncryptHistory, Encrypter$2 as Encrypter, EncryptionServiceProvider, EnsureEmailIsVerified, type EnumLike, type ErrorClass, ErrorHandler, Event, Dispatcher$1 as EventDispatcherImpl, type EventKey, type EventListenMap, EventServiceProvider, EventsNeedBusDispatcherError, EventsNeedClassRegistryError, ExceptionsConfiguration, Expression, type Facade$c as Facade, type FacadeStatics$c as FacadeStatics, Factory$b as Factory, type FactoryResult, Failed, FailoverTransport, Faker, FakerOverflowError, FileNotFoundError, FileSessionHandler, FileStore, FilesystemManager, FilesystemServiceProvider, ForeignIdColumnDefinition, ForeignKeyDefinition, FormRequest, FormUploadedFile, Gate, type GateAbility, GateResponse, GeneratorCommand, GenericLock, type GlobalScope, Grammar, type GroupAttributes, type GroupHost, GroupRegistrar, type GuardFactory, HasApiTokens, type HasFactory, HasMany, HasManyThrough, HasOne, HasOneOrMany, Hash, HashAlgorithmError, type HashInfo, HashManager, type HasherFactory, type HashingConfig, HashingServiceProvider, type Having, HelpCommand, type HttpCommandOptions, HttpException, Kernel$1 as HttpKernelImpl, HttpRedirectResponse, HttpRedirector, HttpResponseException, HttpResponseFactory, HttpServerError, HttpServiceProvider, Hub, IncomingRequest, type IncomingRequestOptions, type IndexType, Inertia, InertiaError, InertiaHtml, InertiaMiddleware, Response$1 as InertiaPageResponse, ResponseFactory as InertiaResponseFactory, InertiaServiceProvider, type ValidationErrors as InertiaValidationErrors, type InferRuleType, type InferValidatedType, InvalidCacheConfigError, InvalidCastError, InvalidListenerError, InvalidLogLevelError, InvalidRuleParameterError, InvalidSignatureError, InvalidUrlSignatureError, JOBS_TABLE_MIGRATION, JobClassNotFoundError, type JobContext, type JobMiddleware, JobSerializationError, JoinClause, type JoinType, type JsonWhenCallback, KEY_GENERATE_SIGNATURE, type KernelApp, type KeyGenerateIO, LEVEL_SEVERITY, LazyCollection$1 as LazyCollection, type LengthAwarePage, LengthAwarePaginator, ListCommand, type ListenerTuple, type LocalDiskConfig, LocalFilesystem, type LockFactory, LockTimeoutError, Lockout, Log, LogChannelCycleError, LogManager, LogServiceProvider, LogTransport, type LoggedQuery, LogicError, Login, Logout, MIGRATION_CREATE_STUB, MIGRATION_STUB, MIGRATION_UPDATE_STUB, MODEL_EVENTS, Mail, MailManager, MailMessage, type MailMessageAction, MailNotificationChannel, MailQueueUnavailableError, MailServiceProvider, type MailTransporter, MailUnavailableError, Mailable, MailerImpl, MakeCastCommand, MakeCommandCommand, MakeControllerCommand, MakeEventCommand, MakeFactoryCommand, MakeJobCommand, MakeListenerCommand, MakeMailCommand, MakeMiddlewareCommand, MakeModelCommand, MakeNotificationCommand, MakeObserverCommand, MakePolicyCommand, MakeProviderCommand, MakeRequestCommand, MakeResourceCommand, MakeRuleCommand, MakeSeederCommand, MakeTestCommand, type Manifest, type ManifestChunk, ManuallyFailedError, type Many, MassAssignmentError, MaxAttemptsExceededError, MemoryStore, MergeProp, MessageBagImpl, MethodNotAllowedHttpError, MiddlewareConfiguration, MiddlewareNotFoundError, Migration, MigrationCreator, type MigrationRecord, MigrationRepository, type MigrationStatus, Migrator, type MigratorOptions, MissingAppKeyError, MissingModelError, MissingRecipientError, Model, type ModelBuilder, type ModelClass, type ModelEvent, type ModelListener, ModelNotFoundError$1 as ModelNotFoundError, ModelRegistry, type MorphConstraint, MorphMany, MorphOne, MorphTo, MySqlSchemaGrammar, NOTIFICATIONS_TABLE, NOTIFICATIONS_TABLE_MIGRATION, type NewAccessToken, NodeConsoleInput, NodeConsoleOutput, NotDatabaseNotifiableError, NotFoundHttpError, Notifiable$1 as Notifiable, type NotifiableConstructor, Notification$1 as Notification, Dispatcher$2 as NotificationDispatcherImpl, NotificationDispatcherUnavailableError, NotificationFacade, NotificationQueueUnavailableError, NotificationsServiceProvider, NullFailedJobProvider, NullLogger, NullQueue, OPERATORS, OnceProp, type OptionDefinition, type OptionValue$4 as OptionValue, OptionalProp, type Order, PERSONAL_ACCESS_TOKENS_MIGRATION, type PagePropsFrom, type PaginationLink, Paginator, type PaginatorOptions, type ParsedInput, type ParsedRule, type ParsedSetCookie, type ParsedSignature, Password, PasswordBroker, PasswordBrokerManager, PasswordReset, PasswordRule, PathTraversalError, PendingBatch, PendingChain, PendingDispatch, PersonalAccessToken, PinoLogger, PipelineError, PipelineServiceProvider, Pivot, type PivotIds, type PlainNotificationMail, type PolicyClass, PostgresSchemaGrammar, type PreloadAttributesResolver, PropsResolver, ProviderBootError, ProviderRegisterError, QUEUE_JOB, Builder$1 as QueryBuilder, QueryError, Queue$1 as Queue, QueueBase, type QueueCommandContext, QueueError, type QueueJobPayload, QueueManager, QueueServiceProvider, QueueUnavailableError, Queueable, QueuedConsoleInput, QueuedMailSender, type QueuedMailableFactory, RESTART_CACHE_KEY, RateLimiter, type RawResult, type RecipientOverrides, RedirectIfAuthenticated, RedisJob, RedisLock, RedisQueue, type RedisQueueOptions, RedisRepository, type RedisSessionClient, RedisSessionHandler, RedisStore, RedisTaggedStore, type ReferentialAction, Registered, type RegisteredModel, Relation, type RelationConstraint, type RelationNames, RelationNotFoundError, RelationNotLoadedError, type RelationValue, type RenderCallback, type RenderedContent, type ReplStarter, type ReportCallback, Repository$1 as Repository, ResetPassword, type ResetPasswordMail, type ResolvedMiddleware, type ResolvedServeOptions, type ResourceMethod, type ResourceRoute, type RollbackOptions, Route$1 as Route, type RouteAttributes, type RouteBinder, RouteDefinition, type RouteFileCallback, type RouteHandler, type RouteListFilters, type RouteListRow, RouteModelNotFoundError, RouteModelResolverImpl, RouteNotDefinedError, type RouteStage, RoutingError, type RoutingOptions, RoutingServiceProvider, Rule, type RuleContext, type RunningServer, type Runtime, type S3ClientLike, type S3DiskConfig, S3Filesystem, SSR_RENDER_FAILED, STORAGE_LINK_SIGNATURE, Schedule, ScheduleImpl, ScheduleListCommand, ScheduleNameRequiredError, ScheduleRunCommand, ScheduleWorkCommand, type ScheduleWorkOptions, ScheduledEventImpl, Schema, SchemaBuilder, SchemaBuilderToken, SchemaGrammar, type Scope, type ScopeCallback, type ScopeStatic, type Scopes, type ScrollMetadata, ScrollProp, Seeder, type SeederClass, type SelectColumn, SendEmailVerificationNotification, SendQueuedMailable, SendQueuedNotifications, type Serialized, type SerializedObject, type ServeOptions, ServiceProvider$t as ServiceProvider, SessionFacade as Session, type SessionConfig, SessionGuard, type SessionGuardOptions, type SessionHandlerFactory, SessionManager, SessionMessageBag, SessionServiceProvider, Store$1 as SessionStore, type SharedPropsFrom, type SimplePage, type SmtpConfig, SmtpTransport, SoftDeletingScope, type SpawnResult, type Spawner, SqliteSchemaGrammar, SsrError, type SsrFailure, HttpGateway as SsrHttpGateway, type StackFrame, StackLogger, StartSession, type State, type StateContext, Storage, type StoredBatchOptions, Str, type StringPipeResolver, type SyncChanges, SyncJob, SyncQueue, type TagAttributes, TagsNotSupportedError, TestCommand, ThrottleRequests, ThrottleRequestsError, TimeoutExceededError, TinkerCommand, type TinkerOptions, type TinkerRepl, TokenGuard, type TokenGuardOptions, TokenMismatchError, TokenRepository, type TransporterFactory, TrimStrings, TypeGenerator, type TypeGeneratorOptions, type TypedRedirector, UNIQUE_LOCK, USERS_TABLE_MIGRATION, UniqueJobsNeedCacheError, UniqueLock, type UniqueLockSpec, UnknownCacheDriverError, UnknownCacheStoreError, UnknownDiskError, UnknownFilesystemDriverError, UnknownLogChannelError, UnknownLogDriverError, UnknownMailTransportError, UnknownMailerError, UnknownNotificationChannelError, UnknownQueueConnectionError, UnknownQueueDriverError, UnknownValidationRuleError, UnrenderableNotificationDataError, UnrenderableNotificationMailError, UnsupportedCipherError, UnsupportedOperationError, type UriParameter, UrlGenerationError, type UrlResolver, type UserProviderFactory, ValidateSignature, Validated, ValidationErrorImpl, ValidationException, ValidationFactoryImpl, ValidationServiceProvider, Validator, ValidatorImpl, type VerifiableUser, Verified, VerifyCsrfToken, VerifyEmail, type VerifyEmailMail, ViewFactoryUnavailableError, Vite, ViteError, ViteHtml, WORKER_DISCOVERY_DIRECTORIES, type Where, type WhereArgs, type WhereBoolean, WithoutOverlapping, Worker, type WorkerListener, type WorkerOptions, __, abort, abortIf, abortUnless, addApiRouting, allowGuests, app, applyExceptionCallbacks, applyMiddlewareCallbacks, applyReplacements, auth, back, bcrypt, builtinRules, bunRuntime, cache, castGet, castSet, classNameOf, clientAddress, collect, columnKey, compareRoutes, config, contentDisposition, cookie, createDailyChannel, createDialect, createPayload, createSingleChannel, createStderrChannel, createToken, csrfToken, currentContainer, currentLogContext, currentRequest, currentVite, databaseConfigDefaults, debugPage, decodePayload, decrypt, defaultAttributeName, defaultLockFactory, defaultProviders, defaultWorkerOptions, delaySeconds, describeError, deserialize, detectRuntime, discoverClasses, discoverFactories, discoverJobs, discoverListeners, discoverPolicies, dispatch, dispatchRoute, dispatchSync, encodePayload, encrypt, enumValues, env, errorBagFrom, errors, escapeHtml, event, exceedsJsonDepth, expandWildcardKeys, extensionFromMime, facade, fake, fetchNotifications, filterRouteList, formatAddress, formatDate, formatDateTime, formatRouteList, formatTimestamp, fromEntries, generateAppKey, generateModelTypes, getMorphAlias, getMorphedModel, guessTable, hashInfo, healthResponse, inertia, inertiaBody, inertiaHead, inject, ipMatches, isBlank, isBun, isDateCast, isEmptyValue, isEquivalent, isJsonCast, isListenerClass, isListenerTuple, isModel, isQueueable, isQueueableListener, isUnique, isUploadedFileLike, joinDiskPath, keyGenerateHandler, loadRelations, loadRoutesFrom, logger, makeFailedJobProvider, meetsLevel, mergeGroup, mergeLogContext, mergeRecursive, migrationDatePrefix, minimalPage, modelEventName, morphMap, normalizeAddress, normalizeAddresses, normalizeBackoff, normalizeLists, normalizePath, normalizeUri, now, old, openSqlite, optionalCookieJar, optionalSession, orderForBindings, parseArgv, parseBracketKey, parseCookieHeader, parseDateTime, parseKey, parseParameters, parseRuleSpec, parseSignature, passwordVerify, prepareValue, queueConfigDefaults, queueOptionsOf, raw as rawSql, rawWithBindings, redirect, registerHttpCommands, registerKeyGenerateCommand, registerMigrationCommands, registerModelTypesCommand, registerQueueCommands, registerStorageLinkCommand, renderContent, renderError, request, requestScope, resolveArguments, resolveDiskPath, resolveMiddleware, resolveMorphClass, resolveOptions, resourceRoutes, response, restoreJob, restoreValue, retry, roundTrip, route, routeListRows, runConsole, runConsoleAndExit, runMiddleware, runSeeder, sanitize, sendEmailVerificationUsing, sendNotification, serialize, serializeContext, serializeCookie, serializeDate, serializeValue, serve, serveBun, serveNode, servePublicFile, session, setClientAddress, stackFrames, statusFor, statusText, storageLinkHandler, substituteBindings, suggest, summarizeValidation, tap, toNotifiableList, toResponse, toWebRequest, tokenableType, transformLeaves, url, usePaginationResolvers, validateRequiredArguments, value, vite, viteReactRefresh, withHeaders, workerOptionsFrom, writeResponse };