Skip to main content
GET
Query Census 2021

Overview

Returns Census 2021 data for a building block. Figures are aggregated across every building in the block. For example, total_buildings is the number of buildings in the block, and construction_year_* fields count buildings per construction period. The response is a flat JSON object containing every field of the matched record. The exact shape depends on the requested dataset.
The query parameter is geographical_code, but the response field is named geographic_code.
Requires a valid Bearer token in the Authorization header. See Authentication to get one.

Path parameters


Lookup methods

Find the building block with exactly one of these lookup methods: Sending no lookup method, more than one, or only half of a pair (for example, lat without lon) returns a 400.

Query parameters

All query parameters are optional on their own. Each request must include the parameters for exactly one lookup method.

Response

Returns a flat JSON object. Every field of the matched Census 2021 record is included. The exact fields depend on the requested dataset.

Example requests

Example response

All three example requests point to the same building block, so they return the same response.

Error responses

Example 400 response:

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

dataset
enum<string>
required

Census 2021 dataset to query. Currently only building_and_characteristics is supported.

Available options:
building_and_characteristics

Query Parameters

geographical_code
string

Geographical code identifying the area (e.g. quarter/village code). Use together with building_block.

building_block
string

Building block number within the geographical area. Use together with geographical_code.

lat
number

Latitude of the location. Use together with lon.

lon
number

Longitude of the location. Use together with lat.

kaek
string

KAEK (cadastral) code of a parcel. Use on its own.

Response

Every field of the matched record is returned as a flat JSON object. Response shape depends on the requested dataset.

The response is of type object.