Made response of taking screenshot always in JSON format.