API Key Management

Hi, we are using KoBo for a project and are using the new API. First, we don’t see a way to regenerate the API key. If we deploy to production with the same API key as we used in development this can create a security risk.

Secondly, using the new API, we are able to pull an Excel of the data but could not find the endpoint that gives us the data in JSON, can you assist us in identifying this?

Thanks kindly

Hi Jamiel, i am trying to pull data from KoBo to excel using the API so that i can get realtime data but i have not been successful, Would you know how a can go about it?

Thank you.

Hi Billy,

You should be able to retrieve a JSON result set when you pull from this URL

https://kobo.humanitarianresponse.info/exports/?format=json

The JSON result set will contain links to the XLSX files that in turn need to be retrieved. Be sure to put your API key in the header. I used Postman and Python to get it working and then ported it to our app in Kotlin.

You can send a DELETE to https://kf.kobotoolbox.org/token/ to remove your API key (substitute your hostname for kf.kobotoolbox.org as appropriate). Then, to make a new one, send an empty POST.

2 Likes