| name | apple-notes-multi-env-setup |
| description | Configure Apple Notes automation for multiple accounts and environments.
Trigger: "apple notes multi account".
|
| allowed-tools | Read, Write, Edit, Bash(osascript:*), Grep |
| version | 1.0.0 |
| license | MIT |
| author | Jeremy Longshore <jeremy@intentsolutions.io> |
| tags | ["saas","macos","apple-notes","automation"] |
| compatible-with | claude-code |
Apple Notes Multi-Environment Setup
Multiple Account Configuration
const Notes = Application("Notes");
const accounts = Notes.accounts();
const iCloud = accounts.find(a => a.name() === "iCloud");
const gmail = accounts.find(a => a.name() === "Gmail");
const local = accounts.find(a => a.name() === "On My Mac");
function createNoteInAccount(accountName, title, body) {
const account = Notes.accounts().find(a => a.name() === accountName);
if (!account) throw new Error(`Account ${accountName} not found`);
const note = Notes.Note({ name: title, body: body });
account.folders[0].notes.push(note);
return note.id();
}
Environment-Based Configuration
interface NotesEnvConfig {
accountName: string;
defaultFolder: string;
autoSync: boolean;
}
const ENVIRONMENTS: Record<string, NotesEnvConfig> = {
personal: { accountName: "iCloud", defaultFolder: "Personal", autoSync: true },
work: { accountName: "Gmail", defaultFolder: "Work", autoSync: true },
local: { accountName: "On My Mac", defaultFolder: "Notes", autoSync: false },
};
Resources