mw_raw: Middleware to read the raw body of a request

Description Usage Arguments Value See Also Examples

View source: R/mw-raw.R

Description

Adds the raw body, as a raw object to the raw field of the request.

Usage

1
mw_raw(type = "application/octet-stream")

Arguments

type

Content type to match. If it does not match, then the request object is not modified.

Value

Handler function.

See Also

Other middleware: mw_etag(), mw_json(), mw_log(), mw_multipart(), mw_static(), mw_text(), mw_urlencoded()

Examples

1
2
3
app <- new_app()
app$use(mw_raw())
app

presser documentation built on July 1, 2020, 5:49 p.m.