screentime_sql
Execute custom SQL queries against the macOS Screen Time database to retrieve app usage data. Use the ZOBJECT table for raw pipe-separated results.
Instructions
Run a custom SQL query against macOS knowledgeC.db (Screen Time database). Use ZOBJECT table with ZSTREAMNAME='/app/usage'. Timestamps use Core Data epoch (978307200 offset from Unix). Returns raw pipe-separated results.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sql": "<sql>"
},
"name": "screentime_sql"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sql | Yes | SQL query to execute against knowledgeC.db |