POST
/
organizations
/
{organization}
/
databases
/
{database}
/
branches
/
{branch}
/
query-patterns
Create a new query patterns report
curl --request POST \
  --url https://api.planetscale.com/v1/organizations/{organization}/databases/{database}/branches/{branch}/query-patterns \
  --header 'Authorization: <api-key>'
{
  "id": "<string>",
  "state": "pending",
  "created_at": "<string>",
  "finished_at": "<string>",
  "url": "<string>",
  "download_url": "<string>",
  "actor": {}
}

Authorizations

Authorization
string
header
required

Path Parameters

organization
string
required

The name of the organization the branch belongs to

database
string
required

The name of the database the branch belongs to

branch
string
required

The name of the branch

Response

The created query patterns download

id
string
required

The ID of the query patterns download

state
enum<string>
required

The state of the download

Available options:
pending,
completed,
failed
created_at
string
required

When the download was created

finished_at
string
required

When the download was finished

url
string
required

The URL to access the query patterns download

download_url
string
required

The URL to download the query patterns file

actor
object
required