server

command
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2026 License: MIT Imports: 8 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Command server 是 mcp-toolify 的组装示例:基座 + spill(大结果落盘)。

别的插件按同样方式装:import 后按「外 → 内」的顺序各调一次 Install(推荐顺序见 README 的「插件顺序」一节)。本仓库另带 audit(审计);配额、审批一类由使用方以外置 module 提供——任何插件都必须能从仓库外装进来,否则基座就给自带插件开了特例。

改了工具函数后重新生成 wrapper(生成物不入库,构建前现场生成):

go generate ./example/...

运行(token 鉴权是强制的,因此必须给配置文件):

go run ./example/cmd/server -addr :8011 -config ./example/conf/mcp.toml

试一次只读调用:

curl -sS localhost:8011 -H 'Authorization: Bearer replace-me-readonly' \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json, text/event-stream' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
       "params":{"name":"greeter.greet","arguments":{"name":"world","excited":true}}}'

Jump to

Keyboard shortcuts

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