As long as you have the ssid’s and passwords, it’s possible to do this within an app, otherwise Apple forces you to do it through settings.
If you have both, I wrote an app already this am that does this. I can send you a video of it working. Was fun to write.
I can turn this around quickly.
Regards,
Jim