Files
callstack__agent-device/packages/contracts/src/client-settings.ts
Michał Pierzchała 0ee2a86129 refactor: extract contracts workspace package (#1499)
* refactor: extract contracts workspace package

* fix: preserve screenshot diff result contract

* test: stabilize Android keyboard smoke
2026-07-30 17:07:46 +02:00

61 lines
1.5 KiB
TypeScript

// The public API vocabulary for device settings and permission grants.
import type { DeviceCommandBaseOptions } from './client-connection.ts';
export type PermissionTarget =
| 'camera'
| 'microphone'
| 'photos'
| 'contacts'
| 'contacts-limited'
| 'notifications'
| 'calendar'
| 'location'
| 'location-always'
| 'media-library'
| 'motion'
| 'reminders'
| 'siri'
| 'accessibility'
| 'screen-recording'
| 'input-monitoring';
export type SettingsUpdateOptions =
| (DeviceCommandBaseOptions & {
setting: 'clear-app-state';
state: 'clear';
app?: string;
})
| (DeviceCommandBaseOptions & {
setting: 'wifi' | 'airplane' | 'location';
state: 'on' | 'off';
})
| (DeviceCommandBaseOptions & {
setting: 'location';
state: 'set';
latitude: number;
longitude: number;
})
| (DeviceCommandBaseOptions & {
setting: 'animations';
state: 'on' | 'off';
})
| (DeviceCommandBaseOptions & {
setting: 'appearance';
state: 'light' | 'dark' | 'toggle';
})
| (DeviceCommandBaseOptions & {
setting: 'faceid' | 'touchid';
state: 'match' | 'nonmatch' | 'enroll' | 'unenroll';
})
| (DeviceCommandBaseOptions & {
setting: 'fingerprint';
state: 'match' | 'nonmatch';
})
| (DeviceCommandBaseOptions & {
setting: 'permission';
state: 'grant' | 'deny' | 'reset';
permission: PermissionTarget;
mode?: 'full' | 'limited';
});