I guess the Docker daemon has not enough resources so the API cannot respond. You could check the daemon log (if the one you shared was not from it) or try enabling debug logs on the daemon side to see a more detailed logs
https://docs.docker.com/engine/daemon/logs/#enable-debugging
If you scroll up, you can also find how you can read the daemon logs on macOS as I see you added macOS to the tags. If you are using Docker Desktop on macOS, everything is running in a virtual machine so you have less resources in the VM than you have on the entire host and you can change that in the Docker Desktop settings