This is a minimal, PSR compliant, middleware stack that was created as a simple proof-of-concept in the hopes that someone will find it useful. Required dependencies have been restricted to PSR interfaces.
Theoretically you should be able to use this middleware stack in any PSR compliant framework.
composer require kwhat/http-middleware