---
title: "Redis integration · RUAL Documentation"
description: "Use Redis in RUAL blueprints. Cache keys, lists, sets, sorted sets and Bloom filters, and rate limit calls. Every block, with its pins."
canonical: https://docs.rual.nl/integrations/redis
language: en
---

# Redis

Cache keys, lists, sets, sorted sets and Bloom filters, and rate limit calls.

> **Credentials** Create a [service provider](https://docs.rual.nl/blueprints/service-providers) for this service and point the blocks at it. The cluster holds the key, so it never sits on a pin or in a blueprint export.

## Guides

- [Storages](https://docs.rual.nl/blueprints/storage)

## Blocks

Add these blocks on the canvas by searching for their name. Each block page lists its pins and how it behaves.

- [rate limit `function_rate_limit` Counts calls per registered key and reports whether this one is still within the limit. Replaces the incr-key + ttl + condition chain every API blueprint used to build by hand: pick a key that identifies the caller (for example one with a {ip:value} placeholder), a limit, and a window. Rejected calls count towards the limit as well.](https://docs.rual.nl/block-types/redis/function_rate_limit)

- [decrement `function_redis_cache_decr_key` Decrements the number stored at key by one. If the key does not exist, it is set to 0 before performing the operation.](https://docs.rual.nl/block-types/redis/function_redis_cache_decr_key)

- [delete `function_redis_cache_delete_key` Removes the specified key and their values.](https://docs.rual.nl/block-types/redis/function_redis_cache_delete_key)

- [get cache key `function_redis_cache_get_exists` gets the key and returns true or false based of its existence, makes it easier for cache-management in flows](https://docs.rual.nl/block-types/redis/function_redis_cache_get_exists)

- [get cache json key `function_redis_cache_get_exists_json` gets the key and returns true or false based of its existence, makes it easier for cache-management in flows](https://docs.rual.nl/block-types/redis/function_redis_cache_get_exists_json)

- [get cache ttl `function_redis_cache_get_ttl` get the time to live in seconds](https://docs.rual.nl/block-types/redis/function_redis_cache_get_ttl)

- [increment `function_redis_cache_incr_key` Increments the number stored at key by one. If the key does not exist, it is set to 0 before performing the operation.](https://docs.rual.nl/block-types/redis/function_redis_cache_incr_key)

- [exists `function_redis_cache_key_exists` Checks if the key already exists](https://docs.rual.nl/block-types/redis/function_redis_cache_key_exists)

- [set `function_redis_cache_set_key` Set key to hold the string value. If key already holds a value, it is overwritten, regardless of its type.](https://docs.rual.nl/block-types/redis/function_redis_cache_set_key)

- [set json `function_redis_cache_set_key_json` Set key to hold the string value. If key already holds a value, it is overwritten, regardless of its type.](https://docs.rual.nl/block-types/redis/function_redis_cache_set_key_json)

- [set cache ttl `function_redis_cache_ttl` set the time to live in seconds](https://docs.rual.nl/block-types/redis/function_redis_cache_ttl)

- [bf add `redis_bloom_add` Add an item to a Bloom filter. Creates the filter if it does not exist.](https://docs.rual.nl/block-types/redis/redis_bloom_add)

- [bf exists `redis_bloom_exists` Check if an item may exist in a Bloom filter. Returns true if the item may exist (with the configured false-positive rate), false if it definitely does not exist.](https://docs.rual.nl/block-types/redis/redis_bloom_exists)

- [bf madd `redis_bloom_madd` Add multiple items to a Bloom filter at once. Creates the filter if it does not exist.](https://docs.rual.nl/block-types/redis/redis_bloom_madd)

- [bf mexists `redis_bloom_mexists` Check if multiple items may exist in a Bloom filter. Returns an array of booleans.](https://docs.rual.nl/block-types/redis/redis_bloom_mexists)

- [bf reserve `redis_bloom_reserve` Create a new Bloom filter with a given error rate and initial capacity. The filter will auto-scale if capacity is exceeded.](https://docs.rual.nl/block-types/redis/redis_bloom_reserve)

- [get by index `redis_list_index` Get an element from a list by its index](https://docs.rual.nl/block-types/redis/redis_list_index)

- [insert at index `redis_list_insert` Insert an element before or after another element in a list](https://docs.rual.nl/block-types/redis/redis_list_insert)

- [len `redis_list_len` get the length of a list](https://docs.rual.nl/block-types/redis/redis_list_len)

- [pop `redis_list_pop` Remove and get the first element in a list](https://docs.rual.nl/block-types/redis/redis_list_pop)

- [push `redis_list_push` prepend one element to a list](https://docs.rual.nl/block-types/redis/redis_list_push)

- [push array `redis_list_push_array` prepend multiple elements to a list](https://docs.rual.nl/block-types/redis/redis_list_push_array)

- [pushx `redis_list_pushx` prepend an element to a list, only if the list exists](https://docs.rual.nl/block-types/redis/redis_list_pushx)

- [range `redis_list_range` get a range of elements from a list. Use start 0 and stop -1 to retrieve all items.](https://docs.rual.nl/block-types/redis/redis_list_range)

- [remove `redis_list_remove` removes the first count occurrences of elements equal to element](https://docs.rual.nl/block-types/redis/redis_list_remove)

- [rpop `redis_list_rpop` remove and get the last element in a list](https://docs.rual.nl/block-types/redis/redis_list_rpop)

- [rpush `redis_list_rpush` append one or multiple elements to a list](https://docs.rual.nl/block-types/redis/redis_list_rpush)

- [rpushx `redis_list_rpushx` append an element to a list, only if the list exists](https://docs.rual.nl/block-types/redis/redis_list_rpushx)

- [set `redis_list_set` set the value of an element in a list by its index](https://docs.rual.nl/block-types/redis/redis_list_set)

- [trim `redis_list_trim` trim a list to the specified range](https://docs.rual.nl/block-types/redis/redis_list_trim)

- [add `redis_set_add` add one member to a set](https://docs.rual.nl/block-types/redis/redis_set_add)

- [card `redis_set_card` get the number of members in a set](https://docs.rual.nl/block-types/redis/redis_set_card)

- [is member `redis_set_ismember` determine if a given value is a member of a set](https://docs.rual.nl/block-types/redis/redis_set_ismember)

- [members `redis_set_members` Get all the members in a set](https://docs.rual.nl/block-types/redis/redis_set_members)

- [pop `redis_set_pop` Remove and return one random member from a set](https://docs.rual.nl/block-types/redis/redis_set_pop)

- [push array `redis_set_push_array` prepend multiple elements to a sadd](https://docs.rual.nl/block-types/redis/redis_set_push_array)

- [randmember `redis_set_randmember` Get one random member from a set](https://docs.rual.nl/block-types/redis/redis_set_randmember)

- [rem `redis_set_rem` Remove one member from a set](https://docs.rual.nl/block-types/redis/redis_set_rem)

- [zadd `redis_set_zadd` add one member to a sorted set](https://docs.rual.nl/block-types/redis/redis_set_zadd)

- [zrange `redis_set_zrange` retrieve items from the sorted sets](https://docs.rual.nl/block-types/redis/redis_set_zrange)

- [zrem `redis_zrem` remove one member from a sorted set](https://docs.rual.nl/block-types/redis/redis_zrem)

- [get cache `value_redis_cache_get_key` get redis cache](https://docs.rual.nl/block-types/redis/value_redis_cache_get_key)

## Next steps

- [Third-Party Integrations](https://docs.rual.nl/tutorials/third-party-integrations): Calling outside APIs, receiving their webhooks, keeping data in sync and handling failures.

- [All integrations](https://docs.rual.nl/integrations): Everything RUAL connects to, by what it is for.
