---
title: "Delete Contacts"
method: POST
path: "/contact/delete"
tags: ["Contacts"]
---

# Delete Contacts

`POST /contact/delete`

The Delete Contacts(Async) API enables you to delete contacts either by specifying filtering criteria or by directly providing contact identifiers. It supports both identified and anonymous contact types and can handle deletion using direct contact identifiers, filtered criteria, or external file URLs.

## Headers

- `api-key` string, required
- `Content-Type` string, required

## Request body

- object
  - `filtering_criteria_operator` string — Define how multiple filtering criteria blocks should be combined (Supported "and" & "or"). Mandatory if more than one 'filtering_criteria' block are provided. Optional if only one filtering block is used.
  - `filtering_criteria` object[] — Used to dynamically select contacts to be deleted based on conditions like attribute values, audience IDs, or other fields.
    - `condition_operator` string — Specifies how multiple conditions within this block should be combined(Supported "and" & "or").
    - `condition_details` object[] — Defines specific conditions used to filter contacts.
      - `field` string — Specify field name to filter on email, identity, list_id, contact_type, or attribute name.
      - `field_category` string — Specify field category to be added in filter condition. fields allowed: config , attribute, audience
      - `operation` string — Specify the category of the field. Supported: equals, startswith, not_equals, greater_than_or_equal_to, greater_than, not_in, less_than, ends_with, is_not_null, is_null
      - `value` string[] — Values to match for the given field and operation. The datatype of value must match with datatype of field selected. regex is :- ^(?:\d+|[a-zA-Z]+|[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}|[0-9]{10}|[A-Za-z0-9]{4}(-[A-Za-z0-9]{4}){3})$
  - `data` object — Used for directly deleting specific contacts or deleting via file. When this block is present, filtering criteria is ignored.
    - `contact_type` string, required — Type of contact to be deleted. Mandatory when 'data' is used. Allowed values: 'identified', 'anonymous'
    - `delete_type` string, required — Specifies how deletion should happen. Accepts: soft | audience soft : Deletes comntact from system and audience. audience : Deletes contact only from specified audiences. Mandatory if data object is present.
    - `contacts` object[] — An array of contacts: Either contacts or file_url should be specified, but not both together, as it will lead to a validation error.
      - `identity` string — identity of individual contact as per client pannel settings. Applicable only if contact_type is identified.
      - `contact_id` integer — contact_id of individual contact. contact_id will be accepted for both identified & anon cases.
      - `email` string — email of contact in case of anon
      - `mobile` string — mobile of contact in case of anon
      - `audience_details` object[] — Specify audience to delete contact from. Will be ignored in case of delete_type is other than audience or contact type is anonymous. Audience can be specified either by audience_id or audience name, if both presents it will cause validation error.
        - `audience_id` integer[] — Specify audience by audience_id regex:- \[\s*([1-9]\d*\s*,\s*)*[1-9]\d*\s*\]
        - `audience_name` string[] — Specify audience by audience_name regex:- \[\s*("[A-Za-z]+"(\s*,\s*"[A-Za-z]+")*)?\s*\]
        - `audience_type` string, required — Specify audience_type. "list" | "ccg"
    - `file_url` string — Url of file located at S3 or GC storage or equivalent. Bulk delete by file is not applicable to anonymous contact_type
    - `audience_details` object[] — Specify audience to delete contact from. This will apply to all specified contacts. Will be ignored in case of delete_type is other than audience. Audience can be specified either by audience_id or audience name, if both presents it will cause validation error. if audience_details present for both individual contact & all contacts then both audiences will be tagged accordingly
      - `audience_id` integer[] — Specify audience by audience_id regex:- \[\s*([1-9]\d*\s*,\s*)*[1-9]\d*\s*\]
      - `audience_name` string[] — Specify audience by audience_name regex:- \[\s*("[A-Za-z]+"(\s*,\s*"[A-Za-z]+")*)?\s*\]
      - `audience_type` string, required — Specify audience_type. "list" | "ccg"

## Response `200`

- object
  - `request_id` string, required — Unique request id of request.
  - `code` integer, required — Response status Code. (200 for success / 500 for error etc).
  - `status` string, required — status of api request (success|failed)
  - `description` string, required — Api response description

## Other responses

- `500`

---

[API](https://skmtc.net/netcorecloud/apis/contacts-api.md) · [All operations](https://skmtc.net/netcorecloud/apis/contacts-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/netcorecloud/contacts-api/versions/2878cfd0ee01/schema)
