fix documentation for request middleware