Post Command
Post-command tags dispatch additional commands after a prompt flow completes or is cancelled. A post-command-only string does not start a session; at least one prompt must be present.
Inline syntax
<!command>
Run after successful completion.
<!!command>
Run after cancellation.
<!:100 command>
Run after completion with a 100-tick delay.
<!!:20 command>
Run after cancellation with a 20-tick delay.
<!command @console>
Force console execution.
<!command @player>
Force player execution.
@console and @player are whitespace-delimited tokens and may appear anywhere in the inline command body.
Inline answer references are zero-based:
/mute <Player?> <Reason?> <!broadcast {0} was muted: {1}>An out-of-range inline {N} reference fails that post-action unless it uses a default="..." transformer.
Inline and preset answer substitutions are inserted without automatic surrounding quotes or added escapes for quotes and backslashes. With answers Steve and Repeated griefing, the example dispatches broadcast Steve was muted: Repeated griefing. The receiving command decides how spaces separate arguments. Quotes written explicitly around a placeholder, such as "{1}", stay in place.
Substitutions use the accepted answers after the prompt's normal sanitization and any configured transformer. Answer text is not reparsed as prompt tags, answer references, or PlaceholderAPI expressions.
Executor inheritance and console gating
An inline command with no executor marker inherits the main command's dispatch context:
A normal player command runs it as that player.
Console Delegate runs it as console.
Player Delegate runs it as the target player and inherits the permission attachment.
Explicit @player or @console overrides that inheritance. In particular, explicit @player does not carry a Player Delegate permission attachment.
Console execution gating (3.2.0)
When a post-command resolves to execute as console (via explicit @console, a preset with execute_as: "console", or inherited console delegation), it is permitted only when:
The session originated from
/consoledelegate, ORThe player is an operator (OP), OR
The player holds
promptpaper.pcm.console,promptpaper.admin, orpromptpaper.consoledelegate.
If none of these conditions are met, the post-command is dropped with a warning logged to the server console.
Answer arity guarantee (3.2.0)
Answer indexing follows the effective answers collected during the session:
Zero-arity prompts (such as info-only dialogs with no input rows or layout-only
title/bodyrows) contribute 0 answers and never shift answer indices.Multi-input dialogs contribute exactly N answers (one per input field).
Inline post-command placeholders remain zero-based (
{0},{1}, ...).Preset post-command placeholders remain one-based (
{input},{input:1},{input:N}).
Preset post-commands
Reference a definition in presets.json with <!@id>. The preset's execution_policy, execute_as, and delay_ticks are authoritative. Parser hints such as <!!@id> or <!:40@id> do not override the preset.
Preset placeholders are one-based:
{input}and{input:1}: first collected answer{input:N}: Nth collected answer{0},{1}, ...: zero-based aliases{player}: the prompting/target player's name, even when the command executes as console%...%: PlaceholderAPI values when PlaceholderAPI is installed
Append one transformer to an answer placeholder, such as {input:1:upper}, {0:trim}, or {1:math(*1.5)}. Out-of-range references without a default="..." transformer fail the action. Duplicate preset post-command references within the same lifecycle event are deduplicated and executed at most once.
<!@id> can also reference a conditional post-command from the conditional_post_commands array. Its condition selects a trusted if_true or if_false action. See Command Flows for approval gates, conditions, transformers, and -breakIf.
Cancellation
<!!command> receives any answers collected before cancellation. A preset runs only when its configured execution_policy matches the actual session result, even if the reference used the opposite marker.
See Presets Configuration for the full JSON format.
Last updated
Was this helpful?