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

# Crear un blueprint de nivel org o repo

> Crea un blueprint. ``type`` se infiere a partir de ``repo_name``.

Según la especificación, esto nunca activa automáticamente una compilación; quien llama debe
hacer ``POST /builds`` explícitamente.

<div id="permissions">
  ## Permisos
</div>

Se requiere un usuario de servicio con el permiso `ManageRepoBlueprints` a nivel de organización. La creación de blueprints de nivel de organización requiere el permiso `ManageOrgSnapshots`.

<div id="behavior">
  ## Comportamiento
</div>

Crea un blueprint de nivel de organización o de repo. Un blueprint define la configuración declarativa de Environment para las sesiones de Devin. Modificar un blueprint no activa automáticamente una compilación; debes llamar explícitamente al endpoint de compilaciones.


## OpenAPI

````yaml es/v3-openapi.yaml POST /v3beta1/organizations/{org_id}/snapshot-setup/blueprints
openapi: 3.1.0
info:
  description: API de Devin v3 con autenticación mediante usuario de servicio y RBAC
  title: Devin API v3
  version: 3.0.0
servers: []
security:
  - bearerAuth: []
paths:
  /v3beta1/organizations/{org_id}/snapshot-setup/blueprints:
    post:
      tags:
        - snapshot_setup
      summary: Crear un blueprint de nivel org o repo
      description: >-
        Crea un blueprint. ``type`` se infiere a partir de ``repo_name``.


        Según la especificación, esto nunca activa automáticamente una
        compilación; quien llama debe

        hacer ``POST /builds`` explícitamente.
      operationId: >-
        create_org_blueprint_v3beta1_organizations__org_id__snapshot_setup_blueprints_post
      parameters:
        - description: 'ID de la organización (prefijo: org-)'
          in: path
          name: org_id
          required: true
          schema:
            example: org-abc123def456
            title: Org Id
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateOrgBlueprintBody'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Blueprint'
          description: Respuesta satisfactoria
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Error de validación
components:
  schemas:
    CreateOrgBlueprintBody:
      properties:
        contents:
          anyOf:
            - type: string
            - type: 'null'
          description: Cuerpo YAML inicial opcional para el blueprint.
          title: Contents
        repo_name:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Si se establece, crea un blueprint de nivel de repo para ese
            repositorio. Si se omite, crea un blueprint para toda la
            organización (nivel de organización).
          title: Repo Name
      title: CreateOrgBlueprintBody
      type: object
    Blueprint:
      description: >-
        Esquema público del recurso ``Blueprint``.


        Nota: el enum ``type`` puede ampliarse en el futuro; los clientes DEBEN
        manejar correctamente

        los valores desconocidos. El contenido YAML se obtiene por separado
        mediante

        ``GET /blueprints/{id}/contents``.
      properties:
        blueprint_id:
          title: Blueprint Id
          type: string
        created_at:
          title: Created At
          type: integer
        repo_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Repo Name
        type:
          enum:
            - enterprise
            - org
            - repo
          title: Type
          type: string
        updated_at:
          title: Updated At
          type: integer
      required:
        - blueprint_id
        - type
        - repo_name
        - created_at
        - updated_at
      title: Blueprint
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    bearerAuth:
      description: 'Credencial de usuario de servicio (prefijo: cog_)'
      scheme: bearer
      type: http

````