Get Legislation
get_legislationGet metadata for one specific piece of UK legislation by type + year + number (e.g. ukpga/2010/15 = Equality Act 2010). Returns title, type, year, number, status, extent, enactment date, a long-title summary, and the full-text URL. Content is XML; fields are best-effort parsed and a raw excerpt is included.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | Yes | Document type, e.g. "ukpga". One of: ukpga (UK Public General Acts), uksi (UK Statutory Instruments), asp (Scottish Parliament Acts), anaw/asc (Wales), nia (Northern Ireland), ukla (UK Local Acts). | |
| year | Yes | Year, e.g. 2010. | |
| number | Yes | Item number within that year/type, e.g. 15. |