3 ms·
JSON's syntax, at least, is defined. Also using JSON implies that extra stuff will be ignored and missing stuff rendered as null rather than causing the parser
by JulianMorrison 17y ago
JSON's syntax, at least, is defined. Also using JSON implies that extra stuff will be ignored and missing stuff rendered as null rather than causing the parser to crash - it's a forgiving format. Meanwhile it's a lot lighter than XML/HTML. And of course, I'm envisaging use of the "Accept" header to pick a format. Browsers ask for HTML. API users might ask for JSON.
- bct 17y agoI agree with all your points, but none of them have anything to do with how "REST" something is.