Example Node

Basic Example Node

Overview

This node, named "Example Node," is a basic transformation node designed to add or overwrite a string property in each input item’s JSON data. It takes an input string from the user and sets this string as the value of the myString field on every incoming data item. This node is useful when you want to annotate or tag data items with a consistent string value or inject a static piece of information into your workflow data.

Practical examples:

  • Adding a status label or category name to all items passing through.
  • Injecting a fixed comment or note into each data record for downstream processing.
  • Setting a default string value before sending data to another system.

Properties

Name Meaning
My String The string value to set on each item's myString field.

Output

The output consists of the same number of items as the input. Each item’s JSON data will have a new or updated property called myString containing the string provided by the user. No binary data is produced.

Output example (for one item):

{
  "myString": "User provided string value"
}

Dependencies

  • No external services or API keys are required.
  • This node only depends on n8n core runtime and standard node interfaces.

Troubleshooting

  • Empty or missing input: If no input data is provided, the node will simply return an empty array.
  • Invalid string input: Since the property expects a string, providing other types may cause unexpected results or errors.
  • Error handling: If an error occurs during processing an item, and the node is configured to continue on failure, the error details will be attached to the output item under an error property. Otherwise, the node will throw an error stopping execution.

Links and References

Discussion