2024-05-02 17:03:24 发布
网友
有没有办法通过OneNote API或其他方式获取OneNote页面中内容的时间戳?我一直在使用API获取页面的html内容和元数据,但是我没有找到获取时间戳的方法。我想得到这些,这样我就可以看到编辑历史。当您高亮显示文本并右键单击文本时,它们会显示在OneNote中,如图所示:OneNote时间戳。基本上是否有导出此信息的方法?理想情况下,这将在Python中实现,但我并不挑剔
谢谢
假设您正在查找页面的编辑历史记录,那么您最好使用Microsoft响应中的“lastModifiedDateTime”字段来获取/me/onenote/pages/{id}
以下是一个示例响应:
HTTP/1.1 200 OK Content-type: application/json Content-length: 312 { "title": "title-value", "createdByAppId": "createdByAppId-value", "links": { "oneNoteClientUrl": { "href": "href-value" }, "oneNoteWebUrl": { "href": "href-value" } }, "contentUrl": "contentUrl-value", "content": "content-value", "lastModifiedDateTime": "2016-10-19T10:37:00Z" }
您可以通过以下链接在OneNote REST API文档中找到完整的详细信息:https://docs.microsoft.com/en-us/graph/api/page-get?view=graph-rest-1.0
OneNote笔记本和分区也有“lastModifiedDateTime”
您可以使用Python解析“lastModifiedDateTime”字段的响应。有关使用Python解析API响应的指导,请参见下面两页
Selecting fields from JSON output
What's the best way to parse a JSON response from the requests library?
祝你的项目顺利完成
假设您正在查找页面的编辑历史记录,那么您最好使用Microsoft响应中的“lastModifiedDateTime”字段来获取/me/onenote/pages/{id}
以下是一个示例响应:
您可以通过以下链接在OneNote REST API文档中找到完整的详细信息:https://docs.microsoft.com/en-us/graph/api/page-get?view=graph-rest-1.0
OneNote笔记本和分区也有“lastModifiedDateTime”
您可以使用Python解析“lastModifiedDateTime”字段的响应。有关使用Python解析API响应的指导,请参见下面两页
Selecting fields from JSON output
What's the best way to parse a JSON response from the requests library?
祝你的项目顺利完成
相关问题 更多 >
编程相关推荐