Delete Companies

DELETE https://app.alaaqat.com/api/companies/delete-selected

Deletes one or more companies in a single request. Each company's notes are deleted with it. Your API key needs the company-delete ability, and the team member who created the key needs Delete Company.

{warning} Deleting is permanent. A deleted company and its notes cannot be restored.

Header

{
    "Accept": "application/json",
    "Content-Type": "application/json"
}

Body

{
    selected_ids: string[]
}
Field Required Validation Description
selected_ids Required An array of company IDs The _id of every company to delete.
{
    "selected_ids": [
        "6655a1b2c3d4e5f6a7b8c901",
        "6655a1b2c3d4e5f6a7b8c902"
    ]
}

An ID that does not match a company in your account is skipped, and the rest are still deleted.

Response

200 OK

{
    "message": "Entity was deleted successfully.",
    "data": []
}

The response is the same whether every ID matched a company or some were skipped. To check the result, list your companies again.