Result of a single file download operation.
The response is designed to allow partial success in batch operations.
The errors are standardized using FileOperationError literals for certain
recoverable conditions for use cases that involve LLMs performing
file operations.
FileDownloadResponse(
self,
path: str,
content: bytes | None = None,
error: FileOperationError | None = None
)| Name | Type |
|---|---|
| path | str |
| content | bytes | None |
| error | FileOperationError | None |
The file path that was requested. Included for easy correlation when processing batch results, especially useful for error messages.
File contents as bytes on success, None on failure.
A FileOperationError literal for known conditions, or a
backend-specific error string when the failure cannot be normalized.
None on success.