Skip to main content
Glama
allegiant

MQScript MCP Server

by allegiant

mqscript_device_setbrightness

Adjust screen brightness on mobile devices by specifying a level from 0 to 255 for automation scripts.

Instructions

Set screen brightness

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
brightnessYesBrightness level (0-255)

Implementation Reference

  • The tool handler function that receives the brightness value and generates the corresponding MQScript command `Device.SetBrightness(brightness)` along with a descriptive response.
    handler: async (args: { brightness: number }) => { const { brightness } = args; const script = `Device.SetBrightness(${brightness})`; return { content: [ { type: 'text', text: `Generated MQScript set brightness command:\n\`\`\`\n${script}\n\`\`\`\n\nThis sets screen brightness to ${brightness}.` } ] }; }
  • The input schema defining the required 'brightness' parameter as a number between 0 and 255.
    inputSchema: { type: 'object' as const, properties: { brightness: { type: 'number', description: 'Brightness level (0-255)', minimum: 0, maximum: 255 } }, required: ['brightness'] },
  • The complete tool registration object within DeviceCommands, which is spread into the ALL_TOOLS registry.
    setBrightness: { name: 'mqscript_device_setbrightness', description: 'Set screen brightness', inputSchema: { type: 'object' as const, properties: { brightness: { type: 'number', description: 'Brightness level (0-255)', minimum: 0, maximum: 255 } }, required: ['brightness'] }, handler: async (args: { brightness: number }) => { const { brightness } = args; const script = `Device.SetBrightness(${brightness})`; return { content: [ { type: 'text', text: `Generated MQScript set brightness command:\n\`\`\`\n${script}\n\`\`\`\n\nThis sets screen brightness to ${brightness}.` } ] }; } },
  • src/index.ts:54-54 (registration)
    Spreading DeviceCommands into ALL_TOOLS object used for tool lookup and registration in MCP server handlers.
    ...SysCommands,

Other Tools

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/allegiant/MQScript_MCP'

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