aboutsummaryrefslogtreecommitdiff
path: root/examples/redis-unstable/src/commands/hpttl.json
diff options
context:
space:
mode:
authorMitja Felicijan <mitja.felicijan@gmail.com>2026-01-21 22:40:55 +0100
committerMitja Felicijan <mitja.felicijan@gmail.com>2026-01-21 22:40:55 +0100
commit5d8dfe892a2ea89f706ee140c3bdcfd89fe03fda (patch)
tree1acdfa5220cd13b7be43a2a01368e80d306473ca /examples/redis-unstable/src/commands/hpttl.json
parentc7ab12bba64d9c20ccd79b132dac475f7bc3923e (diff)
downloadcrep-5d8dfe892a2ea89f706ee140c3bdcfd89fe03fda.tar.gz
Add Redis source code for testing
Diffstat (limited to 'examples/redis-unstable/src/commands/hpttl.json')
-rw-r--r--examples/redis-unstable/src/commands/hpttl.json87
1 files changed, 87 insertions, 0 deletions
diff --git a/examples/redis-unstable/src/commands/hpttl.json b/examples/redis-unstable/src/commands/hpttl.json
new file mode 100644
index 0000000..c5cde0e
--- /dev/null
+++ b/examples/redis-unstable/src/commands/hpttl.json
@@ -0,0 +1,87 @@
1{
2 "HPTTL": {
3 "summary": "Returns the TTL in milliseconds of a hash field.",
4 "complexity": "O(N) where N is the number of specified fields",
5 "group": "hash",
6 "since": "7.4.0",
7 "arity": -5,
8 "function": "hpttlCommand",
9 "history": [],
10 "command_flags": [
11 "READONLY",
12 "FAST"
13 ],
14 "acl_categories": [
15 "HASH"
16 ],
17 "command_tips": [
18 "NONDETERMINISTIC_OUTPUT"
19 ],
20 "key_specs": [
21 {
22 "flags": [
23 "RO",
24 "ACCESS"
25 ],
26 "begin_search": {
27 "index": {
28 "pos": 1
29 }
30 },
31 "find_keys": {
32 "range": {
33 "lastkey": 0,
34 "step": 1,
35 "limit": 0
36 }
37 }
38 }
39 ],
40 "reply_schema": {
41 "description": "Array of results. Returns empty array if the key does not exist.",
42 "type": "array",
43 "minItems": 0,
44 "maxItems": 4294967295,
45 "items": {
46 "oneOf": [
47 {
48 "description": "The field does not exist.",
49 "const": -2
50 },
51 {
52 "description": "The field exists but has no associated expire.",
53 "const": -1
54 },
55 {
56 "description": "TTL in milliseconds.",
57 "type": "integer",
58 "minimum": 1
59 }
60 ]
61 }
62 },
63 "arguments": [
64 {
65 "name": "key",
66 "type": "key",
67 "key_spec_index": 0
68 },
69 {
70 "name": "fields",
71 "token": "FIELDS",
72 "type": "block",
73 "arguments": [
74 {
75 "name": "numfields",
76 "type": "integer"
77 },
78 {
79 "name": "field",
80 "type": "string",
81 "multiple": true
82 }
83 ]
84 }
85 ]
86 }
87}