I'm able to export a smartsheet document as JSON with the API, however, our endpoint doesn't support nested data. So I'd like to get it either as flattened JSON or CSV.
Sample #4 here shows the CSV option:
// Sample 4: Get sheet as CSV
curl https://api.smartsheet.com/2.0/sheets/{sheetId} \
-H "Authorization: Bearer ll352u9jujauoqz4gstvsae05" \
-H "Accept: text/csv" \
-o output.csv
When I try it with the terminal or Postman it returns, "Invalid Accept header. Media type not supported."
Am I doing something wrong or is it no longer supported?
Otherwise I'm going to have to write something to reformat the JSON for our use case.
Thank you