check_permissions
Verify macOS Accessibility and Screen Recording permissions for desktop automation. Returns status and setup instructions for missing permissions.
Instructions
Check whether macOS Accessibility and Screen Recording permissions are granted. Returns status for each permission and instructions for any that are missing.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/utility.ts:119-144 (handler)Handler function for the 'check_permissions' tool which tests Accessibility and Screen Recording permissions.
async function handleCheckPermissions(): Promise<CallToolResult> { const accessibility = await testAccessibility(); const screenRecording = await testScreenRecording(); const missing: string[] = []; if (!accessibility) missing.push(ACCESSIBILITY_INSTRUCTIONS); if (!screenRecording) missing.push(SCREEN_RECORDING_INSTRUCTIONS); const instructions = missing.length === 0 ? "All permissions granted." : `Grant the following permissions:\n${missing.map((m) => ` - ${m}`).join("\n")}`; return { content: [ { type: "text" as const, text: JSON.stringify( { accessibility, screenRecording, instructions }, null, 2, ), }, ], }; } - src/tools/utility.ts:35-35 (schema)Input schema definition for the 'check_permissions' tool.
const CheckPermissionsInputSchema = z.object({}); - src/tools/utility.ts:50-59 (registration)MCP tool definition for 'check_permissions' in utilityToolDefinitions array.
{ name: "check_permissions", description: "Check whether macOS Accessibility and Screen Recording permissions are granted. Returns status for each permission and instructions for any that are missing.", inputSchema: zodToToolInputSchema(CheckPermissionsInputSchema), annotations: { readOnlyHint: true, destructiveHint: false, }, }, - src/tools/utility.ts:174-174 (registration)Registration of the 'check_permissions' handler in the tool dispatch map.
check_permissions: () => enqueue(() => handleCheckPermissions()),