diff --git a/express/express.d.ts b/express/express.d.ts index 17c4ff36a6..cf5014e82b 100644 --- a/express/express.d.ts +++ b/express/express.d.ts @@ -424,7 +424,22 @@ declare module "express" { * @param code */ status(code: number): Response; - + + /** + * Set the response HTTP status code to `statusCode` and send its string representation as the response body. + * @link http://expressjs.com/4x/api.html#res.sendStatus + * + * Examples: + * + * res.sendStatus(200); // equivalent to res.status(200).send('OK') + * res.sendStatus(403); // equivalent to res.status(403).send('Forbidden') + * res.sendStatus(404); // equivalent to res.status(404).send('Not Found') + * res.sendStatus(500); // equivalent to res.status(500).send('Internal Server Error') + * + * @param code + */ + sendStatus(code: number): Send; + /** * Set Link header field with the given `links`. *