codemode-go

module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 12, 2026 License: MIT

README

PkgGoDev

codemode-go

Convert OpenAPI specifications to MCP (Model Context Protocol) tools with Starlark scripting support.

Overview

codemode-go provides two modular MCP tools:

  • codemode - Code mode MCP wrapper that enables tool searching, schema inspection, and Starlark-based execution for composing multi-step operations.

  • swagtools - OpenAPI request executor that converts OpenAPI/Swagger specifications into callable MCP tools, handling parameter validation and HTTP orchestration.

Installation

go get github.com/aki237/codemode-go

See EXAMPLES.md for usage patterns.

Core Tools

Search for tools by keyword. Returns results ranked by relevance.

{
  "query": "weather"
}
get_schema

Retrieve detailed parameter and response schemas for tools.

{
  "tools": ["get_weather", "get_forecast"]
}
execute

Chain tool calls in Starlark. Use call_tool(name, params) to invoke registered tools.

{
  "code": "result = call_tool('get_weather', {'location': 'New York'})\nreturn result['temperature']"
}

Components

  • Convertor: Central registry for MCP tools with search and schema inspection
  • Dispatcher: Loads OpenAPI specs and generates MCP tools with HTTP handling
  • Starlark Integration: Execute multi-step operations through Python-like scripting

Development

Run tests:

go test ./...

License

MIT

Directories

Path Synopsis
example
mcp command

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL