API recipes

Practical examples for using the Houski API.

Examples

Find areas with poor broadband coverage

Programming language

Select the programming language you want to display the code examples in.

Find areas with poor broadband coverage
Internet score is derived from public broadband coverage data. Score below 5 means underserved - ideal for satellite ISP marketing (Starlink, Xplore), fixed-wireless expansion, and rural connectivity grants.
Request
Shell session
curl -X GET "http://127.0.0.1:8080/properties?api_key=YOUR_API_KEY&country_abbreviation=ca&page=1&property_type_in=House,Townhouse&province_abbreviation=sk&results_per_page=5&score_internet_lt=5&select=address,city,score_internet,demographic_municipal_population_density_sq_km,estimate_list_price"
TypeScript code
const houski_recipe_data = async (): Promise<PropertiesResponse> => {

    // You must copy the PropertiesResponse type declarations from the 
    // Houski API documentation to strongly type the response

    const url = new URL('http://127.0.0.1:8080/properties');
    url.searchParams.set('api_key', 'YOUR_API_KEY');
    url.searchParams.set('country_abbreviation', 'ca');
    url.searchParams.set('page', '1');
    url.searchParams.set('property_type_in', 'House,Townhouse');
    url.searchParams.set('province_abbreviation', 'sk');
    url.searchParams.set('results_per_page', '5');
    url.searchParams.set('score_internet_lt', '5');
    url.searchParams.set('select', 'address,city,score_internet,demographic_municipal_population_density_sq_km,estimate_list_price');

    const response = await fetch(url);
    const data = await response.json();

    return data;
}

(async () => {
let data: PropertiesResponse = await houski_recipe_data();

// Log the response
console.log(data);
})();
Response
JSON
{
  "cache_hit": false,
  "cost_cents": 1.6499998569488523,
  "data": [
    {
      "address": "Lot 11 Lake Rose Meadow Drive",
      "city": "Loon Lake No. 561",
      "demographic_municipal_population_density_sq_km": 0.20000000298023224,
      "estimate_list_price": 173212,
      "property_id": "100ca5fcf70cbe86",
      "score_internet": 2
    },
    {
      "address": "1447 Lakeview Drive",
      "city": "Mervin No. 499",
      "demographic_municipal_population_density_sq_km": 3.700000047683716,
      "estimate_list_price": 513424,
      "property_id": "100e66195a81a376",
      "score_internet": 3
    },
    {
      "address": "46 Airport Drive",
      "city": "Candle Lake",
      "demographic_municipal_population_density_sq_km": 18.399999618530273,
      "estimate_list_price": 176815,
      "property_id": "101923963eebbfa5",
      "score_internet": 4
    },
    {
      "address": "NW 31-29-25W3 Plan 101530864 Parcel 145597292",
      "city": "St. Andrews No. 287",
      "estimate_list_price": 295387,
      "property_id": "101b8e699fcae8fd",
      "score_internet": 4
    },
    {
      "address": "76 Mulberry Road",
      "city": "Blucher No. 343",
      "demographic_municipal_population_density_sq_km": 57.20000076293945,
      "estimate_list_price": 191643,
      "property_id": "101e64e45113c818",
      "score_internet": 4
    }
  ],
  "error": "",
  "pagination": {
    "current_page": 1,
    "has_next_page": true,
    "has_previous_page": false,
    "page_total": 1627
  },
  "price_quote": false,
  "result_total": 8135,
  "time_ms": 105,
  "ui_info": {
    "country": "Canada",
    "country_abbreviation": "CA",
    "country_abbreviation_id": "9ace2b6431b7f1be",
    "country_abbreviation_link": "ca",
    "country_slug": "canada",
    "province": "Saskatchewan",
    "province_abbreviation": "SK",
    "province_abbreviation_id": "9e918fc836441859",
    "province_abbreviation_link": "ca/sk",
    "province_slug": "saskatchewan"
  }
}