Added all the json stuff, do in background stuff