跳到正文
cccskills
免费在 GitHub 公开

apple-notes-install-auth

Set up macOS permissions and verify access for automating Apple Notes with AppleScript, JavaScript for Automation (JXA), `osascript`, or Shortcuts. It helps establish a scoped, read-only authorization and a wrapper for approved operations.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

Set up macOS automation access for Apple Notes via AppleScript, JXA, and Shortcuts. Use when configuring accessibility permissions, setting up osascript access, or initializing Apple Notes automation on macOS. Trigger: "setup apple notes", "apple notes automation", "apple notes permissions".

实测评分 未实测

查看安装方法

适用场景

  • Granting macOS automation permission for Notes
  • Checking Apple Notes access through `osascript` or JXA
  • Preparing an approved Notes wrapper or Shortcuts workflow

包含的文件(1)

  • SKILL.md5.0 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

Apple Notes Install & Auth

Overview

Apple Notes has no REST API. Automation uses macOS scripting technologies: AppleScript, JavaScript for Automation (JXA), Shortcuts, and the osascript command-line tool. No SDK to install — but you need macOS accessibility permissions.

Prerequisites

  • macOS 13+ (Ventura or later recommended)
  • Terminal app or iTerm2
  • System Preferences > Privacy & Security > Automation permissions

Instructions

Step 1: Grant Automation Permissions

# macOS requires explicit permission for scripts to control Notes.app
# The first time you run an osascript command targeting Notes, macOS will prompt.
# You can also pre-grant in: System Preferences > Privacy & Security > Automation

# Test basic Notes access (will trigger permission prompt)
osascript -e 'tell application "Notes" to get name of every note in default account'

Step 2: Verify JXA (JavaScript for Automation) Access

# JXA is the modern alternative to AppleScript
# Run JavaScript via osascript with -l JavaScript flag

osascript -l JavaScript -e '
  const Notes = Application("Notes");
  Notes.includeStandardAdditions = true;
  const noteCount = Notes.defaultAccount.notes.length;
  `Apple Notes accessible: ${noteCount} notes found`;
'

Step 3: Create a Wrapper Script

#!/bin/bash
# scripts/notes-cli.sh — Wrapper for common Apple Notes operations

case "$1" in
  count)
    osascript -l JavaScript -e '
      const Notes = Application("Notes");
      Notes.defaultAccount.notes.length;
    '
    ;;
  list)
    osascript -l JavaScript -e '
      const Notes = Application("Notes");
      const notes = Notes.defaultAccount.notes();
      notes.slice(0, 20).map(n => `${n.id()} | ${n.name()}`).join("\n");
    '
    ;;
  folders)
    osascript -l JavaScript -e '
      const Notes = Application("Notes");
      Notes.defaultAccount.folders().map(f => f.name()).join("\n");
    '
    ;;
  *)
    echo "Usage: notes-cli.sh {count|list|folders}"
    ;;
esac

Step 4: Verify Shortcuts Integration

# Apple Shortcuts can also interact with Notes
# Check available shortcuts
shortcuts list | grep -i note

# Run a shortcut that creates a note
shortcuts run "Create Note" --input-path /dev/stdin <<< "Test content"

Automation Technologies

TechnologyLanguageBest ForDocs
AppleScriptAppleScriptSimple operationsApple Scripting Guide
JXAJavaScriptComplex logic, JSON handlingApple JXA Reference
osascriptCLI wrapperScripts, CI/CDman osascript
ShortcutsVisualNon-developer workflowsShortcuts app
PyXAPythonPython automationpyxa.dev

Output

  • A recorded consent decision for the exact invoking app and macOS user
  • A read-only, scoped authorization result (not a complete note listing)
  • A wrapper that exposes only the approved operations and fails on unknown input
  • An explicit decision on whether any Shortcuts workflow is approved

Examples

For a first-time setup, run one read-only count against the intended account and accept the macOS prompt in the interactive session. Do not use the list wrapper against a production account unless the task specifically requires metadata discovery; it can expose titles in terminal history and CI logs. For Shortcuts, use a non-production shortcut and a test note rather than a workflow that creates notes in a default account.

Error Handling

ErrorCauseSolution
Not authorized to send Apple eventsMissing automation permissionGrant in System Preferences > Privacy > Automation
Notes got an error: AppleEvent timed outNotes.app not runningLaunch Notes first or add activate
-1743 errAEAppNotAllowedDenied by TCCReset TCC: tccutil reset AppleEvents
execution error: Notes is not runningNotes.app closedAdd tell app "Notes" to activate

Resources

Next Steps

Proceed to apple-notes-hello-world for your first note creation.

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Add a synthetic-data CI gate for customer-owned Abridge integration code. Test consent handling, note-review handoffs, redaction, and rollback behavior with mocked vendor boundaries, without connecting CI to a live Abridge or EHR tenant.

中文简介正在准备中。当前显示英语简介。

  • Adding regression checks to an Abridge integration repository
  • Testing consent and note-release handling
  • Checking logs for sensitive data exposure
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

Triage Abridge recording, note review, Epic handoff, and access problems using observed symptoms and approved guidance. Identify the affected workflow stage, organize a minimal timeline, and prepare a redacted escalation record for the responsible team.

中文简介正在准备中。当前显示英语简介。

  • Separate recording problems from upload failures
  • Investigate note creation delays and editor issues
  • Identify the responsible team for Epic handoff failures
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

Map and review an Abridge clinical documentation workflow from consent and recording through draft review, evidence checks, edits, and final disposition. Keep clinician approval explicit, identify failure exits, and separate verified facts from tenant-specific details and pending approvals.

中文简介正在准备中。当前显示英语简介。

  • Map a clinical note workflow for a care setting
  • Check where consent and patient identity are verified
  • Review draft notes against linked evidence before sign-off
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

Audit how clinician-reviewed Abridge note sections map into Epic templates and downstream workflows. Use approved test records to document destinations, exceptions, evidence, rollback steps, and a go or no-go decision for a specific environment.

中文简介正在准备中。当前显示英语简介。

  • Checking Abridge note section mappings to Epic templates
  • Auditing a department’s approved documentation handoff
  • Preparing test evidence and a go or no-go decision
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

Review Abridge adoption and workflow value using local usage records, clinician feedback, and verified contract costs. Build an evidence based decision table covering adoption, quality, support burden, and options to expand, hold, or improve the rollout.

中文简介正在准备中。当前显示英语简介。

  • Reviewing adoption after an Abridge rollout
  • Preparing evidence for a renewal decision
  • Comparing workflow outcomes across care settings
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

Prepare a bounded support bundle for an Abridge issue using allowlisted operational details such as versions, coarse timestamps, and correlation references. Exclude recordings, transcripts, patient identifiers, credentials, and unrestricted logs, then document redactions and review details.

中文简介正在准备中。当前显示英语简介。

  • Preparing reviewed evidence for an Abridge support case
  • Documenting redactions and excluded data
  • Collecting approved operational details for an incident
jeremylongshore/tons-of-skills-marketplace28692026年10月25日 更新

查看 jeremylongshore 的全部技能

报告此技能的问题