Open an element's inspection, as a scan does
curl --request POST \ --url https://api.whatsbuilt.fi/v1/projects/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/inspections \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "global_id": "example", "plan_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'Returns the element’s open inspection under the plan that covers it, and creates it with its number when it has none. Without a covering plan the project’s default template opens. Opening again returns the same inspection.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”The body of openInspection.
object
A live element of the project
Needed when several active plans cover the element (409 PLAN_CHOICE_REQUIRED)
Example generated
{ "global_id": "example", "plan_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}Responses
Section titled “Responses”The inspection
A live inspection.
object
The inspection.
The project.
The element’s IFC GlobalId.
The plan it belongs to.
Its template.
Its status.
The step under way.
Its topic.
The inspection number, INSP-00001 onwards per project; null until the inspection is opened
Its steps in the template’s order.
A step of an inspection.
object
The step result.
The template step.
Its status.
Who recorded it.
Their name, read when answering.
The integration’s id or the app’s client id when created_via is integration or app
When it was recorded.
When it happened.
True when recorded after the fact.
Its notes.
Why it failed.
Its first failing verdict.
The check-list version the step is pinned to; its items are the checks recordCheck takes
Its checks.
A check of an inspection step.
object
The check result.
The check-list item it answers.
Its status.
True when it failed before.
Who recorded it.
Their name, read when answering.
The integration’s id or the app’s client id when created_via is integration or app
When it was recorded.
When it happened.
True when recorded after the fact.
Its note.
Why it failed.
The row’s change time.
Example
{ "steps": [ { "created_via": "agent", "checks": [ { "created_via": "agent" } ] } ], "deleted": false}PLAN_NOT_COVERING: the plan is not active or does not cover the element; VALIDATION_ERROR
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 role the scopes give does not cover the write, or 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, or no plan covers the element and the project has no default template
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"}PLAN_CHOICE_REQUIRED with the covering plans in details; CONFLICT once the project is handed over to maintenance
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"}IDEMPOTENCY_KEY_REUSED: the key was used with another body
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"}