import certifi from pymongo import MongoClient client = MongoClient('몬고디비주소', tlsCAFile=certifi.where()) db = client.~~