Sorted Set
ZPOPMAX
Removes and returns up to count members with the highest scores in the sorted set stored at key.
Arguments
keybodystringrequired
The key of the sorted set
Response
integer
The number of elements removed. Defaults to 1.
Example
const popped = await redis.zpopmax("key", 4);