Astra DevOps API (2.0.0)

Download OpenAPI specification:Download

Use this REST API to perform lifecycle actions for DataStax Astra databases.

To get started, get your application token from your Astra database. You can then create, terminate, resize, park, and unpark databases using the DevOps API. You cannot park, unpark, or resize serverless databases.

Authentication

BearerAuth

A token must be passed in header to access the API

Security Scheme Type HTTP
HTTP Authorization Scheme bearer

Operations

The DevOps APIs are for interacting with Astra databases and all aspects of their lifecycle

Returns a list of databases

Get a list of databases visible to the user

Authorizations:
BearerAuth (org-db-view)
query Parameters
include
string
Default: "nonterminated"
Enum: "nonterminated" "all" "active" "pending" "preparing" "prepared" "initializing" "parked" "parking" "unparking" "terminating" "terminated" "resizing" "error" "maintenance"

Allows filtering so that databases in listed states are returned

provider
string
Default: "ALL"
Enum: "ALL" "GCP" "AWS" "AZURE"

Allows filtering so that databases from a given provider are returned

starting_after
string

Optional parameter for pagination purposes. Used as this value for starting retrieving a specific page of results

limit
integer [ 1 .. 100 ]
Default: 25

Optional parameter for pagination purposes. Specify the number of items for one page of data

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a new database

Takes a user provided databaseInfo and returns the uuid for a new database

Authorizations:
BearerAuth (org-db-create)
Request Body schema: application/json

Definition of new database

name
required
string

Name of the database--user friendly identifier

keyspace
required
string

Keyspace name in database

cloudProvider
required
string
Enum: "AWS" "GCP"

This is the cloud provider where the database lives.

tier
required
string
Value: "serverless"

With the exception of classic databases, all databases are serverless. Classic databases can no longer be created with the DevOps API.

capacityUnits
required
integer [ 1 .. 1 ]

Capacity units were used for classic databases, but are not used for serverless databases. Enter 1 CU for serverless databases. Classic databases can no longer be created with the DevOps API.

region
required
string

Region refers to the cloud region.

Responses

Request samples

Content type
application/json
{
  • "name": "mySplendidDatabase",
  • "keyspace": "myKeyspace",
  • "cloudProvider": "AWS",
  • "tier": "serverless",
  • "capacityUnits": 1,
  • "region": "us-west-2"
}

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

Finds database by ID

Returns specified database

Authorizations:
BearerAuth (org-db-view)
path Parameters
databaseID
required
string

String representation of the database ID

Responses

Response samples

Content type
application/json
{
  • "id": "1234-5678-91011121-3141",
  • "orgId": "organizations/7142-1283-54249566-3707",
  • "ownerId": "users/8243-2404-85664728-0889",
  • "info": {
    },
  • "creationTime": "2012-11-01T22:08:41+00:00",
  • "terminationTime": "2019-11-01T22:08:41+00:00",
  • "status": "ACTIVE",
  • "storage": {
    },
  • "availableActions": [
    ],
  • "message": "Auto parked due to inactivity",
}

Adds keyspace into database

Adds the specified keyspace to the database

Authorizations:
BearerAuth (db-keyspace-create)
path Parameters
databaseID
required
string

String representation of the database ID

keyspaceName
required
string

Name of database keyspace

Responses

Response samples

Content type
application/json
{
  • "errors": [
    ]
}

Obtain zip for connecting to the database

Returns a temporary URL to download a zip file with certificates for connecting to the database. The URL expires after five minutes.

There are two types of the secure bundle URL:

  • Internal - Use with VPC peering connections to use private networking and avoid public internet for communication.
  • External - Use with any connection where the public internet is sufficient for communication between the application and the Astra database with MTLS.
Both types support MTLS for communication via the driver.

Authorizations:
BearerAuth (db-cql)
path Parameters
databaseID
required
string

String representation of the database ID

Responses

Response samples

Content type
application/json
{
  • "downloadURL": "nifty.cloud.datastax.com:9092",
  • "downloadURLInternal": "internal-nifty.cloud.datastax.com:9092",
  • "downloadURLMigrationProxy": "proxy-nifty.cloud.datastax.com:9092",
  • "downloadURLMigrationProxyInternal": "proxy-nifty.cloud.datastax.com:9092"
}

Terminates a database

Terminates a database

Authorizations:
BearerAuth (org-db-terminate)
path Parameters
databaseID
required
string

String representation of the database ID

query Parameters
preparedStateOnly
boolean
Default: false

For internal use only. Used to safely terminate prepared databases.

Responses