Retrieve the exact same headers of xlsx when requesting a REST API end point

The objective that I want to achieve is that I want to import data from Kobotoolbox to Google Spreadsheet using REST API End Points with human readable headers.
The below URL is demonstrating an example of what Kobo REST API result is:

https://kc.humanitarianresponse.info/api/v1/data/[formId]?format=json

I can retrieve the data with json format using basic authentication, and import them to Google spreadsheet using Google App Script without any issues, except, the need to have human readable headers.

When requesting the previous mentioned URL, I am looking for a way to have the same exact headers that result when (downloading/exporting) data of a specific form to - for example - xlsx,.

Is there any end point that returns a map between json keys and the actual headers.

Thank you in advance!

1 Like

@m.jaqmaqji, maybe this post discussed previously should help you solve your issue: