Wikidiff2/JSON diff format

required required optional required optional Each object includes: optional optional
 * array of objects
 * Each object in the  array represents a line in a visual, line-by-line comparison between the two revisions.
 * integer
 * The type of change represented by the diff object, either:
 * : A line with the same content in both revisions, included to provide context when viewing the diff. The API returns up to two context lines around each change.
 * : A line included in the  revision but not in the   revision.
 * : A line included in the  revision but not in the   revision.
 * : A line containing text that differs between the two revisions. (For changes to paragraph location as well as content, see type 5.)
 * : When a paragraph's location differs between the two revisions, a type 4 object represents the location in the  revision.
 * : When a paragraph's location differs between the two revisions, a type 5 object represents the location in the  revision. This type can also include word-level differences between the two revisions.
 * integer
 * The line number of the change based on the  revision.
 * string
 * The text of the line, including content from both revisions. For a line containing text that differs between the two revisions, you can use  to visually indicate added and removed text. For a line containing a new line, the API returns the text as   (empty string).
 * array of objects
 * An array of objects that indicate where and in what style text should be highlighted to visually represent changes.
 * (integer): Where the highlighted text should start, in the number of bytes from the beginning of the line.
 * (integer): The length of the highlighted section, in bytes.
 * (integer): The type of highlight:
 * indicates an addition.
 * indicates a deletion.
 * object
 * Visual indicators to use when a paragraph's location differs between the two revisions.  objects occur in pairs within the diff.
 * (string): The ID of the paragraph described by the diff object.
 * (string): The ID of the corresponding paragraph.
 * For type 4 diff objects,  represents the location in the   revision.
 * For type 5 diff objects,  represents the location in the   revision.
 * (integer): A visual indicator of the relationship between the two locations. You can use this property to display an arrow icon within the diff.
 * indicates that the  paragraph is lower on the page than the   paragraph.
 * indicates that the  paragraph is higher on the page than the   paragraph.
 * object
 * The span of the line, in bytes from the beginning of the page, including:
 * (integer): The first byte of the line
 * (integer): The last byte of the line