Documentation for `scw sdb-sql`
The CLI documentation pages are currently under construction
The content is up to date. We're making improvements to the site over the next few weeks for a better experience.
This API allows you to manage your Serverless SQL Databases.
Export a database backup
Export a database backup providing a download link once the export process is completed. You must provide the backup_id parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| backup-id | UUID of the Serverless SQL Database backup. | Required |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
Get a database backup information
Retrieve information about your Serverless SQL Database backup. You must provide the backup_id parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| backup-id | UUID of the Serverless SQL Database backup. | Required |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
List your Serverless SQL Database backups
List all Serverless SQL Database backups for a given Scaleway Project or Database. By default, the backups returned in the list are ordered by creation date in descending order, though this can be modified via the order_by field.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| project-id | Filter by the UUID of the Scaleway project. | |
| database-id | Filter by the UUID of the Serverless SQL Database. | Required |
| order-by | Sorting criteria. One of created_at_asc, created_at_desc. | One of: created_at_desc, created_at_asc |
| organization-id | Filter by the UUID of the Scaleway organization. | |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par, all |
Create a new Serverless SQL Database
You must provide the following parameters: organization_id, project_id, name, cpu_min, cpu_max. You can also provide from_backup_id to create a database from a backup.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| project-id | Project ID to use. If none is passed the default project ID will be used | |
| name | The name of the Serverless SQL Database to be created. | Required |
| cpu-min | The minimum number of CPU units for your Serverless SQL Database. | Required |
| cpu-max | The maximum number of CPU units for your Serverless SQL Database. | Required |
| from-backup-id | The ID of the backup to create the database from. | |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
Delete a database
Deletes a database. You must provide the database_id parameter. All data stored in the database will be permanently deleted.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| database-id | UUID of the Serverless SQL Database. | Required |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
Get a database information
Retrieve information about your Serverless SQL Database. You must provide the database_id parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| database-id | UUID of the Serverless SQL DB database. | Required |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
List your Serverless SQL Databases
List all Serverless SQL Databases for a given Scaleway Organization or Scaleway Project. By default, the databases returned in the list are ordered by creation date in ascending order, though this can be modified via the order_by field. For the name parameter, the value you include will be checked against the whole name string to see if it includes the string you put in the parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| project-id | Project ID to use. If none is passed the default project ID will be used | |
| name | Filter by the name of the database | |
| order-by | Sorting criteria. One of created_at_asc, created_at_desc, name_asc, name_desc | One of: created_at_asc, created_at_desc, name_asc, name_desc |
| organization-id | Filter by the UUID of the Scaleway organization | |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par, all |
Restore a database from a backup
Restore a database from a backup. You must provide the backup_id parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| database-id | UUID of the Serverless SQL Database. | Required |
| backup-id | UUID of the Serverless SQL Database backup to restore. | Required |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |
Update database information
Update CPU limits of your Serverless SQL Database. You must provide the database_id parameter.
Usage:
Code
Arguments:
| Name | Description | Argument Specifications |
|---|---|---|
| database-id | UUID of the Serverless SQL Database. | Required |
| cpu-min | The minimum number of CPU units for your Serverless SQL Database. | |
| cpu-max | The maximum number of CPU units for your Serverless SQL Database. | |
| region | Region to target. If none is passed will use default region from the config | Default: fr-parOne of: fr-par |