getAudioInfo
Retrieve audio device details from the current operating environment, aiding in system configuration and troubleshooting with accurate device information.
Instructions
获取当前设备的音频设备信息
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Input Schema (JSON Schema)
{
"properties": {},
"required": [],
"type": "object"
}
Implementation Reference
- src/index.ts:669-677 (handler)Handler implementation for the 'getAudioInfo' tool. It uses the 'systeminformation' library (si.audio()) to fetch audio device information and returns it as a JSON string in the tool response.case "getAudioInfo": { const audioInfo = await si.audio(); return { content: [{ type: "text", text: JSON.stringify(audioInfo, null, 2) }] }; }
- src/index.ts:226-234 (registration)Registration of the 'getAudioInfo' tool in the listTools handler (handleRequest). Includes name, description, and empty input schema (no parameters required).{ name: "getAudioInfo", description: "获取当前设备的音频设备信息", inputSchema: { type: "object", properties: {}, required: [] } },
- src/index.ts:229-232 (schema)Input schema for 'getAudioInfo' tool: an empty object (no input parameters). Defined within the tool registration.inputSchema: { type: "object", properties: {}, required: []