Answer
Check whether only the single leaf/server certificate was imported into the wallet, rather than the full certificate chain (intermediate + root certificates too) — UTL_HTTP typically needs the complete chain to validate the connection, not just the endpoint's own certificate. To get the full chain: run openssl s_client -host <hostname> -port 443 -prexit -showcerts to display every certificate in the chain, save each one into its own .pem file (each starting with -----BEGIN CERTIFICATE----- and ending with -----END CERTIFICATE-----), then import all of them into the wallet (the leaf certificate can be skipped if it's already imported). Importing the complete chain this way resolves SSL errors that persist despite the leaf certificate already being present.