Key Value
Key Value (key-value)
Parse key-value pairs, like “k1=v1,k2=v2,…”.
Transform json
Minimal example
actions: - key-value: {}JSON
{ "actions": [ { "key-value": {} } ]}Contents
Fields
| Field | Type | Required | Description |
|---|---|---|---|
description General | string | describe this step. | |
condition General | lua-expression (string) | Only run this action if the specified condition is met. Examples: 2 * count() | |
delim Parsing | string | The delimiter between pairs, defaults to comma. | |
suppress-warnings Warnings | boolean (bool) | Suppress warnings generated by this action. | |
input-field Input | field (string) | Field containing text to parse as key-value pairs. Examples: data_field | |
remove Output | boolean (bool) | Remove the field containing the value. | |
autoconvert Output | boolean (bool) | Convert values if possible. | |
key-value-delim Parsing | string | The delimiter between the key and the value, default equals. | |
multiple Output | Multiple | If there are multiple k-v pairs with the same key, choose which one to use E.g. “a=1,b=2,b=3’. Allowed values: first, last, array |
General
Show fields
| Field | Type | Required | Description |
|---|---|---|---|
description | string | describe this step. | |
condition | lua-expression (string) | Only run this action if the specified condition is met. Examples: 2 * count() |
Parsing
Show fields
| Field | Type | Required | Description |
|---|---|---|---|
delim | string | The delimiter between pairs, defaults to comma. | |
key-value-delim | string | The delimiter between the key and the value, default equals. |
Warnings
Show fields
| Field | Type | Required | Description |
|---|---|---|---|
suppress-warnings | boolean (bool) | Suppress warnings generated by this action. |
Input
Show fields
| Field | Type | Required | Description |
|---|---|---|---|
input-field | field (string) | Field containing text to parse as key-value pairs. Examples: data_field |
Output
Show fields
| Field | Type | Required | Description |
|---|---|---|---|
remove | boolean (bool) | Remove the field containing the value. | |
autoconvert | boolean (bool) | Convert values if possible. | |
multiple | Multiple | If there are multiple k-v pairs with the same key, choose which one to use E.g. “a=1,b=2,b=3’. Allowed values: first, last, array |
Schema
Multiple Options
| Value | Description |
|---|---|
first | First |
last | Last |
array | Array |