slice_id required default (empty string)The 32-character id of the slice whose field you want a widget for. Required - an empty or unknown slice id makes the command return an empty string.
field_id required default (empty string)The 16-character field id within that slice (for example headline........ or category........). Required - an unknown field id returns an empty string, unless the slice has autofields set, in which case it is cloned from the text field.
required optional default (empty - optional)Set to 1 to render the widget as required (adds the required attribute so the browser blocks an empty submit). Empty or 0 leaves it optional.
widget_type optional default (the field's configured widget)A 3-letter widget code that overrides the widget configured on the field (for example sel for a select, fld for a plain field, dte for a date picker, chb for a checkbox). Leave empty to use the field's own configured widget.
widget_properties optional default (none)A JSON object that tunes the widget - keys such as name (override the label), input_help (override the help), const_arr (option list for sel), row_count, input_type. Pass either a JSON object or a string holding a JSON object.
preset_value optional default (none)A starting value for the new field (single value or JSON). The original code marks this not yet implemented, so do not rely on it.
item_index optional default 1The number N in the generated control name aa[nN_slice][field]. Default 1. Use the same index across several inputs to make them one new item, or different indexes to build several new items on one page.
{input:9e1d2b9f88e3d6c3bf0eb967378610d6:headline........}
{input:9e1d2b9f88e3d6c3bf0eb967378610d6:headline........:1}
{input:9e1d2b9f88e3d6c3bf0eb967378610d6:integer.........::sel:{"const_arr":{"0":"No","1":"Yes"}}}
{input:9e1d2b9f88e3d6c3bf0eb967378610d6:headline........:::{"name":"Your name","input_help":"Type your full name"}}
{input:9e1d2b9f88e3d6c3bf0eb967378610d6:headline........:::::2}
[{input:nonexistentslicexxxxxxxxxxxx:headline........}]