confluence - How to parse rest api code from confluence page
问题描述
how can i parse fields ( task id,task status, task body) from rest api which is on confluence page
I am trying to parse the rest api from confluence page to get Task ID,Task Status, and body fields from the api code. I am open for python,alteryx or sas or any option to parse this file. we have few other rest api's which need to be parsed. so looking for automate process. please recommend a solution.
```{"id":"33469","type":"page","status":"current","title":"Huddle Tracker","body":{"storage":{"value":"<ac:task-list>\n<ac:task>\n<ac:task-id>4</ac:task-id>\n<ac:task-status>incomplete</ac:task-status>\n<ac:task-body><span><ac:link><ri:user ri:userkey=\"123456789abc\" /></ac:link> - 6/13</span></ac:task-body>\n</ac:task>\n<ac:task>\n<ac:task-id>5</ac:task-id>\n<ac:task-status>incomplete</ac:task-status>\n<ac:task-body><p><span><ac:link><ri:user ri:userkey=\"123456789abc\" /></ac:link> - 6</span>/14</p></ac:task-body>\n</ac:task>\n<ac:task>\n<ac:task-id>6</ac:task-id>\n<ac:task-status>incomplete</ac:task-status>\n<ac:task-body><span><ac:link><ri:user ri:userkey=\"123456789abc\" /></ac:link> - 6/15<br /></span></ac:task-body>\n</ac:task>\n<ac:task>\n<ac:task-id>7</ac:task-id>\n<ac:task-status>incomplete</ac:task-status>\n<ac:task-body><span><ac:link><ri:user ri:userkey=\"123456789abc\" /></ac:link> - 6/16<br /></span></ac:task-body>\n</ac:task>\n</ac:task-list><p><span><br /></span></p><p><span><br /></span></p><p><br /></p>","representation":"storage","_expandable":{"content":"/rest/api/content/33469"}},"_expandable":{"editor":"","view":"","export_view":"","styled_view":"","anonymous_export_view":""}},"extensions":{"position":"none"},"_links":{"webui":"/display/abcd01d/Huddle+Tracker","edit":"/pages/resumedraft.action?draftId=33469","tinyui":"/x/Rw-zEw","collection":"/rest/api/content","base":"https://confluence:9999","context":"","self":"https://confluence:9999/rest/api/content/33469"},"_expandable":{"container":"/rest/api/space/abcd01d","metadata":"","operations":"","children":"/rest/api/content/33469/child","restrictions":"/rest/api/content/33469/restriction/byOperation","history":"/rest/api/content/33469/history","ancestors":"","version":"","descendants":"/rest/api/content/33469/descendant","space":"/rest/api/space/abcd01d"}}
i need Task ID, Task Status and Task Body parsed.
解决方案
在寻找可用的工具之后,我决定使用 RPA 来抓取内容并解析它。我发现的另一个选择是使用 python 包来抓取数据。
推荐阅读
- javascript - 将 GooglePay 与 React 集成
- php - 在 PHP 中提取 URL 的特定点
- python - 创建 N 个长度为 M 的数组,其中序列在每个数组上增加 1
- amazon-web-services - CloudFront:分发版只能在欧洲访问
- c# - C# Windows 窗体 - 锚点
- data-binding - Aurelia 更改自己的属性不会调用更改的侦听器
- authentication - 创建 EKS 集群时是否会自动部署 Heptio Authenticator?
- ruby-on-rails - Rails 从深度关联中获取计数
- microservices - 如何在 Istio 中记录请求和响应正文
- java - 提供给 orElse() 的方法不完全执行