Create a macro or replace or append its lines (never runs it)
gma3_store_macroStores, replaces, or appends grandMA3 macros and their command lines with validation and read-back checks, without running the macro.
Instructions
mode (required): create (refuses an existing macro), replace (removes the existing lines first, keeping the macro, its appearance and its executor assignments) or append (adds after the existing lines). lines: [{command, wait (seconds, "follow" or "go" = a manual wait until the next Go+), enabled, add_to_cmdline, execute, name, note, raw}]; name, note, cli of the macro. Before anything is sent the references in each line are checked (single objects named with full keywords; a Store earlier in the macro counts as creating its object); raw: true stores a line unchecked. Refuses a locked or running macro, and a name another macro has (naming the holder; the pool's names are read once per call, compared case-insensitively; a duplicate makes lookups by name ambiguous, and whether the console would store "#2" is not verified for macros): on_name_taken refuse (default) | allow_suffix (store anyway); in the batch form a name an earlier macro of the call was stored under counts as taken. Sends Store Macro N, Delete/Store Macro N.L and one set per property; NEVER runs the macro. The console rewrites command text outside quotes (trims, collapses spaces, expands abbreviated keywords): every line is read back and compared exactly; a rewritten line is a mismatch unless accept_console_form: true (it is reported in rewritten either way). Batch form: give the list instead of the single object's fields; the other arguments are defaults for every item (an item's own fields win). Each item gets the single form's checks and read-back, and its own outcome; items run in order, nothing is retried, an unknown outcome stops the rest, and the result has one line per item (detail: true for every step).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cli | No | ||
| mode | No | Required (per macro or for the whole batch). | |
| name | No | ||
| note | No | ||
| lines | No | Required unless macros is given. | |
| macro | No | Macro number. Required unless macros is given. | |
| detail | No | Return every item's full result with its steps (default false: one line per item). | |
| macros | No | Batch form: several macros, each {macro, mode, lines, name, note, cli}; mode may be given once for all. | |
| verify | No | ||
| preview | No | ||
| data_pool | No | Data pool number (DataPool n). Default: the current data pool, as without this parameter. | |
| on_name_taken | No | When another macro has the name: refuse (default, nothing is sent) or allow_suffix (store anyway). | |
| stop_on_failure | No | Batch form: stop at the first item that does not succeed (default false: independent items go on; an item on an object an earlier item failed on is skipped either way). | |
| accept_console_form | No |