Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

how to get data from API using curl ?

Not applicable

(I am new to curl and also apigee)

I am trying to get the Body data from API

"https://staging.api.pearson.com/content/scapi/urn:pearson:manifestation:014f333d-ceda-476f-81f2-d3d6c89ace42"

using curl with following command but unable to get any data than fault string

curl "https://staging.api.pearson.com/content/scapi/urn:pearson:manifestation:014f333d-ceda-476f-81f2-d3d6c89ace42"


Error that I am getting is :

{"fault":{"faultstring":"Failed to resolve API Key variable request.header.x-api key","detail":"errorcode":"steps.oauth.v2.FailedToResolveAPIKey"}}}

but when accessing the URL multiple times in Browser, I can able to get JSON data as desired

5049-capture-20170607-170606.png

Kindly somebody suggest to get JSON data

Sorry I am new to curl and also apigee

Thanks

1 2 4,337
2 REPLIES 2