addind content-Type for non ascii
use json.dump instead of json.dumps
adding charset check