curl python JSON RESTful API
Using terminal you can get a nice JSON output from a RESTful API using curl.
curl -H 'Accept: application/json' -v http://api.domain.com/someObjectPath/withQuery=parameter | python -m json.tool
The URL should look familiar if you know REST.
Want to store it in a file?
curl -H 'Accept: application/json' -v http://api.domain.com/someObjectPath/withQuery=parameter | python -m json.tool >> file
Written by Jeffrey Jackson
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Xcode
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#