Connecting to the Server Using URI-Like Strings or Key-Value Pairs Percent encoding must be used for reserved characters in the elements of the URI- like string. For example, if you specify a string that includes the  @  character, the character must be replaced by  %40 . If you include a zone ID in an IPv6 address, the %  character used as the separator must be replaced with  %25 . The parameters you can use in a URI-like connection string are described at Base Connection Parameters. MySQL Shell’s  shell.parseUri()  and  shell.unparseUri()  methods can be used to deconstruct and assemble a URI-like connection string. Given a URI-like connection string,  shell.parseUri() returns a dictionary containing each element found in the string.  shell.unparseUri()  converts a dictionary of URI components and connection options into a valid URI-like connection string for connecting to MySQL, which can be used in MySQL Shell or by MySQL Connectors which implement X DevAPI. If no password is specified in the URI-like string, which is recommended, interactive clients prompt for the password. The following examples show how to specify URI-like strings with the user name  user_name . In each case, the password is prompted for. mysqlx:// user_name @localhost:33065 mysql:// user_name @localhost:3333 mysqlx:// user_name @/ path %2F to %2F socket.sock mysqlx:// user_name @( /path/to/socket.sock ) 372 •To specify a TLS version and ciphersuite to use for encrypted connections: •An optional query can be specified, consisting of values each given as a  key = value  pair or as a single key . To specify multiple values, separate them by  ,  characters. A mix of  key = value  and  key  values is permissible. Values can be of type list, with list values ordered by appearance. Strings must be either percent encoded or surrounded by parentheses. The following are equivalent. •An optional path can be specified, which represents a database. •An X Protocol connection using a socket, with the path provided using either percent encoding or parentheses. •An X Protocol connection to a remote server instance, using a host name, an IPv4 address, and an IPv6 address. •A classic MySQL protocol connection to a local server instance listening at port 3333. •An X Protocol connection to a local server instance listening at port 33065. Important mysqlx:// user_name @server.example.com/ mysqlx:// user_name @198.51.100.14:123 mysqlx:// user_name @[2001:db8:85a3:8d3:1319:8a2e:370:7348] # use ’world’ as the default database mysqlx:// user_name @198.51.100.1/world # use ’world_x’ as the default database, encoding _ as %5F mysqlx:// user_name @198.51.100.2:33060/world%5Fx ssluser@127.0.0.1?ssl-ca=%2Froot%2Fclientcert%2Fca-cert.pem\ &ssl-cert=%2Froot%2Fclientcert%2Fclient-cert.pem\ &ssl-key=%2Froot%2Fclientcert%2Fclient-key ssluser@127.0.0.1?ssl-ca=(/root/clientcert/ca-cert.pem)\ &ssl-cert=(/root/clientcert/client-cert.pem)\ &ssl-key=(/root/clientcert/client-key)