I am using postman to test an API I have, all is good when the request does not contain sub-domain, however when I add a sub-domain to URL I am getting this response.
Could not get any response
There was an error connecting to http://subdomain.localhost:port/api/
Why this might have happened:
The server couldn't send a response:Ensure that the backend is working properly
Self-signed SSL certificates are being blocked:Fix this by turning off 'SSL certificate verification' in Settings > General
Proxy configured incorrectly Ensure that proxy is configured correctly in Settings > Proxy
Request timeout:Change request timeout in Settings > General
If I copy the same URL from postman and paste it into the browser I get a proper response, is there some kind of configurations I should do to make postman work with sub-domains?
If all above methods doesn't work check your environment variables, And make sure that the following environments are not set. If those are set and not needed by any other application remove them.
Reference link
When getting the following error,
you need to do the following.
Step 1: In Postman, click the wrench icon, go to settings, then go to the Proxy tab.
Step 2: Create a custom Proxy. This article explains how to create a custom proxy. After you create the custom Proxy, make sure you turn the Proxy toggle button to off. I put 61095 in for the proxy server and it worked for me.
Step 3 :
Success
I had the same issue. It was caused by a newline at the end of the "Authorization" header's value, which I had set manually by copy-pasting the bearer token (which accidentally contained the newline at its end)
You mentioned you are using a CER certificate.
According to the Postman page on certificates.
Choose your client certificate file in the CRT file field. Currently, we only support the CRT format. Support for other formats (like PFX) will come soon.
The name of the extension CER, CRT doesn't make the certificate that type of certificate but, these are the excepted extensions names.
CER is an X.509 certificate in binary form, DER encoded.
CRT is a binary X.509 certificate, encapsulated in text (base-64) encoding.
You can use OpenSSL to change a CER file into a CRT file. I have not had good luck with it but it looks like this.
or
First Go to Settings in Postman:
1) Off the SSL certificate verification in General Tab:
2) Off the Global Proxy Configuration and Use System Proxy in Proxy Tab
For me, it was that route that I was calling in my node server wasn't returning anything. Adding
to the route I was calling resolved the issue.