Multi-Line Text Block Parser
Patterns for parsing structured text blocks — email bodies, legacy system output, report sections — by splitting on line delimiters and extracting key-value pairs.
Sign in or create a free account to copy this script.
Provided as-is, without warranty of any kind. Review and test each pattern in a non-production environment before deploying it to live automations. See our Terms.
Problem this solves
Email bodies and legacy system outputs contain data in semi-structured text that needs field-by-field extraction.
Usage Notes
- 1.Patterns 1-3 are designed to nest: Split lines (1), extract key-value (2), route to variables (3).
- 2.Delimiter flexibility: Pattern 2 splits on : but can be adapted for =, |, tab, or any delimiter.
- 3.Values containing delimiters: Pattern 2 handles values with colons by splitting and taking index [1].
- 4.Section extraction (Pattern 4): CropTextBetweenFlags returns text between markers, not including them.
- 5.DataTable initialization uses InputTable: { ^['col1', 'col2', ...] } syntax.