Capgemini Interview Question

how to execute middleware in a code