search with onedrive graph api

This commit is contained in:
spencerwooo
2022-01-21 21:42:21 +08:00
parent 038b4288cb
commit 1b658b6a98
4 changed files with 117 additions and 32 deletions
+31
View File
@@ -13,3 +13,34 @@ export type OdFileObject = {
}
}
}
export type OdFolderObject = {
'@odata.count': number
value: Array<{
id: string
name: string
lastModifiedDateTime: string
size: number
folder: {
childCount: number
view: {
sortBy: 'name'
sortOrder: 'ascending'
viewType: 'thumbnails'
}
}
}>
}
export type OdSearchResult = Array<{
id: string
name: string
file?: OdFileObject
folder?: OdFolderObject
path: string
parentReference: {
id: string
name: string
path: string
}
}>