User-driven Database Connectors

Has anything been built that allows a user to define the database connection to use within a live Streamlit app? For example, if I have a Streamlit page that allows users select from a list of database connectors, e.g.,


is there a (secure) way for the user to then enter their credentials within the app itself and allow the Streamlit app to use those to access the database? Similarly, is there a way to allow user-driven secrets that can be dynamically added to Streamlit’s secrets based on user input?

Appreciate any and all thoughts and lemme know if I can provide any additional details or clarity! Many Thanks!