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

# Start a proxy log export (Enterprise)

> Initiates a background job to export proxy logs for an app or LLM



## OpenAPI

````yaml /swagger/5.12/ai-studio-swagger.yml post /exports
openapi: 3.0.1
info:
  title: Midsommar API
  description: This is the API for the Midsommar user and group management system.
  termsOfService: http://swagger.io/terms/
  contact:
    name: API Support
    url: http://www.swagger.io/support
    email: support@swagger.io
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
  version: '1.0'
servers:
  - url: //localhost:8080/api/v1
security: []
paths:
  /exports:
    post:
      tags:
        - Exports
      summary: Start a proxy log export (Enterprise)
      description: Initiates a background job to export proxy logs for an app or LLM
      requestBody:
        description: Export request parameters
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/api.ExportRequest'
        required: true
      responses:
        '202':
          description: Accepted
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ProxyLogExportResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ErrorResponse'
        '402':
          description: Enterprise feature required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ErrorResponse'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/models.ErrorResponse'
      security:
        - BearerAuth: []
components:
  schemas:
    api.ExportRequest:
      required:
        - end_date
        - source_id
        - source_type
        - start_date
      type: object
      properties:
        end_date:
          type: string
        search:
          type: string
        source_id:
          type: integer
        source_type:
          type: string
          enum:
            - app
            - llm
            - user
        start_date:
          type: string
    models.ProxyLogExportResponse:
      type: object
      properties:
        attributes:
          $ref: '#/components/schemas/models.ProxyLogExportAttributes'
        id:
          type: string
        type:
          type: string
    models.ErrorResponse:
      type: object
      properties:
        errors:
          type: array
          items:
            type: object
            properties:
              detail:
                type: string
              title:
                type: string
    models.ProxyLogExportAttributes:
      type: object
      properties:
        completed_at:
          type: string
        end_date:
          type: string
        error_message:
          type: string
        expires_at:
          type: string
        export_id:
          type: string
        file_size:
          type: integer
        requested_at:
          type: string
        requested_by:
          type: integer
        search_filter:
          type: string
        source_id:
          type: integer
        source_type:
          $ref: '#/components/schemas/models.ExportSourceType'
        start_date:
          type: string
        status:
          $ref: '#/components/schemas/models.ExportStatus'
        total_records:
          type: integer
    models.ExportSourceType:
      type: string
      enum:
        - app
        - llm
        - user
      x-enum-varnames:
        - ExportSourceApp
        - ExportSourceLLM
        - ExportSourceUser
    models.ExportStatus:
      type: string
      enum:
        - pending
        - processing
        - completed
        - failed
        - expired
      x-enum-varnames:
        - ExportStatusPending
        - ExportStatusProcessing
        - ExportStatusCompleted
        - ExportStatusFailed
        - ExportStatusExpired
  securitySchemes:
    BearerAuth:
      type: apiKey
      name: Authorization
      in: header

````