Provided that the xml tag nodes and the json structure is identical (identical meaning same objects...names..values), you can implement a common json-to-xml conversion in a filter (a custom filter) to set a new filter value for comparison to the target xml.
Note that the exact structure may not be the same, as the common conversion apis, wrap the xml in a special tag scheme, but you can override it is needed.