枚举活动(预览)
列出在某个项上或某个层次结构下发生的最近活动。
注意:活动处于限定预览阶段,尚未对所有租户可用。
权限
调用此 API 需要以下权限之一。 若要了解详细信息,包括如何选择权限的信息,请参阅权限。
权限类型 | 权限(从最低特权到最高特权) |
---|---|
委派(工作或学校帐户) | Files.Read、Files.ReadWrite、Files.Read.All、Files.ReadWrite.All、Sites.Read.All、Sites.ReadWrite.All |
委派(个人 Microsoft 帐户) | 不支持。 |
应用程序 | Files.Read.All、Files.ReadWrite.All、Sites.Read.All、Sites.ReadWrite.All |
HTTP 请求
GET /drives/{drive-id}/activities
GET /drives/{drive-id}/items/{item-id}/activities
GET /sites/{site-id}/lists/{list-id}/activities
GET /sites/{site-id}/lists/{list-id}/items/{item-id}/activities
示例
请求
GET /me/drive/activities
响应
HTTP/1.1 200 OK
Content-type: application/json
{
"value": [
{
"action": {
"comment": {}
},
"actor": {
"user": {
"displayName": "Xavier Wilke"
}
},
"id": "EJalEvjV1EgIYFQAAAAAAA==",
"times": {
"recordedDateTime": "2017-07-29T18:34:40Z"
}
},
{
"action": {
"edit": {},
"version": {
"newVersion": "2.0"
}
},
"actor": {
"user": {
"displayName": "Judith Clemons"
}
},
"id": "cInT6/fV1EgFYFQAAAAAAA==",
"times": {
"recordedDateTime": "2017-07-29T16:23:35Z"
}
},
{
"action": {
"mention": {
"mentionees": [
{
"user": {
"displayName": "Judith Clemons"
}
}
]
}
},
"actor": {
"user": {
"displayName": "Misty Suarez"
}
},
"id": "EBJa0vPV1EjFX1QAAAAAAA==",
"times": {
"recordedDateTime": "2017-07-28T20:14:14Z"
}
},
{
"action": {
"rename": {
"oldName": "Document2.docx"
}
},
"actor": {
"user": {
"displayName": "Misty Suarez"
}
},
"id": "QFJFlfPV1Ei/X1QAAAAAAA==",
"times": {
"recordedDateTime": "2017-07-28T20:12:32Z"
}
},
{
"action": {
"create": {}
},
"actor": {
"user": {
"displayName": "Misty Suarez"
}
},
"id": "IJydkPPV1Ei9X1QAAAAAAA==",
"times": {
"recordedDateTime": "2017-07-28T20:02:24Z"
}
}
]
}