I was recently working with the FogBugz XML API and I needed to get some attribute value from the response. Below is the perfectly legal call chain needed to get an attribute value from my preferred XML parser, DOMDocument:
$case_id = $dom_document->getElementsByTagName('case')->item(0)->attributes->getNamedItem('ixBug')->nodeValue;
Assuming FogCreek chose to go with a JSON API for FogBugz we could expect something along these lines to get the same value:
$case_id = $json->case->ixBug
For this reason I would prefer to work with a JSON API as compared to an XML API. Imagine the code you'd need to actually parse a complete XML document and not simply returning an attribute value.
Did you mean?
Else I'm not really sure why you go to attributes here as both things imply different meaning :)