Forward user info headers to Mistral OCR API (#27253)

Mirrors the ENABLE_FORWARD_USER_INFO_HEADERS pattern already used by
the audio/TTS and external document loader integrations, so the
Mistral OCR backend can identify the requesting user the same way.

Co-authored-by: andrep <vpham@aut.ac.nz>
This commit is contained in:
andrep2222andandrep authored and GitHub committed 2026-07-23 12:33:19 -05:00
1 parent 49abfbdd15
commit 66bf96c62d
2 files changed
+10 -2

No files matched your search

@@ -554,6 +554,7 @@ class Loader:
api_key=self.kwargs.get('MISTRAL_OCR_API_KEY'),
file_path=file_path,
use_base64=self.kwargs.get('MISTRAL_OCR_USE_BASE64', False),
user=self.user,
)
elif self.engine == 'paddleocr_vl' and self.kwargs.get('PADDLEOCR_VL_TOKEN') != '':
loader = PaddleOCRVLLoader(