Keyboard selector like on Android

On the Android phone, if you are typing text, a little icon shows allowing the user to select a keyboard, which can be anything from Emoji to an actual other language keyboard.
What do I need to do to add this?
I also include something like setting a preference, testing for if the language is installed, and anything else I haven’t thought of

the iPhone keyboard already does this as well…
obviously won’t apply to a desktop keyboard… although macOS does include a virtual keyboard