Cover image
Try Now
2025-04-14

英国房地产价格搜索MCP服务器

3 years

Works with Finder

1

Github Watches

0

Github Forks

0

Github Stars

Property Price Search MCP Server

A Model Context Protocol (MCP) server that allows users to search for property prices by postcode using the HM Land Registry's SPARQL endpoint.

Features

  • Search property prices by postcode or street/city combination
  • Filter results by price range, property type, and date range
  • Connect to HM Land Registry's public SPARQL endpoint
  • Implements MCP stdio transport for IDE integration
  • TypeScript implementation with full type safety
  • Comprehensive test suite
  • CLI interface for direct usage

Prerequisites

  • Node.js >= 18
  • npm >= 7

Installation

Global Installation

npm install -g property-prices-mcp

Local Installation

npm install property-prices-mcp

Usage

Command Line Interface

property-prices-mcp

As a Library

import { McpClient } from '@modelcontextprotocol/sdk/client';

const client = new McpClient();
const result = await client.resource('property-prices').query({
  postcode: 'SW1A 1AA',
  minPrice: 1000000,
  propertyType: 'flat',
  limit: 5,
});

console.log(result);

Search Parameters

The server accepts the following search parameters:

Parameter Type Description Default
postcode string UK postcode to search -
street string Street name -
city string City name -
minPrice number Minimum property price -
maxPrice number Maximum property price -
propertyType string One of: detached, semi-detached, terraced, flat, other -
fromDate string Start date (YYYY-MM-DD) -
toDate string End date (YYYY-MM-DD) -
limit number Maximum number of results 10
offset number Number of results to skip 0
sortBy string Sort by 'date' or 'price' 'date'
sortOrder string Sort order 'asc' or 'desc' 'desc'

Response Format

The API returns results in the following format:

interface PropertyPrice {
  price: number;
  date: string;
  propertyType: string;
  newBuild: boolean;
  tenure: string;
  paon: string;
  saon?: string;
  street: string;
  locality?: string;
  town: string;
  district: string;
  county: string;
  postcode: string;
}

interface SearchResponse {
  results: PropertyPrice[];
  total: number;
  offset: number;
  limit: number;
}

Error Handling

The server returns standard HTTP status codes:

  • 200: Successful request
  • 400: Invalid parameters
  • 404: No results found
  • 500: Server error

Error responses include a message explaining the error:

{
  "error": "Invalid postcode format"
}

Development

  1. Clone the repository:

    git clone https://github.com/joemclo/property-prices-mcp.git
    cd property-prices-mcp
    
  2. Install dependencies:

    npm install
    
  3. Build the project:

    npm run build
    
  4. Run tests:

    npm test                  # Run all tests
    npm run test:unit        # Run unit tests only
    npm run test:integration # Run integration tests only
    
  5. Start in development mode:

    npm run dev
    

Troubleshooting

Common Issues

  1. SPARQL Endpoint Connection Issues

    • Check your internet connection
    • Verify the HM Land Registry endpoint is available
    • Ensure your IP is not being rate limited
  2. Invalid Postcode Format

    • Ensure postcodes are in the correct UK format
    • Remove any extra spaces
    • Use uppercase letters
  3. No Results Found

    • Try broadening your search criteria
    • Check if the date range is too narrow
    • Verify the postcode exists

Contributing

Please read CONTRIBUTING.md for details on our code of conduct and the process for submitting pull requests.

Changelog

See CHANGELOG.md for a list of changes and version history.

License

This project is licensed under the MIT License - see the LICENSE file for details.

相关推荐

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • Alexandru Strujac
  • Efficient thumbnail creator for YouTube videos

  • https://maiplestudio.com
  • Find Exhibitors, Speakers and more

  • Yusuf Emre Yeşilyurt
  • I find academic articles and books for research and literature reviews.

  • Carlos Ferrin
  • Encuentra películas y series en plataformas de streaming.

  • lumpenspace
  • Take an adjectivised noun, and create images making it progressively more adjective!

  • https://zenepic.net
  • Embark on a thrilling diplomatic quest across a galaxy on the brink of war. Navigate complex politics and alien cultures to forge peace and avert catastrophe in this immersive interstellar adventure.

  • apappascs
  • 发现市场上最全面,最新的MCP服务器集合。该存储库充当集中式枢纽,提供了广泛的开源和专有MCP服务器目录,并提供功能,文档链接和贡献者。

  • ShrimpingIt
  • MCP系列GPIO Expander的基于Micropython I2C的操作,源自ADAFRUIT_MCP230XX

  • pontusab
  • 光标与风浪冲浪社区,查找规则和MCP

  • av
  • 毫不费力地使用一个命令运行LLM后端,API,前端和服务。

  • ravitemer
  • 一个功能强大的Neovim插件,用于管理MCP(模型上下文协议)服务器

  • jae-jae
  • MCP服务器使用剧作《无头浏览器》获取网页内容。

  • patruff
  • Ollama和MCP服务器之间的桥梁,使本地LLMS可以使用模型上下文协议工具

  • JackKuo666
  • 🔍使AI助手可以通过简单的MCP接口搜索和访问PYPI软件包信息。

    Reviews

    4 (1)
    Avatar
    user_ApDka2ha
    2025-04-17

    As a dedicated user of the property-prices-mcp application, I must say this tool is invaluable for anyone interested in real estate market trends. Created by joemclo, this repository provides comprehensive data analysis on property prices with user-friendly features. I highly recommend checking it out at https://github.com/joemclo/property-prices-mcp. This application has greatly helped me in making informed decisions about property investments.