orchestrator
2024.10
true
UiPath logo, featuring letters U and I in white

Orchestrator API 指南

Automation CloudAutomation Cloud Public SectorAutomation SuiteStandalone
上次更新日期 2024年12月4日

警示请求

将警示标记为已读

此请求使您能够在用户有权访问的租户中将一个或多个警示标记为已读。

发布

https://{yourDomain}/odata/Alerts/UiPath.Server.Configuration.OData.MarkAsRead

请求标头

密钥

授权

承载

请求正文

{
    "ids": [
      "197ed863-037b-4d89-8271-c04e30b52240"
    ]
}{
    "ids": [
      "197ed863-037b-4d89-8271-c04e30b52240"
    ]
}

响应代码

200 OK

响应正文

{
    "value": 12
}{
    "value": 12
}
重要提示: 请求正文必须包含 UserNotificationId 作为负载 "ids" 字段的值。 要查找 UserNotificationId,请先向 /odata/Alerts 端点发出 GET 请求。
例如,调用 GET /odata/Alerts 将返回以下响应正文:
{
  "value": [
    {
      "NotificationName": "Robot.StatusChanged.Offline",
      "Data": "{\"RobotId\":123,\"RobotName\":\"user@uipath.com-unattended\",\"State\":2,\"IsUnresponsive\":false,\"OrganizationUnitId\":null,\"HostMachineName\":\"MachineName\",\"ReportingTime\":\"2021-08-20T16:48:43.76\",\"Message\":\"#robot Robot(user@uipath.com-unattended) disconnected. (#1222)\",\"MessageErrorCode\":1222,\"FolderId\":null,\"FolderFullyQualifiedName\":null,\"ForceDisplay\":false,\"Type\":\"UiPath.Orchestrator.Core.Alerts.Model.RobotStatusNotification\",\"Properties\":{}}",
      "Component": "Robots",
      "Severity": "Fatal",
      "CreationTime": "2021-08-20T16:48:50.02Z",
      "State": "Unread",
      "UserNotificationId": "197ed863-037b-4d89-8271-c04e30b52240",
      "Id": "a258f4c5-7465-40f8-a650-02228353fd4e"
    }
  ]
}{
  "value": [
    {
      "NotificationName": "Robot.StatusChanged.Offline",
      "Data": "{\"RobotId\":123,\"RobotName\":\"user@uipath.com-unattended\",\"State\":2,\"IsUnresponsive\":false,\"OrganizationUnitId\":null,\"HostMachineName\":\"MachineName\",\"ReportingTime\":\"2021-08-20T16:48:43.76\",\"Message\":\"#robot Robot(user@uipath.com-unattended) disconnected. (#1222)\",\"MessageErrorCode\":1222,\"FolderId\":null,\"FolderFullyQualifiedName\":null,\"ForceDisplay\":false,\"Type\":\"UiPath.Orchestrator.Core.Alerts.Model.RobotStatusNotification\",\"Properties\":{}}",
      "Component": "Robots",
      "Severity": "Fatal",
      "CreationTime": "2021-08-20T16:48:50.02Z",
      "State": "Unread",
      "UserNotificationId": "197ed863-037b-4d89-8271-c04e30b52240",
      "Id": "a258f4c5-7465-40f8-a650-02228353fd4e"
    }
  ]
}
"UserNotificationId" 值(即 197ed863-037b-4d89-8271-c04e30b52240)映射到 POST /odata/Alerts/UiPath.Server.Configuration.OData.MarkAsRead 端点的请求正文中的 "ids" 键。
  • 将警示标记为已读
  • 请求标头
  • 请求正文
  • 响应代码
  • 响应正文

此页面有帮助吗?

获取您需要的帮助
了解 RPA - 自动化课程
UiPath Community 论坛
Uipath Logo White
信任与安全
© 2005-2024 UiPath。保留所有权利。