Elements filtered by type, storey, name and property values
curl --request POST \ --url https://api.whatsbuilt.fi/v1/projects/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/elements/query \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "model_version_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "ifc_type": "example", "storey_name": "example", "search": "example", "properties": [], "limit": 200, "cursor": "example", "include_total": true }'The filter of the app’s element list. Live elements of the current models, or of one model version. A page holds at most limit elements; pass next_cursor as cursor with the same filter for the next.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”The filter of an element query and the page to read.
object
Part of the name, type name or GlobalId
Every condition must hold
One condition on a property of the elements.
object
eq, prefix and contains take value; in takes values; exists neither
The next_cursor of the previous page; the other fields must be the same
Responses
Section titled “Responses”One page
ElementQueryPage: one page of queryElements.
object
ElementMatch: an element of a query page with the conditions’ values on it.
object
The conditions’ values on this element, keyed pset.property
object
Null with include_total: false and on every page after the first
First page with an in condition: each of its values with the elements that have it, in the order sent
ElementPropertyValueCount: one value and the elements that have it.
object
Example generated
{ "data": [ { "global_id": "example", "project_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "name": "example", "ifc_type": "example", "predefined_type": "example", "storey_name": "example", "building_name": "example", "type_name": "example", "archived_at": "example", "matched": { "additionalProperty": "example" }, "model_version_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" } ], "total": 1, "next_cursor": "example", "value_counts": [ { "value": "example", "count": 1 } ]}VALIDATION_ERROR for a malformed id or parameter; INVALID_PROPERTY_FILTER for a property condition the filter cannot use
The error body of every /v1 answer of 400 or more.
object
A sentence for people; it may change
Part of the contract
What the code names, where it names something
The X-Request-Id of the call
Example generated
{ "error": "example", "code": "example", "details": "example", "request_id": "example"}Missing, malformed, expired or revoked token
The error body of every /v1 answer of 400 or more.
object
A sentence for people; it may change
Part of the contract
What the code names, where it names something
The X-Request-Id of the call
Example generated
{ "error": "example", "code": "example", "details": "example", "request_id": "example"}INSUFFICIENT_SCOPE; INSUFFICIENT_PROJECT_ROLE when the project is not the integration’s; PUBLIC_API_DISABLED when the project’s owning organisation has turned the API off
The error body of every /v1 answer of 400 or more.
object
A sentence for people; it may change
Part of the contract
What the code names, where it names something
The X-Request-Id of the call
Example generated
{ "error": "example", "code": "example", "details": "example", "request_id": "example"}No such project or element
The error body of every /v1 answer of 400 or more.
object
A sentence for people; it may change
Part of the contract
What the code names, where it names something
The X-Request-Id of the call
Example generated
{ "error": "example", "code": "example", "details": "example", "request_id": "example"}RATE_LIMITED; wait for Retry-After seconds
The error body of every /v1 answer of 400 or more.
object
A sentence for people; it may change
Part of the contract
What the code names, where it names something
The X-Request-Id of the call
Example generated
{ "error": "example", "code": "example", "details": "example", "request_id": "example"}