Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ChainableCommander

Hierarchy

  • RedisCommander<{ type: "pipeline" }>
    • ChainableCommander

Index

Properties

Methods

Properties

length: number

Methods

  • acl(subcommand: "CAT", callback?: Callback<unknown>): ChainableCommander
  • acl(subcommand: "CAT", categoryname: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • acl(...args: [subcommand: "DELUSER", ...usernames: (string | Buffer)[], callback: Callback<number>]): ChainableCommander
  • acl(...args: [subcommand: "DELUSER", ...usernames: (string | Buffer)[]]): ChainableCommander
  • acl(subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, callback?: Callback<string>): ChainableCommander
  • acl(...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • acl(...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[]]): ChainableCommander
  • acl(subcommand: "GENPASS", callback?: Callback<string>): ChainableCommander
  • acl(subcommand: "GENPASS", bits: string | number, callback?: Callback<string>): ChainableCommander
  • acl(subcommand: "GETUSER", username: string | Buffer, callback?: Callback<string[]>): ChainableCommander
  • acl(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • acl(subcommand: "LIST", callback?: Callback<string[]>): ChainableCommander
  • acl(subcommand: "LOAD", callback?: Callback<"OK">): ChainableCommander
  • acl(subcommand: "LOG", callback?: Callback<unknown>): ChainableCommander
  • acl(subcommand: "LOG", count: string | number, callback?: Callback<unknown>): ChainableCommander
  • acl(subcommand: "LOG", reset: "RESET", callback?: Callback<unknown>): ChainableCommander
  • acl(subcommand: "SAVE", callback?: Callback<"OK">): ChainableCommander
  • acl(subcommand: "SETUSER", username: string | Buffer, callback?: Callback<"OK">): ChainableCommander
  • acl(...args: [subcommand: "SETUSER", username: string | Buffer, ...rules: (string | Buffer)[], callback: Callback<"OK">]): ChainableCommander
  • acl(...args: [subcommand: "SETUSER", username: string | Buffer, ...rules: (string | Buffer)[]]): ChainableCommander
  • acl(subcommand: "USERS", callback?: Callback<string[]>): ChainableCommander
  • acl(subcommand: "WHOAMI", callback?: Callback<string>): ChainableCommander
  • List the ACL categories or the commands inside a category

    • group: server
    • complexity: O(1) since the categories and commands are a fixed set.
    • since: 6.0.0

    Parameters

    • subcommand: "CAT"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CAT"
    • categoryname: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Remove the specified ACL users and the associated rules

    • group: server
    • complexity: O(1) amortized time considering the typical user.
    • since: 6.0.0

    Parameters

    • Rest ...args: [subcommand: "DELUSER", ...usernames: (string | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DELUSER", ...usernames: (string | Buffer)[]]

    Returns ChainableCommander

  • Returns whether the user can execute the given command without executing the command.

    • group: server
    • complexity: O(1).
    • since: 7.0.0

    Parameters

    • subcommand: "DRYRUN"
    • username: string | Buffer
    • command: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[], callback: Callback<string>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Generate a pseudorandom secure password to use for ACL users

    • group: server
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • subcommand: "GENPASS"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "GENPASS"
    • bits: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Get the rules for a specific ACL user

    • group: server
    • complexity: O(N). Where N is the number of password, command and pattern rules that the user has.
    • since: 6.0.0

    Parameters

    • subcommand: "GETUSER"
    • username: string | Buffer
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • List the current ACL rules in ACL config file format

    • group: server
    • complexity: O(N). Where N is the number of configured users.
    • since: 6.0.0

    Parameters

    • subcommand: "LIST"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Reload the ACLs from the configured ACL file

    • group: server
    • complexity: O(N). Where N is the number of configured users.
    • since: 6.0.0

    Parameters

    • subcommand: "LOAD"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • List latest events denied because of ACLs in place

    • group: server
    • complexity: O(N) with N being the number of entries shown.
    • since: 6.0.0

    Parameters

    • subcommand: "LOG"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LOG"
    • count: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LOG"
    • reset: "RESET"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Save the current ACL rules in the configured ACL file

    • group: server
    • complexity: O(N). Where N is the number of configured users.
    • since: 6.0.0

    Parameters

    • subcommand: "SAVE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Modify or create the rules for a specific ACL user

    • group: server
    • complexity: O(N). Where N is the number of rules provided.
    • since: 6.0.0

    Parameters

    • subcommand: "SETUSER"
    • username: string | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "SETUSER", username: string | Buffer, ...rules: (string | Buffer)[], callback: Callback<"OK">]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "SETUSER", username: string | Buffer, ...rules: (string | Buffer)[]]

    Returns ChainableCommander

  • List the username of all the configured ACL rules

    • group: server
    • complexity: O(N). Where N is the number of configured users.
    • since: 6.0.0

    Parameters

    • subcommand: "USERS"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Return the name of the user associated to the current connection

    • group: server
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • subcommand: "WHOAMI"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • aclBuffer(subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • aclBuffer(...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • aclBuffer(...args: [subcommand: "DRYRUN", username: string | Buffer, command: string | Buffer, ...args: (string | number | Buffer)[]]): ChainableCommander
  • aclBuffer(subcommand: "GENPASS", callback?: Callback<Buffer>): ChainableCommander
  • aclBuffer(subcommand: "GENPASS", bits: string | number, callback?: Callback<Buffer>): ChainableCommander
  • aclBuffer(subcommand: "GETUSER", username: string | Buffer, callback?: Callback<Buffer[]>): ChainableCommander
  • aclBuffer(subcommand: "LIST", callback?: Callback<Buffer[]>): ChainableCommander
  • aclBuffer(subcommand: "USERS", callback?: Callback<Buffer[]>): ChainableCommander
  • aclBuffer(subcommand: "WHOAMI", callback?: Callback<Buffer>): ChainableCommander
  • Append a value to a key

    • group: string
    • complexity: O(1). The amortized time complexity is O(1) assuming the appended value is small and the already present value is of any size, since the dynamic string library used by Redis will double the free space available on every reallocation.
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • value: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Sent by cluster clients after an -ASK redirect

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • auth(password: string | Buffer, callback?: Callback<"OK">): ChainableCommander
  • auth(username: string | Buffer, password: string | Buffer, callback?: Callback<"OK">): ChainableCommander
  • Authenticate to the server

    • group: connection
    • complexity: O(N) where N is the number of passwords defined for the user
    • since: 1.0.0

    Parameters

    • password: string | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • username: string | Buffer
    • password: string | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Asynchronously rewrite the append-only file

    • group: server
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<string>

    Returns ChainableCommander

  • bitfield(key: RedisKey, encodingOffsetToken: "GET", encoding: string | Buffer, offset: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, encodingOffsetValueToken: "SET", encoding: string | Buffer, offset: string | number, value: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, encodingOffsetIncrementToken: "INCRBY", encoding: string | Buffer, offset: string | number, increment: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", wrap: "WRAP", encodingOffsetValueToken: "SET", encoding: string | Buffer, offset: string | number, value: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", wrap: "WRAP", encodingOffsetIncrementToken: "INCRBY", encoding: string | Buffer, offset: string | number, increment: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", sat: "SAT", encodingOffsetValueToken: "SET", encoding: string | Buffer, offset: string | number, value: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", sat: "SAT", encodingOffsetIncrementToken: "INCRBY", encoding: string | Buffer, offset: string | number, increment: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", fail: "FAIL", encodingOffsetValueToken: "SET", encoding: string | Buffer, offset: string | number, value: string | number, callback?: Callback<unknown>): ChainableCommander
  • bitfield(key: RedisKey, overflow: "OVERFLOW", fail: "FAIL", encodingOffsetIncrementToken: "INCRBY", encoding: string | Buffer, offset: string | number, increment: string | number, callback?: Callback<unknown>): ChainableCommander
  • Perform arbitrary bitfield integer operations on strings

    • group: bitmap
    • complexity: O(1) for each subcommand specified
    • since: 3.2.0

    Parameters

    • key: RedisKey
    • encodingOffsetToken: "GET"
    • encoding: string | Buffer
    • offset: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • encodingOffsetValueToken: "SET"
    • encoding: string | Buffer
    • offset: string | number
    • value: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • encodingOffsetIncrementToken: "INCRBY"
    • encoding: string | Buffer
    • offset: string | number
    • increment: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • wrap: "WRAP"
    • encodingOffsetValueToken: "SET"
    • encoding: string | Buffer
    • offset: string | number
    • value: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • wrap: "WRAP"
    • encodingOffsetIncrementToken: "INCRBY"
    • encoding: string | Buffer
    • offset: string | number
    • increment: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • sat: "SAT"
    • encodingOffsetValueToken: "SET"
    • encoding: string | Buffer
    • offset: string | number
    • value: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • sat: "SAT"
    • encodingOffsetIncrementToken: "INCRBY"
    • encoding: string | Buffer
    • offset: string | number
    • increment: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • fail: "FAIL"
    • encodingOffsetValueToken: "SET"
    • encoding: string | Buffer
    • offset: string | number
    • value: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • overflow: "OVERFLOW"
    • fail: "FAIL"
    • encodingOffsetIncrementToken: "INCRBY"
    • encoding: string | Buffer
    • offset: string | number
    • increment: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • bitfield_ro(...args: [key: RedisKey, encodingOffsetToken: "GET", ...encodingOffsets: (string | number | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • bitfield_ro(...args: [key: RedisKey, encodingOffsetToken: "GET", ...encodingOffsets: (string | number | Buffer)[]]): ChainableCommander
  • Perform arbitrary bitfield integer operations on strings. Read-only variant of BITFIELD

    • group: bitmap
    • complexity: O(1) for each subcommand specified
    • since: 6.0.0

    Parameters

    • Rest ...args: [key: RedisKey, encodingOffsetToken: "GET", ...encodingOffsets: (string | number | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, encodingOffsetToken: "GET", ...encodingOffsets: (string | number | Buffer)[]]

    Returns ChainableCommander

  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • Pop elements from a list, or block until one is available

    • group: list
    • complexity: O(N+M) where N is the number of provided keys and M is the number of elements returned.
    • since: 7.0.0

    Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • blmpopBuffer(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]

    Returns ChainableCommander

  • Pop an element from a list, push it to another list and return it; or block until one is available

    • group: list
    • complexity: O(1)
    • since: 2.2.0

    Parameters

    • source: RedisKey
    • destination: RedisKey
    • timeout: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], min: "MIN", callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], min: "MIN", callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], min: "MIN"]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], min: "MIN"]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], max: "MAX", callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], max: "MAX", callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], max: "MAX"]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], max: "MAX"]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, ...keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number]): ChainableCommander
  • bzmpop(...args: [timeout: string | number, numkeys: string | number, keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number]): ChainableCommander
  • call(command: string, callback?: Callback<unknown>): ChainableCommander
  • call(command: string, args: (string | number | Buffer)[], callback?: Callback<unknown>): ChainableCommander
  • call(...args: [command: string, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • call(...args: [command: string, ...args: (string | number | Buffer)[]]): ChainableCommander
  • Call arbitrary commands.

    redis.call('set', 'foo', 'bar') is the same as redis.set('foo', 'bar'), so the only case you need to use this method is when the command is not supported by ioredis.

    redis.call('set', 'foo', 'bar');
    redis.call('get', 'foo', (err, value) => {
    // value === 'bar'
    });

    Parameters

    • command: string
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • command: string
    • args: (string | number | Buffer)[]
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [command: string, ...args: (string | number | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [command: string, ...args: (string | number | Buffer)[]]

    Returns ChainableCommander

  • callBuffer(command: string, callback?: Callback<unknown>): ChainableCommander
  • callBuffer(command: string, args: (string | number | Buffer)[], callback?: Callback<unknown>): ChainableCommander
  • callBuffer(...args: [command: string, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • callBuffer(...args: [command: string, ...args: (string | number | Buffer)[]]): ChainableCommander
  • client(subcommand: "CACHING", yes: "YES", callback?: Callback<"OK">): ChainableCommander
  • client(subcommand: "CACHING", no: "NO", callback?: Callback<"OK">): ChainableCommander
  • client(subcommand: "GETNAME", callback?: Callback<string>): ChainableCommander
  • client(subcommand: "GETREDIR", callback?: Callback<number>): ChainableCommander
  • client(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "ID", callback?: Callback<number>): ChainableCommander
  • client(subcommand: "INFO", callback?: Callback<string>): ChainableCommander
  • client(...args: [subcommand: "KILL", ...args: RedisValue[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "KILL", ...args: RedisValue[]]): ChainableCommander
  • client(subcommand: "LIST", callback?: Callback<unknown>): ChainableCommander
  • client(...args: [subcommand: "LIST", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "LIST", idToken: "ID", ...clientIds: (string | number)[]]): ChainableCommander
  • client(subcommand: "LIST", type: "TYPE", normal: "NORMAL", callback?: Callback<unknown>): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", normal: "NORMAL", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", normal: "NORMAL", idToken: "ID", ...clientIds: (string | number)[]]): ChainableCommander
  • client(subcommand: "LIST", type: "TYPE", master: "MASTER", callback?: Callback<unknown>): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", master: "MASTER", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", master: "MASTER", idToken: "ID", ...clientIds: (string | number)[]]): ChainableCommander
  • client(subcommand: "LIST", type: "TYPE", replica: "REPLICA", callback?: Callback<unknown>): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", replica: "REPLICA", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", replica: "REPLICA", idToken: "ID", ...clientIds: (string | number)[]]): ChainableCommander
  • client(subcommand: "LIST", type: "TYPE", pubsub: "PUBSUB", callback?: Callback<unknown>): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", pubsub: "PUBSUB", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "LIST", type: "TYPE", pubsub: "PUBSUB", idToken: "ID", ...clientIds: (string | number)[]]): ChainableCommander
  • client(subcommand: "NO-EVICT", on: "ON", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "NO-EVICT", off: "OFF", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "PAUSE", timeout: string | number, callback?: Callback<"OK">): ChainableCommander
  • client(subcommand: "PAUSE", timeout: string | number, write: "WRITE", callback?: Callback<"OK">): ChainableCommander
  • client(subcommand: "PAUSE", timeout: string | number, all: "ALL", callback?: Callback<"OK">): ChainableCommander
  • client(subcommand: "REPLY", on: "ON", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "REPLY", off: "OFF", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "REPLY", skip: "SKIP", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "SETNAME", connectionName: string | Buffer, callback?: Callback<"OK">): ChainableCommander
  • client(...args: [subcommand: "TRACKING", ...args: RedisValue[], callback: Callback<unknown>]): ChainableCommander
  • client(...args: [subcommand: "TRACKING", ...args: RedisValue[]]): ChainableCommander
  • client(subcommand: "TRACKINGINFO", callback?: Callback<string>): ChainableCommander
  • client(subcommand: "UNBLOCK", clientId: string | number, callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "UNBLOCK", clientId: string | number, timeout: "TIMEOUT", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "UNBLOCK", clientId: string | number, error: "ERROR", callback?: Callback<unknown>): ChainableCommander
  • client(subcommand: "UNPAUSE", callback?: Callback<"OK">): ChainableCommander
  • Instruct the server about tracking or not keys in the next request

    • group: connection
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • subcommand: "CACHING"
    • yes: "YES"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "CACHING"
    • no: "NO"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Get the current connection name

    • group: connection
    • complexity: O(1)
    • since: 2.6.9

    Parameters

    • subcommand: "GETNAME"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Get tracking notifications redirection client ID if any

    • group: connection
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • subcommand: "GETREDIR"
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: connection
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Returns the client ID for the current connection

    • group: connection
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "ID"
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Returns information about the current client connection.

    • group: connection
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "INFO"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Kill the connection of a client

    • group: connection
    • complexity: O(N) where N is the number of client connections
    • since: 2.4.0

    Parameters

    • Rest ...args: [subcommand: "KILL", ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "KILL", ...args: RedisValue[]]

    Returns ChainableCommander

  • Get the list of client connections

    • group: connection
    • complexity: O(N) where N is the number of client connections
    • since: 2.4.0

    Parameters

    • subcommand: "LIST"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", idToken: "ID", ...clientIds: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • type: "TYPE"
    • normal: "NORMAL"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", normal: "NORMAL", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", normal: "NORMAL", idToken: "ID", ...clientIds: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • type: "TYPE"
    • master: "MASTER"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", master: "MASTER", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", master: "MASTER", idToken: "ID", ...clientIds: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • type: "TYPE"
    • replica: "REPLICA"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", replica: "REPLICA", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", replica: "REPLICA", idToken: "ID", ...clientIds: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • type: "TYPE"
    • pubsub: "PUBSUB"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", pubsub: "PUBSUB", idToken: "ID", ...clientIds: (string | number)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LIST", type: "TYPE", pubsub: "PUBSUB", idToken: "ID", ...clientIds: (string | number)[]]

    Returns ChainableCommander

  • Set client eviction mode for the current connection

    • group: connection
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "NO-EVICT"
    • on: "ON"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "NO-EVICT"
    • off: "OFF"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Stop processing commands from clients for some time

    • group: connection
    • complexity: O(1)
    • since: 2.9.50

    Parameters

    • subcommand: "PAUSE"
    • timeout: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "PAUSE"
    • timeout: string | number
    • write: "WRITE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "PAUSE"
    • timeout: string | number
    • all: "ALL"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Instruct the server whether to reply to commands

    • group: connection
    • complexity: O(1)
    • since: 3.2.0

    Parameters

    • subcommand: "REPLY"
    • on: "ON"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "REPLY"
    • off: "OFF"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "REPLY"
    • skip: "SKIP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Set the current connection name

    • group: connection
    • complexity: O(1)
    • since: 2.6.9

    Parameters

    • subcommand: "SETNAME"
    • connectionName: string | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Enable or disable server assisted client side caching support

    • group: connection
    • complexity: O(1). Some options may introduce additional complexity.
    • since: 6.0.0

    Parameters

    • Rest ...args: [subcommand: "TRACKING", ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "TRACKING", ...args: RedisValue[]]

    Returns ChainableCommander

  • Return information about server assisted client side caching for the current connection

    • group: connection
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "TRACKINGINFO"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Unblock a client blocked in a blocking command from a different connection

    • group: connection
    • complexity: O(log N) where N is the number of client connections
    • since: 5.0.0

    Parameters

    • subcommand: "UNBLOCK"
    • clientId: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "UNBLOCK"
    • clientId: string | number
    • timeout: "TIMEOUT"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "UNBLOCK"
    • clientId: string | number
    • error: "ERROR"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Resume processing of clients that were paused

    • group: connection
    • complexity: O(N) Where N is the number of paused clients
    • since: 6.2.0

    Parameters

    • subcommand: "UNPAUSE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • cluster(...args: [subcommand: "ADDSLOTS", ...slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "ADDSLOTS", slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "ADDSLOTS", ...slots: (string | number)[]]): ChainableCommander
  • cluster(...args: [subcommand: "ADDSLOTS", slots: (string | number)[]]): ChainableCommander
  • cluster(...args: [subcommand: "ADDSLOTSRANGE", ...startSlotEndSlots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "ADDSLOTSRANGE", ...startSlotEndSlots: (string | number)[]]): ChainableCommander
  • cluster(subcommand: "BUMPEPOCH", callback?: Callback<"BUMPED" | "STILL">): ChainableCommander
  • cluster(subcommand: "COUNT-FAILURE-REPORTS", nodeId: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • cluster(subcommand: "COUNTKEYSINSLOT", slot: string | number, callback?: Callback<number>): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTS", ...slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTS", slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTS", ...slots: (string | number)[]]): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTS", slots: (string | number)[]]): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTSRANGE", ...startSlotEndSlots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]): ChainableCommander
  • cluster(...args: [subcommand: "DELSLOTSRANGE", ...startSlotEndSlots: (string | number)[]]): ChainableCommander
  • cluster(subcommand: "FAILOVER", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "FAILOVER", force: "FORCE", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "FAILOVER", takeover: "TAKEOVER", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "FLUSHSLOTS", callback?: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>): ChainableCommander
  • cluster(subcommand: "FORGET", nodeId: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "GETKEYSINSLOT", slot: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • cluster(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • cluster(subcommand: "INFO", callback?: Callback<string>): ChainableCommander
  • cluster(subcommand: "KEYSLOT", key: string | Buffer, callback?: Callback<number>): ChainableCommander
  • cluster(subcommand: "LINKS", callback?: Callback<unknown[]>): ChainableCommander
  • cluster(subcommand: "MEET", ip: string | Buffer, port: string | number, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "MYID", callback?: Callback<string>): ChainableCommander
  • cluster(subcommand: "NODES", callback?: Callback<unknown>): ChainableCommander
  • cluster(subcommand: "REPLICAS", nodeId: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • cluster(subcommand: "REPLICATE", nodeId: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "RESET", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "RESET", hard: "HARD", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "RESET", soft: "SOFT", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SAVECONFIG", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SET-CONFIG-EPOCH", configEpoch: string | number, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SETSLOT", slot: string | number, nodeIdToken: "IMPORTING", nodeId: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SETSLOT", slot: string | number, nodeIdToken: "MIGRATING", nodeId: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SETSLOT", slot: string | number, nodeIdToken: "NODE", nodeId: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SETSLOT", slot: string | number, stable: "STABLE", callback?: Callback<"OK">): ChainableCommander
  • cluster(subcommand: "SHARDS", callback?: Callback<unknown>): ChainableCommander
  • cluster(subcommand: "SLAVES", nodeId: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • cluster(subcommand: "SLOTS", callback?: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>): ChainableCommander
  • Assign new hash slots to receiving node

    • group: cluster
    • complexity: O(N) where N is the total number of hash slot arguments
    • since: 3.0.0

    Parameters

    • Rest ...args: [subcommand: "ADDSLOTS", ...slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "ADDSLOTS", slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "ADDSLOTS", ...slots: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "ADDSLOTS", slots: (string | number)[]]

    Returns ChainableCommander

  • Assign new hash slots to receiving node

    • group: cluster
    • complexity: O(N) where N is the total number of the slots between the start slot and end slot arguments.
    • since: 7.0.0

    Parameters

    • Rest ...args: [subcommand: "ADDSLOTSRANGE", ...startSlotEndSlots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "ADDSLOTSRANGE", ...startSlotEndSlots: (string | number)[]]

    Returns ChainableCommander

  • Advance the cluster config epoch

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "BUMPEPOCH"
    • Optional callback: Callback<"BUMPED" | "STILL">

    Returns ChainableCommander

  • Return the number of failure reports active for a given node

    • group: cluster
    • complexity: O(N) where N is the number of failure reports
    • since: 3.0.0

    Parameters

    • subcommand: "COUNT-FAILURE-REPORTS"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Return the number of local keys in the specified hash slot

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "COUNTKEYSINSLOT"
    • slot: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Set hash slots as unbound in receiving node

    • group: cluster
    • complexity: O(N) where N is the total number of hash slot arguments
    • since: 3.0.0

    Parameters

    • Rest ...args: [subcommand: "DELSLOTS", ...slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DELSLOTS", slots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DELSLOTS", ...slots: (string | number)[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DELSLOTS", slots: (string | number)[]]

    Returns ChainableCommander

  • Set hash slots as unbound in receiving node

    • group: cluster
    • complexity: O(N) where N is the total number of the slots between the start slot and end slot arguments.
    • since: 7.0.0

    Parameters

    • Rest ...args: [subcommand: "DELSLOTSRANGE", ...startSlotEndSlots: (string | number)[], callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DELSLOTSRANGE", ...startSlotEndSlots: (string | number)[]]

    Returns ChainableCommander

  • Forces a replica to perform a manual failover of its master.

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "FAILOVER"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "FAILOVER"
    • force: "FORCE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "FAILOVER"
    • takeover: "TAKEOVER"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Delete a node's own slots information

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "FLUSHSLOTS"
    • Optional callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>

    Returns ChainableCommander

  • Remove a node from the nodes table

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "FORGET"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Return local key names in the specified hash slot

    • group: cluster
    • complexity: O(log(N)) where N is the number of requested keys
    • since: 3.0.0

    Parameters

    • subcommand: "GETKEYSINSLOT"
    • slot: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: cluster
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Provides info about Redis Cluster node state

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "INFO"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Returns the hash slot of the specified key

    • group: cluster
    • complexity: O(N) where N is the number of bytes in the key
    • since: 3.0.0

    Parameters

    • subcommand: "KEYSLOT"
    • key: string | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Returns a list of all TCP links to and from peer nodes in cluster

    • group: cluster
    • complexity: O(N) where N is the total number of Cluster nodes
    • since: 7.0.0

    Parameters

    • subcommand: "LINKS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Force a node cluster to handshake with another node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "MEET"
    • ip: string | Buffer
    • port: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Return the node id

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "MYID"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Get Cluster config for the node

    • group: cluster
    • complexity: O(N) where N is the total number of Cluster nodes
    • since: 3.0.0

    Parameters

    • subcommand: "NODES"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • List replica nodes of the specified master node

    • group: cluster
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "REPLICAS"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Reconfigure a node as a replica of the specified master node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "REPLICATE"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Reset a Redis Cluster node

    • group: cluster
    • complexity: O(N) where N is the number of known nodes. The command may execute a FLUSHALL as a side effect.
    • since: 3.0.0

    Parameters

    • subcommand: "RESET"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "RESET"
    • hard: "HARD"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "RESET"
    • soft: "SOFT"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Forces the node to save cluster state on disk

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "SAVECONFIG"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Set the configuration epoch in a new node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "SET-CONFIG-EPOCH"
    • configEpoch: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Bind a hash slot to a specific node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "SETSLOT"
    • slot: string | number
    • nodeIdToken: "IMPORTING"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETSLOT"
    • slot: string | number
    • nodeIdToken: "MIGRATING"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETSLOT"
    • slot: string | number
    • nodeIdToken: "NODE"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETSLOT"
    • slot: string | number
    • stable: "STABLE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Get array of cluster slots to node mappings

    • group: cluster
    • complexity: O(N) where N is the total number of cluster nodes
    • since: 7.0.0

    Parameters

    • subcommand: "SHARDS"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • List replica nodes of the specified master node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • subcommand: "SLAVES"
    • nodeId: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get array of Cluster slot to node mappings

    • group: cluster
    • complexity: O(N) where N is the total number of Cluster nodes
    • since: 3.0.0

    Parameters

    • subcommand: "SLOTS"
    • Optional callback: Callback<[startSlotRange: number, endSlotRange: number, ...nodes: [host: string, port: number, nodeId: string, info: unknown[]][]][]>

    Returns ChainableCommander

  • command(subcommand: "COUNT", callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "DOCS", callback?: Callback<unknown[]>): ChainableCommander
  • command(...args: [subcommand: "DOCS", ...commandNames: (string | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • command(...args: [subcommand: "DOCS", ...commandNames: (string | Buffer)[]]): ChainableCommander
  • command(subcommand: "GETKEYS", callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "GETKEYSANDFLAGS", callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "HELP", callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "INFO", callback?: Callback<unknown[]>): ChainableCommander
  • command(...args: [subcommand: "INFO", ...commandNames: (string | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • command(...args: [subcommand: "INFO", ...commandNames: (string | Buffer)[]]): ChainableCommander
  • command(subcommand: "LIST", callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "LIST", filterby: "FILTERBY", moduleNameToken: "MODULE", moduleName: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "LIST", filterby: "FILTERBY", categoryToken: "ACLCAT", category: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • command(subcommand: "LIST", filterby: "FILTERBY", patternToken: "PATTERN", pattern: string, callback?: Callback<unknown[]>): ChainableCommander
  • Get total number of Redis commands

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "COUNT"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get array of specific Redis command documentation

    • group: server
    • complexity: O(N) where N is the number of commands to look up
    • since: 7.0.0

    Parameters

    • subcommand: "DOCS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DOCS", ...commandNames: (string | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "DOCS", ...commandNames: (string | Buffer)[]]

    Returns ChainableCommander

  • Extract keys given a full Redis command

    • group: server
    • complexity: O(N) where N is the number of arguments to the command
    • since: 2.8.13

    Parameters

    • subcommand: "GETKEYS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Extract keys and access flags given a full Redis command

    • group: server
    • complexity: O(N) where N is the number of arguments to the command
    • since: 7.0.0

    Parameters

    • subcommand: "GETKEYSANDFLAGS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get array of specific Redis command details, or all when no argument is given.

    • group: server
    • complexity: O(N) where N is the number of commands to look up
    • since: 2.8.13

    Parameters

    • subcommand: "INFO"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "INFO", ...commandNames: (string | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "INFO", ...commandNames: (string | Buffer)[]]

    Returns ChainableCommander

  • Get an array of Redis command names

    • group: server
    • complexity: O(N) where N is the total number of Redis commands
    • since: 7.0.0

    Parameters

    • subcommand: "LIST"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • filterby: "FILTERBY"
    • moduleNameToken: "MODULE"
    • moduleName: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • filterby: "FILTERBY"
    • categoryToken: "ACLCAT"
    • category: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • filterby: "FILTERBY"
    • patternToken: "PATTERN"
    • pattern: string
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • config(...args: [subcommand: "GET", ...parameters: (string | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • config(...args: [subcommand: "GET", ...parameters: (string | Buffer)[]]): ChainableCommander
  • config(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • config(subcommand: "RESETSTAT", callback?: Callback<unknown>): ChainableCommander
  • config(subcommand: "REWRITE", callback?: Callback<unknown>): ChainableCommander
  • config(...args: [subcommand: "SET", ...parameterValues: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • config(...args: [subcommand: "SET", ...parameterValues: (string | number | Buffer)[]]): ChainableCommander
  • Get the values of configuration parameters

    • group: server
    • complexity: O(N) when N is the number of configuration parameters provided
    • since: 2.0.0

    Parameters

    • Rest ...args: [subcommand: "GET", ...parameters: (string | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "GET", ...parameters: (string | Buffer)[]]

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Reset the stats returned by INFO

    • group: server
    • complexity: O(1)
    • since: 2.0.0

    Parameters

    • subcommand: "RESETSTAT"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Rewrite the configuration file with the in memory configuration

    • group: server
    • complexity: O(1)
    • since: 2.8.0

    Parameters

    • subcommand: "REWRITE"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Set configuration parameters to the given values

    • group: server
    • complexity: O(N) when N is the number of configuration parameters provided
    • since: 2.0.0

    Parameters

    • Rest ...args: [subcommand: "SET", ...parameterValues: (string | number | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "SET", ...parameterValues: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Return the number of keys in the selected database

    • group: server
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<number>

    Returns ChainableCommander

  • debug(subcommand: string, callback?: Callback<unknown>): ChainableCommander
  • debug(...args: [subcommand: string, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • debug(...args: [subcommand: string, ...args: (string | number | Buffer)[]]): ChainableCommander
  • Decrement the integer value of a key by the given number

    • group: string
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • decrement: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Discard all commands issued after MULTI

    • group: transactions
    • complexity: O(N), when N is the number of queued commands
    • since: 2.0.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Return a serialized version of the value stored at the specified key.

    • group: generic
    • complexity: O(1) to access the key and additional O(NM) to serialize it, where N is the number of Redis objects composing the value and M their average size. For small string values the time complexity is thus O(1)+O(1M) where M is small, so simply O(1).
    • since: 2.6.0

    Parameters

    • key: RedisKey
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Echo the given string

    • group: connection
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • message: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • eval(script: string | Buffer, numkeys: string | number, callback?: Callback<unknown>): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...args: (string | number | Buffer)[]]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...keys: RedisKey[], callback: Callback<unknown>]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, keys: RedisKey[], callback: Callback<unknown>]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...args: RedisValue[], callback: Callback<unknown>]): ChainableCommander
  • eval(...args: [script: string | Buffer, numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • evalsha(sha1: string | Buffer, numkeys: string | number, callback?: Callback<unknown>): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...args: (string | number | Buffer)[]]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...keys: RedisKey[], callback: Callback<unknown>]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, keys: RedisKey[], callback: Callback<unknown>]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...args: RedisValue[], callback: Callback<unknown>]): ChainableCommander
  • evalsha(...args: [sha1: string | Buffer, numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • exec(callback?: Callback<[error: Error, result: unknown][]>): Promise<[error: Error, result: unknown][]>
  • Execute all commands issued after MULTI

    • group: transactions
    • complexity: Depends on commands in the transaction
    • since: 1.2.0

    Parameters

    • Optional callback: Callback<[error: Error, result: unknown][]>

    Returns Promise<[error: Error, result: unknown][]>

  • failover(callback?: Callback<"OK">): ChainableCommander
  • failover(millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(abort: "ABORT", callback?: Callback<"OK">): ChainableCommander
  • failover(abort: "ABORT", millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, abort: "ABORT", callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, abort: "ABORT", millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, force: "FORCE", callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, force: "FORCE", millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, force: "FORCE", abort: "ABORT", callback?: Callback<"OK">): ChainableCommander
  • failover(targetToken: "TO", host: string | Buffer, port: string | number, force: "FORCE", abort: "ABORT", millisecondsToken: "TIMEOUT", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • Start a coordinated failover between this server and one of its replicas.

    • group: server
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • abort: "ABORT"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • abort: "ABORT"
    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • abort: "ABORT"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • abort: "ABORT"
    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • force: "FORCE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • force: "FORCE"
    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • force: "FORCE"
    • abort: "ABORT"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • targetToken: "TO"
    • host: string | Buffer
    • port: string | number
    • force: "FORCE"
    • abort: "ABORT"
    • millisecondsToken: "TIMEOUT"
    • milliseconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • function(subcommand: "DELETE", libraryName: string | Buffer, callback?: Callback<string>): ChainableCommander
  • function(subcommand: "DUMP", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "FLUSH", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "FLUSH", async: "ASYNC", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "FLUSH", sync: "SYNC", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • function(subcommand: "KILL", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "LIST", callback?: Callback<unknown[]>): ChainableCommander
  • function(subcommand: "LIST", withcode: "WITHCODE", callback?: Callback<unknown[]>): ChainableCommander
  • function(subcommand: "LIST", libraryNamePatternToken: "LIBRARYNAME", libraryNamePattern: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • function(subcommand: "LIST", libraryNamePatternToken: "LIBRARYNAME", libraryNamePattern: string | Buffer, withcode: "WITHCODE", callback?: Callback<unknown[]>): ChainableCommander
  • function(subcommand: "LOAD", functionCode: string | Buffer, callback?: Callback<string>): ChainableCommander
  • function(subcommand: "LOAD", replace: "REPLACE", functionCode: string | Buffer, callback?: Callback<string>): ChainableCommander
  • function(subcommand: "RESTORE", serializedValue: string | number | Buffer, callback?: Callback<string>): ChainableCommander
  • function(subcommand: "RESTORE", serializedValue: string | number | Buffer, flush: "FLUSH", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "RESTORE", serializedValue: string | number | Buffer, append: "APPEND", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "RESTORE", serializedValue: string | number | Buffer, replace: "REPLACE", callback?: Callback<string>): ChainableCommander
  • function(subcommand: "STATS", callback?: Callback<unknown>): ChainableCommander
  • Delete a function by name

    • group: scripting
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "DELETE"
    • libraryName: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Dump all functions into a serialized binary payload

    • group: scripting
    • complexity: O(N) where N is the number of functions
    • since: 7.0.0

    Parameters

    • subcommand: "DUMP"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Deleting all functions

    • group: scripting
    • complexity: O(N) where N is the number of functions deleted
    • since: 7.0.0

    Parameters

    • subcommand: "FLUSH"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "FLUSH"
    • async: "ASYNC"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "FLUSH"
    • sync: "SYNC"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: scripting
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Kill the function currently in execution.

    • group: scripting
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "KILL"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • List information about all the functions

    • group: scripting
    • complexity: O(N) where N is the number of functions
    • since: 7.0.0

    Parameters

    • subcommand: "LIST"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • withcode: "WITHCODE"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • libraryNamePatternToken: "LIBRARYNAME"
    • libraryNamePattern: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LIST"
    • libraryNamePatternToken: "LIBRARYNAME"
    • libraryNamePattern: string | Buffer
    • withcode: "WITHCODE"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Create a function with the given arguments (name, code, description)

    • group: scripting
    • complexity: O(1) (considering compilation time is redundant)
    • since: 7.0.0

    Parameters

    • subcommand: "LOAD"
    • functionCode: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "LOAD"
    • replace: "REPLACE"
    • functionCode: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Restore all the functions on the given payload

    • group: scripting
    • complexity: O(N) where N is the number of functions on the payload
    • since: 7.0.0

    Parameters

    • subcommand: "RESTORE"
    • serializedValue: string | number | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "RESTORE"
    • serializedValue: string | number | Buffer
    • flush: "FLUSH"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "RESTORE"
    • serializedValue: string | number | Buffer
    • append: "APPEND"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Parameters

    • subcommand: "RESTORE"
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Return information about the function currently running (name, description, duration)

    • group: scripting
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "STATS"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • functionBuffer(subcommand: "DELETE", libraryName: string | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "DUMP", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "FLUSH", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "FLUSH", async: "ASYNC", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "FLUSH", sync: "SYNC", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "KILL", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "LOAD", functionCode: string | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "LOAD", replace: "REPLACE", functionCode: string | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "RESTORE", serializedValue: string | number | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "RESTORE", serializedValue: string | number | Buffer, flush: "FLUSH", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "RESTORE", serializedValue: string | number | Buffer, append: "APPEND", callback?: Callback<Buffer>): ChainableCommander
  • functionBuffer(subcommand: "RESTORE", serializedValue: string | number | Buffer, replace: "REPLACE", callback?: Callback<Buffer>): ChainableCommander
  • geoadd(...args: [key: RedisKey, ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geoadd(...args: [key: RedisKey, ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geoadd(...args: [key: RedisKey, nx: "NX", ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, nx: "NX", ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geoadd(...args: [key: RedisKey, nx: "NX", ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, nx: "NX", ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geoadd(...args: [key: RedisKey, xx: "XX", ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, xx: "XX", ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geoadd(...args: [key: RedisKey, xx: "XX", ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • geoadd(...args: [key: RedisKey, xx: "XX", ch: "CH", ...longitudeLatitudeMembers: (string | number | Buffer)[]]): ChainableCommander
  • geodist(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, callback?: Callback<string>): ChainableCommander
  • geodist(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, m: "M", callback?: Callback<string>): ChainableCommander
  • geodist(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, km: "KM", callback?: Callback<string>): ChainableCommander
  • geodist(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, ft: "FT", callback?: Callback<string>): ChainableCommander
  • geodist(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, mi: "MI", callback?: Callback<string>): ChainableCommander
  • geodistBuffer(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • geodistBuffer(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, m: "M", callback?: Callback<Buffer>): ChainableCommander
  • geodistBuffer(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, km: "KM", callback?: Callback<Buffer>): ChainableCommander
  • geodistBuffer(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, ft: "FT", callback?: Callback<Buffer>): ChainableCommander
  • geodistBuffer(key: RedisKey, member1: string | number | Buffer, member2: string | number | Buffer, mi: "MI", callback?: Callback<Buffer>): ChainableCommander
  • Query a sorted set representing a geospatial index to fetch members matching a given maximum distance from a point

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements inside the bounding box of the circular area delimited by center and radius and M is the number of items inside the index.
    • since: 3.2.0

    Parameters

    • Rest ...args: [key: RedisKey, longitude: string | number, latitude: string | number, radius: string | number, ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, longitude: string | number, latitude: string | number, radius: string | number, ...args: RedisValue[]]

    Returns ChainableCommander

  • A read-only variant for GEORADIUS

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements inside the bounding box of the circular area delimited by center and radius and M is the number of items inside the index.
    • since: 3.2.10

    Parameters

    • Rest ...args: [key: RedisKey, longitude: string | number, latitude: string | number, radius: string | number, ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, longitude: string | number, latitude: string | number, radius: string | number, ...args: RedisValue[]]

    Returns ChainableCommander

  • Query a sorted set representing a geospatial index to fetch members matching a given maximum distance from a member

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements inside the bounding box of the circular area delimited by center and radius and M is the number of items inside the index.
    • since: 3.2.0

    Parameters

    • Rest ...args: [key: RedisKey, member: string | number | Buffer, radius: string | number, ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, member: string | number | Buffer, radius: string | number, ...args: RedisValue[]]

    Returns ChainableCommander

  • A read-only variant for GEORADIUSBYMEMBER

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements inside the bounding box of the circular area delimited by center and radius and M is the number of items inside the index.
    • since: 3.2.10

    Parameters

    • Rest ...args: [key: RedisKey, member: string | number | Buffer, radius: string | number, ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, member: string | number | Buffer, radius: string | number, ...args: RedisValue[]]

    Returns ChainableCommander

  • Query a sorted set representing a geospatial index to fetch members inside an area of a box or a circle.

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements in the grid-aligned bounding box area around the shape provided as the filter and M is the number of items inside the shape
    • since: 6.2.0

    Parameters

    Returns ChainableCommander

  • Parameters

    Returns ChainableCommander

  • Query a sorted set representing a geospatial index to fetch members inside an area of a box or a circle, and store the result in another key.

    • group: geo
    • complexity: O(N+log(M)) where N is the number of elements in the grid-aligned bounding box area around the shape provided as the filter and M is the number of items inside the shape
    • since: 6.2.0

    Parameters

    Returns ChainableCommander

  • Parameters

    Returns ChainableCommander

  • Returns the bit value at offset in the string value stored at key

    • group: bitmap
    • complexity: O(1)
    • since: 2.2.0

    Parameters

    • key: RedisKey
    • offset: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Get a substring of the string stored at a key

    • group: string
    • complexity: O(N) where N is the length of the returned string. The complexity is ultimately determined by the returned length, but because creating a substring from an existing string is very cheap, it can be considered O(1) for small strings.
    • since: 2.4.0

    Parameters

    • key: RedisKey
    • start: string | number
    • end: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Set the string value of a key and return its old value

    • group: string
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • value: string | number | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • hello(callback?: Callback<unknown[]>): ChainableCommander
  • hello(protover: string | number, callback?: Callback<unknown[]>): ChainableCommander
  • hello(protover: string | number, clientnameToken: "SETNAME", clientname: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • hello(protover: string | number, usernamePasswordToken: "AUTH", username: string | Buffer, password: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • hello(protover: string | number, usernamePasswordToken: "AUTH", username: string | Buffer, password: string | Buffer, clientnameToken: "SETNAME", clientname: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • Handshake with Redis

    • group: connection
    • complexity: O(1)
    • since: 6.0.0

    Parameters

    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • protover: string | number
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • protover: string | number
    • clientnameToken: "SETNAME"
    • clientname: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • protover: string | number
    • usernamePasswordToken: "AUTH"
    • username: string | Buffer
    • password: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • protover: string | number
    • usernamePasswordToken: "AUTH"
    • username: string | Buffer
    • password: string | Buffer
    • clientnameToken: "SETNAME"
    • clientname: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get all the fields and values in a hash

    • group: hash
    • complexity: O(N) where N is the size of the hash.
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • Optional callback: Callback<Record<string, string>>

    Returns ChainableCommander

  • Increment the integer value of a hash field by the given number

    • group: hash
    • complexity: O(1)
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • field: string | Buffer
    • increment: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Increment the float value of a hash field by the given amount

    • group: hash
    • complexity: O(1)
    • since: 2.6.0

    Parameters

    • key: RedisKey
    • field: string | Buffer
    • increment: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • hincrbyfloatBuffer(key: RedisKey, field: string | Buffer, increment: string | number, callback?: Callback<Buffer>): ChainableCommander
  • hscan(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • hscan(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • hscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • hscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • Incrementally iterate hash fields and associated values

    • group: hash
    • complexity: O(1) for every call. O(N) for a complete iteration, including enough command calls for the cursor to return back to 0. N is the number of elements inside the collection..
    • since: 2.8.0

    Parameters

    • key: RedisKey
    • cursor: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • hscanBuffer(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • hscanBuffer(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • hscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • hscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • Set the value of a hash field, only if the field does not exist

    • group: hash
    • complexity: O(1)
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • field: string | Buffer
    • value: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Increment the integer value of a key by the given amount

    • group: string
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • increment: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Increment the float value of a key by the given amount

    • group: string
    • complexity: O(1)
    • since: 2.6.0

    Parameters

    • key: RedisKey
    • increment: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Find all keys matching the given pattern

    • group: generic
    • complexity: O(N) with N being the number of keys in the database, under the assumption that the key names in the database and the given pattern have limited length.
    • since: 1.0.0

    Parameters

    • pattern: string
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Get the UNIX time stamp of the last successful save to disk

    • group: server
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<number>

    Returns ChainableCommander

  • latency(subcommand: "DOCTOR", callback?: Callback<string>): ChainableCommander
  • latency(subcommand: "GRAPH", event: string | Buffer, callback?: Callback<string>): ChainableCommander
  • latency(subcommand: "HELP", callback?: Callback<unknown[]>): ChainableCommander
  • latency(subcommand: "HISTOGRAM", callback?: Callback<unknown>): ChainableCommander
  • latency(...args: [subcommand: "HISTOGRAM", ...commands: (string | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • latency(...args: [subcommand: "HISTOGRAM", ...commands: (string | Buffer)[]]): ChainableCommander
  • latency(subcommand: "HISTORY", event: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • latency(subcommand: "LATEST", callback?: Callback<unknown[]>): ChainableCommander
  • latency(subcommand: "RESET", callback?: Callback<number>): ChainableCommander
  • latency(...args: [subcommand: "RESET", ...events: (string | Buffer)[], callback: Callback<number>]): ChainableCommander
  • latency(...args: [subcommand: "RESET", ...events: (string | Buffer)[]]): ChainableCommander
  • Return a human readable latency analysis report.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "DOCTOR"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Return a latency graph for the event.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "GRAPH"
    • event: string | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Show helpful text about the different subcommands.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Return the cumulative distribution of latencies of a subset of commands or all.

    • group: server
    • complexity: O(N) where N is the number of commands with latency information being retrieved.
    • since: 7.0.0

    Parameters

    • subcommand: "HISTOGRAM"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "HISTOGRAM", ...commands: (string | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "HISTOGRAM", ...commands: (string | Buffer)[]]

    Returns ChainableCommander

  • Return timestamp-latency samples for the event.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "HISTORY"
    • event: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Return the latest latency samples for all events.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "LATEST"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Reset latency data for one or more events.

    • group: server
    • complexity: O(1)
    • since: 2.8.13

    Parameters

    • subcommand: "RESET"
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "RESET", ...events: (string | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "RESET", ...events: (string | Buffer)[]]

    Returns ChainableCommander

  • Get an element from a list by its index

    • group: list
    • complexity: O(N) where N is the number of elements to traverse to get to the element at index. This makes asking for the first or the last element of the list O(1).
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • index: string | number
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • linsert(key: RedisKey, before: "BEFORE", pivot: string | number | Buffer, element: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • linsert(key: RedisKey, after: "AFTER", pivot: string | number | Buffer, element: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • Insert an element before or after another element in a list

    • group: list
    • complexity: O(N) where N is the number of elements to traverse before seeing the value pivot. This means that inserting somewhere on the left end on the list (head) can be considered O(1) and inserting somewhere on the right end (tail) is O(N).
    • since: 2.2.0

    Parameters

    • key: RedisKey
    • before: "BEFORE"
    • pivot: string | number | Buffer
    • element: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • after: "AFTER"
    • pivot: string | number | Buffer
    • element: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: string, members: string[]]>]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpop(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT"]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], left: "LEFT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT"]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number, callback: Callback<[key: Buffer, members: Buffer[]]>]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lmpopBuffer(...args: [numkeys: string | number, keys: RedisKey[], right: "RIGHT", countToken: "COUNT", count: string | number]): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, lenToken: "MAXLEN", len: string | number, callback?: Callback<number>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, numMatchesToken: "COUNT", numMatches: string | number, callback?: Callback<number[]>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, numMatchesToken: "COUNT", numMatches: string | number, lenToken: "MAXLEN", len: string | number, callback?: Callback<number[]>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, rankToken: "RANK", rank: string | number, callback?: Callback<number>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, rankToken: "RANK", rank: string | number, lenToken: "MAXLEN", len: string | number, callback?: Callback<number>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, rankToken: "RANK", rank: string | number, numMatchesToken: "COUNT", numMatches: string | number, callback?: Callback<number[]>): ChainableCommander
  • lpos(key: RedisKey, element: string | number | Buffer, rankToken: "RANK", rank: string | number, numMatchesToken: "COUNT", numMatches: string | number, lenToken: "MAXLEN", len: string | number, callback?: Callback<number[]>): ChainableCommander
  • Return the index of matching elements on a list

    • group: list
    • complexity: O(N) where N is the number of elements in the list, for the average case. When searching for elements near the head or the tail of the list, or when the MAXLEN option is provided, the command may run in constant time.
    • since: 6.0.6

    Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • lenToken: "MAXLEN"
    • len: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • numMatchesToken: "COUNT"
    • numMatches: string | number
    • Optional callback: Callback<number[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • numMatchesToken: "COUNT"
    • numMatches: string | number
    • lenToken: "MAXLEN"
    • len: string | number
    • Optional callback: Callback<number[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • rankToken: "RANK"
    • rank: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • rankToken: "RANK"
    • rank: string | number
    • lenToken: "MAXLEN"
    • len: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • rankToken: "RANK"
    • rank: string | number
    • numMatchesToken: "COUNT"
    • numMatches: string | number
    • Optional callback: Callback<number[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • element: string | number | Buffer
    • rankToken: "RANK"
    • rank: string | number
    • numMatchesToken: "COUNT"
    • numMatches: string | number
    • lenToken: "MAXLEN"
    • len: string | number
    • Optional callback: Callback<number[]>

    Returns ChainableCommander

  • Prepend one or multiple elements to a list

    • group: list
    • complexity: O(1) for each element added, so O(N) to add N elements when the command is called with multiple arguments.
    • since: 1.0.0

    Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Prepend an element to a list, only if the list exists

    • group: list
    • complexity: O(1) for each element added, so O(N) to add N elements when the command is called with multiple arguments.
    • since: 2.2.0

    Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Get a range of elements from a list

    • group: list
    • complexity: O(S+N) where S is the distance of start offset from HEAD for small lists, from nearest end (HEAD or TAIL) for large lists; and N is the number of elements in the specified range.
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • start: string | number
    • stop: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Remove elements from a list

    • group: list
    • complexity: O(N+M) where N is the length of the list and M is the number of elements removed.
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • count: string | number
    • element: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Set the value of an element in a list by its index

    • group: list
    • complexity: O(N) where N is the length of the list. Setting either the first or the last element of the list is O(1).
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • index: string | number
    • element: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Trim a list to the specified range

    • group: list
    • complexity: O(N) where N is the number of elements to be removed by the operation.
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • start: string | number
    • stop: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Outputs memory problems report

    • group: server
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "DOCTOR"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Show allocator internal stats

    • group: server
    • complexity: Depends on how much memory is allocated, could be slow
    • since: 4.0.0

    Parameters

    • subcommand: "MALLOC-STATS"
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Ask the allocator to release memory

    • group: server
    • complexity: Depends on how much memory is allocated, could be slow
    • since: 4.0.0

    Parameters

    • subcommand: "PURGE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Show memory usage details

    • group: server
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "STATS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Estimate the memory usage of a key

    • group: server
    • complexity: O(N) where N is the number of samples.
    • since: 4.0.0

    Parameters

    • subcommand: "USAGE"
    • key: RedisKey
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Parameters

    • subcommand: "USAGE"
    • key: RedisKey
    • countToken: "SAMPLES"
    • count: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Atomically transfer a key from a Redis instance to another one.

    • group: generic
    • complexity: This command actually executes a DUMP+DEL in the source instance, and a RESTORE in the target instance. See the pages of these commands for time complexity. Also an O(N) data transfer between the two instances is performed.
    • since: 2.6.0

    Parameters

    • Rest ...args: [host: string | Buffer, port: string | number, ...args: RedisValue[], callback: Callback<"OK">]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [host: string | Buffer, port: string | number, ...args: RedisValue[]]

    Returns ChainableCommander

  • module(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • module(subcommand: "LIST", callback?: Callback<unknown>): ChainableCommander
  • module(subcommand: "LOAD", path: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • module(...args: [subcommand: "LOAD", path: string | Buffer, ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • module(...args: [subcommand: "LOAD", path: string | Buffer, ...args: (string | number | Buffer)[]]): ChainableCommander
  • module(subcommand: "LOADEX", path: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, argsToken: "ARGS", ...args: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, argsToken: "ARGS", ...args: (string | number | Buffer)[]]): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...configs: (string | number | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...configs: (string | number | Buffer)[]]): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...args: RedisValue[], callback: Callback<unknown>]): ChainableCommander
  • module(...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...args: RedisValue[]]): ChainableCommander
  • module(subcommand: "UNLOAD", name: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • List all modules loaded by the server

    • group: server
    • complexity: O(N) where N is the number of loaded modules.
    • since: 4.0.0

    Parameters

    • subcommand: "LIST"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Load a module

    • group: server
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "LOAD"
    • path: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOAD", path: string | Buffer, ...args: (string | number | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOAD", path: string | Buffer, ...args: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Load a module with extended parameters

    • group: server
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • subcommand: "LOADEX"
    • path: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, argsToken: "ARGS", ...args: (string | number | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, argsToken: "ARGS", ...args: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...configs: (string | number | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...configs: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...args: RedisValue[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "LOADEX", path: string | Buffer, configsToken: "CONFIG", ...args: RedisValue[]]

    Returns ChainableCommander

  • Unload a module

    • group: server
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "UNLOAD"
    • name: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Inspect the internal encoding of a Redis object

    • group: generic
    • complexity: O(1)
    • since: 2.2.3

    Parameters

    • subcommand: "ENCODING"
    • key: RedisKey
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get the logarithmic access frequency counter of a Redis object

    • group: generic
    • complexity: O(1)
    • since: 4.0.0

    Parameters

    • subcommand: "FREQ"
    • key: RedisKey
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: generic
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get the time since a Redis object was last accessed

    • group: generic
    • complexity: O(1)
    • since: 2.2.3

    Parameters

    • subcommand: "IDLETIME"
    • key: RedisKey
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get the number of references to the value of the key

    • group: generic
    • complexity: O(1)
    • since: 2.2.3

    Parameters

    • subcommand: "REFCOUNT"
    • key: RedisKey
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get the expiration Unix timestamp for a key in milliseconds

    • group: generic
    • complexity: O(1)
    • since: 7.0.0

    Parameters

    • key: RedisKey
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Internal commands for debugging HyperLogLog values

    • group: hyperloglog
    • complexity: N/A
    • since: 2.8.9

    Parameters

    • subcommand: string | Buffer
    • key: RedisKey
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • An internal command for testing HyperLogLog values

    • group: hyperloglog
    • complexity: N/A
    • since: 2.8.9

    Parameters

    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • psetex(key: RedisKey, milliseconds: string | number, value: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • Set the value and expiration in milliseconds of a key

    • group: string
    • complexity: O(1)
    • since: 2.6.0

    Parameters

    • key: RedisKey
    • milliseconds: string | number
    • value: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Listen for messages published to channels matching the given patterns

    • group: pubsub
    • complexity: O(N) where N is the number of patterns the client is already subscribed to.
    • since: 2.0.0

    Parameters

    • Rest ...args: [...patterns: string[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: string[]

    Returns ChainableCommander

  • psync(replicationid: string | number | Buffer, offset: string | number, callback?: Callback<unknown>): ChainableCommander
  • Internal command used for replication

    • group: server
    • complexity: undefined
    • since: 2.8.0

    Parameters

    • replicationid: string | number | Buffer
    • offset: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • publish(channel: string | Buffer, message: string | Buffer, callback?: Callback<number>): ChainableCommander
  • Post a message to a channel

    • group: pubsub
    • complexity: O(N+M) where N is the number of clients subscribed to the receiving channel and M is the total number of subscribed patterns (by any client).
    • since: 2.0.0

    Parameters

    • channel: string | Buffer
    • message: string | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • pubsub(subcommand: "CHANNELS", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "CHANNELS", pattern: string, callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "HELP", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "NUMPAT", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "NUMSUB", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(...args: [subcommand: "NUMSUB", ...channels: (string | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • pubsub(...args: [subcommand: "NUMSUB", ...channels: (string | Buffer)[]]): ChainableCommander
  • pubsub(subcommand: "SHARDCHANNELS", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "SHARDCHANNELS", pattern: string, callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(subcommand: "SHARDNUMSUB", callback?: Callback<unknown[]>): ChainableCommander
  • pubsub(...args: [subcommand: "SHARDNUMSUB", ...shardchannels: (string | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • pubsub(...args: [subcommand: "SHARDNUMSUB", ...shardchannels: (string | Buffer)[]]): ChainableCommander
  • List active channels

    • group: pubsub
    • complexity: O(N) where N is the number of active channels, and assuming constant time pattern matching (relatively short channels and patterns)
    • since: 2.8.0

    Parameters

    • subcommand: "CHANNELS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CHANNELS"
    • pattern: string
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: pubsub
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get the count of unique patterns pattern subscriptions

    • group: pubsub
    • complexity: O(1)
    • since: 2.8.0

    Parameters

    • subcommand: "NUMPAT"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get the count of subscribers for channels

    • group: pubsub
    • complexity: O(N) for the NUMSUB subcommand, where N is the number of requested channels
    • since: 2.8.0

    Parameters

    • subcommand: "NUMSUB"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "NUMSUB", ...channels: (string | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "NUMSUB", ...channels: (string | Buffer)[]]

    Returns ChainableCommander

  • List active shard channels

    • group: pubsub
    • complexity: O(N) where N is the number of active shard channels, and assuming constant time pattern matching (relatively short shard channels).
    • since: 7.0.0

    Parameters

    • subcommand: "SHARDCHANNELS"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • subcommand: "SHARDCHANNELS"
    • pattern: string
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Get the count of subscribers for shard channels

    • group: pubsub
    • complexity: O(N) for the SHARDNUMSUB subcommand, where N is the number of requested shard channels
    • since: 7.0.0

    Parameters

    • subcommand: "SHARDNUMSUB"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "SHARDNUMSUB", ...shardchannels: (string | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "SHARDNUMSUB", ...shardchannels: (string | Buffer)[]]

    Returns ChainableCommander

  • Stop listening for messages posted to channels matching the given patterns

    • group: pubsub
    • complexity: O(N+M) where N is the number of patterns the client is already subscribed and M is the number of total patterns subscribed in the system (by any client).
    • since: 2.0.0

    Parameters

    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [...patterns: string[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: string[]

    Returns ChainableCommander

  • Return a random key from the keyspace

    • group: generic
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<string>

    Returns ChainableCommander

  • Enables read queries for a connection to a cluster replica node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Disables read queries for a connection to a cluster replica node

    • group: cluster
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • An internal command for configuring the replication stream

    • group: server
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • replicaof(host: string | Buffer, port: string | number, callback?: Callback<"OK">): ChainableCommander
  • Make the server a replica of another instance, or promote it as master.

    • group: server
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • host: string | Buffer
    • port: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • restore(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<"OK">): ChainableCommander
  • Create a key using the provided serialized value, previously obtained using DUMP.

    • group: generic
    • complexity: O(1) to create the new key and additional O(NM) to reconstruct the serialized value, where N is the number of Redis objects composing the value and M their average size. For small string values the time complexity is thus O(1)+O(1M) where M is small, so simply O(1). However for sorted set values the complexity is O(NMlog(N)) because inserting values into sorted sets is O(log(N)).
    • since: 2.6.0

    Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, callback?: Callback<unknown>): ChainableCommander
  • restore-asking(key: RedisKey, ttl: string | number, serializedValue: string | number | Buffer, replace: "REPLACE", absttl: "ABSTTL", secondsToken: "IDLETIME", seconds: string | number, frequencyToken: "FREQ", frequency: string | number, callback?: Callback<unknown>): ChainableCommander
  • An internal command for migrating keys in a cluster

    • group: server
    • complexity: O(1) to create the new key and additional O(NM) to reconstruct the serialized value, where N is the number of Redis objects composing the value and M their average size. For small string values the time complexity is thus O(1)+O(1M) where M is small, so simply O(1). However for sorted set values the complexity is O(NMlog(N)) because inserting values into sorted sets is O(log(N)).
    • since: 3.0.0

    Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • ttl: string | number
    • serializedValue: string | number | Buffer
    • replace: "REPLACE"
    • absttl: "ABSTTL"
    • secondsToken: "IDLETIME"
    • seconds: string | number
    • frequencyToken: "FREQ"
    • frequency: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Return the role of the instance in the context of replication

    • group: server
    • complexity: O(1)
    • since: 2.8.12

    Parameters

    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Append one or multiple elements to a list

    • group: list
    • complexity: O(1) for each element added, so O(N) to add N elements when the command is called with multiple arguments.
    • since: 1.0.0

    Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Append an element to a list, only if the list exists

    • group: list
    • complexity: O(1) for each element added, so O(N) to add N elements when the command is called with multiple arguments.
    • since: 2.2.0

    Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, ...elements: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Synchronously save the dataset to disk

    • group: server
    • complexity: O(N) where N is the total number of keys in all databases
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • scan(cursor: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, countToken: "COUNT", count: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, patternToken: "MATCH", pattern: string, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • scan(cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • Incrementally iterate the keys space

    • group: generic
    • complexity: O(1) for every call. O(N) for a complete iteration, including enough command calls for the cursor to return back to 0. N is the number of elements inside the collection.
    • since: 2.8.0

    Parameters

    • cursor: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • scanBuffer(cursor: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, countToken: "COUNT", count: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, patternToken: "MATCH", pattern: string, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • scanBuffer(cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, typeToken: "TYPE", type: string | Buffer, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • Parameters

    • cursor: string | number
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • Parameters

    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • typeToken: "TYPE"
    • type: string | Buffer
    • Optional callback: Callback<[cursor: Buffer, elements: Buffer[]]>

    Returns ChainableCommander

  • script(subcommand: "DEBUG", yes: "YES", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "DEBUG", sync: "SYNC", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "DEBUG", no: "NO", callback?: Callback<unknown>): ChainableCommander
  • script(...args: [subcommand: "EXISTS", ...sha1s: (string | Buffer)[], callback: Callback<unknown>]): ChainableCommander
  • script(...args: [subcommand: "EXISTS", ...sha1s: (string | Buffer)[]]): ChainableCommander
  • script(subcommand: "FLUSH", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "FLUSH", async: "ASYNC", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "FLUSH", sync: "SYNC", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "KILL", callback?: Callback<unknown>): ChainableCommander
  • script(subcommand: "LOAD", script: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • Set the debug mode for executed scripts.

    • group: scripting
    • complexity: O(1)
    • since: 3.2.0

    Parameters

    • subcommand: "DEBUG"
    • yes: "YES"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "DEBUG"
    • sync: "SYNC"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "DEBUG"
    • no: "NO"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Check existence of scripts in the script cache.

    • group: scripting
    • complexity: O(N) with N being the number of scripts to check (so checking a single script is an O(1) operation).
    • since: 2.6.0

    Parameters

    • Rest ...args: [subcommand: "EXISTS", ...sha1s: (string | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [subcommand: "EXISTS", ...sha1s: (string | Buffer)[]]

    Returns ChainableCommander

  • Remove all the scripts from the script cache.

    • group: scripting
    • complexity: O(N) with N being the number of scripts in cache
    • since: 2.6.0

    Parameters

    • subcommand: "FLUSH"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "FLUSH"
    • async: "ASYNC"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "FLUSH"
    • sync: "SYNC"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: scripting
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Kill the script currently in execution.

    • group: scripting
    • complexity: O(1)
    • since: 2.6.0

    Parameters

    • subcommand: "KILL"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Load the specified Lua script into the script cache.

    • group: scripting
    • complexity: O(N) with N being the length in bytes of the script body.
    • since: 2.6.0

    Parameters

    • subcommand: "LOAD"
    • script: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Change the selected database for the current connection

    • group: connection
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • index: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • set(key: RedisKey, value: string | number | Buffer, callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", nx: "NX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", nx: "NX", get: "GET", callback?: Callback<string>): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", xx: "XX", callback?: Callback<"OK">): ChainableCommander
  • set(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", xx: "XX", get: "GET", callback?: Callback<string>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, secondsToken: "EX", seconds: string | number, xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, millisecondsToken: "PX", milliseconds: string | number, xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeSecondsToken: "EXAT", unixTimeSeconds: string | number, xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, unixTimeMillisecondsToken: "PXAT", unixTimeMilliseconds: string | number, xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", nx: "NX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • setBuffer(key: RedisKey, value: string | number | Buffer, keepttl: "KEEPTTL", xx: "XX", get: "GET", callback?: Callback<Buffer>): ChainableCommander
  • Sets or clears the bit at offset in the string value stored at key

    • group: bitmap
    • complexity: O(1)
    • since: 2.2.0

    Parameters

    • key: RedisKey
    • offset: string | number
    • value: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Set the value and expiration of a key

    • group: string
    • complexity: O(1)
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • seconds: string | number
    • value: string | number | Buffer
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Set the value of a key, only if the key does not exist

    • group: string
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • value: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • setrange(key: RedisKey, offset: string | number, value: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • Overwrite part of a string at key starting at the specified offset

    • group: string
    • complexity: O(1), not counting the time taken to copy the new string in place. Usually, this string is very small so the amortized complexity is O(1). Otherwise, complexity is O(M) with M being the length of the value argument.
    • since: 2.2.0

    Parameters

    • key: RedisKey
    • offset: string | number
    • value: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Determine if a given value is a member of a set

    • group: set
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • member: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • slaveof(host: string | Buffer, port: string | number, callback?: Callback<"OK">): ChainableCommander
  • Make the server a replica of another instance, or promote it as master.

    • group: server
    • complexity: O(1)
    • since: 1.0.0

    Parameters

    • host: string | Buffer
    • port: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Get the slow log's entries

    • group: server
    • complexity: O(N) where N is the number of entries returned
    • since: 2.2.12

    Parameters

    • subcommand: "GET"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "GET"
    • count: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: server
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Get the slow log's length

    • group: server
    • complexity: O(1)
    • since: 2.2.12

    Parameters

    • subcommand: "LEN"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Clear all entries from the slow log

    • group: server
    • complexity: O(N) where N is the number of entries in the slowlog
    • since: 2.2.12

    Parameters

    • subcommand: "RESET"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • sort_ro(key: RedisKey, callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, asc: "ASC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, asc: "ASC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, desc: "DESC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, desc: "DESC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[]]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], asc: "ASC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], asc: "ASC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], asc: "ASC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], asc: "ASC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], desc: "DESC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], desc: "DESC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], desc: "DESC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "GET", ...patterns: string[], desc: "DESC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, asc: "ASC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, asc: "ASC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, desc: "DESC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, desc: "DESC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[]]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], asc: "ASC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], asc: "ASC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], asc: "ASC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], asc: "ASC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], desc: "DESC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], desc: "DESC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], desc: "DESC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken: "GET", ...patterns: string[], desc: "DESC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, asc: "ASC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, asc: "ASC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, desc: "DESC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, desc: "DESC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[]]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], asc: "ASC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], desc: "DESC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, asc: "ASC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, asc: "ASC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, desc: "DESC", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, desc: "DESC", alpha: "ALPHA", callback?: Callback<unknown>): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[]]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], asc: "ASC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], asc: "ASC", alpha: "ALPHA"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], desc: "DESC"]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", alpha: "ALPHA", callback: Callback<unknown>]): ChainableCommander
  • sort_ro(...args: [key: RedisKey, patternToken: "BY", pattern: string, offsetCountToken: "LIMIT", offset: string | number, count: string | number, patternToken1: "GET", ...pattern1s: string[], desc: "DESC", alpha: "ALPHA"]): ChainableCommander
  • spublish(shardchannel: string | Buffer, message: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • Post a message to a shard channel

    • group: pubsub
    • complexity: O(N) where N is the number of clients subscribed to the receiving shard channel.
    • since: 7.0.0

    Parameters

    • shardchannel: string | Buffer
    • message: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • sscan(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • sscan(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • sscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • sscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • Incrementally iterate Set elements

    • group: set
    • complexity: O(1) for every call. O(N) for a complete iteration, including enough command calls for the cursor to return back to 0. N is the number of elements inside the collection..
    • since: 2.8.0

    Parameters

    • key: RedisKey
    • cursor: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • sscanBuffer(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • sscanBuffer(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • sscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • sscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • Listen for messages published to the given shard channels

    • group: pubsub
    • complexity: O(N) where N is the number of shard channels to subscribe to.
    • since: 7.0.0

    Parameters

    • Rest ...args: [...shardchannels: (string | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: (string | Buffer)[]

    Returns ChainableCommander

  • Listen for messages published to the given channels

    • group: pubsub
    • complexity: O(N) where N is the number of channels to subscribe to.
    • since: 2.0.0

    Parameters

    • Rest ...args: [...channels: (string | Buffer)[], callback: Callback<unknown>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: (string | Buffer)[]

    Returns ChainableCommander

  • Get a substring of the string stored at a key

    • group: string
    • complexity: O(N) where N is the length of the returned string. The complexity is ultimately determined by the returned length, but because creating a substring from an existing string is very cheap, it can be considered O(1) for small strings.
    • since: 1.0.0

    Parameters

    • key: RedisKey
    • start: string | number
    • end: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • swapdb(index1: string | number, index2: string | number, callback?: Callback<"OK">): ChainableCommander
  • Swaps two Redis databases

    • group: server
    • complexity: O(N) where N is the count of clients watching or blocking on keys from both databases.
    • since: 4.0.0

    Parameters

    • index1: string | number
    • index2: string | number
    • Optional callback: Callback<"OK">

    Returns ChainableCommander

  • Internal command used for replication

    • group: server
    • complexity: undefined
    • since: 1.0.0

    Parameters

    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • wait(numreplicas: string | number, timeout: string | number, callback?: Callback<number>): ChainableCommander
  • Wait for the synchronous replication of all the write commands sent in the context of the current connection

    • group: generic
    • complexity: O(1)
    • since: 3.0.0

    Parameters

    • numreplicas: string | number
    • timeout: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Marks a pending message as correctly processed, effectively removing it from the pending entries list of the consumer group. Return value of the command is the number of messages successfully acknowledged, that is, the IDs we were actually able to resolve in the PEL.

    • group: stream
    • complexity: O(1) for each message ID processed.
    • since: 5.0.0

    Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, ...ids: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, ...ids: (string | number | Buffer)[]]

    Returns ChainableCommander

  • xautoclaim(key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, start: string | number | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • xautoclaim(key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, start: string | number | Buffer, justid: "JUSTID", callback?: Callback<unknown[]>): ChainableCommander
  • xautoclaim(key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, start: string | number | Buffer, countToken: "COUNT", count: string | number, callback?: Callback<unknown[]>): ChainableCommander
  • xautoclaim(key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, start: string | number | Buffer, countToken: "COUNT", count: string | number, justid: "JUSTID", callback?: Callback<unknown[]>): ChainableCommander
  • Changes (or acquires) ownership of messages in a consumer group, as if the messages were delivered to the specified consumer.

    • group: stream
    • complexity: O(1) if COUNT is small.
    • since: 6.2.0

    Parameters

    • key: RedisKey
    • group: string | Buffer
    • consumer: string | Buffer
    • minIdleTime: string | number | Buffer
    • start: string | number | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • consumer: string | Buffer
    • minIdleTime: string | number | Buffer
    • start: string | number | Buffer
    • justid: "JUSTID"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • consumer: string | Buffer
    • minIdleTime: string | number | Buffer
    • start: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • consumer: string | Buffer
    • minIdleTime: string | number | Buffer
    • start: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • justid: "JUSTID"
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[]]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", callback: Callback<unknown[]>]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID"]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • xclaim(...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]): ChainableCommander
  • Changes (or acquires) ownership of a message in a consumer group, as if the message was delivered to the specified consumer.

    • group: stream
    • complexity: O(log N) with N being the number of messages in the PEL of the consumer group.
    • since: 5.0.0

    Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, countToken: "RETRYCOUNT", count: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, force: "FORCE", justid: "JUSTID"]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number, countToken: "RETRYCOUNT", count: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, group: string | Buffer, consumer: string | Buffer, minIdleTime: string | number | Buffer, ...ids: (string | number | Buffer)[], msToken: "IDLE", ms: string | number, unixTimeMillisecondsToken: "TIME", unixTimeMilliseconds: string | number]

    Returns ChainableCommander

  • Removes the specified entries from the stream. Returns the number of items actually deleted, that may be different from the number of IDs passed in case certain IDs do not exist.

    • group: stream
    • complexity: O(1) for each single item to delete in the stream, regardless of the stream size.
    • since: 5.0.0

    Parameters

    • Rest ...args: [key: RedisKey, ...ids: (string | number | Buffer)[], callback: Callback<number>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [key: RedisKey, ...ids: (string | number | Buffer)[]]

    Returns ChainableCommander

  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, mkstream: "MKSTREAM", callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, mkstream: "MKSTREAM", entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, newId: "$", callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, newId: "$", entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, newId: "$", mkstream: "MKSTREAM", callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATE", key: RedisKey, groupname: string | Buffer, newId: "$", mkstream: "MKSTREAM", entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "CREATECONSUMER", key: RedisKey, groupname: string | Buffer, consumername: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "DELCONSUMER", key: RedisKey, groupname: string | Buffer, consumername: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "DESTROY", key: RedisKey, groupname: string | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "HELP", callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "SETID", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "SETID", key: RedisKey, groupname: string | Buffer, id: string | number | Buffer, entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "SETID", key: RedisKey, groupname: string | Buffer, newId: "$", callback?: Callback<unknown>): ChainableCommander
  • xgroup(subcommand: "SETID", key: RedisKey, groupname: string | Buffer, newId: "$", entriesReadToken: "ENTRIESREAD", entriesRead: string | number, callback?: Callback<unknown>): ChainableCommander
  • Create a consumer group.

    • group: stream
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • mkstream: "MKSTREAM"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • mkstream: "MKSTREAM"
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • mkstream: "MKSTREAM"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "CREATE"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • mkstream: "MKSTREAM"
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Create a consumer in a consumer group.

    • group: stream
    • complexity: O(1)
    • since: 6.2.0

    Parameters

    • subcommand: "CREATECONSUMER"
    • key: RedisKey
    • groupname: string | Buffer
    • consumername: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Delete a consumer from a consumer group.

    • group: stream
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "DELCONSUMER"
    • key: RedisKey
    • groupname: string | Buffer
    • consumername: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Destroy a consumer group.

    • group: stream
    • complexity: O(N) where N is the number of entries in the group's pending entries list (PEL).
    • since: 5.0.0

    Parameters

    • subcommand: "DESTROY"
    • key: RedisKey
    • groupname: string | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Show helpful text about the different subcommands

    • group: stream
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "HELP"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Set a consumer group to an arbitrary last delivered ID value.

    • group: stream
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • subcommand: "SETID"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETID"
    • key: RedisKey
    • groupname: string | Buffer
    • id: string | number | Buffer
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETID"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • subcommand: "SETID"
    • key: RedisKey
    • groupname: string | Buffer
    • newId: "$"
    • entriesReadToken: "ENTRIESREAD"
    • entriesRead: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • xpending(key: RedisKey, group: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • xpending(key: RedisKey, group: string | Buffer, start: string | number | Buffer, end: string | number | Buffer, count: string | number, callback?: Callback<unknown[]>): ChainableCommander
  • xpending(key: RedisKey, group: string | Buffer, start: string | number | Buffer, end: string | number | Buffer, count: string | number, consumer: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • xpending(key: RedisKey, group: string | Buffer, minIdleTimeToken: "IDLE", minIdleTime: string | number, start: string | number | Buffer, end: string | number | Buffer, count: string | number, callback?: Callback<unknown[]>): ChainableCommander
  • xpending(key: RedisKey, group: string | Buffer, minIdleTimeToken: "IDLE", minIdleTime: string | number, start: string | number | Buffer, end: string | number | Buffer, count: string | number, consumer: string | Buffer, callback?: Callback<unknown[]>): ChainableCommander
  • Return information and entries from a stream consumer group pending entries list, that are messages fetched but never acknowledged.

    • group: stream
    • complexity: O(N) with N being the number of elements returned, so asking for a small fixed number of entries per call is O(1). O(M), where M is the total number of entries scanned when used with the IDLE filter. When the command returns just the summary and the list of consumers is small, it runs in O(1) time; otherwise, an additional O(N) time for iterating every consumer.
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • group: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • start: string | number | Buffer
    • end: string | number | Buffer
    • count: string | number
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • start: string | number | Buffer
    • end: string | number | Buffer
    • count: string | number
    • consumer: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • minIdleTimeToken: "IDLE"
    • minIdleTime: string | number
    • start: string | number | Buffer
    • end: string | number | Buffer
    • count: string | number
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • group: string | Buffer
    • minIdleTimeToken: "IDLE"
    • minIdleTime: string | number
    • start: string | number | Buffer
    • end: string | number | Buffer
    • count: string | number
    • consumer: string | Buffer
    • Optional callback: Callback<unknown[]>

    Returns ChainableCommander

  • xrange(key: RedisKey, start: string | number | Buffer, end: string | number | Buffer, callback?: Callback<[id: string, fields: string[]][]>): ChainableCommander
  • xrange(key: RedisKey, start: string | number | Buffer, end: string | number | Buffer, countToken: "COUNT", count: string | number, callback?: Callback<[id: string, fields: string[]][]>): ChainableCommander
  • Return a range of elements in a stream, with IDs matching the specified IDs interval

    • group: stream
    • complexity: O(N) with N being the number of elements being returned. If N is constant (e.g. always asking for the first 10 elements with COUNT), you can consider it O(1).
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • start: string | number | Buffer
    • end: string | number | Buffer
    • Optional callback: Callback<[id: string, fields: string[]][]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • start: string | number | Buffer
    • end: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[id: string, fields: string[]][]>

    Returns ChainableCommander

  • xrangeBuffer(key: RedisKey, start: string | number | Buffer, end: string | number | Buffer, callback?: Callback<[id: Buffer, fields: Buffer[]][]>): ChainableCommander
  • xrangeBuffer(key: RedisKey, start: string | number | Buffer, end: string | number | Buffer, countToken: "COUNT", count: string | number, callback?: Callback<[id: Buffer, fields: Buffer[]][]>): ChainableCommander
  • Parameters

    • key: RedisKey
    • start: string | number | Buffer
    • end: string | number | Buffer
    • Optional callback: Callback<[id: Buffer, fields: Buffer[]][]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • start: string | number | Buffer
    • end: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[id: Buffer, fields: Buffer[]][]>

    Returns ChainableCommander

  • xread(...args: [streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]): ChainableCommander
  • xread(...args: [streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xread(...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]): ChainableCommander
  • xread(...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xread(...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]): ChainableCommander
  • xread(...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xread(...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]): ChainableCommander
  • xread(...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • Return never seen elements in multiple streams, with IDs greater than the ones reported by the caller for each stream. Can block.

    • group: stream
    • complexity: For each stream mentioned: O(N) with N being the number of elements being returned, it means that XREAD-ing with a fixed COUNT is O(1). Note that when the BLOCK option is used, XADD will pay O(M) time in order to serve the M clients blocked on the stream getting new data.
    • since: 5.0.0

    Parameters

    • Rest ...args: [streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: string, items: [id: string, fields: string[]][]][]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • xreadBuffer(...args: [streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: Buffer, items: [id: Buffer, fields: Buffer[]][]][]>]): ChainableCommander
  • xreadBuffer(...args: [streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadBuffer(...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: Buffer, items: [id: Buffer, fields: Buffer[]][]][]>]): ChainableCommander
  • xreadBuffer(...args: [millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadBuffer(...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: Buffer, items: [id: Buffer, fields: Buffer[]][]][]>]): ChainableCommander
  • xreadBuffer(...args: [countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadBuffer(...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<[key: Buffer, items: [id: Buffer, fields: Buffer[]][]][]>]): ChainableCommander
  • xreadBuffer(...args: [countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]): ChainableCommander
  • xreadgroup(...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]): ChainableCommander
  • Return new entries from a stream using a consumer group, or access the history of the pending entries for a given consumer. Can block.

    • group: stream
    • complexity: For each stream mentioned: O(M) with M being the number of elements returned. If M is constant (e.g. always asking for the first 10 elements with COUNT), you can consider it O(1). On the other side when XREADGROUP blocks, XADD will pay the O(N) time in order to serve the N clients blocked on the stream getting new data.
    • since: 5.0.0

    Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[], callback: Callback<unknown[]>]

    Returns ChainableCommander

  • Parameters

    • Rest ...args: [groupConsumerToken: "GROUP", group: string | Buffer, consumer: string | Buffer, countToken: "COUNT", count: string | number, millisecondsToken: "BLOCK", milliseconds: string | number, noack: "NOACK", streamsToken: "STREAMS", ...args: RedisValue[]]

    Returns ChainableCommander

  • xrevrange(key: RedisKey, end: string | number | Buffer, start: string | number | Buffer, callback?: Callback<[id: string, fields: string[]][]>): ChainableCommander
  • xrevrange(key: RedisKey, end: string | number | Buffer, start: string | number | Buffer, countToken: "COUNT", count: string | number, callback?: Callback<[id: string, fields: string[]][]>): ChainableCommander
  • Return a range of elements in a stream, with IDs matching the specified IDs interval, in reverse order (from greater to smaller IDs) compared to XRANGE

    • group: stream
    • complexity: O(N) with N being the number of elements returned. If N is constant (e.g. always asking for the first 10 elements with COUNT), you can consider it O(1).
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • end: string | number | Buffer
    • start: string | number | Buffer
    • Optional callback: Callback<[id: string, fields: string[]][]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • end: string | number | Buffer
    • start: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[id: string, fields: string[]][]>

    Returns ChainableCommander

  • xrevrangeBuffer(key: RedisKey, end: string | number | Buffer, start: string | number | Buffer, callback?: Callback<[id: Buffer, fields: Buffer[]][]>): ChainableCommander
  • xrevrangeBuffer(key: RedisKey, end: string | number | Buffer, start: string | number | Buffer, countToken: "COUNT", count: string | number, callback?: Callback<[id: Buffer, fields: Buffer[]][]>): ChainableCommander
  • Parameters

    • key: RedisKey
    • end: string | number | Buffer
    • start: string | number | Buffer
    • Optional callback: Callback<[id: Buffer, fields: Buffer[]][]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • end: string | number | Buffer
    • start: string | number | Buffer
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[id: Buffer, fields: Buffer[]][]>

    Returns ChainableCommander

  • xsetid(key: RedisKey, lastId: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xsetid(key: RedisKey, lastId: string | number | Buffer, maxDeletedEntryIdToken: "MAXDELETEDID", maxDeletedEntryId: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • xsetid(key: RedisKey, lastId: string | number | Buffer, entriesAddedToken: "ENTRIESADDED", entriesAdded: string | number, callback?: Callback<unknown>): ChainableCommander
  • xsetid(key: RedisKey, lastId: string | number | Buffer, entriesAddedToken: "ENTRIESADDED", entriesAdded: string | number, maxDeletedEntryIdToken: "MAXDELETEDID", maxDeletedEntryId: string | number | Buffer, callback?: Callback<unknown>): ChainableCommander
  • An internal command for replicating stream values

    • group: stream
    • complexity: O(1)
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • lastId: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • lastId: string | number | Buffer
    • maxDeletedEntryIdToken: "MAXDELETEDID"
    • maxDeletedEntryId: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • lastId: string | number | Buffer
    • entriesAddedToken: "ENTRIESADDED"
    • entriesAdded: string | number
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • lastId: string | number | Buffer
    • entriesAddedToken: "ENTRIESADDED"
    • entriesAdded: string | number
    • maxDeletedEntryIdToken: "MAXDELETEDID"
    • maxDeletedEntryId: string | number | Buffer
    • Optional callback: Callback<unknown>

    Returns ChainableCommander

  • xtrim(key: RedisKey, maxlen: "MAXLEN", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, maxlen: "MAXLEN", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, maxlen: "MAXLEN", equal: "=", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, maxlen: "MAXLEN", equal: "=", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, maxlen: "MAXLEN", approximately: "~", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, maxlen: "MAXLEN", approximately: "~", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", equal: "=", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", equal: "=", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", approximately: "~", threshold: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • xtrim(key: RedisKey, minid: "MINID", approximately: "~", threshold: string | number | Buffer, countToken: "LIMIT", count: string | number, callback?: Callback<number>): ChainableCommander
  • zadd(...args: [key: RedisKey, ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[], callback: Callback<number>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<string>]): ChainableCommander
  • zadd(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, nx: "NX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", gt: "GT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", gt: "GT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", lt: "LT", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[], callback: Callback<Buffer>]): ChainableCommander
  • zaddBuffer(...args: [key: RedisKey, xx: "XX", lt: "LT", ch: "CH", incr: "INCR", ...scoreMembers: (string | number | Buffer)[]]): ChainableCommander
  • Count the members in a sorted set with scores within the given values

    • group: sorted-set
    • complexity: O(log(N)) with N being the number of elements in the sorted set.
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • zincrby(key: RedisKey, increment: string | number, member: string | number | Buffer, callback?: Callback<string>): ChainableCommander
  • Increment the score of a member in a sorted set

    • group: sorted-set
    • complexity: O(log(N)) where N is the number of elements in the sorted set.
    • since: 1.2.0

    Parameters

    • key: RedisKey
    • increment: string | number
    • member: string | number | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • zincrbyBuffer(key: RedisKey, increment: string | number, member: string | number | Buffer, callback?: Callback<Buffer>): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zinter(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zinterBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zlexcount(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • Count the number of members in a sorted set between a given lexicographical range

    • group: sorted-set
    • complexity: O(log(N)) with N being the number of elements in the sorted set.
    • since: 2.8.9

    Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], min: "MIN", callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], min: "MIN", callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], min: "MIN"]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], min: "MIN"]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], min: "MIN", countToken: "COUNT", count: string | number]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], max: "MAX", callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], max: "MAX", callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], max: "MAX"]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], max: "MAX"]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number, callback: Callback<unknown>]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, ...keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number]): ChainableCommander
  • zmpop(...args: [numkeys: string | number, keys: RedisKey[], max: "MAX", countToken: "COUNT", count: string | number]): ChainableCommander
  • Remove and return members with the highest scores in a sorted set

    • group: sorted-set
    • complexity: O(log(N)*M) with N being the number of elements in the sorted set, and M being the number of elements popped.
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Remove and return members with the lowest scores in a sorted set

    • group: sorted-set
    • complexity: O(log(N)*M) with N being the number of elements in the sorted set, and M being the number of elements popped.
    • since: 5.0.0

    Parameters

    • key: RedisKey
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrange(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements returned.
    • since: 1.2.0

    Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangeBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • byscore: "BYSCORE"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • bylex: "BYLEX"
    • rev: "REV"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<Buffer[]>

    Returns ChainableCommander

  • zrangebylex(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<string[]>): ChainableCommander
  • zrangebylex(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set, by lexicographical range

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements being returned. If M is constant (e.g. always asking for the first 10 elements with LIMIT), you can consider it O(log(N)).
    • since: 2.8.9

    Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrangebylexBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangebylexBuffer(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangebyscore(key: RedisKey, min: string | number, max: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrangebyscore(key: RedisKey, min: string | number, max: string | number, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrangebyscore(key: RedisKey, min: string | number, max: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrangebyscore(key: RedisKey, min: string | number, max: string | number, withscores: "WITHSCORES", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set, by score

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements being returned. If M is constant (e.g. always asking for the first 10 elements with LIMIT), you can consider it O(log(N)).
    • since: 1.0.5

    Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • withscores: "WITHSCORES"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrangebyscoreBuffer(key: RedisKey, min: string | number, max: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangebyscoreBuffer(key: RedisKey, min: string | number, max: string | number, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangebyscoreBuffer(key: RedisKey, min: string | number, max: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrangebyscoreBuffer(key: RedisKey, min: string | number, max: string | number, withscores: "WITHSCORES", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, byscore: "BYSCORE", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", callback?: Callback<number>): ChainableCommander
  • zrangestore(dst: RedisKey, src: RedisKey, min: string | number | Buffer, max: string | number | Buffer, bylex: "BYLEX", rev: "REV", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<number>): ChainableCommander
  • Determine the index of a member in a sorted set

    • group: sorted-set
    • complexity: O(log(N))
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • member: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • zremrangebylex(key: RedisKey, min: string | number | Buffer, max: string | number | Buffer, callback?: Callback<number>): ChainableCommander
  • Remove all members in a sorted set between the given lexicographical range

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements removed by the operation.
    • since: 2.8.9

    Parameters

    • key: RedisKey
    • min: string | number | Buffer
    • max: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Remove all members in a sorted set within the given indexes

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements removed by the operation.
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • start: string | number
    • stop: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • Remove all members in a sorted set within the given scores

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements removed by the operation.
    • since: 1.2.0

    Parameters

    • key: RedisKey
    • min: string | number
    • max: string | number
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • zrevrange(key: RedisKey, start: string | number, stop: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrevrange(key: RedisKey, start: string | number, stop: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set, by index, with scores ordered from high to low

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements returned.
    • since: 1.2.0

    Parameters

    • key: RedisKey
    • start: string | number
    • stop: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • start: string | number
    • stop: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrevrangeBuffer(key: RedisKey, start: string | number, stop: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangeBuffer(key: RedisKey, start: string | number, stop: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebylex(key: RedisKey, max: string | number | Buffer, min: string | number | Buffer, callback?: Callback<string[]>): ChainableCommander
  • zrevrangebylex(key: RedisKey, max: string | number | Buffer, min: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set, by lexicographical range, ordered from higher to lower strings.

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements being returned. If M is constant (e.g. always asking for the first 10 elements with LIMIT), you can consider it O(log(N)).
    • since: 2.8.9

    Parameters

    • key: RedisKey
    • max: string | number | Buffer
    • min: string | number | Buffer
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • max: string | number | Buffer
    • min: string | number | Buffer
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrevrangebylexBuffer(key: RedisKey, max: string | number | Buffer, min: string | number | Buffer, callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebylexBuffer(key: RedisKey, max: string | number | Buffer, min: string | number | Buffer, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebyscore(key: RedisKey, max: string | number, min: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrevrangebyscore(key: RedisKey, max: string | number, min: string | number, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • zrevrangebyscore(key: RedisKey, max: string | number, min: string | number, withscores: "WITHSCORES", callback?: Callback<string[]>): ChainableCommander
  • zrevrangebyscore(key: RedisKey, max: string | number, min: string | number, withscores: "WITHSCORES", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<string[]>): ChainableCommander
  • Return a range of members in a sorted set, by score, with scores ordered from high to low

    • group: sorted-set
    • complexity: O(log(N)+M) with N being the number of elements in the sorted set and M the number of elements being returned. If M is constant (e.g. always asking for the first 10 elements with LIMIT), you can consider it O(log(N)).
    • since: 2.2.0

    Parameters

    • key: RedisKey
    • max: string | number
    • min: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • max: string | number
    • min: string | number
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • max: string | number
    • min: string | number
    • withscores: "WITHSCORES"
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • max: string | number
    • min: string | number
    • withscores: "WITHSCORES"
    • offsetCountToken: "LIMIT"
    • offset: string | number
    • count: string | number
    • Optional callback: Callback<string[]>

    Returns ChainableCommander

  • zrevrangebyscoreBuffer(key: RedisKey, max: string | number, min: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebyscoreBuffer(key: RedisKey, max: string | number, min: string | number, offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebyscoreBuffer(key: RedisKey, max: string | number, min: string | number, withscores: "WITHSCORES", callback?: Callback<Buffer[]>): ChainableCommander
  • zrevrangebyscoreBuffer(key: RedisKey, max: string | number, min: string | number, withscores: "WITHSCORES", offsetCountToken: "LIMIT", offset: string | number, count: string | number, callback?: Callback<Buffer[]>): ChainableCommander
  • Determine the index of a member in a sorted set, with scores ordered from high to low

    • group: sorted-set
    • complexity: O(log(N))
    • since: 2.0.0

    Parameters

    • key: RedisKey
    • member: string | number | Buffer
    • Optional callback: Callback<number>

    Returns ChainableCommander

  • zscan(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • zscan(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • zscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • zscan(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: string, elements: string[]]>): ChainableCommander
  • Incrementally iterate sorted sets elements and associated scores

    • group: sorted-set
    • complexity: O(1) for every call. O(N) for a complete iteration, including enough command calls for the cursor to return back to 0. N is the number of elements inside the collection..
    • since: 2.8.0

    Parameters

    • key: RedisKey
    • cursor: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • Parameters

    • key: RedisKey
    • cursor: string | number
    • patternToken: "MATCH"
    • pattern: string
    • countToken: "COUNT"
    • count: string | number
    • Optional callback: Callback<[cursor: string, elements: string[]]>

    Returns ChainableCommander

  • zscanBuffer(key: RedisKey, cursor: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • zscanBuffer(key: RedisKey, cursor: string | number, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • zscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • zscanBuffer(key: RedisKey, cursor: string | number, patternToken: "MATCH", pattern: string, countToken: "COUNT", count: string | number, callback?: Callback<[cursor: Buffer, elements: Buffer[]]>): ChainableCommander
  • Get the score associated with the given member in a sorted set

    • group: sorted-set
    • complexity: O(1)
    • since: 1.2.0

    Parameters

    • key: RedisKey
    • member: string | number | Buffer
    • Optional callback: Callback<string>

    Returns ChainableCommander

  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<string[]>]): ChainableCommander
  • zunion(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[]]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[]]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, keys: RedisKey[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[]]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", sum: "SUM", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", min: "MIN", withscores: "WITHSCORES"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX"]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES", callback: Callback<Buffer[]>]): ChainableCommander
  • zunionBuffer(...args: [numkeys: string | number, ...args: RedisValue[], aggregate: "AGGREGATE", max: "MAX", withscores: "WITHSCORES"]): ChainableCommander

Generated using TypeDoc