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

# Delete One or More Tweets

> Deletes one or more tweets from a specified user account. This endpoint supports two modes:

1.  **Single Tweet Deletion**: Provide a `target_id` to delete a specific tweet.
2.  **Bulk Deletion**: Omit the `target_id` to delete **all** tweets from the user's account.

**Warning**: The bulk deletion mode is irreversible and will permanently remove all tweets from the account. Use with extreme caution.



## OpenAPI

````yaml /api-reference/openapi.json post /twitter/tweets/delete-batch
openapi: 3.1.0
info:
  title: Twitter API Service
  description: |2-

            A comprehensive Twitter API service that provides various Twitter operations including:
            
            * **Search Operations**: Advanced search, hashtags, cashtags
            * **Tweet Operations**: Post, like, retweet, quote, bookmark, delete
            * **User Operations**: Batch user information retrieval
            * **Influencer Operations**: Get tweets from top influencers
            
            All endpoints return standardized responses in the format:
            ```json
            {
                "code": 200,
                "msg": "success", 
                "data": {...}
            }
            ```
            
            ## Authentication
            
            This API uses Bearer token authentication. Include your token in the Authorization header:
            ```
            Authorization: Bearer your_token_here
            ```
            
  contact:
    name: API Support
    email: support@twitterxapi.com
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.twexapi.io
    description: Development server
security: []
paths:
  /twitter/tweets/delete-batch:
    post:
      tags:
        - Tweet Actions Endpoints
      summary: Delete One or More Tweets
      description: >-
        Deletes one or more tweets from a specified user account. This endpoint
        supports two modes:


        1.  **Single Tweet Deletion**: Provide a `target_id` to delete a
        specific tweet.

        2.  **Bulk Deletion**: Omit the `target_id` to delete **all** tweets
        from the user's account.


        **Warning**: The bulk deletion mode is irreversible and will permanently
        remove all tweets from the account. Use with extreme caution.
      operationId: delete_tweets_batch_twitter_tweets_delete_batch_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DeleteTweetQuery'
        required: true
      responses:
        '200':
          description: Success confirmation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeleteTweetResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    DeleteTweetQuery:
      properties:
        cookie:
          type: string
          title: Cookie
          description: >-
            Twitter authentication cookie or Twitter auth_token,
            [how-to-get-twitter-cookie](https://youtube-promotion.pages.dev/how-to-get-twitter-cookie)
          example: ct0=abc123... or 2c4a4e1832096aa694c739b83c83b6d96d43eba7
        username:
          type: string
          title: Username
          description: Twitter username whose tweets to delete
          example: myusername
        target_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Target Id
          description: >-
            Specific tweet ID to delete (if not provided, deletes all user
            tweets)
          example: '1234567890123456789'
      type: object
      required:
        - cookie
        - username
      title: DeleteTweetQuery
      description: Parameters for deleting tweets
    DeleteTweetResponse:
      properties:
        code:
          type: integer
          title: Code
          description: HTTP status code
          default: 200
        msg:
          type: string
          title: Msg
          description: Response message
          default: success
        data:
          items:
            type: string
          type: array
          title: Data
          description: List of deleted tweet IDs
      type: object
      required:
        - data
      title: DeleteTweetResponse
      description: Delete tweet response
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````