Skip to main content
Use XCLAIM to change the owner of specific pending entries in a consumer group. The entries must have been idle for at least <min-idle-time> milliseconds, which is what keeps two recovery attempts from stealing the same work from each other: the first claim resets the idle time and the second one then finds nothing to take. Claiming resets the entry’s delivery time and increments its delivery counter, unless JUSTID is used, which returns only the IDs and leaves the counter alone. IDLE and TIME set the new idle time or the last delivery time explicitly, RETRYCOUNT overrides the delivery counter, and FORCE creates a pending entry for IDs that exist in the stream but are not currently pending. Entries that no longer exist in the stream are removed from the pending list instead of being claimed. When you want to claim whatever is idle rather than specific IDs, use XAUTOCLAIM.

Syntax

Arguments

Response

The reply reports the result of the operation. Error replies have the same shape in RESP2 and RESP3 and are surfaced as exceptions by the SDKs below.
Client libraries often decode bulk strings, maps, sets, and numeric strings into language-native values. The table describes the Redis wire reply.

Examples

TCP examples use the TLS REDIS_URL from the Upstash console. REST examples use UPSTASH_REDIS_REST_URL and UPSTASH_REDIS_REST_TOKEN.

Related topics

XCLAIMOverview