Get a floor
const url = 'https://example.com/v1/example/data/floors/example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/v1/example/data/floors/example \ --header 'Authorization: Bearer <token>'With Accept: application/geo+json, returns IMDF features: floors as levels, outlined by their walkable area. IMDF positions are worked out from the space’s georeference, so these need one.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The project ID of the space
The floor’s id
Responses
Section titled “Responses”The floor
A floor of the space. Floors are worked out from the scan each time the navigation mesh is generated. A floor found at about the same height as before keeps its id, title and ordinal; any others are removed or added.
object
Identifies the floor. Equal to its key in the space’s floors.
The floor’s number, counting up from 0 for the lowest. Visitors see “Floor title.
The floor’s name as visitors see it, e.g. “Ground floor”, in place of its number.
object
The text in the language given by locale. Also shown when there’s no variant for the viewer’s language.
The language value is written in, as a BCP 47 tag - a base language such as en, or a regional one such as en-GB.
Translations of value, keyed by BCP 47 language tag. A viewer sees the variant for their exact language (e.g. en-GB), then the one for its base language (e.g. en), then value.
object
The height of the floor’s walkable surface, in metres. A point belongs to the highest floor whose y is no more than 0.5m above it.
The floor’s level relative to the floor with ground-level access, which is 0: 1 is the floor above it, -1 the one below. Defaults to the floor’s position counting up from the lowest, which is right unless the space has floors below ground level.
How far the floor extends above y, in metres - up to just below the next floor. Used to decide what’s shown when viewing one floor at a time.
Example
{ "name": "0", "title": "Reception", "ordinal": 0}A GeoJSON FeatureCollection of IMDF features.
object
An IMDF feature: a GeoJSON Feature with a feature_type. Coordinates are WGS 84 longitude and latitude.
object
The feature’s id, a version 4 UUID.
The IMDF feature type, e.g. amenity.
A GeoJSON geometry, or null for features with none.
The properties IMDF defines for the feature type.
object
Example
{ "type": "FeatureCollection", "features": [ { "type": "Feature" } ]}The token is missing or invalid.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}The token has no access to this space.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}No item has this id.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}The item has no IMDF equivalent.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}An item with this id already exists or the space is being duplicated - or, for IMDF, the space has no georeference or floors (noGeoreference, noFloors) or is missing information IMDF requires (imdfIncomplete).
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}Too many requests. Retry after Retry-After seconds.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}Headers
Section titled “Headers”Seconds to wait before retrying
Something upstream failed.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}The space is moving between servers. Retry after Retry-After seconds.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}Headers
Section titled “Headers”Seconds to wait before retrying
Something upstream timed out.
object
A description of the error
A stable identifier for the kind of error
For invalidBody: what failed validation, and where
object
Example generated
{ "error": "example", "code": "example", "issues": [ {} ]}