Redis Enhanced icon

Redis Enhanced

Get, send and update data in Redis with enhanced operations

Overview

The node "Redis Enhanced" provides a comprehensive interface to interact with a Redis database, supporting a wide range of Redis operations including string manipulation, list handling, set and sorted set management, hash operations, key scanning, and Lua script execution. It is designed for users who want to get, send, update, or manage data in Redis with enhanced capabilities beyond basic commands.

A typical use case includes caching data, managing queues (lists), storing user sessions or configurations (hashes), publishing messages to channels, or performing atomic increments and conditional updates. For example, you can use the "Hash Set" operation to store structured JSON data under a specific field in a Redis hash, which is useful for maintaining user profiles or application settings.

Properties

Name Meaning
Hash The name of the Redis hash where the field will be set.
Field The specific field name within the hash to set the value for.
Value The value to assign to the specified field in the hash.
Value Is JSON Whether the provided value should be parsed as JSON before setting it in the hash.

Output

The output JSON object contains confirmation of the hash field being set, structured as:

{
  "hash": "name_of_hash",
  "field": "field_name",
  "value": <the_value_set>
}
  • The value field reflects the actual value stored, which may be a parsed JSON object if "Value Is JSON" is enabled.
  • No binary data output is produced by this operation.

Dependencies

  • Requires a connection to a Redis instance configured via an API key credential or equivalent authentication method.
  • The node depends on the Redis client library and utility functions bundled internally.
  • Proper Redis credentials must be configured in n8n for successful connection and command execution.

Troubleshooting

  • Invalid JSON Error: If "Value Is JSON" is enabled but the input value is not valid JSON, the node throws an error indicating invalid JSON. To fix, ensure the value is correctly formatted JSON or disable the "Value Is JSON" option.
  • Connection Issues: Errors related to connecting to Redis usually indicate misconfigured credentials or network issues. Verify Redis server availability and credential correctness.
  • Field or Hash Missing: Required parameters like "Hash" and "Field" must be provided; missing these will cause errors.
  • Permission Denied: Ensure the Redis user has permissions to perform hash set operations.
  • Unexpected Data Types: If the value is expected to be JSON but is plain text, parsing might fail. Confirm the data format matches the "Value Is JSON" setting.

Links and References

Discussion