CLUSTER MYID

Available since 3.0.0.

Time complexity: O(1)

Returns the node's id.

The CLUSTER MYID command returns the unique, auto-generated identifier that is associated with the connected cluster node.

*Return value

Bulk string reply: The node id.