trying to fix 500
json-ed output and added timestamp
added cross origin header for json
added fix for json return of 404