Skip to main content
Glama
JackXuyi

Current operating environment

getWifiInfo

Retrieve current device Wi-Fi connection details including network name, signal strength, and connection status to monitor network environment.

Instructions

获取当前设备的 Wi-Fi 信息

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler implementation for the 'getWifiInfo' tool. It fetches Wi-Fi networks using the 'systeminformation' library (si.wifiNetworks()) and returns the information as a JSON string in the tool response format.
    case "getWifiInfo": { const wifiInfo = await si.wifiNetworks(); return { content: [{ type: "text", text: JSON.stringify(wifiInfo, null, 2) }] }; }
  • The schema/declaration of the 'getWifiInfo' tool in the list of available tools returned by the ListTools handler. Includes name, description, and input schema (empty object).
    { name: "getWifiInfo", description: "获取当前设备的 Wi-Fi 信息", inputSchema: { type: "object", properties: {}, required: [] } },
  • src/index.ts:787-791 (registration)
    Registration of the request handlers for listing tools (which includes getWifiInfo schema) and calling tools (which dispatches to the getWifiInfo handler).
    server.setRequestHandler(ListToolsRequestSchema, handleRequest); // 处理工具调用 server.setRequestHandler(CallToolRequestSchema, handleCallToolRequest);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/JackXuyi/env-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server