Database Servers (Admin)

Updated Oct 4, 2026 Markdown

GET /api/v1/databases

List every database on the server (admin)

Server-wide listing including orphan databases (no {user}_ prefix match). Used by the operator's orphan-cleanup tool. Response data is a list of {name, owner, size_mb, ...} rows.

Responses:

Status Schema Description
200 object Successful Response

Response example (200):

JSON
{}

cURL example:

shell
curl -X GET \
  -H "X-WHost-Key: $WHOST_API_KEY" \
  -H "X-WHost-Timestamp: $(date +%s)" \
  -H "X-WHost-Nonce: $(openssl rand -hex 16)" \
  -H "X-WHost-Signature: $(compute_hmac)" \
  https://your-server:2000/api/v1/databases

DELETE /api/v1/databases/{db_name}

Drop any database (admin)

Admin orphan-cleanup. Refuses to drop internal system schemas.

Path parameters:

Name Type Required Notes
db_name string yes —

Responses:

Status Schema Description
200 MessageResponse Successful Response
422 HTTPValidationError Validation Error

Response example (200):

JSON
{
  "message": "string",
  "status": "success"
}

cURL example:

shell
curl -X DELETE \
  -H "X-WHost-Key: $WHOST_API_KEY" \
  -H "X-WHost-Timestamp: $(date +%s)" \
  -H "X-WHost-Nonce: $(openssl rand -hex 16)" \
  -H "X-WHost-Signature: $(compute_hmac)" \
  https://your-server:2000/api/v1/databases/{db_name}

GET /api/v1/databases/{db_name}/phpmyadmin-url

Mint phpMyAdmin SSO URL for any database (admin)

Admin-scope variant — works for orphan databases too. Returns 200 with error_code=PMA_NOT_INSTALLED when phpMyAdmin is absent. Handle both shapes client-side.

Path parameters:

Name Type Required Notes
db_name string yes —

Responses:

Status Schema Description
200 object Successful Response
422 HTTPValidationError Validation Error

Response example (200):

JSON
{}

cURL example:

shell
curl -X GET \
  -H "X-WHost-Key: $WHOST_API_KEY" \
  -H "X-WHost-Timestamp: $(date +%s)" \
  -H "X-WHost-Nonce: $(openssl rand -hex 16)" \
  -H "X-WHost-Signature: $(compute_hmac)" \
  https://your-server:2000/api/v1/databases/{db_name}/phpmyadmin-url
Still Need Help?

Our support team is here around the clock for anything you can't find above.