Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
aea84da
Restored RH Response Tests from server/test/uk/gov/ons/addressIndex/s…
Felixim0 Feb 27, 2026
e3a26d6
added rh imports
Felixim0 Feb 27, 2026
78bc82d
Version bump
Felixim0 Feb 27, 2026
a6d16f5
Added RH to Highlight functions
Felixim0 Feb 27, 2026
3672684
Restored RH Components
Felixim0 Feb 27, 2026
7fec172
Restore RH uprn endpoints to paths and componenets
Felixim0 Feb 27, 2026
7efd9f5
Restored RH deffinitions to swagger
Felixim0 Feb 27, 2026
c15cee9
Added partial match to openapi deffinitions for swagger
Felixim0 Feb 27, 2026
f6293b4
Restored model responses for RH endpoints
Felixim0 Feb 27, 2026
6b39c90
Restored UPRNRH tests
Felixim0 Feb 27, 2026
819457a
Restored UPRN RH model
Felixim0 Feb 27, 2026
a01144f
Restored controllers for RH endpoints
Felixim0 Feb 27, 2026
997caff
Restored RH tests
Felixim0 Feb 27, 2026
00272ad
restored 'RH' tests, leaving EQ ones intact
Felixim0 Feb 27, 2026
5cb5257
Restored the conrollers for RH endpoints
Felixim0 Feb 27, 2026
83644e0
Restored RH endpoints from readme in api-deffinitions
Felixim0 Feb 27, 2026
7bed8dc
Restored RH readme files to the explore the API docs
Felixim0 Feb 27, 2026
5d6598e
Restored /addresses/rh/uprn/ RH endpoint into the routes file. Restor…
Felixim0 Feb 27, 2026
402f3b6
Restored /addresses/rh/postcode/ RH endpoint in the routes file. rest…
Felixim0 Feb 27, 2026
9b983c5
Restored /addresses/rh/partial RH endpoint in the routes file. Restor…
Felixim0 Feb 27, 2026
ef45d37
Removed obscure, weird characters from the end of these files. Or per…
Felixim0 Feb 27, 2026
fd6f31a
Added special characters to prevent obscure bug from occuring. See pr…
Felixim0 Feb 27, 2026
00ec49f
Special character removal
Felixim0 Feb 27, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,040 changes: 920 additions & 120 deletions api-definitions/ai-openapi.json

Large diffs are not rendered by default.

21 changes: 21 additions & 0 deletions api-definitions/explore-the-api/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,27 @@
Gets an address by UPRN (EQ version).
</td>
</tr>
<tr class="table--row">
<td class="table--cell">GET</td>
<td class="table--cell"><a href="rh/partial/readme.md">/addresses/rh/partial</a></td>
<td class="table--cell">
Search by partial address for type ahead (RH Version).
</td>
</tr>
<tr class="table--row">
<td class="table--cell">GET</td>
<td class="table--cell"><a href="rh/postcode/readme.md">/addresses/rh/postcode/{postcode}</a></td>
<td class="table--cell">
Search for an address by postcode (RH version).
</td>
</tr>
<tr class="table--row">
<td class="table--cell">GET</td>
<td class="table--cell"><a href="rh/uprn/readme.md">/addresses/rh/uprn/{uprn}</a></td>
<td class="table--cell">
Gets an address by UPRN (RH version).
</td>
</tr>

</tbody>
</table>
Expand Down
265 changes: 265 additions & 0 deletions api-definitions/explore-the-api/rh/partial/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,265 @@
<h1 class="jupiter">/addresses/rh/partial</h1>



<p>Search by partial address (for type ahead). RH version</p>

<h2>Request</h2>

<p><code>GET /addresses/rh/partial</code></p>



<h3>Query parameters</h3>

<table class="table">
<thead class="table--head">
<th scope="col" class="table--header--cell">Parameter name</th>
<th scope="col" class="table--header--cell">Value</th>
<th scope="col" class="table--header--cell">Description</th>
<th scope="col" class="table--header--cell">Additional</th>
</thead>
<tbody>
<tr class="table--row">
<td class="table--cell">input</td>
<td class="table--cell">string</td>
<td class="table--cell">Specifies the address input.</td>
<td class="table--cell">
Required
</td>
</tr>
<tr class="table--row">
<td class="table--cell">fallback</td>
<td class="table--cell">string</td>
<td class="table--cell">Specifies whether a slow fallback query is used in the event of the main query returning no results.</td>
<td class="table--cell">
Optional
<br>Default: False
</td>
</tr>
<tr class="table--row">
<td class="table--cell">offset</td>
<td class="table--cell">string</td>
<td class="table--cell">Specifies the offset from zero, used for pagination.</td>
<td class="table--cell">
Optional
<br>Default: 0
<br>Maximum: 250
</td>
</tr>
<tr class="table--row">
<td class="table--cell">limit</td>
<td class="table--cell">string</td>
<td class="table--cell">Specifies the number of addresses to return.</td>
<td class="table--cell">
Optional
<br>Default: 10
<br>Maximum: 100
</td>
</tr>
<tr class="table--row">
<td class="table--cell">classificationfilter</td>
<td class="table--cell">string</td>
<td class="table--cell">Classification code filter. Can be pattern match (ZW*), exact match (RD06), multiple exact match (RD02,RD04) or a preset keyword such as residential, commercial, workplace or educational</td>
<td class="table--cell">
Optional
</td>
</tr>
<tr class="table--row">
<td class="table--cell">epoch</td>
<td class="table--cell">string</td>
<td class="table--cell">Select a specific AddressBase Epoch to search.</td>
<td class="table--cell">
Optional
</td>
</tr>
<tr class="table--row">
<td class="table--cell">favourpaf</td>
<td class="table--cell">string</td>
<td class="table--cell">paf beats nag on draw for best match</td>
<td class="table--cell">
Optional
<br>Default: True
</td>
</tr>
<tr class="table--row">
<td class="table--cell">favourwelsh</td>
<td class="table--cell">string</td>
<td class="table--cell">Welsh beats English on draw for best match</td>
<td class="table--cell">
Optional
<br>Default: False
</td>
</tr>
<tr class="table--row">
<td class="table--cell">eboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in England as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">nboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in Northern Ireland as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">sboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in Scotland as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">wboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in Wales as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">lboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in Channel Islands as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">mboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses in Isle of Man as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
<tr class="table--row">
<td class="table--cell">jboost</td>
<td class="table--cell">string</td>
<td class="table--cell">Weighting for addresses not allocated to a country as a decimal from 0 to 10</td>
<td class="table--cell">
Optional
<br>Default: 1.0
</td>
</tr>
</tr>
</tbody>
</table>


<h2>Responses</h2>


<h3>200</h3>
<p>Success. A json return of matched addresses.</p>

<h3>429</h3>
<p>Server too busy. The Address Index API is experiencing exceptional load.</p>

<h3>500</h3>
<p>Internal server error. Failed to process the request due to an internal error.</p>

<h3>400</h3>
<p>Bad request. Indicates an issue with the request. Further details are provided in the response.</p>

<h3>401</h3>
<p>Unauthorised. The API key provided with the request is invalid.</p>


<h2>CURL example</h2>

<pre><code>curl -uYOUR_APIKEY_FOLLOWED_BY_A_COLON: #API_URL#/addresses/partial</code></pre>

<h2>Sample Queries</h2>

<p><pre>corn ex</pre></p>
<p><pre>4 EX26GA</pre></p>

<h2>Sample Output</h2>



<pre><code>
{
{
"apiVersion": "1.0.0-SNAPSHOT",
"dataVersion": "NA",
"response": {
"input": "corn ex",
"addresses": [
{
"uprn": "10013049665",
"bestMatchAddress": "Corn Exchange Office, 1 George Street, Exeter, EX1 1BU",
"bestMatchAddressType": "PAF",
"censusAddressType": "NA",
"censusEstabType": "NA",
"countryCode": "E"
},
{
"uprn": "10023121714",
"bestMatchAddress": "Cornerstone Housing LTD, Cornerstone House, Western Way, Exeter, EX1 1AL",
"bestMatchAddressType": "PAF",
"censusAddressType": "NA",
"censusEstabType": "NA",
"countryCode": "E"
},
{
"uprn": "100041124274",
"bestMatchAddress": "Exeter Corn Exchange, Market Street, Exeter, EX1 1BW",
"bestMatchAddressType": "PAF",
"censusAddressType": "NA",
"censusEstabType": "NA",
"countryCode": "E"
},
{
"uprn": "10013038377",
"bestMatchAddress": "The Real Cornish Pasty CO, 11 Martins Lane, Exeter, EX1 1EY",
"bestMatchAddressType": "PAF",
"censusAddressType": "NA",
"censusEstabType": "NA",
"countryCode": "E"
},
{
"uprn": "100041124355",
"bestMatchAddress": "Devon & Cornwall Constabulary, Heavitree Road, Exeter, EX1 2LR",
"bestMatchAddressType": "PAF",
"censusAddressType": "NA",
"censusEstabType": "NA",
"countryCode": "E"
}
],
"filter": "",
"fallback": false,
"epoch": "",
"limit": 5,
"offset": 0,
"total": 161,
"maxScore": 0,
"favourpaf": true,
"favourwelsh": false,
"eboost": 1,
"nboost": 1,
"sboost": 1,
"wboost": 1
},
"status": {
"code": 200,
"message": "Ok"
},
"errors": [

]
}
</code></pre>
Loading