wikimedia logo

Wikimedia

by punkpeye

3 forks
1 stars
Free

What is Wikimedia

Wikimedia is an advanced Model Context Protocol (MCP) server designed by Punkpeye to facilitate interaction with Wikimedia APIs. It allows users to access and retrieve content from Wikipedia and other Wikimedia projects using natural language queries. This server enables seamless programmatic access to a wide array of Wikimedia resources, making it easier for developers and AI systems to fetch real-time information from these vast repositories.

How to Use Wikimedia

To get started with Wikimedia, ensure that you have Python 3.12 or higher installed, along with the necessary uv package manager and MCP server framework. Once your environment is set up, you can utilize various tools and commands to interact with Wikimedia content:

  1. Install and Configure: Set up your environment by configuring your system for either development or published settings. Use the appropriate claude_desktop_config.json file path based on your operating system.

  2. Using the Tools:

    • Search Content: Perform a full-text search across Wikimedia pages by specifying the search term, desired number of results, and language.
    • Search Titles: Find page titles that match a search prefix along with descriptions.
    • Get Page: Retrieve complete page details including content, title, URL, and metadata.
    • Get Languages: Discover the availability of a page in different languages.
    • Get Featured: Access featured articles, most-read pages, and pictures of the day for a specific date.
    • Get On This Day: Explore historical events, births, deaths, and holidays for any given date.

Key Features of Wikimedia

  • Comprehensive Search Capabilities: Execute full-text searches across Wikimedia content or title-based searches with intelligent autocomplete suggestions.
  • Page Retrieval: Access detailed information about any Wikimedia page, including content, metadata, and language versions.
  • Featured Content Access: Stay updated with featured articles, pictures of the day, and most-read pages.
  • Historical Insights: Gain insights into historical events, notable births and deaths, and holidays for any date.
  • Multi-language Support: Effortlessly work with content in multiple languages, ensuring a broad and inclusive reach.

Security and Reliability

Wikimedia ensures a secure experience by validating all user inputs and handling rate limiting through the Wikimedia API. The server does not require sensitive data or credentials, and it safeguards against exposing internal details through error messages.

Example Usage

Here’s how you can use the Wikimedia server to execute some common queries:

  • Search for Content:

    result = await client.call_tool("search_content", {
        "query": "artificial intelligence",
        "limit": 5,
        "language": "en"
    })
    
  • Get Featured Content:

    result = await client.call_tool("get_featured", {
        "language": "en"
    })
    
  • Retrieve Historical Events:

    result = await client.call_tool("get_on_this_day", {
        "date": "01/01",
        "type": "all",
        "language": "en"
    })
    

Wikimedia is a powerful tool for developers and AI systems to interact with a multitude of Wikimedia resources, providing both flexibility and depth in accessing and utilizing information.

How to Use

To use the wikimedia, follow these steps:

  1. Visit https://github.com/punkpeye/wikimedia
  2. Follow the setup instructions to create an account (if required)
  3. Connect the MCP server to your Claude Desktop application
  4. Start using wikimedia capabilities within your Claude conversations

Additional Information

Created

January 2, 2025

Company

punkpeye

Start building your own MCP Server

Interested in creating your own MCP Server? Check out the official documentation and resources.

Learn More