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

# Rename a source

> Rename a source. The drive of a drag-and-drop source cannot change.



## OpenAPI

````yaml /openapi.json put /dc/sources/{source_pid}
openapi: 3.1.0
info:
  title: Cominty API
  description: >-
    The HTTP API behind the Cominty Python SDK: chat and threads, memory, MCP
    integrations, agents, skills, document sources, and documents. Send your API
    key in the x-cominty-token header.
  version: main.5359267
servers:
  - url: https://ds.cominty.com
security:
  - comintyToken: []
paths:
  /dc/sources/{source_pid}:
    put:
      tags:
        - document_stores
        - sources
      summary: Rename a source
      description: Rename a source. The drive of a drag-and-drop source cannot change.
      operationId: update_source_dc_sources__source_pid__put
      parameters:
        - name: source_pid
          in: path
          required: true
          schema:
            type: string
            title: Source Pid
          description: Public id of the source (the pid field, a string).
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SourceUpdate'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SourceOut'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    SourceUpdate:
      properties:
        name:
          type: string
          title: Name
          description: New name of the source.
        connection_id:
          type: string
          title: Connection Id
          description: Not used with a drag-and-drop source.
        config:
          additionalProperties: true
          type: object
          title: Config
          description: 'Not used with a drag-and-drop source: its drive cannot change.'
      additionalProperties: false
      type: object
      title: SourceUpdate
    SourceOut:
      properties:
        created_at:
          type: string
          format: date-time
          title: Created At
        id:
          type: integer
          title: Id
          description: Numeric id. Use it in source_ids on a capability or a scope.
        pid:
          type: string
          title: Pid
          description: Public id. Use it in every path.
        name:
          type: string
          title: Name
        scope:
          type: string
          title: Scope
        created_by:
          type: string
          title: Created By
        store:
          type: string
          title: Store
          description: >-
            draganddrop, googledrive or sharepoint. A key creates only
            draganddrop.
        status:
          type: string
          title: Status
          description: >-
            pending, syncing, synced, error, out_of_sync, cancelling, pausing,
            paused, archived, disconnected, inoperative_connection,
            expired_connection, invalid_configuration or daily_quota_reached.
        size:
          type: integer
          title: Size
        embedded_size:
          type: integer
          title: Embedded Size
        config:
          additionalProperties: true
          type: object
          title: Config
        documents_synced:
          type: integer
          title: Documents Synced
        documents_failed:
          type: integer
          title: Documents Failed
        oversized_documents:
          type: integer
          title: Oversized Documents
        documents_embedded:
          type: integer
          title: Documents Embedded
        last_synced_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Synced At
        archived_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Archived At
        connection:
          anyOf:
            - $ref: >-
                #/components/schemas/cominty__api__routers__document_stores__sources__ConnectionOut
            - type: 'null'
      additionalProperties: false
      type: object
      required:
        - created_at
        - id
        - pid
        - name
        - scope
        - created_by
        - store
        - status
        - size
        - embedded_size
        - config
        - documents_synced
        - documents_failed
        - oversized_documents
        - documents_embedded
        - last_synced_at
        - archived_at
        - connection
      title: SourceOut
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    cominty__api__routers__document_stores__sources__ConnectionOut:
      properties:
        id:
          type: string
          title: Id
        name:
          type: string
          title: Name
        status:
          type: string
          title: Status
        created_by:
          type: string
          title: Created By
        expires_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Expires At
        checked_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Checked At
        inoperative:
          type: boolean
          title: Inoperative
      additionalProperties: false
      type: object
      required:
        - id
        - name
        - status
        - created_by
        - expires_at
        - checked_at
        - inoperative
      title: ConnectionOut
    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:
    comintyToken:
      type: apiKey
      in: header
      name: x-cominty-token
      description: >-
        A Cominty Platform API secret. A key created now starts with sk-cmt-.
        Send it as is, or as Bearer sk-cmt-..., with at most one Bearer prefix.
        A key created before the prefix existed has no sk-cmt- and still works.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.