Skip to main content
DELETE
Delete Data Object
The Delete Data Object endpoint allows you to remove a record from a dataset. Deleted records are marked as deleted rather than permanently removed, allowing for potential recovery and audit trail maintenance.

Prerequisites

Authentication

Include your API key in the Authorization header.

Request

Path Parameters

string
required
The unique identifier of the business area. You can obtain this from the List Business Areas endpoint.
string
required
The unique identifier of the schema. You can obtain this from the List Schemas endpoint.
string
required
The unique identifier of the dataset. You can obtain this from the List Datasets endpoint.
string
required
The unique identifier of the data object to delete. You can obtain this from the List Data Objects endpoint.

Headers

string
required
Your Pretectum API key. Create one in the Pretectum app under Configuration → API Keys.
string
default:"application/json"
The response content type. Currently only application/json is supported.

Example Requests

Response

A successful deletion returns a 204 No Content response with no body.

Success Response

The 204 No Content response indicates the deletion was successful. The data object is marked as deleted and will no longer appear in list operations.

Error Responses

Soft Delete

Pretectum uses soft delete for data objects:
  • Records are marked as deleted (deleted: true) rather than permanently removed.
  • Deleted records are excluded from list operations and search results.
  • This approach maintains data integrity for audit trails and allows potential recovery.
Deletion is a sensitive operation. Ensure you have proper confirmation workflows in place before deleting data objects, especially in production environments.

Batch Deletion

To delete multiple data objects, call the delete endpoint for each object. For better performance with large batches, consider running deletions in parallel:

Best Practices

  1. Confirm before deleting: Implement confirmation dialogs or double-check logic before executing deletions.
  2. Log deletions: Maintain a record of what was deleted, when, and by whom for audit purposes.
  3. Handle errors gracefully: Not-found errors may indicate the object was already deleted.
  4. Consider permissions: Ensure only authorized users can delete data objects.
  5. Test in non-production first: Verify your deletion logic in a test environment before running in production.

List Data Objects

Retrieve records from a dataset

Create Data Object

Add new records to a dataset

Update Data Object

Modify existing records

Search Data Objects

Search across all datasets