more changes, json support