This is a legacy guide for Power Manager v3, published 2005 – 2010, and is provided for reference only.
The latest guide is for Power Manager v5.10.4.

Scripting the Notifications

Count Pending Events

Counts the number of pending Events.

tell application "Power Manager Scripting"
    tell notifications
    	set numEvents to count PMEvents
    end tell
end tell

Name of the Next Event

Get the name of the next Event to perform

tell application "Power Manager Scripting"
    tell notifications
    	set myName to name of first PMEvent
    end tell
end tell

Action of the Next Event

Get the action of the next Event to perform.

tell application "Power Manager Scripting"
    tell notifications
    	set myAction to type class of action of first PMEvent
    end tell
end tell

Date and Time of the Next Event

Get the trigger date of the next Event to perform.

tell application "Power Manager Scripting"
    tell notifications
    	set myDate to date of trigger of first PMEvent
    end tell
end tell

Delay an Event

Delays the pending Event called “Morning” by 5 minutes.

tell application "Power Manager Scripting"
    tell notifications
    	delay unique id (unique id of PMEvent "Morning") as string seconds (5 * 60)
    end tell
end tell

Cancel an Event

Cancels the next pending Event.

tell application "Power Manager Scripting"
    tell notifications
    	cancel unique id (unique id of first PMEvent) as string
    end tell
end tell

Cancel Next Shut Down Event

Cancels the next Event with a Shut Down action.

tell application "Power Manager Scripting"
    tell notifications
    	cancel unique id (unique id of first PMEvent whose type class of action is shutdown) as string
    end tell
end tell