How can I get the Token from the server

Working with Postman, using the configeration as shown at the screen shoot, I’m able to get the token from the server.
How can I do this using Kotlin code, planning to use it from a mobile app.