There's an option to sort exported keys in the web UI and CLI, but it's missing from the REST API.