Note: Beagle Security API v1 has been deprecated. We recommend that you upgrade to v2
Delete an application
Used to delete details of an existing application.
API
DELETE
https://api.beaglesecurity.com/rest/v2/applications?application_token={application_token}
Required scope: edit_project
Request headers
| Name | Value |
|---|---|
| Authorization | Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx |
Request parameter
| Name | Type | Description | Required |
|---|---|---|---|
| applicationToken | string | A unique token for identifying the application in your project |
Example request
curl --location --request DELETE \
'https://api.beaglesecurity.com/rest/v2/applications?application_token=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \
--header 'Authorization: Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'
// This token will be generated from Beagle security settings -> Access token
BeagleSecurityClient client = BeagleSecurityClientBuilder.instance()
.withAPIToken("xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")
.build();
// Delete application
String applicationToken = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx";
Application application = client.deleteApplication(applicationToken);
Response
| Name | Type | Description |
|---|---|---|
| name | string | Name of the application |
| url | string | URL of the application |
| applicationToken | string | A unique token for identifying the application in your project |
| projectKey | string | A unique key for identifying the project |
| signatureStatus | string |
Used to know the domain verification status of the application.
Possible values are:
Verified Application is verified.
NotVerified Application is not verified.
|
| hostingType | string |
Used to specific whether it's WEB or API. If left blank, default will be set to WEB.
Possible values are:
WEB Current application is a WEB.
API Current application is a API.
|
| code | string |
Status code for the API call.
Values are:
SUCCESS API call is success
PLAN_NOT_SUPPORTED Your plan does not support this feature.
PROJECT_ALREADY_EXISTS Project already exists in your account.
INVALID_SESSION Invalid session
FAILED Failed to delete application.
NOT_AUTHORIZED User authentication failed.
|
| message | string | Success/failure message for the API call |
Example response
{
"name": "Default name",
"url": "https://example.com",
"applicationToken": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"projectKey": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"signatureStatus": "Verified",
"hostingType": "API",
"code": "SUCCESS",
"message": "Success."
}
{
"code": "TEST_RUNNING",
"message": "A test for this application is running. Cannot delete."
}
{
"code": "NOT_AUTHORIZED",
"message": "Not authorized"
}