POST /api/v1/session//documentation
Uploads an API documentation file (OpenAPI/Swagger YAML or JSON) to the session. The file is automatically chunked and processed asynchronously, with each chunk stored as a separate documentation item.Path Parameters
The UUID of the session to upload documentation to
Request Body (multipart/form-data)
The documentation file to upload. Supported formats: YAML, JSON (OpenAPI/Swagger specs)
Response
Status message indicating the upload was queued
The session UUID
The UUID of the processing job created for this upload
The UUID assigned to represent this uploaded file
The number of chunks the file was split into for processing
The initial status of the upload job (always “queued”)
Example Request
Example Response
Error Responses
Session not found
Processing Details
- Chunking: The uploaded file is split into chunks based on the configured chunk size (default: 20,000 tokens)
- Async Processing: A background job processes each chunk and stores it as a DocumentationItem
- Metadata Extraction: Application name and version are extracted from the session’s discovery or scrape input
- Job Tracking: Use the returned
jobIdto monitor processing progress
Checking Upload Status
After uploading, you can check the processing status by querying the job:The upload operation returns immediately with a job ID. The actual processing happens asynchronously in the background.
Related Endpoints
- Get Documentation - Retrieve uploaded documentation
- Delete Documentation - Remove uploaded documentation
- Get Session - View session data including documentation items