From 09ca521e3585bc1a0a29c89e6624a9b3388a4a5c Mon Sep 17 00:00:00 2001 From: rjmurray Date: Mon, 13 Jan 2025 15:31:26 +0000 Subject: [PATCH 1/3] plugin.spec sync --- plugins/string/.CHECKSUM | 8 ++-- plugins/string/bin/komand_string | 2 +- plugins/string/help.md | 47 +++++++------------ .../actions/split_to_object/schema.py | 2 +- plugins/string/plugin.spec.yaml | 7 +-- plugins/string/setup.py | 2 +- 6 files changed, 27 insertions(+), 41 deletions(-) diff --git a/plugins/string/.CHECKSUM b/plugins/string/.CHECKSUM index 3aadcd55be..dc62cc3956 100644 --- a/plugins/string/.CHECKSUM +++ b/plugins/string/.CHECKSUM @@ -1,7 +1,7 @@ { - "spec": "66e9ce90ef486ea29f7113995ed701ab", - "manifest": "1ec5f5cb6f45039155f589eb516e4e2b", - "setup": "9db7a8efac3085fd9937946ee94a5cec", + "spec": "af4772c66e6dfae2a41dbc24c4fafde9", + "manifest": "ff9feb5c62cc6078a3212085652011c3", + "setup": "394787d1ead943699cecc2712c114b1b", "schemas": [ { "identifier": "length/schema.py", @@ -25,7 +25,7 @@ }, { "identifier": "split_to_object/schema.py", - "hash": "d39a4841d4f5601bc93f5a28ae286eeb" + "hash": "69e573420b92e9c831d81e095534f76b" }, { "identifier": "trim/schema.py", diff --git a/plugins/string/bin/komand_string b/plugins/string/bin/komand_string index cfe15232cb..c8f9c9228e 100755 --- a/plugins/string/bin/komand_string +++ b/plugins/string/bin/komand_string @@ -7,7 +7,7 @@ from sys import argv Name = "String Operations" Vendor = "rapid7" Version = "1.4.2" -Description = "The String plugin provides common programmatic string operations" +Description = "The String Operations plugin allows easy manipulation of string data.This plugin utilizes the Python 3 String library [set of methods](https://docs.python.org/3/library/stdtypes.html#string-methods)" def main(): diff --git a/plugins/string/help.md b/plugins/string/help.md index 7aeec01ba8..e965a31461 100644 --- a/plugins/string/help.md +++ b/plugins/string/help.md @@ -2,7 +2,7 @@ The String Operations plugin allows easy manipulation of string data. -This plugin utilizes the Python 3 String library [set of methods](https://docs.python.org/3/library/stdtypes.html#string-methods). +This plugin utilizes the Python 3 String library [set of methods](https://docs.python.org/3/library/stdtypes.html#string-methods) # Key Features @@ -206,16 +206,22 @@ Example output: ``` #### Split String to Object - + This action is used to convert a string to an object containing key:value strings. -Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. -In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split -by the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. - -The [output schema object](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys. -It allows users the ability to use the green selector and choose a specific variable later in the workflow by name. -[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise. +Any input requiring more than a +single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. +In this case, the input string is +split by the `block_delimiter` character first, and the resulting items are then split +by the `string_delimiter` option. + Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. +The +[output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) +on the action's page can be modified to pre-populate the workflow with the names of the keys. +It allows users the +ability to use the green selector and choose a specific variable later in the workflow by name. +[Input +templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise ##### Input @@ -251,27 +257,6 @@ Example output: } ``` -Here is another example with a slightly more complex string input that contains multiple key:value pairs. -These pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign: - -``` -Computer_ID="bef41e8b-47b8-e188-8e43-3a2b662dd55d" Computer_Name="dgdemo\RGWin64" Computer_Type="Windows" -``` - -Setting `block_delimiter` to ` ` and `string_delimiter` to `=` will return the information presented in the example below. - -Example output: - -``` -{ - "object": { - "Computer_ID": "bef41e8b-47b8-e188-8e43-3a2b662dd55d", - "Computer_Name": "dgdemo\RGWin64", - "Computer_Type": "Windows" - } -} -``` - #### Trim This action is used to trim a string of leading and trailing whitespace @@ -348,7 +333,7 @@ Example output: ## Troubleshooting -There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead. +* There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead. # Version History diff --git a/plugins/string/komand_string/actions/split_to_object/schema.py b/plugins/string/komand_string/actions/split_to_object/schema.py index 76a8da5298..d13e1be9c9 100755 --- a/plugins/string/komand_string/actions/split_to_object/schema.py +++ b/plugins/string/komand_string/actions/split_to_object/schema.py @@ -4,7 +4,7 @@ class Component: - DESCRIPTION = "Converts a string to an object containing key:value strings" + DESCRIPTION = "This action is used to convert a string to an object containing key:value strings.Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then splitby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.The [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.It allows users the ability to use the green selector and choose a specific variable later in the workflow by name.[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise" class Input: diff --git a/plugins/string/plugin.spec.yaml b/plugins/string/plugin.spec.yaml index 42fcae1683..ef8ad322dd 100644 --- a/plugins/string/plugin.spec.yaml +++ b/plugins/string/plugin.spec.yaml @@ -3,7 +3,7 @@ extension: plugin products: [insightconnect] name: string title: String Operations -description: The String plugin provides common programmatic string operations +description: "The String Operations plugin allows easy manipulation of string data.\n\nThis plugin utilizes the Python 3 String library [set of methods](https://docs.python.org/3/library/stdtypes.html#string-methods)" version: 1.4.2 connection_version: 1 vendor: rapid7 @@ -43,7 +43,8 @@ version_history: - "1.1.0 - New action Set Encoding" - "1.0.1 - Update plugin tag from `util` to `utilities` for Marketplace searchability" - "1.0.0 - Initial plugin" -troubleshooting: "There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead." +troubleshooting: + - "There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead." links: - "[Python 3 String Methods](https://docs.python.org/3/library/stdtypes.html#string-methods)" references: @@ -109,7 +110,7 @@ actions: example: '["This", "is", "a", "sentence"]' split_to_object: title: Split String to Object - description: Converts a string to an object containing key:value strings + description: "This action is used to convert a string to an object containing key:value strings.\n\nAny input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.\nIn this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split\nby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.\nThe [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.\nIt allows users the ability to use the green selector and choose a specific variable later in the workflow by name.\n[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise" input: string: title: String Input diff --git a/plugins/string/setup.py b/plugins/string/setup.py index 1ab1abb37a..6cf722ca73 100755 --- a/plugins/string/setup.py +++ b/plugins/string/setup.py @@ -4,7 +4,7 @@ setup(name="string-rapid7-plugin", version="1.4.2", - description="The String plugin provides common programmatic string operations", + description="The String Operations plugin allows easy manipulation of string data.This plugin utilizes the Python 3 String library [set of methods](https://docs.python.org/3/library/stdtypes.html#string-methods)", author="rapid7", author_email="", url="", From 56ea67a8d679ec9e3d7342369ede941017ffb52e Mon Sep 17 00:00:00 2001 From: rjmurray Date: Mon, 13 Jan 2025 16:40:30 +0000 Subject: [PATCH 2/3] updaing help.md --- plugins/string/.CHECKSUM | 4 +-- plugins/string/help.md | 35 +++++++++++-------- .../actions/split_to_object/schema.py | 2 +- plugins/string/plugin.spec.yaml | 4 ++- 4 files changed, 26 insertions(+), 19 deletions(-) diff --git a/plugins/string/.CHECKSUM b/plugins/string/.CHECKSUM index dc62cc3956..817e207ce7 100644 --- a/plugins/string/.CHECKSUM +++ b/plugins/string/.CHECKSUM @@ -1,5 +1,5 @@ { - "spec": "af4772c66e6dfae2a41dbc24c4fafde9", + "spec": "c957502ef3eb0b416e91445e327d1d7a", "manifest": "ff9feb5c62cc6078a3212085652011c3", "setup": "394787d1ead943699cecc2712c114b1b", "schemas": [ @@ -25,7 +25,7 @@ }, { "identifier": "split_to_object/schema.py", - "hash": "69e573420b92e9c831d81e095534f76b" + "hash": "41201592318a69a4d5e9cb62d214b600" }, { "identifier": "trim/schema.py", diff --git a/plugins/string/help.md b/plugins/string/help.md index e965a31461..d7dbaab042 100644 --- a/plugins/string/help.md +++ b/plugins/string/help.md @@ -207,21 +207,7 @@ Example output: #### Split String to Object -This action is used to convert a string to an object containing key:value strings. - -Any input requiring more than a -single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. -In this case, the input string is -split by the `block_delimiter` character first, and the resulting items are then split -by the `string_delimiter` option. - Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. -The -[output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) -on the action's page can be modified to pre-populate the workflow with the names of the keys. -It allows users the -ability to use the green selector and choose a specific variable later in the workflow by name. -[Input -templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise +This action is used to convert a string to an object containing key:value strings ##### Input @@ -334,6 +320,25 @@ Example output: ## Troubleshooting * There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead. +* For the `Split String to Object` action:, + +Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. +In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split +by the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. + +The [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys. +It allows users the ability to use the green selector and choose a specific variable later in the workflow by name. +[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise + +* More complex string input that contains multiple key:value pairs. These pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign: + + ```Computer_ID="bef41e8b-47b8-e188-8e43-3a2b662dd55d" Computer_Name="dgdemo RGWin64" Computer_Type="Windows" ``` + + Setting `block_delimiter` to ` ` and `string_delimiter` to `=` will return the information presented in the example below. + + Example output: + + ``` { "object": { "Computer_ID": "bef41e8b-47b8-e188-8e43-3a2b662dd55d", "Computer_Name": "dgdemo RGWin64", "Computer_Type": "Windows" } } ``` # Version History diff --git a/plugins/string/komand_string/actions/split_to_object/schema.py b/plugins/string/komand_string/actions/split_to_object/schema.py index d13e1be9c9..81e15d18c2 100755 --- a/plugins/string/komand_string/actions/split_to_object/schema.py +++ b/plugins/string/komand_string/actions/split_to_object/schema.py @@ -4,7 +4,7 @@ class Component: - DESCRIPTION = "This action is used to convert a string to an object containing key:value strings.Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then splitby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.The [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.It allows users the ability to use the green selector and choose a specific variable later in the workflow by name.[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise" + DESCRIPTION = "This action is used to convert a string to an object containing key:value strings" class Input: diff --git a/plugins/string/plugin.spec.yaml b/plugins/string/plugin.spec.yaml index ef8ad322dd..425fde7081 100644 --- a/plugins/string/plugin.spec.yaml +++ b/plugins/string/plugin.spec.yaml @@ -45,6 +45,8 @@ version_history: - "1.0.0 - Initial plugin" troubleshooting: - "There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead." + - "For the `Split String to Object` action:, \n\nAny input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.\nIn this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split\nby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.\n\nThe [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.\nIt allows users the ability to use the green selector and choose a specific variable later in the workflow by name.\n[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise\n" + - "More complex string input that contains multiple key:value pairs. These pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign:\n\n ```Computer_ID=\"bef41e8b-47b8-e188-8e43-3a2b662dd55d\" Computer_Name=\"dgdemo\ RGWin64\" Computer_Type=\"Windows\" ``` \n\n Setting `block_delimiter` to ` ` and `string_delimiter` to `=` will return the information presented in the example below.\n\n Example output: \n\n ``` { \"object\": { \"Computer_ID\": \"bef41e8b-47b8-e188-8e43-3a2b662dd55d\", \"Computer_Name\": \"dgdemo\ RGWin64\", \"Computer_Type\": \"Windows\" } } ```" links: - "[Python 3 String Methods](https://docs.python.org/3/library/stdtypes.html#string-methods)" references: @@ -110,7 +112,7 @@ actions: example: '["This", "is", "a", "sentence"]' split_to_object: title: Split String to Object - description: "This action is used to convert a string to an object containing key:value strings.\n\nAny input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.\nIn this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split\nby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.\nThe [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.\nIt allows users the ability to use the green selector and choose a specific variable later in the workflow by name.\n[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise" + description: "This action is used to convert a string to an object containing key:value strings" input: string: title: String Input From b69d705cd96dc6a1547deaa7ec0a1112a00482c8 Mon Sep 17 00:00:00 2001 From: rjmurray Date: Tue, 14 Jan 2025 10:03:59 +0000 Subject: [PATCH 3/3] Updating help.md --- plugins/string/.CHECKSUM | 4 +- plugins/string/help.md | 39 ++++++++++--------- .../actions/split_to_object/schema.py | 2 +- plugins/string/plugin.spec.yaml | 5 +-- 4 files changed, 26 insertions(+), 24 deletions(-) diff --git a/plugins/string/.CHECKSUM b/plugins/string/.CHECKSUM index 817e207ce7..6c72bc9922 100644 --- a/plugins/string/.CHECKSUM +++ b/plugins/string/.CHECKSUM @@ -1,5 +1,5 @@ { - "spec": "c957502ef3eb0b416e91445e327d1d7a", + "spec": "f712d68ed3cdd1ab0abb816e1500f77d", "manifest": "ff9feb5c62cc6078a3212085652011c3", "setup": "394787d1ead943699cecc2712c114b1b", "schemas": [ @@ -25,7 +25,7 @@ }, { "identifier": "split_to_object/schema.py", - "hash": "41201592318a69a4d5e9cb62d214b600" + "hash": "67ae59d7cf96ba0f195ab4e26dfa6592" }, { "identifier": "trim/schema.py", diff --git a/plugins/string/help.md b/plugins/string/help.md index d7dbaab042..208a435c3f 100644 --- a/plugins/string/help.md +++ b/plugins/string/help.md @@ -207,7 +207,21 @@ Example output: #### Split String to Object -This action is used to convert a string to an object containing key:value strings +This action is used to convert a string to an object containing key:value strings. + +Any input requiring more than a +single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. In this case, the input string is +split by the `block_delimiter` character first, and the resulting items are then split by the `string_delimiter` option. + Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. + +The +[output object](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) +on the action's page can be modified to pre-populate the workflow with the names of the keys. It allows users the +ability to use the green selector and choose a specific variable later in the workflow by name. [Input +templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise. + + +Please refer to troubleshooting section for a more complex example ##### Input @@ -319,26 +333,15 @@ Example output: ## Troubleshooting -* There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead. -* For the `Split String to Object` action:, - -Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. -In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split -by the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it. - -The [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys. -It allows users the ability to use the green selector and choose a specific variable later in the workflow by name. -[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise - -* More complex string input that contains multiple key:value pairs. These pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign: +* `Split String to Object`: if the input contains multiple key:value pairs and these pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign we can follow the below example: - ```Computer_ID="bef41e8b-47b8-e188-8e43-3a2b662dd55d" Computer_Name="dgdemo RGWin64" Computer_Type="Windows" ``` + + Example text: `Computer_ID="bef41e8b-47b8-e188-8e43-3a2b662dd55d" Computer_Name="dgdemo\RGWin64" Computer_Type="Windows"` + + Example Input: `{"block_delimiter": " ","string": +"Computer_ID="bef41e8b-47b8-e188-8e43-3a2b662dd55d" Computer_Name="dgdemo RGWin64" Computer_Type="Windows","string_delimiter": "="}` + + Example output: `{ "object": { "Computer_ID": "bef41e8b-47b8-e188-8e43-3a2b662dd55d", "Computer_Name": "dgdemo RGWin64", "Computer_Type": "Windows" } }` - Setting `block_delimiter` to ` ` and `string_delimiter` to `=` will return the information presented in the example below. - Example output: - - ``` { "object": { "Computer_ID": "bef41e8b-47b8-e188-8e43-3a2b662dd55d", "Computer_Name": "dgdemo RGWin64", "Computer_Type": "Windows" } } ``` +* There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead. # Version History diff --git a/plugins/string/komand_string/actions/split_to_object/schema.py b/plugins/string/komand_string/actions/split_to_object/schema.py index 81e15d18c2..62a074997a 100755 --- a/plugins/string/komand_string/actions/split_to_object/schema.py +++ b/plugins/string/komand_string/actions/split_to_object/schema.py @@ -4,7 +4,7 @@ class Component: - DESCRIPTION = "This action is used to convert a string to an object containing key:value strings" + DESCRIPTION = "This action is used to convert a string to an object containing key:value strings.Any input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split by the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.The [output object](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys. It allows users the ability to use the green selector and choose a specific variable later in the workflow by name. [Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise.Please refer to troubleshooting section for a more complex example" class Input: diff --git a/plugins/string/plugin.spec.yaml b/plugins/string/plugin.spec.yaml index 425fde7081..ed8427cfa2 100644 --- a/plugins/string/plugin.spec.yaml +++ b/plugins/string/plugin.spec.yaml @@ -44,9 +44,8 @@ version_history: - "1.0.1 - Update plugin tag from `util` to `utilities` for Marketplace searchability" - "1.0.0 - Initial plugin" troubleshooting: + - "`Split String to Object`: if the input contains multiple key:value pairs and these pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign we can follow the below example:\n\n + Example text: `Computer_ID=\"bef41e8b-47b8-e188-8e43-3a2b662dd55d\" Computer_Name=\"dgdemo\\RGWin64\" Computer_Type=\"Windows\"`\n + Example Input: `{\"block_delimiter\": \" \",\"string\":\n\"Computer_ID=\"bef41e8b-47b8-e188-8e43-3a2b662dd55d\" Computer_Name=\"dgdemo RGWin64\" Computer_Type=\"Windows\",\"string_delimiter\": \"=\"}`\n + Example output: `{ \"object\": { \"Computer_ID\": \"bef41e8b-47b8-e188-8e43-3a2b662dd55d\", \"Computer_Name\": \"dgdemo RGWin64\", \"Computer_Type\": \"Windows\" } }`\n\n" - "There may be complex string manipulation needs that are likely outside the scope of this plugin. If this is the case, consider using the Python 3 Script plugin instead." - - "For the `Split String to Object` action:, \n\nAny input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option.\nIn this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split\nby the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.\n\nThe [output schema](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys.\nIt allows users the ability to use the green selector and choose a specific variable later in the workflow by name.\n[Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise\n" - - "More complex string input that contains multiple key:value pairs. These pairs are separated from each other by a space, and the keys and values within each pair are separated by an equal sign:\n\n ```Computer_ID=\"bef41e8b-47b8-e188-8e43-3a2b662dd55d\" Computer_Name=\"dgdemo\ RGWin64\" Computer_Type=\"Windows\" ``` \n\n Setting `block_delimiter` to ` ` and `string_delimiter` to `=` will return the information presented in the example below.\n\n Example output: \n\n ``` { \"object\": { \"Computer_ID\": \"bef41e8b-47b8-e188-8e43-3a2b662dd55d\", \"Computer_Name\": \"dgdemo\ RGWin64\", \"Computer_Type\": \"Windows\" } } ```" links: - "[Python 3 String Methods](https://docs.python.org/3/library/stdtypes.html#string-methods)" references: @@ -112,7 +111,7 @@ actions: example: '["This", "is", "a", "sentence"]' split_to_object: title: Split String to Object - description: "This action is used to convert a string to an object containing key:value strings" + description: "This action is used to convert a string to an object containing key:value strings.\n\nAny input requiring more than a single key:value pair, e.g. `USER=Bob` needs to use the `block_delimiter` option. In this case, the input string is split by the `block_delimiter` character first, and the resulting items are then split by the `string_delimiter` option. Stripping of double-quotes is automatically applied in this situation for each item before the plugin returns it.\n\nThe [output object](https://docs.komand.com/v0.42.1/docs/python-script-plugins#section-configure-the-plugin-output-schema) on the action's page can be modified to pre-populate the workflow with the names of the keys. It allows users the ability to use the green selector and choose a specific variable later in the workflow by name. [Input templating](https://docs.komand.com/docs/input-templating) would need to be used to obtain variables by name otherwise.\n\nPlease refer to troubleshooting section for a more complex example" input: string: title: String Input