“Couldn’t connect to host” usually means it’s a problem with the endpoint, which isn’t something I can help you with.
Per https://rating-widget.com/blog/solution-for-wordpress-plugin-couldnt-connect-to-host/:
When does “couldn’t connect to host” can happen?
This is a common HTTP error may happen when a client server is trying to retrieve a remote web page by establishing a TCP connection.
What does “couldn’t connect to host” mean?
This error indicates that the remote web server did not accept the TCP connection request, and hence the HTTP request could not be conducted.
Why does “couldn’t connect to host” caused?
There are various reasons for this error, but here’s the most common ones:
Firewall mis-configuration: outgoing TCP connections are disabled. This is the most common reason for the error.
Crashed or failed web server processes: an error that happens on the remote server in the middle of the request process.
Network or router failure: an error that happens in your router’s connection or somewhere in the internet before actually getting to the remote server.