====== Global Macro Palette Trigger ======
The //Global Macro Palette trigger// lets you add your macro to a floating palette, so you can trigger it by clicking on the macro name in the palette.
{{:undefined:macropalet.gif
====== URL Trigger ======
Any active macro can be triggered using the kmtrigger: scheme with a URL like this:
kmtrigger://macro=<MacroNameOrUUID>[&value=<TriggerValue>]
whe... "<MacroNameOrUUID>" is either the URL encoded Macro Name, or the Macro UUID
"[&value=<TriggerValue>]" is the option to pass "<TriggerValue>" as the Macr
the keystroke, and Keyboard Maestro executes the macro.
===== The Key =====
The key can be a letter, n... can configure the hot key trigger to execute the macro when the key is pressed, when it is long pressed ... d down. This allows you to do things like have a macro execute when the key is pressed, and then a second macro execute when the key is released, for example to
Trigger ======
The *Public Web trigger* makes a macro available without further authentication via the ... one of several triggers that use a `URL`. See\\
[Macro Triggers that Use a URL](https://forum.keyboardma... 44/10?u=jmichaeltx), 2018-07-15, peternlewis
Any macro with the [[Public Web]] trigger can be triggered ... etwork is configured).
**Public Web Trigger on a Macro**
{{:trigger:public-web-trigger-on-macro.png?nol
this [[:Triggers|trigger]] on the [[manual:Macros|Macro]] first.
For a good discussion, see:
* [Tip: ... /8277?u=jmichaeltx), 2017-10-13, peternlewis
* [Macro Triggers that Use a URL](https://forum.keyboardma... ou should use a lot of caution when you allow any macro to be executed with a Remote trigger.**
{{:trigger:caution-small.png?nolink |}}
* **A macro with the _Remote Trigger_ may be used by anyone w
aestro'
then:
keyboardmaestro [options...] <macro name/uid>
Like most CLI tools, you can ask for h... rt^Long^Meaning^
| -a | --async | Do not wait for macro to complete |
| -e | --edit | Edit the macro instead of triggering it |
| -h | --help | Show the help me... s command will edit or trigger a Keyboard Maestro macro as specified.
The macro name can be the name of
Any active macro can be triggered via AppleScript request to the Keyboard Maestro Engine. Keyboard Maest... igger section showing example code to execute the macro by script in a variety of languages (although all... 5-DDCAC055E3ED"
-- or: do script "My Example Macro"
end tell
-- end ignoring
or
osascr... Keyboard Maestro Engine" to do script "My Example Macro"'
As can be seen, you can execute the macro by n
*Group Status Menu trigger* lets you include your macro in the parent macro group *Group Status Menu*.
The parent [[manual:Macro_Groups|Macro Group]] must be configured to display in the menu bar, and when it is active, this macro wi
==
The *Typed String trigger* lets you execute a macro in response to a sequence of keys.
Typed String ... hence descriptive) sequences of keys to trigger a macro. Because the keys first go through to the current... e keys are usually deleted prior to executing the macro, although with this disabled you can use it in an... en you may need a short pause at the start of the macro to allow the simulated deletes to be processed be
====
The *Status Menu trigger* lets you add your macro to the Keyboard Maestro status menu so you can trigger it by selecting the macro name from the status menu.
Keyboard Maestro disp... Menu triggered macros that are active, so if your Macro is restricted to particular applications, then it... plications.
You can control the sorting order of macro groups and macros by adding two characters and a
erver, then you can log in and execute any active macro. You do not need to explicitly set a trigger; if... web browser using the username and password.
Any macro with the [[Public Web]] trigger can be triggered ... n connect to the server.
**To Execute a Specific Macro**
```html
https://localhost:4491/action.html?macro=<YourMacroUUID>&value=<TheTriggerValueToPass>
```
=
The *MIDI trigger* lets you execute a macro when a MIDI packet is received.
You can trigger on specific ... the raw packet fields.
====== Notes =======
The macro can execute when the MIDI note is pressed (note o... d down. This allows you to do things like have a macro execute when the key is pressed, and then a second macro execute when the key is released, for example to
ossible.
The *USB Device Key trigger* executes a macro when any device key is pressed — this includes mo... their normal operation as well as triggering the macro. This is fine for modifiers, unused mouse buttons... can configure the hot key trigger to execute the macro when the key is pressed, when it is long pressed ... d down. This allows you to do things like have a macro execute when the key is pressed, and then a secon
e //Application trigger// allows you to execute a macro when an specified application (or any application... contained the name of the application).
(!) If a macro that is triggered by an application launching is in a macro group that is active only when that application i... en the trigger will probably never fire since the macro will be inactive until after the event has passed
he *Subroutine trigger* (v10+) lets you execute a macro using the [[action:Execute_a_Subroutine|Execute a... defines the parameters that can be passed to the macro, and the variables they are stored in, as well as whether the macro returns a result.
===== See Also =====
=== Trig... Execute a Subroutine]] action
* [[action:Execute_a_Macro|Execute a Macro]] action
* [[/Actions|Actions]]