Table of contents
Changed Elements
Download API definition:
GET https://api.bentley.com/changedelements/changesets[?$top][&$skip]&iTwinId&iModelId

Get a list of processing statuses for changesets in an iModel. This list allows you to inspect which changesets are ready to be used to generate a comparison summary.

Request parameters

Name
In
Required?
Description
$top
query
No

Amount of changesets to return in a single result. Optional.

$skip
query
No

Amount of changesets to skip when returning results. Optional.

iTwinId
query
Yes

Id of the iTwin where the iModel resides.

iModelId
query
Yes

Id of the iModel to query for status of changesets.

Request headers

Name
Required?
Description
Authorization
Yes

OAuth access token with scope changedelements:read

Accept
Yes

Setting to application/vnd.bentley.itwin-platform.v1+json is recommended.

Response 200 OK

OK

json
{
    "changesetStatus": [{
            "id": "c7033d718cab5134d1be1fa47316753985695e1d",
            "index": 3,
            "ready": true
        },
        {
            "id": "ef3c6be62f7bf0053b8b74ded20ea3201840c6e1",
            "index": 4,
            "ready": true
        },
        {
            "id": "45df48dd7b53a6aacc16319dc9e03aa0f26d8407",
            "index": 5,
            "ready": true
        }
    ],
    "_links": {
        "self": {
            "href": "https://api.bentley.com/changedelements/changesets?iTwinId=1036c64d-7fbe-47fd-b03c-4ed7ad7fc829&iModelId=0db82dc1-e871-4209-b40a-6753c6a68c19&$top=3&$skip=2"
        },
        "prev": {
            "href": "https://api.bentley.com/changedelements/changesets?iTwinId=1036c64d-7fbe-47fd-b03c-4ed7ad7fc829&iModelId=0db82dc1-e871-4209-b40a-6753c6a68c19&$top=3&$skip=0"
        },
        "next": {
            "href": "https://api.bentley.com/changedelements/changesets?iTwinId=1036c64d-7fbe-47fd-b03c-4ed7ad7fc829&iModelId=0db82dc1-e871-4209-b40a-6753c6a68c19&$top=3&$skip=5"
        }
    }
}

Response 401 Unauthorized

This response indicates that request lacks valid authentication credentials. Access token might not been provided, issued by the wrong issuer, does not have required scopes or request headers were malformed.

json
{
    "error": {
        "code": "HeaderNotFound",
        "message": "Header Authorization was not found in the request. Access denied."
    }
}

Response 404 Not Found

This response indicates that provided iTwin or iModel was not found.

json
{
    "error": {
        "code": "IModelNotFound",
        "message": "Requested iModel is not available."
    }
}

Response 422 Unprocessable Entity

This response indicates that a URL parameter was malformed or there are missing required parameters.

json
{
    "error": {
        "code": "InvalidChangedElementsRequest",
        "message": "Could not get processed.",
        "details": [{
                "code": "MissingRequiredParameter",
                "message": "Query parameter must be provided.",
                "target": "iModelId"
            },
            {
                "code": "MissingRequiredParameter",
                "message": "Query parameter must be provided.",
                "target": "iTwinId"
            },
            {
                "code": "InvalidParameter",
                "message": "$top must be a positive number.",
                "target": "$top"
            },
            {
                "code": "InvalidParameter",
                "message": "$skip must be a positive number.",
                "target": "$skip"
            }
        ]
    }
}

Response 429 Too many requests

This response indicates that the user has sent too many requests in a given amount of time.

json
{
    "error": {
        "code": "TooManyRequests",
        "message": "More requests were received than the subscription rate-limit allows."
    }
}

Response headers

Name
Description
retry-after

The number of requests exceeds the rate-limit for the client subscription.

changesets-get

TableSchema
Name
Type
Description
changesetStatus
Object[]
_links.self.href
String
_links.prev.href
String
_links.next.href
String

Error

Contains error information.

TableSchema
Name
Type
Description
code
String

One of a server-defined set of error codes.

message
String

A human-readable representation of the error.

target
String

The target of the error.

Error Response

Gives details for an error that occurred while handling the request. Note that clients MUST NOT assume that every failed request will produce an object of this schema, or that all of the properties in the response will be non-null, as the error may have prevented this response from being constructed.

TableSchema
Name
Type
Description
error

Error information.