import * as oak from "https://deno.land/x/oak@v9.0.0/mod.ts";
Classes
Application | A class which registers middleware (via |
Context | Provides context about the current request and response to middleware functions. |
Cookies | An interface which allows setting and accessing cookies related to both the current request and response. |
FormDataReader | A class which provides an interface to access the fields of a
|
HttpError | A base class for individual classes of HTTP errors. |
HttpServerNative | |
HttpServerStd | |
MultiPartStream | A class that takes a file (either a Deno.File or Uint8Array) and bytes and streams the ranges as a multi-part encoded HTTP body. |
NativeRequest | |
Request | An interface which provides information about the current request. |
Response | An interface to control what response will be sent when the middleware finishes processing the request. |
Router | An interface for registering middleware that will run when certain HTTP methods and paths are requested, as well as provides a way to parameterize parts of the requested path. |
ServerSentEvent | An event which contains information which will be sent to the remote
connection and be made available in an |
Variables
httpErrors | An object which contains an individual HTTP Error for each HTTP status
error code (4XX and 5XX). When errors are raised related to a particular
HTTP status code, they will be of the appropriate instance located on this
object. Also, context's |
REDIRECT_BACK | A symbol that indicates to |
STATUS_TEXT | |
testing.mockContextState | Allows external parties to modify the context state. |
Functions
composeMiddleware | Compose multiple middleware functions into a single middleware function. |
etag.calculate | Calculate an ETag value for an entity. If the entity is |
etag.factory | Create middleware that will attempt to decode the response.body into
something that can be used to generate an |
etag.getEntity | For a given Context, try to determine the response body entity that an ETag can be calculated from. |
etag.ifMatch | A helper function that takes the value from the |
etag.ifNoneMatch | A helper function that takes the value from the |
helpers.getQuery | Given a context, return the |
ifRange | Determine, by the value of an |
isErrorStatus | Determines if a HTTP |
isHttpError | |
isRedirectStatus | Determines if a HTTP |
parseRange | |
proxy | Middleware that provides a back-to-back proxy for requests. |
send | Asynchronously fulfill a response with a file from the local file system. |
testing.createMockApp | Creates a mock of |
testing.createMockContext | Create a mock of |
testing.createMockNext | Creates a mock |
Interfaces
ApplicationOptions | |
BodyOptions | |
ByteRange | |
ContextSendOptions | |
CookiesGetOptions | |
CookiesSetDeleteOptions | |
etag.ETagOptions | |
etag.FileInfo | Just the part of |
FormDataBody | |
FormDataReadOptions | |
ListenOptionsBase | |
ListenOptionsTls | |
Middleware | Middleware are functions which are chained together to deal with requests. |
ProxyOptions | |
Route | |
RouterAllowedMethodsOptions | |
RouterContext | The context passed router middleware. |
RouterMiddleware | |
RouterOptions | |
RouterParamMiddleware | Middleware that will be called by the router when handling a specific parameter, which the middleware will be called when a request matches the route parameter. |
SendOptions | |
ServerConstructor | |
ServerRequest | An interface that aligns to the parts of |
ServerResponse | An interface that aligns to what oak returns and is compatible with
|
ServerSentEventInit | |
ServerSentEventTarget | |
testing.MockContextOptions | Options that can be set in a mock context. |
Type Aliases
Body | |
BodyBytes | |
BodyForm | |
BodyFormData | |
BodyJson | |
BodyReader | |
BodyStream | |
BodyText | |
BodyType | |
BodyUndefined | |
ErrorStatus | A HTTP status that is an error (4XX and 5XX). |
FormDataFile | A representation of a file that has been read from a form data body. |
helpers.GetParamsOptions | |
HTTPMethods | |
ListenOptions | |
RedirectStatus | A HTTP status that is a redirect (3XX). |
RouteParams | |
State |