added middleware and README.md