Mhsetnx
Bun

method

RedisClient.hsetnx

key: KeyLike,
field: KeyLike,
value: KeyLike
): Promise<boolean>;

Set the value of a hash field, only if the field does not exist

@param key

The hash key

@param field

The field to set

@param value

The value to set

@returns

Promise that resolves with true if field was set, false if field already exists

Referenced types

type KeyLike = string | ArrayBufferView | Blob