Browse documentation

Request

Type. Parsed Router request passed to middleware.

Table of contents

Category

Type

Type import

ts
import type { Request } from "valyrian.js/router";

Public signature

ts
interface Request { params: Record<string, unknown>; query: Record<string, unknown>; url: string; path: string; matches: string[]; redirect(path: string): Promise<string | void>; }

Type usage

Router Request is the route input passed to middleware with parsed params, query, URL, path, matches and redirect.