Create an Agent Memory service
Create an Agent Memory service in Redis Cloud to store working and long-term memory for AI agents.
| Redis Cloud |
|---|
Redis Agent Memory provides a persistent, structured memory layer that AI agents can use to store, retrieve, and manage contextual data across interactions. This guide walks you through creating and configuring an Agent Memory service in Redis Cloud.
Prerequisites and limitations
To create a Redis Agent Memory service, you will need a Redis Cloud database. If you don't have one, see Create a database.
Agent Memory does not support the following databases during public preview:
- Redis Flex databases
- Databases using AWS PrivateLink connectivity
- Active-Active databases
- Databases with the default user turned off
Create an Agent Memory service
From the Redis Cloud console, select Agent Memory from the left-hand menu.
If you have not already created an Agent Memory service, you'll see a page with an introduction to Agent Memory. Otherwise, select New service to go to the Agent Memory introduction page.
From here:
-
Select Quick create to create an Agent Memory service with default settings using your Free 30MB database. If you haven't created a Free database yet, Redis Cloud will create one and set up the Agent Memory service for you.
After Redis Cloud creates your Agent Memory service, a window containing your Agent Memory service key will appear. Select Copy to copy the key to your clipboard.
Warning:This is the only time the value of the user key is available. Save it to a secure location before closing the dialog box.
If you lose the service key value, you will need to generate a new service key to be able to use the Agent Memory API.
After your service is created, you can use the Agent Memory API from your client app.
-
If you want to customize your Agent Memory service, select Create custom.
This takes you to the Create Agent Memory Service page. This page is divided into the following sections:
- The General settings section defines basic properties of your service.
- The Memory configuration section allows you to define the time-to-live (TTL) of your agent's memories.
General settings
The General settings section defines basic properties of your service.
| Setting name | Description |
|---|---|
| Service name | Enter a name for your Agent Memory service. We recommend you use a name that describes your service's purpose. |
| Select database | Select the Redis Cloud database to use for this service from the list. |
| User for this service | The database access user to use for this service. Agent Memory only supports the default user during public preview. |
Memory configuration
The Memory configuration section allows you to define the time-to-live (TTL) of your agent's memories.
| Setting name | Description |
|---|---|
| Short-term TTL | Defines the time-to-live (TTL) of your agent's short-term memory (also known as session memory). You can define this TTL in seconds, minutes, hours, or days. Default: 1 hour |
| Long-term TTL | Defines the time-to-live (TTL) of your agent's long-term memory. You can define this TTL in seconds, minutes, hours, or days. Default: 365 days |
Create service
When you are done setting the details of your Agent Memory service, select Create to create it.
A window containing your Agent Memory service key will appear. Select Copy to copy the key to your clipboard.
This is the only time the value of the user key is available. Save it to a secure location before closing the dialog box.
If you lose the service key value, you will need to generate a new service key to be able to use the Agent Memory API.
If an error occurs, verify that your database is active. For help, contact support.
Next steps
After your service is created, you can use the Agent Memory API from your client app.
You can also view and edit the service.