adds a batch endpoint to your expressjs api.