curl --request POST \
--url https://api.anysite.io/api/midland/transactions/search \
--header 'Content-Type: application/json' \
--header 'access-token: <api-key>' \
--data '
{
"count": 5000,
"timeout": 300,
"lang": "zh-hk",
"unit": "feet",
"currency": "HKD",
"min_building_age": 499,
"max_building_age": 499,
"text": "<string>",
"market_types": [],
"gains": [],
"features": [],
"property_types": [],
"is_deluxe": true,
"sort": "default",
"region_id": "<string>",
"subregion_ids": [
"<string>"
],
"district_ids": [
"<string>"
],
"sm_district_ids": [
"<string>"
],
"combined_district_ids": [
"<string>"
],
"int_district_ids": [
"<string>"
],
"int_sm_district_ids": [
"<string>"
],
"estate_ids": [
"<string>"
],
"phase_ids": [
"<string>"
],
"building_ids": [
"<string>"
],
"street_ids": [
"<string>"
],
"house_street_ids": [
"<string>"
],
"unit_ids": [
"<string>"
],
"mtr_ids": [
"<string>"
],
"walking_duration": 2,
"school_net": "<string>",
"university_ids": [],
"min_price": 1,
"max_price": 1,
"min_net_area": 1,
"max_net_area": 1,
"min_net_ft_price": 1,
"max_net_ft_price": 1,
"min_holding_period": 1,
"max_holding_period": 1,
"bedrooms": [],
"floor_levels": []
}
'import requests
url = "https://api.anysite.io/api/midland/transactions/search"
payload = {
"count": 5000,
"timeout": 300,
"lang": "zh-hk",
"unit": "feet",
"currency": "HKD",
"min_building_age": 499,
"max_building_age": 499,
"text": "<string>",
"market_types": [],
"gains": [],
"features": [],
"property_types": [],
"is_deluxe": True,
"sort": "default",
"region_id": "<string>",
"subregion_ids": ["<string>"],
"district_ids": ["<string>"],
"sm_district_ids": ["<string>"],
"combined_district_ids": ["<string>"],
"int_district_ids": ["<string>"],
"int_sm_district_ids": ["<string>"],
"estate_ids": ["<string>"],
"phase_ids": ["<string>"],
"building_ids": ["<string>"],
"street_ids": ["<string>"],
"house_street_ids": ["<string>"],
"unit_ids": ["<string>"],
"mtr_ids": ["<string>"],
"walking_duration": 2,
"school_net": "<string>",
"university_ids": [],
"min_price": 1,
"max_price": 1,
"min_net_area": 1,
"max_net_area": 1,
"min_net_ft_price": 1,
"max_net_ft_price": 1,
"min_holding_period": 1,
"max_holding_period": 1,
"bedrooms": [],
"floor_levels": []
}
headers = {
"access-token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
count: 5000,
timeout: 300,
lang: 'zh-hk',
unit: 'feet',
currency: 'HKD',
min_building_age: 499,
max_building_age: 499,
text: '<string>',
market_types: [],
gains: [],
features: [],
property_types: [],
is_deluxe: true,
sort: 'default',
region_id: '<string>',
subregion_ids: ['<string>'],
district_ids: ['<string>'],
sm_district_ids: ['<string>'],
combined_district_ids: ['<string>'],
int_district_ids: ['<string>'],
int_sm_district_ids: ['<string>'],
estate_ids: ['<string>'],
phase_ids: ['<string>'],
building_ids: ['<string>'],
street_ids: ['<string>'],
house_street_ids: ['<string>'],
unit_ids: ['<string>'],
mtr_ids: ['<string>'],
walking_duration: 2,
school_net: '<string>',
university_ids: [],
min_price: 1,
max_price: 1,
min_net_area: 1,
max_net_area: 1,
min_net_ft_price: 1,
max_net_ft_price: 1,
min_holding_period: 1,
max_holding_period: 1,
bedrooms: [],
floor_levels: []
})
};
fetch('https://api.anysite.io/api/midland/transactions/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.anysite.io/api/midland/transactions/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'count' => 5000,
'timeout' => 300,
'lang' => 'zh-hk',
'unit' => 'feet',
'currency' => 'HKD',
'min_building_age' => 499,
'max_building_age' => 499,
'text' => '<string>',
'market_types' => [
],
'gains' => [
],
'features' => [
],
'property_types' => [
],
'is_deluxe' => true,
'sort' => 'default',
'region_id' => '<string>',
'subregion_ids' => [
'<string>'
],
'district_ids' => [
'<string>'
],
'sm_district_ids' => [
'<string>'
],
'combined_district_ids' => [
'<string>'
],
'int_district_ids' => [
'<string>'
],
'int_sm_district_ids' => [
'<string>'
],
'estate_ids' => [
'<string>'
],
'phase_ids' => [
'<string>'
],
'building_ids' => [
'<string>'
],
'street_ids' => [
'<string>'
],
'house_street_ids' => [
'<string>'
],
'unit_ids' => [
'<string>'
],
'mtr_ids' => [
'<string>'
],
'walking_duration' => 2,
'school_net' => '<string>',
'university_ids' => [
],
'min_price' => 1,
'max_price' => 1,
'min_net_area' => 1,
'max_net_area' => 1,
'min_net_ft_price' => 1,
'max_net_ft_price' => 1,
'min_holding_period' => 1,
'max_holding_period' => 1,
'bedrooms' => [
],
'floor_levels' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"access-token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.anysite.io/api/midland/transactions/search"
payload := strings.NewReader("{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("access-token", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.anysite.io/api/midland/transactions/search")
.header("access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anysite.io/api/midland/transactions/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}"
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"@type": "MidlandTransactionCard",
"url": "<string>",
"transaction_type": "<string>",
"transaction_at": 123,
"market_type": "<string>",
"source": "<string>",
"original_source": "<string>",
"tags": [],
"price": 123,
"price_per_net_area": 123,
"area": 123,
"net_area": 123,
"previous_price": 123,
"previous_transaction_at": 123,
"gain_percent": 123,
"holding_period_years": 123,
"bedroom_count": 123,
"sitting_room_count": 123,
"floor": "<string>",
"floor_level": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"flat": "<string>",
"is_premium_paid": true,
"deal_type": "<string>",
"geo": {
"@type": "MidlandGeo",
"region": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"subregion": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"sm_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"combined_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"int_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"int_sm_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"lux_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
}
},
"estate": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"phase": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"building": {
"@type": "MidlandBuilding",
"id": "<string>",
"name": "<string>",
"address": "<string>",
"first_op_at": 123,
"floor_count": 123,
"building_type": "<string>",
"latitude": 123,
"longitude": 123,
"streetview_latitude": 123,
"streetview_longitude": 123,
"streetview_angle": 123
},
"features": [],
"floor_plans": [],
"image": "<string>",
"location": {
"@type": "MidlandLocation",
"latitude": 123,
"longitude": 123
},
"listings_url": "<string>",
"updated_at": 123
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}/midland/transactions/search
Search Midland Realty’s Hong Kong property deal archive — Land Registry records plus Midland’s own transactions, covering the full history rather than a recent window. Filters cover sale or rental deals, free text, recency window, primary or secondary market, resale at a profit or a loss, unit features, record source, ownership class, the luxury segment, the eight-level geography, estate, phase, building, street and unit ids, MTR station with walking time, primary school net, universities, price, saleable area, price per area unit, building age, holding period, bedrooms, floor band and ordering. Each deal carries the transacted price and price per saleable area, areas, the previous deal price and date with the gain and holding period, room counts, floor and flat, the estate / phase / building, unit features, floor plans, coordinates and the deal record source.
Price: 1 credit
curl --request POST \
--url https://api.anysite.io/api/midland/transactions/search \
--header 'Content-Type: application/json' \
--header 'access-token: <api-key>' \
--data '
{
"count": 5000,
"timeout": 300,
"lang": "zh-hk",
"unit": "feet",
"currency": "HKD",
"min_building_age": 499,
"max_building_age": 499,
"text": "<string>",
"market_types": [],
"gains": [],
"features": [],
"property_types": [],
"is_deluxe": true,
"sort": "default",
"region_id": "<string>",
"subregion_ids": [
"<string>"
],
"district_ids": [
"<string>"
],
"sm_district_ids": [
"<string>"
],
"combined_district_ids": [
"<string>"
],
"int_district_ids": [
"<string>"
],
"int_sm_district_ids": [
"<string>"
],
"estate_ids": [
"<string>"
],
"phase_ids": [
"<string>"
],
"building_ids": [
"<string>"
],
"street_ids": [
"<string>"
],
"house_street_ids": [
"<string>"
],
"unit_ids": [
"<string>"
],
"mtr_ids": [
"<string>"
],
"walking_duration": 2,
"school_net": "<string>",
"university_ids": [],
"min_price": 1,
"max_price": 1,
"min_net_area": 1,
"max_net_area": 1,
"min_net_ft_price": 1,
"max_net_ft_price": 1,
"min_holding_period": 1,
"max_holding_period": 1,
"bedrooms": [],
"floor_levels": []
}
'import requests
url = "https://api.anysite.io/api/midland/transactions/search"
payload = {
"count": 5000,
"timeout": 300,
"lang": "zh-hk",
"unit": "feet",
"currency": "HKD",
"min_building_age": 499,
"max_building_age": 499,
"text": "<string>",
"market_types": [],
"gains": [],
"features": [],
"property_types": [],
"is_deluxe": True,
"sort": "default",
"region_id": "<string>",
"subregion_ids": ["<string>"],
"district_ids": ["<string>"],
"sm_district_ids": ["<string>"],
"combined_district_ids": ["<string>"],
"int_district_ids": ["<string>"],
"int_sm_district_ids": ["<string>"],
"estate_ids": ["<string>"],
"phase_ids": ["<string>"],
"building_ids": ["<string>"],
"street_ids": ["<string>"],
"house_street_ids": ["<string>"],
"unit_ids": ["<string>"],
"mtr_ids": ["<string>"],
"walking_duration": 2,
"school_net": "<string>",
"university_ids": [],
"min_price": 1,
"max_price": 1,
"min_net_area": 1,
"max_net_area": 1,
"min_net_ft_price": 1,
"max_net_ft_price": 1,
"min_holding_period": 1,
"max_holding_period": 1,
"bedrooms": [],
"floor_levels": []
}
headers = {
"access-token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
count: 5000,
timeout: 300,
lang: 'zh-hk',
unit: 'feet',
currency: 'HKD',
min_building_age: 499,
max_building_age: 499,
text: '<string>',
market_types: [],
gains: [],
features: [],
property_types: [],
is_deluxe: true,
sort: 'default',
region_id: '<string>',
subregion_ids: ['<string>'],
district_ids: ['<string>'],
sm_district_ids: ['<string>'],
combined_district_ids: ['<string>'],
int_district_ids: ['<string>'],
int_sm_district_ids: ['<string>'],
estate_ids: ['<string>'],
phase_ids: ['<string>'],
building_ids: ['<string>'],
street_ids: ['<string>'],
house_street_ids: ['<string>'],
unit_ids: ['<string>'],
mtr_ids: ['<string>'],
walking_duration: 2,
school_net: '<string>',
university_ids: [],
min_price: 1,
max_price: 1,
min_net_area: 1,
max_net_area: 1,
min_net_ft_price: 1,
max_net_ft_price: 1,
min_holding_period: 1,
max_holding_period: 1,
bedrooms: [],
floor_levels: []
})
};
fetch('https://api.anysite.io/api/midland/transactions/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.anysite.io/api/midland/transactions/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'count' => 5000,
'timeout' => 300,
'lang' => 'zh-hk',
'unit' => 'feet',
'currency' => 'HKD',
'min_building_age' => 499,
'max_building_age' => 499,
'text' => '<string>',
'market_types' => [
],
'gains' => [
],
'features' => [
],
'property_types' => [
],
'is_deluxe' => true,
'sort' => 'default',
'region_id' => '<string>',
'subregion_ids' => [
'<string>'
],
'district_ids' => [
'<string>'
],
'sm_district_ids' => [
'<string>'
],
'combined_district_ids' => [
'<string>'
],
'int_district_ids' => [
'<string>'
],
'int_sm_district_ids' => [
'<string>'
],
'estate_ids' => [
'<string>'
],
'phase_ids' => [
'<string>'
],
'building_ids' => [
'<string>'
],
'street_ids' => [
'<string>'
],
'house_street_ids' => [
'<string>'
],
'unit_ids' => [
'<string>'
],
'mtr_ids' => [
'<string>'
],
'walking_duration' => 2,
'school_net' => '<string>',
'university_ids' => [
],
'min_price' => 1,
'max_price' => 1,
'min_net_area' => 1,
'max_net_area' => 1,
'min_net_ft_price' => 1,
'max_net_ft_price' => 1,
'min_holding_period' => 1,
'max_holding_period' => 1,
'bedrooms' => [
],
'floor_levels' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"access-token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.anysite.io/api/midland/transactions/search"
payload := strings.NewReader("{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("access-token", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.anysite.io/api/midland/transactions/search")
.header("access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.anysite.io/api/midland/transactions/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"count\": 5000,\n \"timeout\": 300,\n \"lang\": \"zh-hk\",\n \"unit\": \"feet\",\n \"currency\": \"HKD\",\n \"min_building_age\": 499,\n \"max_building_age\": 499,\n \"text\": \"<string>\",\n \"market_types\": [],\n \"gains\": [],\n \"features\": [],\n \"property_types\": [],\n \"is_deluxe\": true,\n \"sort\": \"default\",\n \"region_id\": \"<string>\",\n \"subregion_ids\": [\n \"<string>\"\n ],\n \"district_ids\": [\n \"<string>\"\n ],\n \"sm_district_ids\": [\n \"<string>\"\n ],\n \"combined_district_ids\": [\n \"<string>\"\n ],\n \"int_district_ids\": [\n \"<string>\"\n ],\n \"int_sm_district_ids\": [\n \"<string>\"\n ],\n \"estate_ids\": [\n \"<string>\"\n ],\n \"phase_ids\": [\n \"<string>\"\n ],\n \"building_ids\": [\n \"<string>\"\n ],\n \"street_ids\": [\n \"<string>\"\n ],\n \"house_street_ids\": [\n \"<string>\"\n ],\n \"unit_ids\": [\n \"<string>\"\n ],\n \"mtr_ids\": [\n \"<string>\"\n ],\n \"walking_duration\": 2,\n \"school_net\": \"<string>\",\n \"university_ids\": [],\n \"min_price\": 1,\n \"max_price\": 1,\n \"min_net_area\": 1,\n \"max_net_area\": 1,\n \"min_net_ft_price\": 1,\n \"max_net_ft_price\": 1,\n \"min_holding_period\": 1,\n \"max_holding_period\": 1,\n \"bedrooms\": [],\n \"floor_levels\": []\n}"
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"@type": "MidlandTransactionCard",
"url": "<string>",
"transaction_type": "<string>",
"transaction_at": 123,
"market_type": "<string>",
"source": "<string>",
"original_source": "<string>",
"tags": [],
"price": 123,
"price_per_net_area": 123,
"area": 123,
"net_area": 123,
"previous_price": 123,
"previous_transaction_at": 123,
"gain_percent": 123,
"holding_period_years": 123,
"bedroom_count": 123,
"sitting_room_count": 123,
"floor": "<string>",
"floor_level": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"flat": "<string>",
"is_premium_paid": true,
"deal_type": "<string>",
"geo": {
"@type": "MidlandGeo",
"region": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"subregion": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"sm_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"combined_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"int_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"int_sm_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"lux_district": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
}
},
"estate": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"phase": {
"@type": "MidlandRef",
"id": "<string>",
"name": "<string>"
},
"building": {
"@type": "MidlandBuilding",
"id": "<string>",
"name": "<string>",
"address": "<string>",
"first_op_at": 123,
"floor_count": 123,
"building_type": "<string>",
"latitude": 123,
"longitude": 123,
"streetview_latitude": 123,
"streetview_longitude": 123,
"streetview_angle": 123
},
"features": [],
"floor_plans": [],
"image": "<string>",
"location": {
"@type": "MidlandLocation",
"latitude": 123,
"longitude": 123
},
"listings_url": "<string>",
"updated_at": 123
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
API token from the dashboard
Headers
Body
1 <= x <= 1000020 <= x <= 1500zh-hk, zh-cn, en feet, meter HKD, CNY 0 <= x <= 9990 <= x <= 999S, L 17days, 30days, 90days, 180days, 1year, 3year 1, 2 profit, loss balcony, utility_platform, flat_roof, carpark, roof, garden, duplex, triplex, combined landreg, midland, hkp private, hos, tps default, price, price_desc, net_area, net_area_desc, net_ft_price, net_ft_price_desc 11111111111111x >= 11U01, U02, U03, U04, U05, U06, U07, U08, U09, U10, U11, U12, U13 x >= 0x >= 0x >= 0x >= 0x >= 0x >= 0x >= 0x >= 00, 1, 2, 3, 4+ H, M, L Response
Successful Response
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes