{"library":"hapi-require-https","type":"library","category":null,"description":"hapi-require-https is a Hapi plugin designed to enforce HTTPS for incoming requests, providing automatic HTTP to HTTPS redirection. The current stable version is 6.0.0, which requires Hapi v20 or newer. This plugin primarily operates by default using the `X-Forwarded-Proto` header, making it ideal for applications running behind a reverse proxy (like on Heroku or other PaaS environments). It offers a straightforward API, registering as an `onRequest` lifecycle hook to perform 301 redirects. A key differentiator is its explicit support for proxy environments, configurable via a `proxy` option, which can be set to `false` to redirect based on the actual request protocol instead of the forwarded header. Release cadence typically aligns with major Hapi versions or necessary compatibility updates.","language":"javascript","status":"active","version":"6.0.0","tags":["javascript","hapi","https","redirect","paas","heroku"],"last_verified":"Wed May 27","install":[{"cmd":"npm install hapi-require-https","imports":["import HapiRequireHttps from 'hapi-require-https';\n// then use HapiRequireHttps in server.register","const HapiRequireHttps = require('hapi-require-https');\n// then use HapiRequireHttps in server.register","import type { Options } from 'hapi-require-https';"]},{"cmd":"yarn add hapi-require-https","imports":[]},{"cmd":"pnpm add hapi-require-https","imports":[]}],"homepage":null,"github":"https://github.com/bendrucker/hapi-require-https","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/hapi-require-https","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/hapi-require-https/compatibility"}}