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

# Unlink text items from a component

> Unlinks one or more text items from their library component by developer ID.

Each unlinked text item keeps its current text but gets a freshly generated developer ID, and future edits to the library component no longer affect it. Every text item linked to a component shares that component's developer ID with its sibling instances, so a given developer ID unlinks every text item that currently carries it, not just one. Pass `projectId` to scope the unlink to only the instances in one project, leaving instances elsewhere untouched.



## OpenAPI

````yaml openapi.json patch /components/unlink
openapi: 3.0.0
info:
  version: 1.0.0
  title: Ditto API
  description: Programmatically read and write data in your Ditto workspace.
servers:
  - url: https://api.dittowords.com/v2
security: []
paths:
  /components/unlink:
    patch:
      tags:
        - Components
      summary: Unlink text items from a component
      description: >-
        Unlinks one or more text items from their library component by developer
        ID.


        Each unlinked text item keeps its current text but gets a freshly
        generated developer ID, and future edits to the library component no
        longer affect it. Every text item linked to a component shares that
        component's developer ID with its sibling instances, so a given
        developer ID unlinks every text item that currently carries it, not just
        one. Pass `projectId` to scope the unlink to only the instances in one
        project, leaving instances elsewhere untouched.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                textItemIds:
                  type: array
                  items:
                    type: string
                  minItems: 1
                  description: >-
                    Developer IDs of the text items to unlink from their library
                    component. Each must currently be a library instance. Every
                    text item linked to a component shares that component's
                    developer ID with its sibling instances, so a given
                    developer ID unlinks every text item that currently carries
                    it, not just one — scope this with projectId to affect only
                    the instances in one project.
                projectId:
                  type: string
                  description: >-
                    Developer ID of the project to scope the unlink to. If
                    provided, only instances of the given developer IDs within
                    this project are unlinked; instances in other projects are
                    left untouched. If omitted, every instance of each given
                    developer ID is unlinked, regardless of project.
              required:
                - textItemIds
              example:
                textItemIds:
                  - text-item-id-1
                  - text-item-id-2
            examples:
              unlink_all_instances:
                summary: Unlink every instance of a developer ID
                value:
                  textItemIds:
                    - text-item-id-1
              unlink_scoped_to_project:
                summary: Unlink only the instances in one project
                description: >-
                  Only instances of the given developer IDs within this project
                  are unlinked; instances elsewhere are left untouched.
                value:
                  textItemIds:
                    - text-item-id-1
                  projectId: my-project-id
      responses:
        '200':
          description: >-
            Returns success status of the unlink operation and the number of
            text items actually unlinked
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    description: Indicates whether the unlink operation was successful
                  unlinkedCount:
                    type: number
                    description: >-
                      The number of text items actually unlinked. This can
                      exceed the number of developer IDs given, since every
                      instance sharing a given developer ID is unlinked.
                required:
                  - success
                  - unlinkedCount
                example:
                  success: true
                  unlinkedCount: 1
        '400':
          description: >-
            Returned when a text item developer ID does not match any existing
            text item in scope (or, if projectId was given, no instance of it
            exists in that project), or the text item is not linked to a library
            component
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Error message describing the validation failure
                required:
                  - message
              example:
                message: >-
                  Text items are not linked to a library component:
                  text-item-id-1
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization

````