Skip to main content

Arguments

key
string
required
The key

Response

The number of seconds until this expires, negative if the key does not exist or does not have an expiration set.
const seconds = await redis.ttl(key);
I