Request specific middleware parameters
bassemawhoob opened this issue · 0 comments
bassemawhoob commented
Use case
What I'm trying to accomplish is store all outgoing request/responses in the DB with a context on this request. I want to be able to, for example, store the logged in user to the database alongside the payload & response body. My current implementation is that I added a middleware class that implements the request
& response
methods.
Alternative approach
- Manually store each request to be able to add any additional parameters
- Generate a UID for each request that can be later used
Any alternative approaches or ideas?
Thank you for this great gem