Skip to content

LookupResult

Gatepost\Postcode\Client\LookupResult

What the gateway knows about one postcode. A postcode that the gateway does not know is a result with valid false, not an error. Levels 2 to 5 follow NIPOST’s docs. Gatepost has seen only level 1 responses so far.

  • Postcode $postcode: The postcode that the caller asked for. The client never takes it from the response.
  • bool $valid: True when the gateway knows the postcode.
  • ?string $status: The gateway’s word for the postcode, such as valid, invalid, not_found or restricted. It stays text, so a new word is not lost. It is null when the gateway sent none.
  • int $levelRequested: The lookup level that the caller asked for, from 1 to 5.
  • int $levelReceived: The lookup level of the data in the response, from 1 to 5.
  • ?Client\AdministrativeAddress $administrativeAddress: The names of the places that hold the postcode, from level 2, or null.
  • ?string $recentHouseAddress: The most recent house address of the unit, from level 2, or null.
  • ?string $buildingUseStatus: What the building is used for, such as residential, from level 3, or null.

Unofficial. Not made or endorsed by NIPOST.