I invoked the API by postman successfully but did not in HttpClient as the shown below. And there are no logs in wso2carbon.log or error.log
javax.net.ssl.SSLException: hostname in certificate didn't match: <14.201.60.216> != <localhost>
and Do I have to generate my own KeyStore if I want to use httpclient to inovke the linux's API?
You can disable the Hostname verification. To do that set the following property when starting the server
You can refer to https://docs.wso2.com/display/ADMIN44x/Enabling+HostName+Verification