Libraries
    Preparing search index...

    Redirects the client to a new URL. Uses 302 (temporary) by default; pass permanent = true for 301. Created by ActionResult.redirect().

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    permanent: boolean
    url: string

    Methods

    • Parameters

      • _req: IncomingMessage
      • res: ServerResponse
      • _contentNegotiator: ContentNegotiator

      Returns Promise<void>

    • Send a file buffer as a download attachment.

      Parameters

      • content: Uint8Array<ArrayBufferLike> | Buffer<ArrayBufferLike>
      • fileName: string
      • contentType: string = 'application/octet-stream'

      Returns FileResult

    • Explicit JSON response with a specific status code. Use the named factories (ok, notFound, etc.) for common codes. This overload is an escape hatch for uncommon status codes.

      Type Parameters

      • T

      Parameters

      • body: T

      Returns JsonResult<200, T>

    • Explicit JSON response with a specific status code. Use the named factories (ok, notFound, etc.) for common codes. This overload is an escape hatch for uncommon status codes.

      Type Parameters

      • S extends number
      • T

      Parameters

      • body: T
      • status: S
      • Optionalheaders: Record<string, string>

      Returns JsonResult<S, T>