Skip to main content
Glama
XJPeng12

bmahs-mcp-gateway

by XJPeng12

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
BMAHS_AGENT_IDNoGateway agent id in the protocol (default auto-generated)
BMAHS_HTTP_HOSTNoHTTP mode default host
BMAHS_HTTP_PATHNoHTTP mode default path
BMAHS_HTTP_PORTNoHTTP mode default port
BMAHS_LOG_LEVELNoLog level (logs go to stderr to not pollute stdio protocol channel)
BMAHS_MAX_LEASENoMaximum lease setting for auto-occupy
BMAHS_EXPIRE_SECNoDevice expiration time setting
BMAHS_HTTP_TOKENNoHTTP mode default token
BMAHS_AUTO_OCCUPYNoAuto-occupy policy settings
BMAHS_CALL_TIMEOUTNoCall timeout setting
BMAHS_BONJOUR_BROWSENoSet to '0' to disable mDNS browsing channel (default on)
BMAHS_QUERY_INTERVALNoDevice table refresh interval setting
BMAHS_STATIC_DEVICESNoStatic device table, e.g., tcp://192.168.1.10:9527, comma-separated
BMAHS_AUTO_OCCUPY_TTLNoAuto-occupy TTL setting

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
bmahs_devicesA

列出当前发现的全部 BMAHS 设备(id、显示名、自然语言自述、类型、状态、占用方与连接地址)。选设备、查占用状态时先用这个工具。

bmahs_refreshA

重新扫描 BMAHS 设备:发送组播 query 并刷新各设备的自述(hello)。当设备列表为空、新设备刚上电、或怀疑列表过期时调用。

bmahs_describeA

读取某台 BMAHS 设备的完整操作清单(operations)、安全边界(security)与自然语言自述。

bmahs_occupyA

独占占用一台 BMAHS 设备(返回的 token 由网关保存并自动携带)。租约由网关强制为有限时长:不带 ttl 默认 120 秒(2 分钟),请求值超过上限(默认 3600 秒)会被截断,不支持无限期占用。租约到期设备自动收回占用权;任务结束也可调用 bmahs_release 提前释放。

bmahs_releaseA

释放对某台 BMAHS 设备的占用。任务结束、失败或取消后必须调用,否则其它智能体会一直收到「被占用」。

bmahs_callA

对 BMAHS 设备执行任意其操作清单内(operations)的动作,参数按该动作的 args 传。适合调用尚未生成独立工具的动作,或临时查看新设备。

bmahs_screenshotA

(实验)对声明了 ui 能力的 BMAHS 设备抓取一帧当前画面:自动 ui.start → 二进制流取一帧 JPEG → ui.stop,返回图片与保存路径。

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.2/5.0

Scored across 7 tools

Disambiguation5/5

每个工具都有明确且不重叠的职责:列表、刷新、描述、占用、释放、通用调用和截图,描述清晰,不存在混淆风险。

Naming Consistency5/5

所有工具均以 bmahs_ 前缀,采用动词形式(devices, refresh, describe, occupy, release, call, screenshot),模式统一,一致性好。

Tool Count5/5

7 个工具覆盖设备发现、生命周期管理和操作执行,没有冗余,每个工具都必要,规模恰当。

Completeness4/5

覆盖了设备的发现、扫描、描述、占用/释放、操作调用和截图,但缺少如设备配置更新或批量操作等功能,不过对网关场景而言已基本完整。