Authenticating every server request

In my Node.js apps, I have a custom middleware that will check if my API keys are valid to call certain APIs and if not refresh them if they expired within a specified refresh interval. How can I achieve the same in a Mendix app? I can create a microflow that mimics my Node.js middleware, but I would have to explicitly insert this microflow in all the microflows that I create. Is there a way to hook this middleware up so that it gets automatically invoked in all microflows and not have to explicitly add it to individual microflows?
0 answers