site | string or SelectItem | No | - | SharePoint site the document library belongs to, or ‘me’ for the user’s own OneDrive. |
drive | string or SelectItem | No | - | Document library (drive) to search in. Not needed when folder_path is a full SharePoint link. |
folder_path | string | No | - | Restrict the search to a folder: a path inside the library, e.g. ‘Creative Ads/Q4’, or a full SharePoint folder link. Leave empty to search the whole library. |
query | string | Yes | - | Search text. Matches file and folder names, plus file content where the tenant’s search index supports it, e.g. ‘banner’ or ‘q4 report’. |
max_results | integer | No | 25 | Maximum number of results to return. Defaults to 25. |