API recipes

Requests you can copy and run. Each one returns live data from the API.

A request that selects a field with a source column carries exclude=inferred, which leaves out the values Houski worked out, unless it looks up one named property. Remove it to get those values too.

Examples

Get property details in a location

Programming language

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

Get property details by location
Filter by location and property characteristics. This pulls bedrooms, dens, bathrooms, floor area and estimated list price for Calgary houses with 3 or more bedrooms.
Request
Shell session
curl -X GET "https://api.houski.ca/properties?api_key=YOUR_API_KEY&bedroom_gte=3&city=calgary&country_abbreviation=ca&exclude=inferred&page=1&property_type_eq=House&province_abbreviation=ab&results_per_page=3&select=address,bedroom,den,bathroom_full,bathroom_half,interior_sq_m,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('https://api.houski.ca/properties');
    url.searchParams.set('api_key', 'YOUR_API_KEY');
    url.searchParams.set('bedroom_gte', '3');
    url.searchParams.set('city', 'calgary');
    url.searchParams.set('country_abbreviation', 'ca');
    url.searchParams.set('exclude', 'inferred');
    url.searchParams.set('page', '1');
    url.searchParams.set('property_type_eq', 'House');
    url.searchParams.set('province_abbreviation', 'ab');
    url.searchParams.set('results_per_page', '3');
    url.searchParams.set('select', 'address,bedroom,den,bathroom_full,bathroom_half,interior_sq_m,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": true,
  "checked_fields": [
    "bedroom",
    "bathroom_full",
    "bathroom_half",
    "interior_sq_m"
  ],
  "cost_cents": 1.8599999,
  "data": [
    {
      "address": "370 Rowley Way NW",
      "bathroom_full": 2,
      "bathroom_half": 1,
      "bedroom": 3,
      "den": 0,
      "estimate_list_price": 1652197,
      "interior_sq_m": 285.02414,
      "property_id": "132a75dd38341a25"
    },
    {
      "address": "406 Crimson Ridge Place NW",
      "bathroom_full": 3,
      "bathroom_half": 1,
      "bedroom": 3,
      "den": 1,
      "estimate_list_price": 1603968,
      "interior_sq_m": 275.2694,
      "property_id": "15f1300ff5b78de"
    },
    {
      "address": "236 Crimson Ridge Place NW",
      "bathroom_full": 2,
      "bathroom_half": 0,
      "bedroom": 3,
      "den": 0,
      "estimate_list_price": 815704,
      "interior_sq_m": 187.29253,
      "property_id": "16124d237fc5f6b5"
    }
  ],
  "error": "",
  "pagination": {
    "current_page": 1,
    "has_next_page": true,
    "has_previous_page": false,
    "page_total": 14121
  },
  "price_quote": false,
  "result_total": 42361,
  "time_ms": 31,
  "ui_info": {
    "city": "Calgary",
    "city_id": "6ec95b53075d062c",
    "city_link": "ca/ab/calgary",
    "city_slug": "calgary",
    "country": "Canada",
    "country_abbreviation": "CA",
    "country_abbreviation_id": "9ace2b6431b7f1be",
    "country_abbreviation_link": "ca",
    "country_slug": "canada",
    "province": "Alberta",
    "province_abbreviation": "AB",
    "province_abbreviation_id": "aae1f05a0f89d2c7",
    "province_abbreviation_link": "ca/ab",
    "province_slug": "alberta"
  }
}