Skip to main content
curl --request DELETE \
  --url 'https://api.usedatabrain.com/api/v2/data-app?name=Customer%20Portal%20Analytics' \
  --header 'Authorization: Bearer service_token_xyz...'
{
  "name": "Customer Portal Analytics"
}
DELETE
https://api.usedatabrain.com
/
api
/
v2
/
data-app
curl --request DELETE \
  --url 'https://api.usedatabrain.com/api/v2/data-app?name=Customer%20Portal%20Analytics' \
  --header 'Authorization: Bearer service_token_xyz...'
{
  "name": "Customer Portal Analytics"
}
Permanently delete a Data App from your organization. This action removes the Data App along with all associated embed configurations and API tokens.
Destructive Operation: This action is irreversible. Deleting a Data App will:
  • Remove all embed configurations associated with this Data App
  • Invalidate all API tokens for this Data App
  • Break any embedded dashboards using this Data App’s tokens
Make sure you have updated your applications before deletion.
Authentication Requirement: This endpoint requires a service token (not a data app API key). Service tokens have elevated permissions to manage Data Apps across your organization.

Endpoint Formats

Authentication

This endpoint requires a service token in the Authorization header. Service tokens differ from data app API keys and provide organization-level permissions. To access your service token:
  1. Go to your Databrain dashboard and open Settings.
  2. Navigate to Settings.
  3. Find the Service Tokens section.
  4. Click the “Generate Token” button to generate a new service token if you don’t have one already.
Use this token as the Bearer value in your Authorization header.

Headers

Authorization
string
required
Bearer token for API authentication. Use your service token (not data app API key).
Authorization: Bearer service_token_xyz...

Query Parameters

name
string
required
The name of the Data App to delete. This must exactly match the Data App name.

Response

name
string
The name of the deleted Data App for confirmation.
error
object
Error object returned only when the request fails. Not included in successful responses.

Examples

HTTP Status Code Summary

Status CodeDescription
200OK - Data App deleted successfully
400Bad Request - Invalid request parameters
500Internal Server Error - Server error occurred

Possible Errors

Error CodeHTTP StatusDescription
INVALID_REQUEST_BODY400Missing or invalid name parameter
DATA_APP_NOT_FOUND400Data App with given name not found
AUTHENTICATION_ERROR400Invalid or missing service token
INTERNAL_SERVER_ERROR500Server error

Quick Start Guide

1

Verify the Data App exists

Before deleting, confirm the Data App exists using the List Data Apps API:
curl --request GET \
  --url 'https://api.usedatabrain.com/api/v2/data-app' \
  --header 'Authorization: Bearer service_token_xyz...'
2

Update your applications

Before deletion, update your applications to remove any references to this Data App’s API tokens and embed configurations.
3

Delete the Data App

Make a DELETE request with the Data App name:
curl --request DELETE \
  --url 'https://api.usedatabrain.com/api/v2/data-app?name=My%20Data%20App' \
  --header 'Authorization: Bearer service_token_xyz...'
4

Verify deletion

Confirm the Data App was deleted by listing Data Apps again:
curl --request GET \
  --url 'https://api.usedatabrain.com/api/v2/data-app' \
  --header 'Authorization: Bearer service_token_xyz...'

Best Practices

Verify Before Delete

Always verify the Data App exists and check its embeds before deletion

Update Applications First

Update your applications to remove Data App references before deletion

Handle Errors

Implement proper error handling for failed deletions

Monitor Impact

Monitor for any broken embedded dashboards after deletion

Next Steps