Problem

City of Vancouver recently regulated Airbnb and other short term rentals. Hosts are required to obtain a licence from the city and platforms are required to deactivate hosts without a valid licence. Recent news reports indicate that hosts have been getting away with fake numbers as there’s currently no mechanism for platforms to validate licence number.

Solution

Automated Short Term Rental Accommodation Licence Integrity Checking System (ASTRALICS ) is a proposed application programming interface (API) intended for City of Vancouver to publish, which Airbnb can use to validate licence numbers.

Upon a host entering the licence number, Airbnb sends licence number, street number, street name, and unit number (in the case of strata units) to ASTRALICS. ASTRALICS checks the City of Vancouver licence database to see if an entry matching the request data exists in the system. If an entry is found, ASTRALICS responds with “valid”. Airbnb will accept the licence number If an entry is not found, ASTRALICS responds with “invalid”. Airbnb will reject the licence number.

Implementation

I have created a fully functional ASTRALICS prototype as 65-line Azure function in Java. It can be easily ported to other languages.

Demonstration

I have created an example licence database as follows:

LICENCENUMBER STREETNAME STREETNUMBER UNITNUMBER 555-1000 Robertson Street 2002 – 555-1001 Gregor Drive 1001 111

If you access ASTRALICS API with a valid licence number, as in the request below, you will get “valid” as the response.

https://astralics.azurewebsites.net/api/validate?licencenumber=555-1001&streetnumber=1001&streetname=Gregor%20Drive&unitnumber=111

If you access ASTRALICS API with a invalid licence, as in the request below, you will get “invalid” as the response.

https://astralics.azurewebsites.net/api/validate?licencenumber=12345&streetnumber=2002&streetname=Robertson%20Street

Source Code