Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface RouteMatcherOptionsGeneric<S>

Type parameters

  • S

Hierarchy

Index

Properties

Optional auth

auth: { password: S; username: S }

Match against the username and password used in HTTP Basic authentication.

Type declaration

  • password: S
  • username: S

Optional headers

headers: DictMatcher<S>

Match against HTTP headers on the request.

Optional hostname

hostname: S

Match against the requested HTTP hostname.

Optional https

https: boolean

If 'true', only HTTPS requests will be matched. If 'false', only HTTP requests will be matched.

Optional method

method: S

Match against the request's HTTP method.

default

'*'

Optional path

path: S

Match on request path after the hostname, including query params.

Optional pathname

pathname: S

Matches like path, but without query params.

Optional port

Match based on requested port, or pass an array of ports to match against any in that array.

Optional query

query: DictMatcher<S>

Match on parsed querystring parameters.

Optional response

response: string | object

Optional url

url: S

Match against the full request URL. If a string is passed, it will be used as a substring match, not an equality match.

Generated using TypeDoc