Example GraphQL Queries
What building site projects do I have?
Copy the following text string and paste it into the query string field of the Query panel:
query{
buildings{
ID
name
description
notes
locked
yearBuilt
}
}
What is the ceiling height of zones in <projectname>?
You can view the ceilingHeight attribute for a given project in Insights. Example buildings that you can see when you create a PassiveLogic account have default ceiling height values.
Here's an example of what you can type into the query string field of the Query panel:
query{
sites(where: {name: {isEqualTo: "<projectname>"}}) {
name
buildings {
ID
floors(where: {name: {isEqualTo: "Floor 0"}}) {
ID
zones(where: {name: {contains: "Bedroom"}}) {
ID
name
properties(where: {name: {isEqualTo: "ceilingHeight"}}) {
name
currentValue
}
}
}
}
}
}
What's the time series data for my Sense Nano?
query {
equipments(where:
{name: {isEqualTo:"Inventory Sense Nano 1"}}) {
name
equipmentComponents {
name
equipmentComponentPropertyRouters {
property {
name
currentValue
history(from: "2024-07-09T00:00:00Z",
to: "2024-07-10T00:00:00Z") {
ts
val
}
}
}
}
}
}