Skip to content

RedisCacheStore

Defined in: src/adapters/redis.ts:275

Response cache backed by Redis with base64-encoded body and TTL-based expiry.

new RedisCacheStore(client, prefix, setWithTTL): RedisCacheStore

Defined in: src/adapters/redis.ts:276

RedisClient

string

(client, key, value, ttlSeconds) => Promise<unknown> | undefined

RedisCacheStore

delete(key): Promise<boolean>

Defined in: src/adapters/redis.ts:330

Delete a cached entry. Returns true if something was removed.

string

Promise<boolean>

CacheStore.delete


get(key): Promise<Response | null>

Defined in: src/adapters/redis.ts:286

Retrieve a cached response by key. Returns null on miss.

string

Promise<Response | null>

CacheStore.get


put(key, response, ttlSeconds): Promise<void>

Defined in: src/adapters/redis.ts:304

Store a response under key with a TTL in seconds.

string

Response

number

Promise<void>

CacheStore.put