Language URL stripper

Language URL stripper

Replace the language from the URL with a custom value

Configuration

OptionDescription
Pattern
Type: string
Required: True

Ininitalized with const regexp = new RegExp($pattern)

Match group
Type: string
Required: True

Used in: const value = regexp.match($pathname)[$matchGroup]

Property
Type: string
Required: True

Name of the event property we will store the matched value in

Replacement pattern
Type: string
Required: True

Initialized with new RegExp($pattern), leave empty to disable path cleanup.

Replacement key
Type: string
Required: True

Where to store the updated path. Keep as $pathname to override.

Replacement value
Type: string
Required: True

properties[key] = $pathname.replace(pattern, value)

Using our REST API you can create this transformation like so:

Terminal