ReferenceFor engineers

Action fields

The field types available when defining how a care flow author configures a custom action in Studio.

Action fields are how a care flow author configures an action in Awell Studio: the interface between an extension and a non-engineer.

What each field declares

A field declares its key, label, description, type, and whether it's required.

Write the label and description for someone who doesn't know the API; they're all the author has to go on. A field called dest_num with no description will be filled in wrongly.

The available field types

TypeWhat the author gets
stringA single line of text
textLonger, multi-line text
numericA number
booleanA toggle
dateA date picker
htmlRich text, for content that gets rendered
jsonA JSON value, for structured input
string_arrayA list of text values
numeric_arrayA list of numbers

Pick the narrowest type that fits. A boolean can't be filled in wrongly the way a string can, and a date field avoids parsing arbitrary date formats.

Reach for json last: it accepts any value, including a wrong one, and Studio gives the author no help filling it in. Use it where the shape genuinely varies.

A string field can also carry a set of options, so the author picks from a list instead of typing. Do that whenever the valid values are known: 74 fields across today's marketplace extensions do.

Fields usually hold variables, not literals

Authors can put variables into field values, so a field can carry patient-specific data at run time rather than a fixed value. Design for that: a "phone number" field will usually hold a variable rather than a literal number.

Next steps

Next: The onEvent function, where the field values arrive.

On this page