Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions content/operate/rc/api/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ linkTitle: REST API
weight: 80
---

The [Redis Cloud REST API]({{< relref "/operate/rc/api/api-reference" >}}) helps you manage your Redis Cloud databases programmatically.
The [Redis Cloud REST API](/content/operate/rc/api/api-reference.md) helps you manage your Redis Cloud databases programmatically.

You can use the API to:

Expand All @@ -22,23 +22,23 @@ You can use the API to:

## Get started

1. [Enable the API]({{< relref "/operate/rc/api/get-started/enable-the-api.md" >}})
1. [Authenticate and authorize]({{< relref "/operate/rc/api/get-started" >}})
1. [Create API keys]({{< relref "/operate/rc/api/get-started/manage-api-keys.md" >}})
1. [Use the API]({{< relref "/operate/rc/api/get-started/use-rest-api.md" >}})
1. [Learn the API lifecycle]({{< relref "/operate/rc/api/get-started/process-lifecycle.md" >}})
1. [Create and manage subscriptions]({{< relref "/operate/rc/api/examples/manage-subscriptions.md" >}})
1. [Enable the API](/content/operate/rc/api/get-started/enable-the-api.md)
1. [Authenticate and authorize](/content/operate/rc/api/get-started/_index.md)
1. [Create API keys](/content/operate/rc/api/get-started/manage-api-keys.md)
1. [Use the API](/content/operate/rc/api/get-started/use-rest-api.md)
1. [Learn the API lifecycle](/content/operate/rc/api/get-started/process-lifecycle.md)
1. [Create and manage subscriptions](/content/operate/rc/api/examples/manage-subscriptions.md)

## Examples

1. [Manage subscriptions]({{< relref "/operate/rc/api/examples/manage-subscriptions.md" >}})
1. [Manage subscriptions](/content/operate/rc/api/examples/manage-subscriptions.md)
1. Database examples
- [Create and manage databases]({{< relref "/operate/rc/api/examples/create-database" >}})
- [Back up and import data]({{< relref "/operate/rc/api/examples/back-up-and-import-data.md" >}})
1. [Estimate costs]({{< relref "/operate/rc/api/examples/dryrun-cost-estimates.md" >}})
- [Create and manage databases](/content/operate/rc/api/examples/create-database.md)
- [Back up and import data](/content/operate/rc/api/examples/back-up-and-import-data.md)
1. [Estimate costs](/content/operate/rc/api/examples/dryrun-cost-estimates.md)

## More info

- Use the [Redis Cloud API]({{< relref "/operate/rc/api/get-started/use-rest-api.md" >}})
- [Full API Reference]({{< relref "/operate/rc/api/api-reference" >}})
- Secure [authentication and authorization]({{< relref "/operate/rc/api/get-started" >}})
- Use the [Redis Cloud API](/content/operate/rc/api/get-started/use-rest-api.md)
- [Full API Reference](/content/operate/rc/api/api-reference.md)
- Secure [authentication and authorization](/content/operate/rc/api/get-started/_index.md)
4 changes: 2 additions & 2 deletions content/operate/rc/api/examples/audit-system-logs.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ To view the log, sign in to the [Redis Cloud console](https://cloud.redis.io/) a

{{<image filename="images/rc/system-logs.png" alt="Choose the Logs command from the Redis Cloud console menu to view your subscription system log." width="100%">}}

To learn more, see [System logs]({{< relref "/operate/rc/logs-reports/system-logs" >}}).
To learn more, see [System logs](/content/operate/rc/logs-reports/system-logs.md).

## Get system logs via REST API

The REST API operation for querying the system log is [`GET /logs`]({{< relref "/operate/rc/api/api-reference#tag/Account/operation/getAccountSystemLogs" >}}). Your account must have the **Owner**, **Viewer**, or **Logs viewer** role to query this endpoint.
The REST API operation for querying the system log is [`GET /logs`](/content/operate/rc/api/api-reference.md#tag/Account/operation/getAccountSystemLogs). Your account must have the **Owner**, **Viewer**, or **Logs viewer** role to query this endpoint.

The `/logs` API operation accepts the following parameters:

Expand Down
24 changes: 11 additions & 13 deletions content/operate/rc/api/examples/back-up-and-import-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,26 +14,25 @@ weight: 40
## Back up a database

When you create or update a database, you can specify the (optional) `periodicBackupPath` parameter
with a [backup path]({{< relref "/operate/rc/databases/back-up-data" >}}).
with a [backup path](/content/operate/rc/databases/back-up-data.md).
This parameter enables periodic and on-demand backup operations for the specified database.

{{<note>}}
The number of database backups that can run simultaneously on a cluster is limited to 4 by default.
{{</note>}}
> [!NOTE]
> The number of database backups that can run simultaneously on a cluster is limited to 4 by default.

For Redis Cloud Pro databases, back up a database with [`POST /subscriptions/{subscriptionId}/databases/{databaseId}/backup`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/backupDatabase" >}}). For Redis Cloud Essentials databases, use [`POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/backupDatabase_1" >}}).
On-demand database backup is an [asynchronous operation]({{< relref "/operate/rc/api/get-started/process-lifecycle" >}}).
For Redis Cloud Pro databases, back up a database with [`POST /subscriptions/{subscriptionId}/databases/{databaseId}/backup`](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/backupDatabase). For Redis Cloud Essentials databases, use [`POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup`](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/backupDatabase_1).
On-demand database backup is an [asynchronous operation](/content/operate/rc/api/get-started/process-lifecycle.md).

The backup database API does not require a body. Instead, the `periodicBackupPath` must be set to a valid path with available storage capacity to store the backup files for the specific database. You can set an `adhocBackupPath` in the body to specify a different backup location for this backup.

See [Set up backup storage locations]({{< relref "/operate/rc/databases/back-up-data#set-up-backup-storage-locations" >}}) to learn how to configure your backup storage locations.
See [Set up backup storage locations](/content/operate/rc/databases/back-up-data.md#set-up-backup-storage-locations) to learn how to configure your backup storage locations.

## Import data to a database

You can import data into an existing database from multiple storage sources, including AWS S3, Redis, and FTP.
Database import is an [asynchronous operation]({{< relref "/operate/rc/api/get-started/process-lifecycle" >}}).
Database import is an [asynchronous operation](/content/operate/rc/api/get-started/process-lifecycle.md).

Use [`POST /v1/subscriptions/{subscriptionId}/databases/{databaseId}/import`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/importDatabase" >}}) to import data to an existing Redis Cloud Pro database. For Redis Cloud Essentials databases, use [`POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/importDatabase_1" >}})
Use [`POST /v1/subscriptions/{subscriptionId}/databases/{databaseId}/import`](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/importDatabase) to import data to an existing Redis Cloud Pro database. For Redis Cloud Essentials databases, use [`POST /fixed/subscriptions/{subscriptionId}/databases/{databaseId}/backup`](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/importDatabase_1)

The requirements for data import are:

Expand All @@ -44,9 +43,8 @@ The requirements for data import are:

The duration of the import process depends on the amount of data imported and the network bandwidth between the data source and the importing database.

{{< warning >}}
Data imported into an existing database overwrites any existing data.
{{< /warning >}}
> [!WARNING]
> Data imported into an existing database overwrites any existing data.

You can specify the backup location with the `sourceType` and `importFromUri` values for these sources:

Expand All @@ -59,4 +57,4 @@ You can specify the backup location with the `sourceType` and `importFromUri` va
|Redis server|redis|redis://[db_password]@[host]:[port]|
|Web server|HTTP|HTTP://[username][:password]@[:port]/[path/]filename.rdb[.gz]|

See [Import data]({{< relref "/operate/rc/databases/import-data" >}}) to learn how to set up your storage locations for data import.
See [Import data](/content/operate/rc/databases/import-data.md) to learn how to set up your storage locations for data import.
34 changes: 17 additions & 17 deletions content/operate/rc/api/examples/create-database.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ You can use the Redis Cloud REST API to create and manage databases.

### Create an Essentials database

To create a Redis Cloud Essentials database, use [`POST /fixed/subscriptions/{subscriptionId}/databases`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/createFixedDatabase" >}}).
To create a Redis Cloud Essentials database, use [`POST /fixed/subscriptions/{subscriptionId}/databases`](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/createFixedDatabase).

This call creates a database in the specified subscription. Use [`GET /fixed/subscriptions`]({{< relref "/operate/rc/api/api-reference#tag/Subscriptions-Essentials/operation/getAllSubscriptions_1" >}}) to get a list of Essentials subscriptions and their IDs.
This call creates a database in the specified subscription. Use [`GET /fixed/subscriptions`](/content/operate/rc/api/api-reference.md#tag/Subscriptions-Essentials/operation/getAllSubscriptions_1) to get a list of Essentials subscriptions and their IDs.

```shell
POST "https://[host]/v1/fixed/subscriptions/{subscriptionId}/databases"
Expand All @@ -31,31 +31,31 @@ This example JSON body contains only the most basic, required parameters to crea

- `name`: The database name. A unique name per subscription that can contain only alphanumeric characters and hyphens

There are other additional parameters and settings that can be defined on database creation. Review the database parameters and options in the [full API reference]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/createFixedDatabase" >}}).
There are other additional parameters and settings that can be defined on database creation. Review the database parameters and options in the [full API reference](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/createFixedDatabase).

Some options may not be compatible with your selected plan. Use [`GET /fixed/subscriptions/{subscriptionId}`]({{< relref "/operate/rc/api/api-reference#tag/Subscriptions-Essentials/operation/getFixedSubscriptionsPlansBySubscriptionId" >}}) to view the plan you have selected and what options it supports.
Some options may not be compatible with your selected plan. Use [`GET /fixed/subscriptions/{subscriptionId}`](/content/operate/rc/api/api-reference.md#tag/Subscriptions-Essentials/operation/getFixedSubscriptionsPlansBySubscriptionId) to view the plan you have selected and what options it supports.

The response body contains the `taskId` for the task that creates the database. You can use [`GET /v1/tasks/{taskId}`]({{< relref "/operate/rc/api/api-reference#tag/Tasks/operation/getTaskById" >}}) to track the task's status.
The response body contains the `taskId` for the task that creates the database. You can use [`GET /v1/tasks/{taskId}`](/content/operate/rc/api/api-reference.md#tag/Tasks/operation/getTaskById) to track the task's status.

### Update an Essentials database

To update a Redis Cloud Essentials database, use [`PUT /fixed/subscriptions/{subscriptionId}/databases/{databaseId}`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/deleteFixedDatabaseByID" >}}).
To update a Redis Cloud Essentials database, use [`PUT /fixed/subscriptions/{subscriptionId}/databases/{databaseId}`](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/deleteFixedDatabaseByID).

The primary component of a database update request is the JSON request body that contains the details of the requested database changes. You can see the full set of changes you can make in the [full API reference]({{< relref "/operate/rc/api/api-reference#tag/Databases-Essentials/operation/deleteFixedDatabaseByID" >}}).
The primary component of a database update request is the JSON request body that contains the details of the requested database changes. You can see the full set of changes you can make in the [full API reference](/content/operate/rc/api/api-reference.md#tag/Databases-Essentials/operation/deleteFixedDatabaseByID).

Some options may not be compatible with your selected plan. Use [`GET /fixed/subscriptions/{subscriptionId}`]({{< relref "/operate/rc/api/api-reference#tag/Subscriptions-Essentials/operation/getFixedSubscriptionsPlansBySubscriptionId" >}}) to view the plan you have selected and what options it supports.
Some options may not be compatible with your selected plan. Use [`GET /fixed/subscriptions/{subscriptionId}`](/content/operate/rc/api/api-reference.md#tag/Subscriptions-Essentials/operation/getFixedSubscriptionsPlansBySubscriptionId) to view the plan you have selected and what options it supports.

The response body contains the `taskId` for the task that updates the database. You can use [`GET /v1/tasks/{taskId}`]({{< relref "/operate/rc/api/api-reference#tag/Tasks/operation/getTaskById" >}}) to track the task's status.
The response body contains the `taskId` for the task that updates the database. You can use [`GET /v1/tasks/{taskId}`](/content/operate/rc/api/api-reference.md#tag/Tasks/operation/getTaskById) to track the task's status.

## Redis Cloud Pro

### Create a Pro database

If you want to create a Pro database in a new subscription, see [Create a Pro subscription]({{< relref "/operate/rc/api/examples/manage-subscriptions#create-a-pro-subscription" >}}).
If you want to create a Pro database in a new subscription, see [Create a Pro subscription](/content/operate/rc/api/examples/manage-subscriptions.md#create-a-pro-subscription).

To create a Redis Cloud Pro database in an existing subscription, use [`POST /subscriptions/{subscriptionId}/databases`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/createDatabase" >}}).
To create a Redis Cloud Pro database in an existing subscription, use [`POST /subscriptions/{subscriptionId}/databases`](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/createDatabase).

This call creates a database in the specified subscription. Use [`GET /subscriptions`]({{< relref "/operate/rc/api/api-reference#tag/Subscriptions-Pro/operation/getAllSubscriptions" >}}) to get a list of subscriptions and their IDs.
This call creates a database in the specified subscription. Use [`GET /subscriptions`](/content/operate/rc/api/api-reference.md#tag/Subscriptions-Pro/operation/getAllSubscriptions) to get a list of subscriptions and their IDs.

```shell
POST "https://[host]/v1/subscriptions/{subscriptionId}/databases"
Expand All @@ -70,14 +70,14 @@ This example JSON body contains only the most basic, required parameters to crea
- `name`: The database name. A unique name per subscription that can contain only alphanumeric characters and hyphens
- `datasetSizeInGb`: Maximum dataset size in GB

There are many additional parameters and settings that can be defined on database creation. Review the database parameters and options in the [full API reference]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/createDatabase" >}}).
There are many additional parameters and settings that can be defined on database creation. Review the database parameters and options in the [full API reference](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/createDatabase).

The response body contains the `taskId` for the task that creates the database. You can use [`GET /v1/tasks/{taskId}`]({{< relref "/operate/rc/api/api-reference#tag/Tasks/operation/getTaskById" >}}) to track the task's status.
The response body contains the `taskId` for the task that creates the database. You can use [`GET /v1/tasks/{taskId}`](/content/operate/rc/api/api-reference.md#tag/Tasks/operation/getTaskById) to track the task's status.

### Update a Redis Cloud Pro database

To update a Redis Cloud Pro database, use [`PUT /subscriptions/{subscriptionId}/databases/{databaseId}`]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/updateDatabase" >}}).
To update a Redis Cloud Pro database, use [`PUT /subscriptions/{subscriptionId}/databases/{databaseId}`](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/updateDatabase).

The primary component of a database update request is the JSON request body that contains the details of the requested database changes. You can see the full set of changes you can make in the [full API reference]({{< relref "/operate/rc/api/api-reference#tag/Databases-Pro/operation/updateDatabase" >}}).
The primary component of a database update request is the JSON request body that contains the details of the requested database changes. You can see the full set of changes you can make in the [full API reference](/content/operate/rc/api/api-reference.md#tag/Databases-Pro/operation/updateDatabase).

The response body contains the `taskId` for the task that updates the database. You can use [`GET /v1/tasks/{taskId}`]({{< relref "/operate/rc/api/api-reference#tag/Tasks/operation/getTaskById" >}}) to track the task's status.
The response body contains the `taskId` for the task that updates the database. You can use [`GET /v1/tasks/{taskId}`](/content/operate/rc/api/api-reference.md#tag/Tasks/operation/getTaskById) to track the task's status.
3 changes: 2 additions & 1 deletion content/operate/rc/api/examples/dryrun-cost-estimates.md
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,8 @@ Here is an example of the pricing response section for the above create subscrip
}
```

{{<note>}}Some of the response content was omitted for brevity.{{</note>}}
> [!NOTE]
> Some of the response content was omitted for brevity.

1. The `pricing` array contains an element for each database, containing the database name and cost evaluation related to that database
2. The database cost is measured in type and number of shards required for the specific database, as defined by the database template in the request. See [Cloud Pricing](https://redislabs.com/redis-enterprise-cloud/pricing)
Expand Down
Loading
Loading