String
36 commands. Toolkit id ooa.string.
| Command | What it does |
|---|---|
| Change case | Convert text to upper, lower, title or sentence case, or to camelCase, PascalCase, snake_case or kebab-case for names and keys. |
| Compare | Compare two texts exactly, ignoring case, or in natural order where numbers inside the text are compared by value. |
| Count occurrences | Count how many times a piece of text appears in a text (matches do not overlap). |
| Count words and lines | How many words, lines, sentences and characters a text has. |
| Encode or decode text | Make text safe for, or read it back from, a web address (URL), HTML, XML, JSON or Base64. |
| Escape for regex | Put a backslash before every character that has a meaning in regular expressions, so the text is matched exactly, e.g. 1+1=2? to 1+1=2?. |
| Extract text | Return the text before, after or between markers. |
| Extract with pattern | Take the parts of a text a pattern describes, e.g. the date, number and amount of "Invoice 42 of 2026-11-16: 99.50"; named parts come back as a Dictionary. |
| Fill a template | Put values into a text with {name} places, e.g. "Dear {first_name}, invoice {number} is due on {due}." from a Dictionary or a table row. |
| Find | Find where a text (or regular expression) first appears, starting from a position. |
| Find all matches | Every place a text or pattern occurs, as a list: all invoice numbers, e-mail addresses or amounts in a text. |
| Get length | Count the characters in a text. |
| Get part of text | Return the part of a text from a start position, for a length or up to an end position. |
| Insert text | Put text into another text at a position (counted from 0), at the start or at the end. |
| Join texts | Join the items of a list into one text with a separator, e.g. names into Ann, Bo and Cy, leaving out empty items if you like. |
| Mask text | Hide most of a text behind a character, keeping the first or last few, e.g. a card number as *********1111 or an e-mail as a@example.com. |
| Normalize spaces | Turn runs of spaces, tabs and no-break spaces into one space and trim the ends, keeping or joining the lines, e.g. for text read from web pages or PDFs. |
| Number to locale text | Write a number as text using the separators of a locale, e.g. 1.234,5 for de-DE. |
| Pad text | Fill a text up to a length with a character on the left or the right, e.g. 42 to 00042; longer text is left as it is. |
| Random text | Generate random text of a given length from letters, digits and/or symbols. |
| Remove characters | Strip digits, letters, punctuation, spaces, line breaks or accents (é becomes e), or characters you list, e.g. to clean phone numbers or IDs. |
| Remove part of text | Cut out a number of characters from a position (counted from 0), e.g. a prefix or a check digit. |
| Repeat text | Repeat a text a number of times, with a separator between, e.g. a line of dashes or placeholders. |
| Replace | Replace text, optionally using a regular expression. |
| Reverse | Return the text with its characters in reverse order. |
| Shorten text | Cut a text to a maximum length and add an ending such as …, if you like at a word break, e.g. for subjects, columns or messages. |
| Split | Split text into a list by a delimiter. |
| Text contains | True when the text has the other text in it, anywhere or as a whole word. |
| Text ends with | True when the text finishes with the other text. |
| Text is a number | True when the text is a number, e.g. 1,250.50 or -3. |
| Text is an email address | True when the text looks like an email address. |
| Text is empty | True when the text has no characters (or, if you like, only spaces). |
| Text matches a pattern | True when the text fits a regular expression, as a whole or somewhere in it, e.g. ^INV-\d{6}$ for an invoice number. |
| Text starts with | True when the text begins with the other text. |
| Text to number | Read a number from text written for a locale, or with the decimal and grouping separators you give. |
| Trim | Remove spaces, or the characters you list, from both ends, the start or the end of a text. |