Just wanted to add a note here for how things are in October 2024.
If using the node.js fetch() function, then all you need to do is to export NODE_EXTRA_CA_CERTS=/some/dir/https_cert.pem and everything "just works". Tested on node.js 20.12.
export NODE_EXTRA_CA_CERTS=/some/dir/https_cert.pem