How to get a map from a GET request?

In my Kotlin code, I’m making a GET request to my Python endpoint that returns a dict. I was wondering how I could get that dict in the Kotlin code.

In my other endpoint that returns a “Response(content, mimetype=‘text/html’)”, I use Jsoup like this:

val doc = Jsoup.parse(url, 15000)

But I don’t know how to deal with getting a dict.