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

# Upload incidents

> Send engineering, devops, or statuspage incidents for AI training via this endpoint



## OpenAPI

````yaml /api-reference/openapi.json post /v1/incidents
openapi: 3.0.3
info:
  title: IrisAgent's API Reference
  description: >
    IrisAgent service can be used as an API to power intelligent conversations
    and search, index, and connect with your internal and external knowledge
    articles, tickets, community forums, product documentation,

    and other informational content.
  version: 1.2.0
servers:
  - url: https://api1.irisagent.com
security:
  - bearerAuth: []
paths:
  /v1/incidents:
    post:
      summary: Upload incidents
      description: >-
        Send engineering, devops, or statuspage incidents for AI training via
        this endpoint
      operationId: uploadIncidents
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/IncidentUploadRequest'
      responses:
        '201':
          description: Incident has been uploaded successfully
        '400':
          description: Bad request - invalid input
        '401':
          description: Unauthorized - invalid credentials
        '403':
          description: Forbidden - insufficient permissions
components:
  schemas:
    IncidentUploadRequest:
      type: object
      properties:
        incident:
          $ref: '#/components/schemas/Incident'
        components:
          items:
            $ref: '#/components/schemas/IncidentComponents'
          type: array
        updates:
          type: array
          items:
            $ref: '#/components/schemas/IncidentUpdate'
        postmortem:
          $ref: '#/components/schemas/IncidentPostmortem'
      required:
        - incident
        - components
        - updates
    Incident:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        status:
          type: string
        started_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        shortlink:
          type: string
      required:
        - id
        - name
        - status
        - shortlink
        - started_at
        - updated_at
    IncidentComponents:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        status:
          type: string
        last_updated_at:
          type: string
          format: date-time
      required:
        - id
        - name
        - status
        - last_updated_at
    IncidentUpdate:
      type: object
      properties:
        impact:
          type: string
        status:
          type: string
        body:
          type: string
        created_at:
          type: string
          format: date-time
        affected_components:
          type: array
          items:
            $ref: '#/components/schemas/AffectedComponent'
      required:
        - impact
        - status
        - body
        - created_at
    IncidentPostmortem:
      type: object
    AffectedComponent:
      type: object
      properties:
        name:
          type: string
        old_status:
          type: string
        new_status:
          type: string
      required:
        - name
        - old_status
        - new_status
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: |
        The `Authorization` header is required to authenticate API requests.
        It should contain a bearer token obtained through the IrisAgent portal.

````