URL-encodes the contents of a string field.

ParameterTypeRequiredDefaultDescription
asstringfalse_urlencodeName of output field.
fieldstringtrue The name of the input field with the value to url-encode. [a]
typestringfalse Type of encoding

[a] When you provide only one parameter, the implied parameter is field

Examples

With an event with a field Bar=https://www.humio.com, you get https%3A%2F%2Fwww.humio.com in the _urlencode field

logscale
urlEncode("Bar")

With an event with a field Bar=https://www.humio.com, you get https%3A%2F%2Fwww.humio.com in the Foo field

logscale
Foo:=urlEncode("Bar")

With an event with a field Bar=https://www.humio.com, you get https%3A%2F%2Fwww.humio.com in the Foo field

logscale
urlEncode("Bar", as="Foo")