This api returns already calculated comparison of revisions of the model. In returned json is very important property "IsUpToDate" which provide information if revision comparison is actual or not. In response are most important four sets of objects - inserted, deleted, changedGeometry, changed. The unaffected & hidden objects are not returned in the response.
"changed" will contain array of objects in following format:
Code Block
borderColor
Red
theme
FadeToGrey
lang
xml
title
The comparison objects in response JSON has following format :
, all returns array of objects, e.g. :
{
"comparisonObjectId": "870c9ced-63fb-4fdf-beaf-ebd19507c072",
"first": {
"id": "3a2d82dc-325c-4369-a083-02e3535d850d",
"type": "Beam",
"name": "Beam_1-01"
},
"second": {
"id": "3a2d82dc-325c-4369-a083-02e3535d850d",
"type": "Beam",
"name": "Beam_1-01"
}
JSON Structure:
Name
Mandatory / Optional
Type
Description
divisionId
string(guid)
The id of the model
firstRevision
int
higher revision number between whose the calculation was done
secondRevision
int
lower revision number between whose the calculation was done
status
string
Can be "DONE" => ok, or "PENDING" => calculation was not yet completed
isUpToDate
bool
Should be be true.
False means that the model was changed after the revision comparison was calculated, so the revision comparison is not actual, and it will be better to recalculate again with POST (see api call above)
calculatedAt
string (date)
The date and time of the calculation
calculatedBy
string (user)
The user which performed the calculation
inserted
objects
Objects that exists only in in first (higher) revision but not in the second
deleted
objects
Objets that exist only in the second (lower) revision, but are already deleted in the first (higher) revision
changedGeometry
objects
Objects that exists in both revisions, but with different geometry
changed
objects
Objects that exist in both revisions, have identical geometry, but some other properties are changed, (objects identical in both revisions are not present in this response)
NOTE : Properties "inserted", "deleted", "changedGeometry" and "changed", all returns array of objects, with following properties:
comparisonObjectId
string(guid)
id of the comparison object
first
object
Object from revision with higher revision number. This object is not present in the "deleted" list.
Object has following properties:
id of the compared element ("id")
element type name ("type")
element name ("name")
second
object
Object from revision with lower revision number. This object is not present in the "inserted" list.