is there some way to control the sorting of the JSON responses in the swagger-ui?
Fo you mean the fields in an api response? Or the list of apis in the ui?
fields in the api response
I don't think so. If you return a hashmap, it has no order. There are libs like https://github.com/frankiesardo/linked which provide sorted maps & sets.
You can try your luck with
array-map which is in the core.
> An array-map maintains the insertion order of the keys. Look up is linear, which is not a problem for small maps (say less than 10 keys). If your map is large, you should use hash-map instead. From the docs https://clojuredocs.org/clojure.core/array-map