---
updatedAt: 2026-04-21T09:18:29.000Z
agentTools:
  projectIndex: https://docs.esputnik.com/llms.txt
---

# Upload file for preprocessor

The method is used for uploading a file for the preprocessor from an external repository.

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "esputnik.com",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://esputnik.com"
    }
  ],
  "security": [
    {
      "basicAuth": []
    }
  ],
  "tags": [
    {
      "name": "Messages"
    }
  ],
  "paths": {
    "/api/v1/preprocessor/file/upload": {
      "post": {
        "tags": [
          "Messages"
        ],
        "summary": "Upload file for preprocessor",
        "description": "The method is used for uploading a file for the preprocessor from an external repository.",
        "operationId": "uploadPreprocessorFile",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PreProcessorDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json; charset=UTF-8": {
                "schema": {
                  "$ref": "#/components/schemas/FileValidationResult"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "FileValidationResult": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          },
          "importId": {
            "type": "string",
            "xml": {
              "name": "asyncSessionId"
            }
          },
          "fileId": {
            "type": "string"
          },
          "valid": {
            "type": "boolean"
          }
        },
        "xml": {
          "name": "fileValidationResult"
        }
      },
      "PreProcessorDto": {
        "required": [
          "link",
          "preprocessorType"
        ],
        "type": "object",
        "properties": {
          "link": {
            "type": "string",
            "description": "The link to the PreProcessor data file in an external repository.",
            "example": "http://example.com/file.json"
          },
          "preprocessorType": {
            "type": "string",
            "description": "PreProcessor data type [Random, Key].",
            "example": "Key"
          },
          "ttlHours": {
            "type": "integer",
            "description": "File time to live in the system in hours. The default value is 1 month.",
            "format": "int32",
            "example": 240
          }
        }
      }
    },
    "securitySchemes": {
      "basicAuth": {
        "type": "http",
        "scheme": "basic"
      }
    }
  }
}
```