easy script for creating basic csv from api data

example script often used to create csv for further data mutation or
reporting