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

# Create Skill

> Create a skill



## OpenAPI

````yaml https://document-assistant.us.aodocs.app/openapi.json post /assistant/api/v1/tenants/{tenant}/skills
openapi: 3.1.0
info:
  title: Document Assistant API
  description: |
    <p>
      The Document Assistant API enables developers to integrate document-based assistant
      functionalities into their applications using AODocs.
    </p>
    <p>
      The first step is to enable AIDA (AODocs Intelligent Document Assistant) in your tenant.
      The support team will provide you with the necessary information on how to get started.
    </p>
    <p>
      The second step is to enable AIDA on libraries. You need to be an administrator of the
      library to do this.<br />
      AIDA can answer questions only from those documents that are in an AIDA enabled
      library.<br />
      We create a vector store index for these documents. This can take some time. The get
      library API provides the status of the indexation and an estimate of the time
      remaining.<br />
      The content of the index is automatically kept up-to-date near real time with the
      content changes.
    </p>
    <p>
      The third step is to ask questions based on the AODocs documents.<br />
      AIDA automatically filters the results based on the user's permissions.
    </p>
    <p>
      <strong>Authentication:</strong> All API endpoints require a valid OAuth2 token in the
      Authorization header. Ensure the client ID of the OAuth2 token is whitelisted in AODocs.
    </p>
  version: 1.1.0
servers:
  - url: https://document-assistant.us.aodocs.app
    description: Production US
  - url: https://document-assistant.eu.aodocs.app
    description: Production EU
security: []
paths:
  /assistant/api/v1/tenants/{tenant}/skills:
    post:
      tags:
        - skill
      summary: Create Skill
      description: Create a skill
      operationId: create_skill_assistant_api_v1_tenants__tenant__skills_post
      parameters:
        - name: tenant
          in: path
          required: true
          schema:
            type: string
            description: The domain of the customer
            examples:
              - example.com
            title: Tenant
          description: The domain of the customer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Skill'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Skill'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    Skill:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: The id of the skill
        name:
          type: string
          title: Name
          description: The name of the skill
        type:
          $ref: '#/components/schemas/SkillType'
          description: >-
            What kind of work this skill does. A 'datasource' skill answers from
            data it looks up, so its answers are checked against the tool
            results behind them and cite those results. An 'action' skill
            performs something in another system and its answer is not checked.
          default: action
        classification:
          $ref: '#/components/schemas/SkillClassificationDTO'
          description: >-
            Structured classification configuration for routing requests to this
            skill
        prompt:
          type: string
          title: Prompt
          description: System prompt used when this skill handles a request
        mcp_servers:
          items:
            $ref: '#/components/schemas/McpServerConfigDTO'
          type: array
          title: Mcp Servers
          description: MCP server connections for this skill's tools
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          description: The date when the skill was created
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
          description: The date when the skill was last updated
      type: object
      required:
        - name
        - classification
        - prompt
      title: Skill
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    SkillType:
      type: string
      enum:
        - datasource
        - action
      title: SkillType
      description: >-
        What kind of work a skill does, which decides whether its answer is
        checked.


        A ``DATASOURCE`` skill answers questions from data it looks up, so its
        answer must

        name the tool results supporting it and is validated against them. An
        ``ACTION``

        skill performs something in another system and reports the outcome, so
        there is no

        data to validate it against and checking it would only manufacture
        failures.
    SkillClassificationDTO:
      properties:
        description:
          type: string
          title: Description
          description: What this skill does (used in classifier prompt)
        example_queries:
          items:
            type: string
          type: array
          maxItems: 10
          minItems: 1
          title: Example Queries
          description: >-
            Example user messages that should route to this skill (3-5
            recommended)
        negative_examples:
          anyOf:
            - items:
                type: string
              type: array
              maxItems: 10
            - type: 'null'
          title: Negative Examples
          description: Example user messages that should NOT route to this skill
        keywords:
          anyOf:
            - items:
                type: string
              type: array
              maxItems: 20
            - type: 'null'
          title: Keywords
          description: Trigger words/phrases for quick matching
      type: object
      required:
        - description
        - example_queries
      title: SkillClassificationDTO
    McpServerConfigDTO:
      properties:
        name:
          type: string
          title: Name
          description: Human-readable name for this MCP server
        url:
          type: string
          title: Url
          description: MCP server endpoint URL (streamable-HTTP)
        secret_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Secret Id
          description: Secret Manager reference for bearer token authentication
      type: object
      required:
        - name
        - url
      title: McpServerConfigDTO
    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:
    HTTPBearer:
      type: http
      scheme: bearer

````