Title Case
Synopsis
Converts strings to Title Case format.
Schema
- titlecase:
field: <ident>
target_field: <string>
fields: <array>
exclude: <array>
preserve_articles: <boolean>
description: <text>
if: <script>
ignore_failure: <boolean>
ignore_missing: <boolean>
on_failure: <processor[]>
on_success: <processor[]>
tag: <string>
Configuration
The following fields are used to define the processor:
| Field | Required | Default | Description |
|---|---|---|---|
field | N | - | Selects value mode: converts the value of this field to Title Case. The value must be a string or an array of strings. Mutually exclusive with fields — when field is set, fields and exclude are ignored |
target_field | N | Same as field | Where the converted value is written in value mode. Ignored in name mode |
fields | N | ["*"] | Selects name mode: glob patterns matching field names to rename to Title Case. The values are left untouched. a.* renames the keys inside object a, *.* those of every root object. Omitting both field and fields renames every root-level field name; names beginning with _ are never renamed |
exclude | N | - | Field names to leave alone in name mode. Has no effect in value mode |
description | N | - | Explanatory note |
if | N | - | Condition to run |
ignore_failure | N | false | Continue processing if conversion fails |
ignore_missing | N | false | Skip processing if referenced field doesn't exist |
on_failure | N | - | See Handling Failures |
on_success | N | - | See Handling Success |
tag | N | - | Identifier |
disabled | N | false | When true, the processor is skipped and the event continues to the next one. Lets you take a processor out of the path without removing its configuration |
Details
Converts string values to Title Case format by capitalizing the first letter of each word while keeping the rest lowercase. This format is commonly used for titles, headings, proper nouns, and display names.
The processor handles various input formats and applies proper Title Case rules, optionally preserving grammar rules for articles and prepositions.
Title Case format capitalizes the first letter of each significant word, resulting in format like "User Account Settings", "Data Processing Pipeline", or "System Configuration Value". This format is widely used for titles and headings.
When preserve_articles is enabled, common articles (a, an, the) and short prepositions (in, on, at, by, for, of, to, up) remain lowercase unless they appear at the beginning of the string.
The processor treats any whitespace or punctuation as word boundaries. Hyphenated words will have each part capitalized (e.g., "real-time" becomes "Real-Time").
Examples
Basic Title Case
Converting text to Title Case format... | |
converts to Title Case: | |
Article Preservation
Preserving articles in proper grammar format... | |
keeps articles lowercase: | |
Mixed Format Input
Converting mixed case input to proper Title Case... | |
normalizes to Title Case: | |
Multiple Fields
Renaming field names to Title Case, leaving values untouched... | |
renames the matched names; the values are unchanged: | |
Menu Item Formatting
Formatting navigation menu items... | |
formats each menu item: | |