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

# Purge customers

> Purge all customers matching the given identifiers.

Purging is a permanent action. Once a customer is purged, they cannot be recovered.

Purging is done on a queue. It may take some time for the customers to be purged. We recommend using the `GET /v2/customers` endpoint to determine if the customers have been purged. Approximate time to purge is
normally under < 5 minutes, but can be several hours in some cases.

Customers who we were able to queue will be returned in the `accepted` array. Customers who we do not hold a record of or cannot find will be returned in the `errors` array.

**Scopes:** `customers:delete`

**Rate limits:** 300 requests per 5 minutes. Shared across all 'customers' endpoints.



## OpenAPI

````yaml /openapi/merchant_api.oas.json delete /api/merchant/v2/customers
openapi: 3.0.0
info:
  title: Merchant API
  description: Interact directly with the Mention Me platform using our REST API.
  termsOfService: https://mention-me.com/help/tnc_f/site
  contact:
    name: Mention Me
    url: https://mention-me.com
    email: support@mention-me.com
  version: v2
servers:
  - url: https://mention-me.com
    description: Production
  - url: https://demo.mention-me.com
    description: Demo
security:
  - Bearer: []
tags:
  - name: Coupons
  - name: Customers
  - name: Referee
paths:
  /api/merchant/v2/customers:
    delete:
      tags:
        - Customers
      summary: Purge customers
      description: >-
        Purge all customers matching the given identifiers.


        Purging is a permanent action. Once a customer is purged, they cannot be
        recovered.


        Purging is done on a queue. It may take some time for the customers to
        be purged. We recommend using the `GET /v2/customers` endpoint to
        determine if the customers have been purged. Approximate time to purge
        is

        normally under < 5 minutes, but can be several hours in some cases.


        Customers who we were able to queue will be returned in the `accepted`
        array. Customers who we do not hold a record of or cannot find will be
        returned in the `errors` array.


        **Scopes:** `customers:delete`


        **Rate limits:** 300 requests per 5 minutes. Shared across all
        'customers' endpoints.
      operationId: delete_merchant_api_customers_delete
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CustomerIdentifierCollectionInput'
      responses:
        '202':
          description: All identifiers that were queued to be purged.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BulkCustomerResponse'
        '401':
          description: Required scopes are missing.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/UnauthorisedRFC7807Problem'
        '404':
          description: No customers matched the identifiers.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/RFC7807Problem'
        '429':
          description: Rate limit exceeded.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/TooManyRequestsRFC7807Problem'
components:
  schemas:
    CustomerIdentifierCollectionInput:
      description: A collection of identifiers for customers in Mention Me.
      required:
        - identifiers
      properties:
        identifiers:
          description: Maximum of 100 identifiers.
          type: array
          items:
            $ref: '#/components/schemas/CustomerIdentifierInterface'
          maxItems: 100
          minItems: 1
      type: object
    BulkCustomerResponse:
      description: >-
        A collection of customer identifiers which were accepted, or resulted in
        an error.
      properties:
        accepted:
          description: All the identifiers that were accepted.
          type: array
          items:
            $ref: '#/components/schemas/CustomerIdentifierInterface2'
          maxItems: 100
          minItems: 0
        errors:
          description: All the identifiers which resulted in errors.
          type: array
          items:
            $ref: '#/components/schemas/CustomerErrorPayloadInterface2'
          maxItems: 100
          minItems: 0
      type: object
    UnauthorisedRFC7807Problem:
      properties:
        status:
          type: integer
          maximum: 599
          minimum: 200
          example: 401
        type:
          type: string
          example: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
        title:
          type: string
          example: Unauthorized
        detail:
          type: string
          example: Missing at least one of the required scopes
      type: object
    RFC7807Problem:
      properties:
        status:
          type: integer
          maximum: 599
          minimum: 200
        type:
          type: string
          example: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
        title:
          type: string
        detail:
          type: string
      type: object
    TooManyRequestsRFC7807Problem:
      properties:
        status:
          type: integer
          maximum: 599
          minimum: 200
          example: 401
        type:
          type: string
          example: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
        title:
          type: string
          example: Too Many Requests
        detail:
          type: string
          example: Rate limit exceeded for Client Id
      type: object
    CustomerIdentifierInterface:
      discriminator:
        propertyName: type
        mapping:
          email:
            $ref: '#/components/schemas/CustomerEmailIdentifier'
          customerId:
            $ref: '#/components/schemas/CustomerIdIdentifier'
      oneOf:
        - $ref: '#/components/schemas/CustomerEmailIdentifier'
        - $ref: '#/components/schemas/CustomerIdIdentifier'
    CustomerIdentifierInterface2:
      discriminator:
        propertyName: type
        mapping:
          email:
            $ref: '#/components/schemas/CustomerEmailIdentifier2'
          customerId:
            $ref: '#/components/schemas/CustomerIdIdentifier2'
      oneOf:
        - $ref: '#/components/schemas/CustomerEmailIdentifier2'
        - $ref: '#/components/schemas/CustomerIdIdentifier2'
    CustomerErrorPayloadInterface2:
      discriminator:
        propertyName: reason
        mapping:
          notFound:
            $ref: '#/components/schemas/MissingCustomerErrorPayload2'
      oneOf:
        - $ref: '#/components/schemas/MissingCustomerErrorPayload2'
    CustomerEmailIdentifier:
      required:
        - type
      properties:
        type:
          description: The type of identifier.
          type: string
          enum:
            - email
        value:
          type: string
          default: ''
          maxLength: 320
          minLength: 1
          pattern: .+\@\S+\.\S+
      type: object
    CustomerIdIdentifier:
      required:
        - type
        - value
      properties:
        type:
          description: The type of identifier.
          type: string
          enum:
            - customerId
        value:
          type: string
      type: object
    CustomerEmailIdentifier2:
      required:
        - type
      properties:
        type:
          description: The type of identifier.
          type: string
          enum:
            - email
        value:
          type: string
          default: ''
          maxLength: 320
          minLength: 1
          pattern: .+\@\S+\.\S+
      type: object
    CustomerIdIdentifier2:
      required:
        - type
        - value
      properties:
        type:
          description: The type of identifier.
          type: string
          enum:
            - customerId
        value:
          type: string
      type: object
    MissingCustomerErrorPayload2:
      properties:
        type:
          $ref: '#/components/schemas/CustomerIdentifierType'
        value:
          type: string
        reason:
          $ref: '#/components/schemas/CustomerIdentifierErrorReason'
      type: object
    CustomerIdentifierType:
      type: string
      enum:
        - email
        - customerId
    CustomerIdentifierErrorReason:
      type: string
      enum:
        - notFound
  securitySchemes:
    Bearer:
      type: http
      description: RFC8725 Compliant JWT
      bearerFormat: JWT
      scheme: bearer

````