---
# System prepended metadata

title: 'prompt_command = "// action:pr'

---

# Klipper Action Prompt Syntax

(extracted from https://github.com/mainsail-crew/mainsail/pull/1630)

### ABNF
```abnf
prompt = "// action:prompt_" command
command = (begin-cmd / text-cmd / 
           button-cmd / button-group-cmd / 
           show-cmd / close-cmd)
begin-cmd = "begin" SP 1*VCHAR
text-cmd = "text" SP 1*VCHAR
button-cmd = ("button" / "footer_button") SP label ["|" gcode ["|" color]] 
label = 1*VCHAR
gcode = 1*(ALPHA / DIGIT / "_")
color = ("primary" / "secondary" / "info" / "warning" / "error")
button-group-cmd = ("button_group_start" / "button_group_end")
show-cmd = "show"
close-cmd = "close"
```
