0

The URL https://www.googleapis.com/freebase/v1/topic/en/alps returns a JSON string that is nicely formatted for reading. How can I tell Freebase to return the raw JSON string without all the unnecessary characters?

Flavio
  • 846
  • 1
  • 9
  • 21

2 Answers2

1

You can make the API request with GZIP enabled which will get rid of ALL the unnecessary bytes.

Accept-Encoding: gzip

You can also use the filter parameter to only return the property values that your app needs.

Shawn Simister
  • 4,613
  • 1
  • 26
  • 31
0

I don't think you can, but it shouldn't make a difference to any JSON parser. The whitespace isn't significant.

Tom Morris
  • 10,490
  • 32
  • 53