Skip to main content

Hong Kong election and legislature MCP Server providing election and legislature data tools

Project description

Hong Kong Government Election and Legislature MCP Server

GitHub Repository License: MIT

This is an MCP server that provides access to government security incident data through a FastMCP interface.

Features

  • Registered Electors Data: Retrieve the number of registered electors in Hong Kong's geographical constituencies for a specified range of years.

Data Source

  • Registered electors data from Registration and Electoral Office (voterregistration.gov.hk)

Examples

  • List number of registered electors in geographical constituencies in Hong Kong between 2009 and 2024

Setup

  1. Clone this repository
  2. Install Python dependencies:
    pip install -r requirements.txt
    
  3. Run the server:
    python app.py
    

Running Options

  • Default stdio mode: python app.py
  • SSE mode (port 8000): python app.py --sse

Cline Integration

To connect this MCP server to Cline using stdio:

  1. Add this configuration to your Cline MCP settings (cline_mcp_settings.json):
{
  "hk-election": {
    "disabled": false,
    "timeout": 3,
    "type": "stdio",
    "command": "uvx",
    "args": [
      "hkopenai.hk-election-mcp-server"
    ]
  }
}

Testing

Tests are available in the tests/ directory. Run with:

pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hkopenai_hk_election_mcp_server-0.1.8.tar.gz (6.4 kB view details)

Uploaded Source

File details

Details for the file hkopenai_hk_election_mcp_server-0.1.8.tar.gz.

File metadata

File hashes

Hashes for hkopenai_hk_election_mcp_server-0.1.8.tar.gz
Algorithm Hash digest
SHA256 afb34b005d88cb118d58174a878d6686c3746d8b10d5b2ce41226c63eaec0f61
MD5 793affa7338bd4bb37a3ed171365a95c
BLAKE2b-256 cdf2d3f1b8a77d857d5eae9ffee7543e024ba74a098209116d307e23028898b9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page