I’m trying to use SharepointLoader within Databricks. Is there anyway we can pass the customPath for the authentication token.
I tried below, but not working
from pathlib import Path
custom_token_path = Path(“/DJ/o365_token.txt”)
loader = SharePointLoader(document_library_id=“18924”, token_path = custom_token_path, auth_with_token=True)
documents = loader.load()
print(documents)
Error:
ValidationError: 1 validation error for _O365TokenStorage
token_path
Path does not point to a file [type=path_not_file, input_value=PosixPath(‘/home/spark-11…entials/o365_token.txt’), input_type=PosixPath]