You have mixed command line options --tlsCertificateKeyFile E:/bin/mongosh-1.10.6-win32-x64/bin/db-alteryx1.pem --tlsAllowInvalidCertificates with connection string uri format.
Thanks Chris. I have used it as below with single and tried with double quotes of file location E:\bin\mongosh-1.10.6-win32-x64\bin\db-alteryx1.pem but throwing a different error. Please let me for any inputs.
db = connect( ‘mongodb://user:pswd@db-1,db-2,db-3/AlteryxGallery?authSource=AlteryxGallery&replicaSet=AlteryxProd&readPreference=primary&tls=true&tlsCertficateKeyFile=“E:\bin\mongosh-1.10.6-win32-x64\bin\db-alteryx1.pem”&tlsAllowInvalidCertificates=true’ );
Error :
MongoParseError: option tlscertficatekeyfile is not supported