---
title: "get cache key · RUAL Documentation"
description: "gets the key and returns true or false based of its existence, makes it easier for cache-management in flows"
canonical: https://docs.rual.nl/block-types/redis/function_redis_cache_get_exists
language: en
---

# get cache key

This block is part of the [`redis`](https://docs.rual.nl/block-types/redis) group and was last modified in core [`v13.0.6`](https://docs.rual.nl/core-versions/130006).

### Redis Key Selection Required

This block relies on a Redis key to perform its redis releated actions. You must manually select the Redis key you want to use in the flow in the blueprint using the Redis key selector modal. To access the modal, click the white button on the block.

gets the key and returns `true` or `false` based of its existence, makes it easier for cache-management in flows

- flow `flow`

- exists `condition` returns `true` if the key exists

- value `value` current value of the cache key

- key `value` current redis key, this outpin be handy when using dynamic redis keys

| `redis get` |
| --- |

A typical wiring for [get cache key](https://docs.rual.nl/block-types/redis/function_redis_cache_get_exists): the `flow` out pin feeds [branch](https://docs.rual.nl/block-types/flow/branch); the `value` out pin feeds [parse](https://docs.rual.nl/block-types/value/value_json_parse).

![Studio canvas example for the get cache key block: typical wiring for get cache key.](https://docs.rual.nl/canvas-examples/function_redis_cache_get_exists.png)

### Commonly used with

In production blueprints, this block is most often wired together with:

- [branch](https://docs.rual.nl/block-types/flow/branch): wired in both directions with this block.

- [create](https://docs.rual.nl/block-types/globals/trigger_custom_function): feeds into this block. Creates a new function that can be executed using the given name.

- [parse](https://docs.rual.nl/block-types/value/value_json_parse): this block feeds into it. Converts a JSON in text format to a data structure that can be used inside functions.

- [==](https://docs.rual.nl/block-types/condition/condition_equal): this block feeds into it. returns true if the two values are equal.

- [get guid](https://docs.rual.nl/block-types/users/user_get_guid): feeds into this block. Returns the guid (field: _meta.guid) of the given user.

- [logical OR](https://docs.rual.nl/block-types/value/value_logical_or): feeds into this block. will return the first truthy value, checking first, then second, then any extended pins. Falsy means null, false, 0, NaN or an empty string, so first being 0 or false also falls through.

### Used in these guides

These documentation pages use or explain this block:

- [Common Blueprint Patterns](https://docs.rual.nl/blueprints/common-patterns)

### Version history

Introduced in [`v13.0.6`](https://docs.rual.nl/core-versions/130006).
