Skip to content

okfn/mcp-ckan-examplepythontools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MCP CKAN Plugin Example

This is an example of a MCP CKAN Plugin that register tools to answer data based on Open Data.

How to create a MCP Plugin

  1. Init a package repository:
uv init --package mcp-ckan-exampleplugin
  1. Define a register_tools(mcp) function that register tools in a MCP Server:
def register_tools(mcp):
    @mcp.tool()
    def greetings_from_examplepythontools():
        return "Hello from mcp_ckan_examplepythontools!"
  1. Register a new mcp_ckan entrypoint in the pyproject.toml file that calls the register_tools function.
[project.entry-points."mcp_ckan"]
mcp-ckan-examplepythontools = "mcp_ckan_examplepythontools:register_tools"
  1. Install it in the same virtual environment as your server.
uv pip install "git+https://github.com/okfn/mcp-ckan"
uv pip install "git+https://github.com/okfn/mcp-ckan-examplepythontools"
uv run mcp-ckan

About

A repository with example Python Tools for our MCP for CKAN

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages