Psycopg2 DLL error with sqlalchemy and postgres as database and FastApi framework

I am using psycopg2 with FastAPI on a Windows 10 system. When attempting to connect to a PostgreSQL database, I encounter the following error:

ImportError: DLL load failed: The specified module could not be found.

I have already installed psycopg2 using pip install psycopg2 and verified that PostgreSQL is running.

May you please show the code that is raising the exception? (Also the error message)