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

# Retirer une branche de l’indexation

## Autorisations

Nécessite un [utilisateur de service](https://docs.devin.ai/fr/api-reference/v3/service-users/members-service-users.md) ou un [jeton d’accès personnel](https://docs.devin.ai/fr/api-reference/personal-access-tokens.md) disposant de l’autorisation `IndexOrgRepositories` au niveau de l’organisation.

## Comportement

Retire une branche spécifique de l’indexation pour le dépôt spécifié. S’il ne reste plus aucune branche après sa suppression, l’indexation est automatiquement désactivée pour le dépôt.

Renvoie une erreur 404 si la branche n’est pas configurée pour l’indexation.


## OpenAPI

````yaml fr/v3-openapi.yaml DELETE /v3/organizations/{org_id}/repositories/{repository_path}/indexing/branches/{branch_name}
openapi: 3.1.0
info:
  description: API Devin v3 avec authentification par compte de service et RBAC
  title: Devin API v3
  version: 3.0.0
servers: []
security:
  - bearerAuth: []
paths:
  /v3/organizations/{org_id}/repositories/{repository_path}/indexing/branches/{branch_name}:
    delete:
      tags:
        - repositories
      summary: Retirer une branche de l’indexation
      operationId: >-
        handle_remove_branch_v3_organizations__org_id__repositories__repository_path__indexing_branches__branch_name__delete
      parameters:
        - in: path
          name: repository_path
          required: true
          schema:
            title: Repository Path
            type: string
        - in: path
          name: branch_name
          required: true
          schema:
            title: Branch Name
            type: string
        - description: "Identifiant d’organisation (préfixe\_: org-)"
          in: path
          name: org_id
          required: true
          schema:
            example: org-abc123def456
            title: Org Id
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RepositoryIndexingResponse'
          description: Réponse réussie
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Non autorisé
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Accès interdit
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Introuvable
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Conflit
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Contenu impossible à traiter
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Trop de requêtes
components:
  schemas:
    RepositoryIndexingResponse:
      properties:
        branches:
          items:
            type: string
          title: Branches
          type: array
        indexing_enabled:
          title: Indexing Enabled
          type: boolean
        indexing_status:
          anyOf:
            - $ref: '#/components/schemas/RepoIndexingStatusResponse'
            - type: 'null'
        repository_path:
          title: Repository Path
          type: string
      required:
        - repository_path
        - indexing_enabled
        - branches
      title: RepositoryIndexingResponse
      type: object
    ProblemDetail:
      description: "Corps d’erreur RFC 9457 application/problem+json pour l’API v3.\n\ndetail est conservé de l’ancien corps {\"detail\": ...} pour assurer la rétrocompatibilité\_; les\nautres membres sont ajoutés de manière additive. errors contient les échecs de validation\nau niveau des champs (422 uniquement)."
      properties:
        detail:
          anyOf:
            - type: string
            - type: 'null'
          description: Explication en langage clair, spécifique à cette occurrence.
          title: Detail
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Code exploitable par machine indiquant le refus d’une action bloquée
            (p. ex. "user_frozen", "migrated_session").
          title: Error Code
        errors:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          description: Erreurs de validation par champ (réponses 422 uniquement).
          title: Errors
        instance:
          anyOf:
            - type: string
            - type: 'null'
          description: Une référence d’URI (le chemin de la requête) pour cette occurrence.
          title: Instance
        status:
          description: Le code d’état HTTP.
          title: Status
          type: integer
        title:
          description: Un bref résumé du type de problème, compréhensible par un humain.
          title: Title
          type: string
        type:
          default: about:blank
          description: Une référence d’URI identifiant le type de problème.
          title: Type
          type: string
      required:
        - title
        - status
      title: ProblemDetail
      type: object
    RepoIndexingStatusResponse:
      properties:
        indexing_enabled:
          title: Indexing Enabled
          type: boolean
        latest_completed_search_index_job:
          anyOf:
            - $ref: '#/components/schemas/RepoIndexJobResponse'
            - type: 'null'
        latest_completed_wiki_index_job:
          anyOf:
            - $ref: '#/components/schemas/RepoIndexJobResponse'
            - type: 'null'
        latest_indexes:
          items:
            $ref: '#/components/schemas/RepoIndexJobResponse'
          title: Latest Indexes
          type: array
      required:
        - indexing_enabled
        - latest_indexes
        - latest_completed_search_index_job
        - latest_completed_wiki_index_job
      title: RepoIndexingStatusResponse
      type: object
    RepoIndexJobResponse:
      properties:
        branch_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Branch Name
        commit:
          title: Commit
          type: string
        created_at:
          title: Created At
          type: integer
        job_id:
          title: Job Id
          type: string
        status:
          enum:
            - failed
            - completed
            - in_progress
          title: Status
          type: string
      required:
        - job_id
        - status
        - commit
        - branch_name
        - created_at
      title: RepoIndexJobResponse
      type: object
  securitySchemes:
    bearerAuth:
      description: "Identifiant de compte de service (préfixe\_: cog_)"
      scheme: bearer
      type: http

````

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