Search UK Street-Level Crimes
ukcrime_search_crimesSearch street-level crimes recorded in one month, or with month_from a range of up to 12 months, inside an area — a point with a 1-mile radius, a polygon, a snapped location_id from an earlier result, or a police neighbourhood — or list the crimes a force could not place on the map (area 'force_unplaced'). Returns the total, counts by category and by latest police outcome, the busiest map points, each month's total for a range, and a page of crimes, each with the persistent_id that ukcrime_get_crime_outcomes takes; for what police resolved in a month, whenever the crime was recorded, use ukcrime_search_outcomes. Locations are anonymised map points, not crime sites. data.police.uk can refuse an area holding more than about 10,000 crimes, whatever the category — then search smaller polygons.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lat | No | Latitude, WGS84 decimal degrees, for area 'point'. | |
| lng | No | Longitude, WGS84 decimal degrees, for area 'point'. | |
| area | Yes | Area to search: 'point' (lat and lng; a 1-mile radius), 'polygon' (polygon), 'location' (location_id), 'neighbourhood' (force and neighbourhood_id), or 'force_unplaced' (force alone: the crimes that force could not place on the map). An area field the chosen area does not use is rejected. | |
| force | No | Force id such as 'leicestershire', or its name such as 'Leicestershire Police' (ukcrime_list_reference topic 'forces' lists both); case-insensitive, spaces, underscores and hyphens match each other, '&' matches 'and', and a trailing 'Police', 'Police Service' or 'Constabulary' is optional. For area 'neighbourhood' (with neighbourhood_id) and 'force_unplaced' (alone), where 'btp' (British Transport Police) is also accepted. | |
| limit | No | Crimes on this page, 1–200. Default 25. | |
| month | No | Month as YYYY-MM, or the last month of the range with month_from. Omitted: the latest published month, echoed as month in the result. | |
| offset | No | Rows to skip before this page; pass next_offset from the previous result. Default 0. | |
| polygon | No | For area 'polygon': 3–2,500 vertices as { lat, lng } objects, or the string 'lat,lng:lat,lng:…'. The ring closes itself (the last vertex joins the first). [lng, lat] pairs are not accepted. | |
| category | No | Crime category slug such as 'burglary', or its display name such as 'Violence and sexual offences'; case-insensitive, and spaces, underscores and hyphens match each other ('vehicle_crime' finds 'vehicle-crime'). Omitted: every category (all-crime). ukcrime_list_reference topic 'categories' lists them. | |
| month_from | No | First month of a range, YYYY-MM, searched through month — up to 12 months, with a total for each in by_month. Omitted: month alone. | |
| location_id | No | For area 'location': location.location_id from an earlier result — one anonymised map point. | |
| neighbourhood_id | No | For area 'neighbourhood', with force: a neighbourhood id from ukcrime_list_reference topic 'neighbourhoods', or from ukcrime_find_neighbourhood for a point. Case-sensitive; only trimmed. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cap | No | Page limit applied. | |
| area | No | The area as the server searched it. | |
| error | No | Present when the call failed. Absent on success. | |
| month | No | The month searched, or the last month of the range, YYYY-MM. | |
| shown | No | Rows on this page. | |
| total | No | Crimes matched in the area over the month or range. | |
| crimes | No | This page of matched crimes: oldest month first over a range, then by category, then location_id, then id. | |
| notice | No | Defaulted month, coverage gaps, why a result is empty, and how to page on. | |
| by_month | No | Crimes matched in each month of the range, oldest first; their totals sum to total. Present only when month_from was given. | |
| category | No | The crime category searched. | |
| data_note | No | What these records can and cannot say; read it first. | |
| truncated | No | True when more rows remain after this page. | |
| by_outcome | No | Matched crimes by latest police outcome, most first; anti-social behaviour is always '(not recorded)'. | |
| month_from | No | First month of the range searched, YYYY-MM; present only when month_from was given. | |
| attribution | No | Open Government Licence attribution. | |
| by_category | No | Matched crimes by category slug, most first. | |
| next_offset | No | Pass as offset for the next page; absent on the last page. | |
| top_locations | No | Up to 10 map points holding the most matched crimes. Absent for area 'force_unplaced'. |