When I try to call an API method using identityserver4, I tried before on Windows and it is working fine only in Mac OS I faced this issue and I don´t know what is happened and
Your Mac does not trust the local development Windows certificate for localhost, you need to buy a get a real certificate that your Mac will trust. Perhaps use LetsEncrypt if you want a real trusted certificate for free.