hapi-swaggered
hapi-swaggered copied to clipboard
Yet another hapi plugin providing swagger compliant API specifications based on routes and joi schemas to be used with swagger-ui.
Joi schema provides the ability to annotate a Joi schema key with a note: https://github.com/hapijs/joi/blob/v8.0.4/API.md#anynotesnotes What do you think about the feasibility of incorporating this information (when provided) in the...
I occasionally get errors like this: ``` code 151023/120031.943, [error], message: Uncaught error: swagger-resource generation failed stack: Error: Uncaught error: swagger-resource generation failed at Object.exports.assert (/Users/mwawrusch/Documents/envy/backend/envy-api/node_modules/hoek/lib/index.js:731:11) at /Users/mwawrusch/Documents/envy/backend/envy-api/node_modules/hapi-swaggered/lib/index.js:65:14 at /Users/mwawrusch/Documents/envy/backend/envy-api/node_modules/hoek/lib/index.js:849:22...
Basically, what I would like to do is modifying the description of a route before swagger sends it out, to add some information that can be automatically generated but is...
When setting ``` response: { modify: true, options: { stripUnknown: true, presence: 'required' } }, ``` all values are optional anyway.
``` javascript { stripPrefix: '/api/v1', basePath: '/alpha', host: '1111111.execute-api.us-west-2.amazonaws.com', } ``` Each endpoint is prefixed with /api/v1, which has been successfully stripped from the documentation, however, it's adding it to...
I would like to host swagger and the ui on a different connection than the api. Is there a way to accomplish this? The following is a snippet from a...
I have the following in an app ``` server.register(require('hapi-auth-bearer-token'), (err) => { server.auth.strategy('simple', 'bearer-access-token', { allowQueryToken: true, // optional, true by default allowMultipleHeaders: false, // optional, false by default accessTokenName:...
As Hapi.js automatically generates HEAD routes for every GET (and based on GET decides what to return), would be cool to allow displaying them, on: - global basis (in plugin...