> ## Documentation Index
> Fetch the complete documentation index at: https://docs.repdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete Respondents

> Delete one or more respondents from a survey and remove all related data. If no respondents remain for the survey, the survey is deleted automatically.

Delete one or more respondents from a survey. Also removes related metadata, interaction data, and flattened records. If no respondents remain for the survey, the survey is deleted automatically.


## OpenAPI

````yaml POST /v2/deleteRespondents
openapi: 3.0.1
info:
  title: API Documentation
  description: API Documentation for Redem 3.0
  version: 1.0.0
  license:
    name: MIT
servers:
  - url: https://api.redem.io
security:
  - apiKeyAuth: []
tags:
  - name: Survey
    description: Survey management
  - name: Respondent
    description: Respondent management
paths:
  /v2/deleteRespondents:
    post:
      tags:
        - Respondent
      summary: Delete respondents
      description: >-
        Delete one or more respondents from a survey and remove all related
        data. If no respondents remain for the survey, the survey is deleted
        automatically.
      operationId: deleteRespondentsV2
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                surveyName:
                  type: string
                  description: The survey name.
                respondentIds:
                  type: array
                  items:
                    type: string
                  minItems: 1
                  description: Array of respondent IDs to delete.
              required:
                - surveyName
                - respondentIds
            example:
              surveyName: Customer-Satisfaction-2025
              respondentIds:
                - R123
                - R124
      responses:
        '200':
          description: >-
            When a request is successfully processed, the API returns a 200 OK
            status code along with the expected data.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    description: >-
                      A variable indicating whether the **operation was
                      successful**.
                  message:
                    type: string
                    description: >-
                      A variable that **human-readable message** providing
                      additional context or confirmation of the requested
                      action.
                  results:
                    type: object
                    description: >-
                      This object serves as a **container to hold the results
                      for the requested data**, encapsulating all relevant
                      information and outputs in a structured format.
                    properties:
                      deleted:
                        type: object
                        properties:
                          respondent:
                            type: number
              example:
                success: true
                message: Respondents deleted successfully
                results:
                  deleted:
                    respondent: 2
        '400':
          description: >-
            When a request fails due to invalid input or other errors, the API
            returns a 400 Bad Request status code. The response includes a
            descriptive message explaining the issue and an error object
            containing additional details to aid in diagnosing and resolving the
            problem.
          content:
            application/json:
              schema:
                type: object
              examples:
                Validation Error:
                  value:
                    success: false
                    message: Validation Error
                    errors:
                      '0': '"surveyName" is required'
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: api-key

````