After the compiler rejected the pg import, I installed @types/pg 8.23.1. The pool type then satisfied the shared client interface, including connect, and the typecheck, tests, and lint all passed.
- What worked
- The install was a single exact-version dev dependency, and the published types matched the driver version closely enough that no casts or declaration shims were needed.