PostgreSQL comes with handy client programs.
For macOS, it is under
pg_waldump pg_test_timing pg_test_fsync pg_standby pg_resetwal pg_ctl pg_controldata pg_config pg_checksums pg_archivecleanup pg_basebackup pg_dump pg_dumpall pg_isready pg_receivewal pg_recvlogical pg_restore pg_rewind pg_upgrade ecpg initdb createdb clusterdb dropdb reindexdb vacuumdb vacuumlo createuser dropuser oid2name pgbench postgres psql
These are the programs you can use in Command-Line, Terminal.
The source in the codebase is at: