Redis - Command
Execute commands on a Redis key-value store.
Sends one raw Redis command (GET, SET, HGET, LPUSH, DEL…) with its arguments and returns the Redis reply under result.
Connect your Redis instance and automate cache and data operations. Send any Redis command with arguments — from simple key-value reads to complex data structure manipulation.
Operations:
- GET / SET / MGET / MSET: Read and write string values, bulk operations.
- HGET / HSET / HGETALL: Work with hash maps (field-value pairs).
- LPUSH / RPUSH / LPOP / LRANGE: Manage ordered lists.
- SADD / SMEMBERS / SINTER: Work with sets and intersections.
- ZADD / ZRANGE / ZRANGEBYSCORE: Sorted sets with scoring.
- DEL / EXISTS / TTL / EXPIRE: Key lifecycle and expiration management.
- INCR / DECR: Atomic counters.
- PUBLISH: Publish messages to channels.
How it works
- Resolves the expressions of the node config. Empty
connection_idandcommandfall back to the incoming item;argsfalls back when it is missing or an empty array. - Resolves the connection: a
redis://URL inconnection_id, aconnection-stringcredential (any URL the client accepts, includingrediss://), or abasic-auth/objectcredential withhost,port(default 6379) and optionalpassword. - Upper-cases
command, dropsnull/undefinedarguments, converts the rest withString()and sends the command as is. - Disconnects and returns
{ result }onoutwith the reply: a string, a number,nullor an array, depending on the command.
In a workflow
The node as it appears in a workflow file (draft_nodes[]), and the envelope of a successful run.
{
"node_id": "node-cache-order",
"label": "Read cached order",
"operator_slug": "integrations.redis.command",
"operator_version": "1.0.0",
"config": {
"connection_id": "pi-credential-xxxx",
"command": "GET",
"args": [
"order:{{ $json.order_id }}"
]
}
}{
"ok": true,
"data": {
"result": "{\"status\":\"open\",\"total\":129.99}"
},
"port": "out"
}Configuration
-
connection_idstring Required -
Credential for your Redis instance. Accepts credentials of type `connection-string` (redis:// URI) or `basic-auth` (password + host + port).
-
commandstring Required Accepts expressions -
Redis command to execute (e.g., GET, SET, HGET, LPUSH, DEL).
-
argsarray Optional -
Command arguments (e.g., key, value, field name).
Behaviour in the code
What the implementation does with these keys beyond what the schema says.
-
args - Every argument is converted with
String(): an object becomes[object Object]. Serialize JSON values to a string before passing them. -
connection_id - A structured credential builds a plain
redis://URL without TLS and without a username. For TLS or ACL users, store the full URL as aconnection-stringcredential.
Output ports
out default Redis replied. A GET on a missing key also leaves here, with result: null.
{
"result": "{\"status\":\"open\",\"total\":129.99}"
}error Validation, credential resolution, the connection or the command failed.
{
"error": "WRONGTYPE Operation against a key holding the wrong kind of value"
}In expressions
What a later node can read from this node's output with $("Redis - Command").item.json.<path> (write your node's label instead of Redis - Command). Editor marks the paths the workflow editor suggests under Previous Nodes (the output contract); Worker marks the paths the worker really returns through out, from the output shown in Ports.
| Expression | Editor | Worker |
|---|---|---|
$("Redis - Command").item.json.resultRedis command response |
Errors
| Message | Port | Cause and fix |
|---|---|---|
connection_id is required | error | No credential in the config or in the incoming item. |
command is required | error | command is empty. |
Credential <connection_id> (type '<type>') missing host | error | A structured credential lacks host. |
ERR <Redis error message> | error | Redis rejected the command (unknown command, wrong number of arguments…); the message is passed through. |
Input contract
-
connection_idstring Required -
commandstring Required -
argsarray Optional
Output contract
-
resultobject Optional -
Redis command response
Contracts (JSON Schema)
The definition exactly as the orchestrator declares it. All is the whole *.definition.js; compare it with the sections above to spot differences between the documentation and the schema. Use it to validate a node before you publish.
{
"slug": "integrations.redis.command",
"name": "Redis - Command",
"category": "integrations",
"version": "1.0.0",
"description": "Execute commands on a Redis key-value store.\n\n Connect your Redis instance and automate cache and data operations. Send any Redis command with arguments — from simple key-value reads to complex data structure manipulation.\n\n **Operations:**\n - **GET / SET / MGET / MSET:** Read and write string values, bulk operations.\n - **HGET / HSET / HGETALL:** Work with hash maps (field-value pairs).\n - **LPUSH / RPUSH / LPOP / LRANGE:** Manage ordered lists.\n - **SADD / SMEMBERS / SINTER:** Work with sets and intersections.\n - **ZADD / ZRANGE / ZRANGEBYSCORE:** Sorted sets with scoring.\n - **DEL / EXISTS / TTL / EXPIRE:** Key lifecycle and expiration management.\n - **INCR / DECR:** Atomic counters.\n - **PUBLISH:** Publish messages to channels.",
"capabilities": [
"kv",
"cache",
"redis",
"database"
],
"group": [
{
"key": "redis",
"name": "Redis",
"icon_url": "/icons/integrations/redis/redis.svg"
}
],
"icon_url": "/icons/integrations/redis/redis.svg",
"config_schema": {
"type": "object",
"properties": {
"connection_id": {
"type": "string",
"title": "Redis Credential",
"description": "Credential for your Redis instance. Accepts credentials of type `connection-string` (redis:// URI) or `basic-auth` (password + host + port).",
"ui_widget": "connection_picker",
"ui_options": {
"credential_types": [
"connection-string",
"basic-auth"
],
"types": [
"redis"
]
}
},
"command": {
"type": "string",
"title": "Command",
"description": "Redis command to execute (e.g., GET, SET, HGET, LPUSH, DEL).",
"format": "expression"
},
"args": {
"type": "array",
"title": "Arguments",
"description": "Command arguments (e.g., key, value, field name)."
}
},
"required": [
"connection_id",
"command"
]
},
"input_contract_schema": {
"type": "object",
"properties": {
"connection_id": {
"type": "string"
},
"command": {
"type": "string"
},
"args": {
"type": "array"
}
},
"required": [
"connection_id",
"command"
]
},
"output_contract_schema": {
"type": "object",
"properties": {
"result": {
"type": "object",
"description": "Redis command response"
}
}
},
"ports": [
{
"port_id": "out",
"label": "Result",
"description": "Command result",
"is_default": true,
"supports_condition": true
},
{
"port_id": "error",
"label": "Error",
"description": "Command execution error",
"is_default": false,
"supports_condition": false
}
],
"execution_mode": "async",
"required_resources": [],
"compatible_worker_pools": [
"standard-io",
"fast-io"
],
"tags": [
"cache",
"kv"
],
"is_stateful": false,
"publisher": {
"identity": "org_sommatic_ai",
"profile": {
"name": "Sommatic AI",
"verified": true,
"url": "https://sommatic.ai",
"logo_url": null
}
}
}{
"type": "object",
"properties": {
"connection_id": {
"type": "string",
"title": "Redis Credential",
"description": "Credential for your Redis instance. Accepts credentials of type `connection-string` (redis:// URI) or `basic-auth` (password + host + port).",
"ui_widget": "connection_picker",
"ui_options": {
"credential_types": [
"connection-string",
"basic-auth"
],
"types": [
"redis"
]
}
},
"command": {
"type": "string",
"title": "Command",
"description": "Redis command to execute (e.g., GET, SET, HGET, LPUSH, DEL).",
"format": "expression"
},
"args": {
"type": "array",
"title": "Arguments",
"description": "Command arguments (e.g., key, value, field name)."
}
},
"required": [
"connection_id",
"command"
]
}{
"type": "object",
"properties": {
"connection_id": {
"type": "string"
},
"command": {
"type": "string"
},
"args": {
"type": "array"
}
},
"required": [
"connection_id",
"command"
]
}{
"type": "object",
"properties": {
"result": {
"type": "object",
"description": "Redis command response"
}
}
}[
{
"port_id": "out",
"label": "Result",
"description": "Command result",
"is_default": true,
"supports_condition": true
},
{
"port_id": "error",
"label": "Error",
"description": "Command execution error",
"is_default": false,
"supports_condition": false
}
]Execution
- Execution
async- Stateful
- No
- Credentials
- Resolved on the server from
connection_id; the secret never reaches the workflow. - Capabilities
kvcacheredisdatabase- Tags
cachekv
Notes and limits
- A new connection is opened and closed on every run; the node does not retry. Non-idempotent commands such as INCR or LPUSH run exactly once per execution.
Reviewed against the orchestrator code · 31e874b · 2026-11-26