adding json middleware and a basic form to use for visualising