{ "$schema": "https://json-structure.org/meta/core/v0/#", "$id": "https://raw.githubusercontent.com/api-evangelist/wikipedia/refs/heads/main/json-structure/mediawiki-core-rest-compare-response-structure.json", "name": "CompareResponse", "description": "Comparison between two revisions.", "type": "object", "properties": { "from": { "$ref": "#/components/schemas/Revision" }, "to": { "$ref": "#/components/schemas/Revision" }, "diff": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "int32", "description": "0 context, 1 add line, 2 delete line, 3 in-line change, 4 moved paragraph, 5 paragraph moved into place" }, "lineNumber": { "type": "int32" }, "text": { "type": "string" }, "offset": { "type": "object", "properties": { "from": { "type": "int32" }, "to": { "type": "int32" } } }, "highlightRanges": { "type": "array", "items": { "type": "object" } } } } } } }