0.0.2 • Published 10 months ago

wbb-ordnance-survey v0.0.2

Weekly downloads
-
License
-
Repository
-
Last release
10 months ago

Ordnance Survey

You can use this project to help identify Unique Property Reference Numbers ( UPRN ) using the 'Ordnance Survey' places API.

Blocks Provided

Provide a list of the blocks provided as part of this integration. This should be a list of block name, and its description.

Block NamePurpose
Find Address via Ordnance SurveyThe main entry point into this module. This will lookup a property based on first line of address and postcode inputs
Error OSUsed whenever there is an error from the API
OS No Address FoundProvides a default message to display when the property can not be found. This block doesn't have to be used, it can be changed using the noAddressFound configuration option as provided below.
OS Address FoundA placeholder for a successful query. As with the line above, this can be changed using the addressFound property.

Handler Names

The following handler names and their functions are available :

Handler NamePurpose
find-uprnSearches for a UPRN based on the address entered. The result of finding a property will set two variables on the conversation. These are wbb-os-uprn and wbb-os-address that will contain the UPRN value, and the full text description of the address.

Configuration Options

( Provide a list of the configuration options for each of the handlers mentioned above )

Within the function there are a number of options that can be set to configure the behaviour of the integration. The tables below show the settings that are available for each handler.

find-uprn

PropertyRequiredDescription
api_keytrueThe API key used to authenticate with the service.
root_urltrueThe base URL of the APIs to call. For example, https://api.os.uk/
firstLinetrueThe name of the field containing the first line of address from a form. For example, address1
postCodetrueThe name of the field containing the postcode for the lookup. For example, postalCode.
noAddressFoundfalseThe block ID to use in cases where the input from the user does not result in a property being found.
addressFoundfalseThe block ID to use when an address has been found.