# Remove tag from a ticket

`DELETE /tickets/{ticket_id}/tags/{id}`

> This is a subset of the full specification, limited to the `DELETE /tickets/{ticket_id}/tags/{id}` operation.
>
> You can find the full specification here: /_bundle/docs/references/@2.12/rest-api/api.intercom.io.yaml

```yaml
openapi: 3.0.1
info:
  title: Intercom API
  version: '2.12'
  description: This is a subset of the full specification, limited to the `DELETE /tickets/{ticket_id}/tags/{id}` operation.
  contact:
    name: Intercom Developer Hub
    url: https://developers.intercom.com
  license:
    name: MIT
    url: https://spdx.org/licenses/MIT
servers:
  - url: https://api.intercom.io
    description: The production API server
  - url: https://api.eu.intercom.io
    description: The european API server
  - url: https://api.au.intercom.io
    description: The australian API server
security:
  - bearerAuth: []
tags:
  - name: Tags
    description: Everything about tags
  - name: Tickets
    description: Everything about your tickets
paths:
  /tickets/{ticket_id}/tags/{id}:
    delete:
      summary: Remove tag from a ticket
      parameters:
        - name: Intercom-Version
          in: header
          schema:
            $ref: '#/components/schemas/intercom_version'
        - name: ticket_id
          in: path
          description: ticket_id
          example: '64619700005694'
          required: true
          schema:
            type: string
        - name: id
          in: path
          description: The unique identifier for the tag which is given by Intercom
          example: '7522907'
          required: true
          schema:
            type: string
      tags:
        - Tags
        - Tickets
      operationId: detachTagFromTicket
      description: You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket.
      responses:
        '200':
          description: successful
          content:
            application/json:
              examples:
                successful:
                  value:
                    type: tag
                    id: '45'
                    name: Manual tag
                    applied_at: 1663597223
                    applied_by:
                      type: admin
                      id: '456'
              schema:
                $ref: '#/components/schemas/tag'
        '401':
          description: Unauthorized
          content:
            application/json:
              examples:
                Unauthorized:
                  value:
                    type: error.list
                    request_id: c3f3ab0e-8c5e-48cf-9c5d-40d87a3d6bdb
                    errors:
                      - code: unauthorized
                        message: Access Token Invalid
              schema:
                $ref: '#/components/schemas/error'
        '404':
          description: Tag not found
          content:
            application/json:
              examples:
                Ticket not found:
                  value:
                    type: error.list
                    request_id: 1865bc32-8bb3-4a50-ba85-501e2273a207
                    errors:
                      - code: ticket_not_found
                        message: Ticket not found
                Tag not found:
                  value:
                    type: error.list
                    request_id: cc601e0a-58fb-411f-a85e-e3a545f988c8
                    errors:
                      - code: tag_not_found
                        message: Tag not found
              schema:
                $ref: '#/components/schemas/error'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - admin_id
              properties:
                admin_id:
                  type: string
                  description: The unique identifier for the admin which is given by Intercom.
                  example: '123'
            examples:
              successful:
                summary: successful
                value:
                  admin_id: 991266726
              ticket_not_found:
                summary: Ticket not found
                value:
                  admin_id: 991266731
              tag_not_found:
                summary: Tag not found
                value:
                  admin_id: 991266736
components:
  schemas:
    error:
      type: object
      title: Error
      description: The API will return an Error List for a failed request, which will contain one or more Error objects.
      properties:
        type:
          type: string
          description: The type is error.list
          example: error.list
        request_id:
          type: string
          nullable: true
          format: uuid
          description: ''
          example: f93ecfa8-d08a-4325-8694-89aeb89c8f85
        errors:
          type: array
          description: An array of one or more error objects
          items:
            properties:
              code:
                type: string
                description: A string indicating the kind of error, used to further qualify the HTTP response code
                example: unauthorized
              message:
                type: string
                nullable: true
                description: Optional. Human readable description of the error.
                example: Access Token Invalid
              field:
                type: string
                nullable: true
                description: Optional. Used to identify a particular field or query parameter that was in error.
                example: email
            required:
              - code
      required:
        - type
        - errors
    intercom_version:
      description: Intercom API version.</br>By default, it's equal to the version set in the app package.
      type: string
      example: '2.12'
      default: '2.12'
      enum:
        - '1.0'
        - '1.1'
        - '1.2'
        - '1.3'
        - '1.4'
        - '2.0'
        - '2.1'
        - '2.2'
        - '2.3'
        - '2.4'
        - '2.5'
        - '2.6'
        - '2.7'
        - '2.8'
        - '2.9'
        - '2.10'
        - '2.11'
        - '2.12'
        - Preview
    reference:
      title: Reference
      type: object
      description: reference to another object
      properties:
        type:
          type: string
          description: ''
          example: contact
        id:
          type: string
          nullable: true
          description: ''
          example: 1a2b3c
    tag:
      title: Tag
      type: object
      x-tags:
        - Tags
      description: A tag allows you to label your contacts, companies, and conversations and list them using that tag.
      properties:
        type:
          type: string
          description: value is "tag"
          example: tag
        id:
          type: string
          description: The id of the tag
          example: '123456'
        name:
          type: string
          description: The name of the tag
          example: Test tag
        applied_at:
          type: integer
          format: date-time
          nullable: true
          description: The time when the tag was applied to the object. Only present when the tag is returned as part of a tagging operation on a contact, conversation, or ticket.
          example: 1663597223
        applied_by:
          type: object
          nullable: true
          description: The admin who applied the tag. Only present when the tag is returned as part of a tagging operation on a contact, conversation, or ticket.
          allOf:
            - $ref: '#/components/schemas/reference'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
```
