get json data from crossbi and generate csv