openapi: 3.0.3
info:
  title: TIIX KPI API
  version: 1.0.0
  description: Consulta consolidada de indicadores para o admin tecnico.
  license:
    name: Uso interno
    url: https://dash.tiix.com.br/adm/api-docs
servers:
  - url: /adm/api
components:
  securitySchemes:
    cookieAuth:
      type: apiKey
      in: cookie
      name: wordpress_logged_in
security:
  - cookieAuth: []
paths:
  /Kpi/overview:
    get:
      operationId: Kpi.overview
      summary: Visao geral dos cards do periodo
      parameters:
        - in: query
          name: id_contrato
          schema:
            type: integer
        - in: query
          name: de
          schema:
            type: string
            format: date
        - in: query
          name: ate
          schema:
            type: string
            format: date
      responses:
        '200':
          description: OK
        '400':
          description: Requisicao invalida
  /Kpi/agenda:
    get:
      operationId: Kpi.agenda
      summary: Indicadores de agenda, utilizacao e SLA
      parameters:
        - in: query
          name: id_contrato
          schema:
            type: integer
        - in: query
          name: de
          schema:
            type: string
            format: date
        - in: query
          name: ate
          schema:
            type: string
            format: date
      responses:
        '200':
          description: OK
        '400':
          description: Requisicao invalida
  /Kpi/exportCsv:
    get:
      operationId: Kpi.exportCsv
      summary: Exporta os KPIs consolidados em CSV
      parameters:
        - in: query
          name: id_contrato
          schema:
            type: integer
        - in: query
          name: de
          schema:
            type: string
            format: date
        - in: query
          name: ate
          schema:
            type: string
            format: date
      responses:
        '200':
          description: OK
        '400':
          description: Requisicao invalida