FerretDB is developing an open source, MongoDB-compatible document database. Their solution lets users interact with FerretDB just like as if it would be MongoDB.
FerretDB is based on Postgres and SQLite. FerretDB allows you to use MongoDB drivers seamlessly with PostgreSQL as the database backend.