cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Claudia.Landivar
AppDynamics Team (Retired)

When making a REST API call with a curl command, how can I resolve an empty server reply?

 

Problem

When making a REST call with a curl command, an empty server reply server results:

 

Command:

curl  --user <user>@<account >:password "http://<controller url>/controller/rest/applications/<app-name>/metrics"

 

The output is:

* Trying [Redacted for sercurity reasons by ^  , AppD Community Manager]...
* Connected to cloud2019092621461.saas.appdynamics.com ([Redacted for sercurity reasons by ^  , AppD Community Manager]) port 443 (#0)
* Server auth using Basic with user 'govind.kumar@cloud2019092621461'
> GET /controller/rest/applications/Java-App/metrics HTTP/1.1
> Host: cloud2019092621461.saas.appdynamics.com:443
> Authorization: Basic [Redacted for sercurity reasons by ^  , AppD Community Manager]
> User-Agent: curl/7.47.0
> Accept: */*
>
* Empty reply from server
* Connection #0 to host cloud201909262146143.saas.appdynamics.com left intact

 

Solution

Use HTTPS in the Controller URL, as follows:

 

Command : curl --user <user>@<account >:password "https://<controller url>/controller/rest/applications/<app-name>/metrics"

 

 

Additional Resources

 

Version history
Last update:
‎07-19-2021 07:41 PM
Updated by:
On-Demand Webinar
Discover new Splunk integrations and AI innovations for Cisco AppDynamics.


Register Now!

Observe and Explore
Dive into our Community Blog for the Latest Insights and Updates!


Read the blog here