Retrieves population density information in a specified area
Retrieves population density estimation together with the estimation range related for a time slot for a given area (described as a polygon) as a data set consisting of a sequence of equally-sized objects covering the input polygon area.
Body ParametersJSON
End date time. It must follow RFC 3339 and must have time zone. Recommended format is yyyy-MM-dd’T’HH:mm:ss.SSSZ (i.e. which allows 2023-07-03T14:27:08.312+02:00 or 2023-07-03T12:27:08.312Z) The maximum endTime allowed is 3 months from the time of the request.
Start date time. It must follow RFC 3339 and must have time zone. Recommended format is yyyy-MM-dd’T’HH:mm:ss.SSSZ
Precision required of response cells. Precision defines a geohash level and corresponds to the length of the geohash for each cell. More information at Geohash system” If not included the default precision level 7 is used by default. In case of using a not supported level by the MNO, the API returns the error response POPULATION_DENSITY_DATA.UNSUPPORTED_PRECISION.
Retrieves population density information in a specified area
curl https://api.example.com/camara/populationdensitydata/retrieve \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer $CAMARA_BEARER_TOKEN" \
-d '{
"area": {
"areaType": "POLYGON"
},
"endTime": "2024-04-23T14:44:18.165Z",
"startTime": "2024-04-23T14:44:18.165Z",
"sink": "https://endpoint.example.com/sink"
}'{
"status": "SUPPORTED_AREA",
"timedPopulationDensityData": [
{
"startTime": "2024-01-03T10:00:00Z",
"endTime": "2024-01-03T11:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 150,
"minPplDensity": 30,
"pplDensity": 60
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 40,
"pplDensity": 90
},
{
"geohash": "ezdqemu",
"dataType": "LOW_DENSITY"
}
]
},
{
"startTime": "2024-01-03T11:00:00Z",
"endTime": "2024-01-03T12:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 30,
"pplDensity": 70
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
},
{
"geohash": "ezdqemu",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
}
]
}
]
}{
"status": "AREA_NOT_SUPPORTED",
"timedPopulationDensityData": []
}{
"status": "PART_OF_AREA_NOT_SUPPORTED",
"timedPopulationDensityData": [
{
"startTime": "2024-01-03T10:00:00Z",
"endTime": "2024-01-03T11:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 150,
"minPplDensity": 30,
"pplDensity": 60
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 40,
"pplDensity": 90
},
{
"geohash": "ezdqemu",
"dataType": "NO_DATA"
}
]
},
{
"startTime": "2024-01-03T11:00:00Z",
"endTime": "2024-01-03T12:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 30,
"pplDensity": 70
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
},
{
"geohash": "ezdqemu",
"dataType": "NO_DATA"
}
]
}
]
}{
"status": 400,
"code": "INVALID_ARGUMENT",
"message": "Invalid input"
}{
"status": 400,
"code": "INVALID_CREDENTIAL",
"message": "Only Access token is supported"
}{
"status": 400,
"code": "INVALID_TOKEN",
"message": "Only bearer token is supported"
}{
"status": 400,
"code": "INVALID_SINK",
"message": "sink not valid for the specified protocol"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_AREA",
"message": "The area is not a polygon shape or has an arbitrary complexity"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MAX_STARTTIME_EXCEEDED",
"message": "Indicated startTime is greater than the maximum allowed"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MIN_STARTTIME_EXCEEDED",
"message": "Indicated startTime is earlier than the minimum allowed"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_END_TIME",
"message": "Indicated endDate is earlier than the startTime"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MAX_TIME_PERIOD_EXCEEDED",
"message": "Indicated time period is greater than the maximum allowed (More than maximum hours between startTime and endTime)"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_TIME_PERIOD",
"message": "Indicated time period is partially in the past and partially in the future"
}{
"status": 401,
"code": "UNAUTHENTICATED",
"message": "Request not authenticated due to missing, invalid, or expired credentials."
}{
"status": 403,
"code": "PERMISSION_DENIED",
"message": "Client does not have sufficient permissions to perform this action."
}{
"status": 404,
"code": "NOT_FOUND",
"message": "The specified resource is not found."
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_REQUEST",
"message": "Indicated combination of area, time interval and precision is too big for both synchronous and asynchronous processing"
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_PRECISION",
"message": "Indicated cell precision (Geohash length) is not supported"
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_SYNC_RESPONSE",
"message": "Indicated combination of area, time interval and precision is too big for synchronous processing and asynchronous processing is not enabled"
}{
"status": 429,
"code": "QUOTA_EXCEEDED",
"message": "Out of resource quota."
}{
"status": 429,
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit reached."
}Returns Examples
{
"status": "SUPPORTED_AREA",
"timedPopulationDensityData": [
{
"startTime": "2024-01-03T10:00:00Z",
"endTime": "2024-01-03T11:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 150,
"minPplDensity": 30,
"pplDensity": 60
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 40,
"pplDensity": 90
},
{
"geohash": "ezdqemu",
"dataType": "LOW_DENSITY"
}
]
},
{
"startTime": "2024-01-03T11:00:00Z",
"endTime": "2024-01-03T12:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 30,
"pplDensity": 70
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
},
{
"geohash": "ezdqemu",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
}
]
}
]
}{
"status": "AREA_NOT_SUPPORTED",
"timedPopulationDensityData": []
}{
"status": "PART_OF_AREA_NOT_SUPPORTED",
"timedPopulationDensityData": [
{
"startTime": "2024-01-03T10:00:00Z",
"endTime": "2024-01-03T11:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 150,
"minPplDensity": 30,
"pplDensity": 60
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 40,
"pplDensity": 90
},
{
"geohash": "ezdqemu",
"dataType": "NO_DATA"
}
]
},
{
"startTime": "2024-01-03T11:00:00Z",
"endTime": "2024-01-03T12:00:00Z",
"cellPopulationDensityData": [
{
"geohash": "ezdqemf",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 100,
"minPplDensity": 30,
"pplDensity": 70
},
{
"geohash": "ezdqemg",
"dataType": "DENSITY_ESTIMATION",
"maxPplDensity": 200,
"minPplDensity": 40,
"pplDensity": 100
},
{
"geohash": "ezdqemu",
"dataType": "NO_DATA"
}
]
}
]
}{
"status": 400,
"code": "INVALID_ARGUMENT",
"message": "Invalid input"
}{
"status": 400,
"code": "INVALID_CREDENTIAL",
"message": "Only Access token is supported"
}{
"status": 400,
"code": "INVALID_TOKEN",
"message": "Only bearer token is supported"
}{
"status": 400,
"code": "INVALID_SINK",
"message": "sink not valid for the specified protocol"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_AREA",
"message": "The area is not a polygon shape or has an arbitrary complexity"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MAX_STARTTIME_EXCEEDED",
"message": "Indicated startTime is greater than the maximum allowed"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MIN_STARTTIME_EXCEEDED",
"message": "Indicated startTime is earlier than the minimum allowed"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_END_TIME",
"message": "Indicated endDate is earlier than the startTime"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.MAX_TIME_PERIOD_EXCEEDED",
"message": "Indicated time period is greater than the maximum allowed (More than maximum hours between startTime and endTime)"
}{
"status": 400,
"code": "POPULATION_DENSITY_DATA.INVALID_TIME_PERIOD",
"message": "Indicated time period is partially in the past and partially in the future"
}{
"status": 401,
"code": "UNAUTHENTICATED",
"message": "Request not authenticated due to missing, invalid, or expired credentials."
}{
"status": 403,
"code": "PERMISSION_DENIED",
"message": "Client does not have sufficient permissions to perform this action."
}{
"status": 404,
"code": "NOT_FOUND",
"message": "The specified resource is not found."
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_REQUEST",
"message": "Indicated combination of area, time interval and precision is too big for both synchronous and asynchronous processing"
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_PRECISION",
"message": "Indicated cell precision (Geohash length) is not supported"
}{
"status": 422,
"code": "POPULATION_DENSITY_DATA.UNSUPPORTED_SYNC_RESPONSE",
"message": "Indicated combination of area, time interval and precision is too big for synchronous processing and asynchronous processing is not enabled"
}{
"status": 429,
"code": "QUOTA_EXCEEDED",
"message": "Out of resource quota."
}{
"status": 429,
"code": "TOO_MANY_REQUESTS",
"message": "Rate limit reached."
}