in MySQL Workbench - Go to your connections in home page . Right click - select option "Copy JDBC Connection String to Clipboard".
example : jdbc:mysql://127.0.0.1:3306/?user=root