macOS AppleScript Fallback for Openclaw

A robust automation skill providing reliable shell and AppleScript fallbacks for core macOS productivity applications.

qy-zhang
v1.0.0
Mar 22, 2026
0
1.1k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install macos-applescript-fallback

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install macos-applescript-fallback using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is macOS AppleScript Fallback?

The macOS AppleScript Fallback is a specialized toolset designed to ensure your AI agent remains functional even when standard API or plugin routes for macOS apps are unavailable. By leveraging local shell execution and optimized AppleScript patterns, this skill provides a fail-safe mechanism for interacting with system-level applications like Reminders, Notes, and Calendar. It is a vital addition to the library of Openclaw Skills for users who require high availability and consistency across different macOS versions.

This skill prioritizes pre-bundled scripts over ad-hoc commands to avoid version-specific parsing errors and locale issues. It serves as a bridge between high-level AI intent and low-level system automation, ensuring that tasks like sending an iMessage or logging a quick note are completed successfully regardless of the environment's complexity.

macOS AppleScript Fallback Use Cases

  • Automating the creation of reminders with specific deadlines directly from a chat interface.
  • Generating formatted HTML notes in Apple Notes for research and travel planning.
  • Scheduling calendar events with precise start and end times across specific accounts like iCloud.
  • Sending urgent iMessage notifications to specific contacts or Apple IDs using system-level messaging services.
  • Providing a reliable fallback when primary macOS automation plugins fail or encounter permission errors.

How macOS AppleScript Fallback Works

  1. The AI agent identifies user intent for a macOS-specific task and extracts required fields such as titles, dates, or contact info.
  2. The skill bypasses standard plugins and targets specialized shell scripts located in the scripts directory to ensure compatibility.
  3. The script executes localized AppleScript to interface directly with the target macOS application (e.g., Messages, Notes).
  4. The system evaluates the exit code and output; if successful, it confirms the result to the user with key details.
  5. In case of failure, the skill triggers a diagnostic workflow to identify common issues like missing Automation permissions or locale mismatches.

macOS AppleScript Fallback Setup

To integrate this into your environment, ensure your shell has the necessary permissions to control System Events and target applications. Clone the repository and ensure the scripts are executable:

# Grant execution permissions to the fallback scripts
chmod +x scripts/*.sh

# Test a reminder creation to trigger the macOS permission prompt
./scripts/create_reminder.sh "Test Openclaw Skills" "2026-05-09 12:00:00"

macOS AppleScript Fallback Data Schema & Taxonomy

The skill utilizes a structured script-to-argument mapping to ensure data integrity across various macOS versions:

Script Arguments Data Format
create_reminder.sh <title> ["datetime"] ISO-8601 strings recommended
create_note.sh <html-body> [account] Body must be valid HTML tags
create_calendar_event.sh <title> <calendar> <start> <end> Specific calendar name or default
send_imessage.sh <recipient> <message> Phone number or Apple ID email

All scripts are centralized in the scripts/ directory, while diagnostic documentation is maintained in references/troubleshooting.md.

macOS AppleScript Fallback Advanced Features

  • Smart Fallbacks: Automatically defaults to the first available calendar or account if the specified name is missing.
  • HTML Rendering: Uses HTML formatting for Notes to ensure consistent visual styles across devices.
  • Service Resolution: Dynamically identifies the iMessage service type rather than relying on hard-coded service names.
  • Permission Troubleshooting: Integrated diagnostic checks for macOS Automation and Privacy settings.
  • Robust Date Handling: Logic designed to minimize failures caused by locale-fragile date strings.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*