summaryrefslogtreecommitdiffstats
path: root/iredis/data/commands/type.md
blob: d27a7e83c6a1489c7b1ca9410c2066a1b979d363 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Returns the string representation of the type of the value stored at `key`. The
different types that can be returned are: `string`, `list`, `set`, `zset`,
`hash` and `stream`.

@return

@simple-string-reply: type of `key`, or `none` when `key` does not exist.

@examples

```cli
SET key1 "value"
LPUSH key2 "value"
SADD key3 "value"
TYPE key1
TYPE key2
TYPE key3
```