Buildings

A building is any venue where Situm's indoor location platform can be configured. More details here.
Attributes
id integer
Building identifier (retrieve all you buildings to know their identifiers)
user_uuid integer
User identifier
name string
Building name
description text
Building address
created_at datetime
Time when the building was created
updated_at datetime
Last time when the building was updated
location object
Building location in geographic coordinates
The location data are represented in WGS84 coordinate system
More details here
Child attributes
lat float
Geographic latitude
lng float
Geographic longitude
corners array of objects
Building corners in geographic coordinates
The location data are represented in WGS84 coordinate system
Each corner is a object. The order is topleft, topright, bottomright, bottomleft
More details here
Corner attributes
lat float
Geographic longitude
lng float
Geographic longitude
dimensions object
Building dimensions in meters
More details here
Child attributes
width float
Building with. Distance between the topleft corner and the topright corner
length float
Building length. Distance between the topright corner and the bottomright corner
rotation float
Building rotation in radians.
In starting from the west in a counter-clockwise order
More details here
custom_fields array of objects
List of custom key-value pairs. More details in Custom fields
Custom field attributes
key string
Custom field key
value string
Custom field value
picture_url string
Building image url (e.g. building as seen from the outside). Can be null
picture_thumb_url string
Thumbnail url of building image. Can be null
server_url string
Server url. Can be null
calibration_model object
Calibration model of the building
Child attributes
id integer
Calibration model identifier
updated_at datetime
Last time when the calibration model was updated
download string
Our API url for download the calibration model. Can be null
info text
Aditional information of the building in HTML
floors array of objects
List of floors of the building. More details in Floors
indoor_pois array of objects
List of indoor points of interest. More details in Indoor POIs
outdoor_pois array of objects
List of outdoor points of interest. More details in Outdoor POIs
events array of objects
List of events. More details in Events
paths object
Navigation graph. More details in Paths
Sample response
[
  {
    "id": 411,
    "user_uuid": "8a017979-8983-42e1-96a2-4e02688ea6da",
    "name": "Situm Headquarters",
    "description": "EDIFICIO EMPRENDIA, CAMPUS VIDA. PLANTA -1, 15782\r\nSANTIAGO DE COMPOSTELA",
    "created_at": "2016-06-22T11:56:21.393+02:00",
    "updated_at": "2017-11-08T08:37:35.026+01:00",
    "location": {
      "lat": 42.8723481628653,
      "lng": -8.56325675585026
    },
    "dimensions": {
      "width": 75.1651861480777,
      "length": 44.9757882118544
    },
    "corners": [
      {
        "lat": 42.872208380569,
        "lng": -8.56275430127425
      },
      {
        "lat": 42.8720897456801,
        "lng": -8.56366235001292
      },
      {
        "lat": 42.8724879448448,
        "lng": -8.56375921042627
      },
      {
        "lat": 42.8726065789683,
        "lng": -8.5628511616876
      }
    ],
    "rotation": -3.31800773549028,
    "custom_fields": [
      {
        "key": "year",
        "value": "2007"
      }
    ],
    "picture_url": null,
    "picture_thumb_url": null,
    "server_url": null,
    "calibration_model": null,
    "info": null
  },
  {
    "id": 630,
    "user_id": 271,
    "name": "Citius",
    "description": null,
    "created_at": "2016-09-16T09:44:09.851+02:00",
    "updated_at": "2016-09-16T09:44:57.616+02:00",
    "location": {
      "lat": 42.8733026240237,
      "lng": -8.55737127363682
    },
    "dimensions": {
      "width": 49.6553182591981,
      "length": 21.8051834147098
    },
    "corners": [
      {
        "lat": 42.8733646501201,
        "lng": -8.55769308216134
      },
      {
        "lat": 42.8734342969238,
        "lng": -8.55709119761082
      },
      {
        "lat": 42.873240597865,
        "lng": -8.5570494651123
      },
      {
        "lat": 42.8731709508428,
        "lng": -8.55765134966282
      }
    ],
    "rotation": -0.156601877040877,
    "picture_url": null,
    "picture_thumb_url": null,
    "server_url": null,
    "calibration_model": null,
    "info": null
  }
]

List of all buildings

Retrieves the basic information of a building, including: name, description, picture, corners and rotation in radians.
Parameters
X-API-EMAIL required
The email of the user
X-API-KEY required
The API key of the user
Returns
Returns an array of building objects.
Error Status Codes
Request url
https://dashboard.situm.es/api/v1/buildings
*Deprecated: https://dashboard.situm.es/api/v1/projects (supported until SDK 4.0)
Curl
curl -H 'Content-Type: application/json' -H 'X-API-EMAIL: user@example.com' -H 'X-API-KEY: T9NP2lzk+jSI/Oi5DG6ODk57O0pZXdx4' "https://dashboard.situm.es/api/v1/buildings"
Response body
[
  {
    "id": 411,
    "user_uuid": "8a017979-8983-42e1-96a2-4e02688ea6da",
    "name": "Situm Headquarters",
    "description": "EDIFICIO EMPRENDIA, CAMPUS VIDA. PLANTA -1, 15782\r\nSANTIAGO DE COMPOSTELA",
    "created_at": "2016-06-22T11:56:21.393+02:00",
    "updated_at": "2017-11-08T08:37:35.026+01:00",
    "location": {
      "lat": 42.8723481628653,
      "lng": -8.56325675585026
    },
    "dimensions": {
      "width": 75.1651861480777,
      "length": 44.9757882118544
    },
    "corners": [
      {
        "lat": 42.872208380569,
        "lng": -8.56275430127425
      },
      {
        "lat": 42.8720897456801,
        "lng": -8.56366235001292
      },
      {
        "lat": 42.8724879448448,
        "lng": -8.56375921042627
      },
      {
        "lat": 42.8726065789683,
        "lng": -8.5628511616876
      }
    ],
    "rotation": -3.31800773549028,
    "custom_fields": [
      {
        "key": "year",
        "value": "2007"
      }
    ],
    "picture_url": null,
    "picture_thumb_url": null,
    "server_url": null,
    "calibration_model": null,
    "info": null
  },
  {
    "id": 630,
    "user_id": 271,
    "name": "Citius",
    "description": null,
    "created_at": "2016-09-16T09:44:09.851+02:00",
    "updated_at": "2016-09-16T09:44:57.616+02:00",
    "location": {
      "lat": 42.8733026240237,
      "lng": -8.55737127363682
    },
    "dimensions": {
      "width": 49.6553182591981,
      "length": 21.8051834147098
    },
    "corners": [
      {
        "lat": 42.8733646501201,
        "lng": -8.55769308216134
      },
      {
        "lat": 42.8734342969238,
        "lng": -8.55709119761082
      },
      {
        "lat": 42.873240597865,
        "lng": -8.5570494651123
      },
      {
        "lat": 42.8731709508428,
        "lng": -8.55765134966282
      }
    ],
    "rotation": -0.156601877040877,
    "picture_url": null,
    "picture_thumb_url": null,
    "server_url": null,
    "calibration_model": null,
    "info": null
  }
]

Details of a building

This method is an aggregation of all the information of a certain building, including: basic building information, floors, paths, events, indoor POIs and outdoor POIs. This information can be retrieved consulting each resource individually.
Parameters
X-API-EMAIL required
The email of the user
X-API-KEY required
The API key of the user
id required path param
Building identifier (retrieve all your buildings to know their identifiers)
Returns
Returns the building object.
Error Status Codes
Request url
https://dashboard.situm.es/api/v1/buildings/:id
*Deprecated: https://dashboard.situm.es/api/v1/projects/:id (supported until SDK 4.0)
Curl
curl -H 'Content-Type: application/json' -H 'X-API-EMAIL: user@example.com' -H 'X-API-KEY: T9NP2lzk+jSI/Oi5DG6ODk57O0pZXdx4' "https://dashboard.situm.es/api/v1/buildings/:id"
Response body
{
  "id": 411,
  "user_uuid": "8a017979-8983-42e1-96a2-4e02688ea6da",
  "name": "Situm Headquarters",
  "description": "EDIFICIO EMPRENDIA, CAMPUS VIDA. PLANTA -1, 15782\r\nSANTIAGO DE COMPOSTELA",
  "created_at": "2016-06-22T11:56:21.393+02:00",
  "updated_at": "2017-11-08T08:37:35.026+01:00",
  "location": {
    "lat": 42.8723481628653,
    "lng": -8.56325675585026
  },
  "dimensions": {
    "width": 75.1651861480777,
    "length": 44.9757882118544
  },
  "corners": [
    {
      "lat": 42.872208380569,
      "lng": -8.56275430127425
    },
    {
      "lat": 42.8720897456801,
      "lng": -8.56366235001292
    },
    {
      "lat": 42.8724879448448,
      "lng": -8.56375921042627
    },
    {
      "lat": 42.8726065789683,
      "lng": -8.5628511616876
    }
  ],
  "rotation": -3.31800773549028,
  "custom_fields": [
    {
      "key": "year",
      "value": "2007"
    }
  ],
  "picture_url": null,
  "picture_thumb_url": null,
  "server_url": null,
  "calibration_model": null,
  "info": null,
  "floors": [
    {
      "id": 746,
      "building_id": 411,
      "project_id": 411,
      "level": 0,
      "level_height": 5,
      "created_at": "2016-06-22T11:58:02.172+02:00",
      "updated_at": "2016-10-27T18:25:31.836+02:00",
      "maps": {
        "scale": 16.816295745079135,
        "map_url": "https://dashboard.situm.es/uploads/situm/floor/map/746/478ee088-96f7-4a5f-a2a4-074c6893c346.png"
      }
    },
    {
      "id": 747,
      "building_id": 411,
      "project_id": 411,
      "level": 1,
      "level_height": 20,
      "created_at": "2016-06-22T12:00:27.595+02:00",
      "updated_at": "2016-10-27T18:25:31.838+02:00",
      "maps": {
        "scale": 16.816295745079135,
        "map_url": "https://dashboard.situm.es/uploads/situm/floor/map/747/3b886f7c-aebc-4571-a0c0-f3d00ff0ea7c.png"
      }
    },
    {
      "id": 748,
      "building_id": 411,
      "project_id": 411,
      "level": 2,
      "level_height": 35,
      "created_at": "2016-06-22T12:00:37.751+02:00",
      "updated_at": "2016-10-27T18:25:31.841+02:00",
      "maps": {
        "scale": 16.816295745079135,
        "map_url": "https://dashboard.situm.es/uploads/situm/floor/map/748/23d6eada-95e7-4eee-a83f-3c01cf07a9f1.png"
      }
    }
  ],
  "indoor_pois": [
    {
      "id": 1502,
      "building_id": 411,
      "name": "Toilet",
      "created_at": "2016-06-27T12:18:04.380+02:00",
      "updated_at": "2016-11-10T16:15:44.819+01:00",
      "category_id": 148,
      "info": "",
      "position": {
        "floor_id": 748,
        "radius": 5,
        "georeferences": {
          "lat": 42.8722209970816,
          "lng": -8.56323592364788
        },
        "cartesians": {
          "x": 38.3861097627922,
          "y": 36.6942448568666
        }
      },
      "custom_fields": [],
    },
    {
      "id": 1501,
      "building_id": 411,
      "name": "Office",
      "created_at": "2016-06-27T12:17:48.716+02:00",
      "updated_at": "2016-11-10T16:15:44.814+01:00",
      "category_id": 148,
      "info": "<p>Office information</p>",
      "position": {
        "floor_id": 748,
        "radius": 5,
        "georeferences": {
          "lat": 42.8724210085808,
          "lng": -8.5628966242075
        },
        "cartesians": {
          "x": 7.19288947420488,
          "y": 19.6853868542679
        }
      },
      "custom_fields": [
        {
          "key": "active",
          "value": "false"
        }
      ],
    },
    {
      "id": 1503,
      "building_id": 411,
      "name": "Kitchen",
      "created_at": "2016-06-27T12:21:50.872+02:00",
      "updated_at": "2016-11-10T16:15:44.824+01:00",
      "category_id": 148,
      "info": "",
      "position": {
        "floor_id": 747,
        "radius": 5,
        "georeferences": {
          "lat": 42.8721875798637,
          "lng": -8.56322787702084
        },
        "cartesians": {
          "x": 38.3903468034698,
          "y": 40.4643423330997
        }
      },
      "custom_fields": [],
    }
  ],
  "outdoor_pois": [],
  "events": [
    {
      "id": 149,
      "building_id": 411,
      "project_id": 411,
      "name": "Welcome!",
      "created_at": "2016-06-27T12:23:44.784+02:00",
      "updated_at": "2016-06-27T12:29:00.838+02:00",
      "url": null,
      "info": "<p><br></p><p style=\"text-align: center;\"><img alt=\"Image title\" class=\"fr-image-dropped fr-fin fr-dib\" src=\"http://dashboard.situm.es/uploads/situm/image/attachment/268/8adaebef-16e0-4ece-a71d-dcf7851a3f2f.png\" width=\"300\"></p><p><br></p><p style=\"text-align: center;\">Welcome to the Situm&nbsp;Headquarters</p><p style=\"text-align: center;\"><a href=\"http://www.situmtechnologies.com\" rel=\"nofollow\" target=\"_blank\">http://www.situmtechnologies.com</a></p><p><br></p>",
      "info_unsafe": "<p><br></p><p style=\"text-align: center;\"><img alt=\"Image title\" class=\"fr-image-dropped fr-fin fr-dib\" src=\"http://dashboard.situm.es/uploads/situm/image/attachment/268/8adaebef-16e0-4ece-a71d-dcf7851a3f2f.png\" width=\"300\"></p><p><br></p><p style=\"text-align: center;\">Welcome to the Situm&nbsp;Headquarters</p><p style=\"text-align: center;\"><a href=\"http://www.situmtechnologies.com\" rel=\"nofollow\" target=\"_blank\">http://www.situmtechnologies.com</a></p><p><br></p>",
      "position": {
        "floor_id": 746,
        "radius": 1.83146813717595,
        "georeferences": {
          "lat": 42.8724229742925,
          "lng": -8.56313265860081
        },
        "cartesians": {
          "x": 26.1414860209916,
          "y": 16.0856386282627
        }
      },
      "custom_fields": [],
      "conversion_area": {
        "floor_id": 748,
        "radius": 2.74165750462968,
        "georeferences": {
          "lat": 42.8724165857291,
          "lng": -8.5628966242075
        },
        "cartesians": {
          "x": 7.27911948967657,
          "y": 7.27911948967657
        }
      }
    }
  ],
  "paths": {
    "nodes": [
      {
        "id": 1,
        "floor_id": 746,
        "x": 27.086,
        "y": 15.141
      },
      {
        "id": 2,
        "floor_id": 746,
        "x": 24.826,
        "y": 17.762
      },
      {
        "id": 3,
        "floor_id": 746,
        "x": 26.555,
        "y": 25.273
      },
      {
        "id": 4,
        "floor_id": 746,
        "x": 39.486,
        "y": 30.065
      },
      {
        "id": 5,
        "floor_id": 746,
        "x": 34.508,
        "y": 33.67
      },
      {
        "id": 6,
        "floor_id": 748,
        "x": 37.574,
        "y": 31.515
      },
      {
        "id": 7,
        "floor_id": 748,
        "x": 39.229,
        "y": 29.557
      },
      {
        "id": 8,
        "floor_id": 748,
        "x": 28.954,
        "y": 25.621
      },
      {
        "id": 9,
        "floor_id": 748,
        "x": 5.654,
        "y": 25.727
      },
      {
        "id": 10,
        "floor_id": 748,
        "x": 5.883,
        "y": 20.141
      },
      {
        "id": 11,
        "floor_id": 747,
        "x": 36.94,
        "y": 32.017
      },
      {
        "id": 12,
        "floor_id": 747,
        "x": 39.35,
        "y": 29.923
      },
      {
        "id": 13,
        "floor_id": 747,
        "x": 44.614,
        "y": 37.913
      },
      {
        "id": 14,
        "floor_id": 747,
        "x": 38.586,
        "y": 41.871
      }
    ],
    "links": [
      {
        "source": 1,
        "target": 2,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 2,
        "target": 3,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 3,
        "target": 4,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 4,
        "target": 5,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 5,
        "target": 6,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 6,
        "target": 7,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 7,
        "target": 8,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 8,
        "target": 9,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 9,
        "target": 10,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 6,
        "target": 11,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 5,
        "target": 11,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 11,
        "target": 12,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 12,
        "target": 13,
        "origin": "both",
        "accessible": true
      },
      {
        "source": 13,
        "target": 14,
        "origin": "both",
        "accessible": true
      }
    ]
  }
}