stablyai/orca · error · RuntimeClientError

invalid_argument

invalid_argument

Error message

--id must be "accessibility" or "screenshots"

What it means

getComputerPermissionSetupId (computer.ts:227) validates the optional --id on `orca computer permissions`. Only 'accessibility' and 'screenshots' are meaningful macOS permission scopes for the Computer Use helper app; any other id is rejected before the computer.permissions RPC. Match is case-sensitive and exact.

Source

Thrown at src/cli/handlers/computer.ts:227

    })
    printResult(result, json, (value) =>
      formatComputerAction('set-value', value, { ...target, ...observeFlags })
    )
  }
}

function assertComputerAppFlag(flags: Map<string, string | boolean>): void {
  getRequiredStringFlag(flags, 'app')
}

function getComputerPermissionSetupId(
  flags: Map<string, string | boolean>
): 'accessibility' | 'screenshots' | undefined {
  const id = getOptionalStringFlag(flags, 'id')
  if (id === undefined || id === 'accessibility' || id === 'screenshots') {
    return id
  }
  throw new RuntimeClientError('invalid_argument', '--id must be "accessibility" or "screenshots"')
}

function formatComputerCapabilities(value: ComputerProviderCapabilities): string {
  return [
    `${value.provider} (${value.platform}, protocol ${value.protocolVersion})`,
    `  Apps: list=${value.supports.apps.list} bundleIds=${value.supports.apps.bundleIds} pids=${value.supports.apps.pids}`,
    `  Windows: list=${value.supports.windows.list} targetById=${value.supports.windows.targetById} targetByIndex=${value.supports.windows.targetByIndex}`,
    `  Observation: screenshot=${value.supports.observation.screenshot} elementFrames=${value.supports.observation.elementFrames} annotatedScreenshot=${value.supports.observation.annotatedScreenshot}`,
    `  Actions: ${Object.entries(value.supports.actions)
      .filter(([, enabled]) => enabled)
      .map(([name]) => name)
      .join(', ')}`
  ].join('\n')
}

View on GitHub (pinned to 1136503c6a)

Solutions

  1. Use --id accessibility or --id screenshots (lowercase, exact)
  2. Omit --id entirely to query/check all permission scopes at once
  3. Run the command once without --id to see available scopes, then target one

Example fix

// before
orca computer permissions --id Accessibility
// after
orca computer permissions --id accessibility
Defensive patterns

Strategy: type-guard

Validate before calling

function assertPermissionId(id) {
  if (id !== undefined && id !== 'accessibility' && id !== 'screenshots') {
    throw new Error('--id must be "accessibility" or "screenshots"')
  }
}

Type guard

function isPermissionId(value) {
  return value === 'accessibility' || value === 'screenshots'
}

Prevention

When it happens

Trigger: `orca computer permissions --id camera`, `--id Accessibility` (wrong case), `--id microphones`, `--id 1`. The flag is optional; omitting it queries all scopes.

Common situations: Typos; wrong case (the check is case-sensitive); guessing an id from other macOS permission types (camera, microphone, input-monitoring).

Related errors


AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12). Data as JSON: /api/errors/51888fbd1be435f2. Report an issue: GitHub.