Hacker News new | ask | show | jobs
by kolinkorr839 2180 days ago
Is there a way to show the output in json format?
2 comments

Would be nice if both of these work (they don't):

curl https://ec2.shop -H 'Accept: application/json'

curl https://ec2.shop?json

It should work that way now :-). Thanks for suggestion.
Per suggest by mike-cardwell, I implemented this:

  curl https://ec2.shop -H 'Accept: application/json'
  curl 'https://ec2.shop?json'
  curl 'https://ec2.shop?txt'