UiPath Documentation
test-cloud
latest
false
重要 :
新发布内容的本地化可能需要 1-2 周的时间才能完成。

Test Cloud API 指南

Get Tenant Consumption Summary

As an organization admin, use this endpoint to retrieve the consumption summary for all tenants in your organization.

API 端点

POST {accessURL}/lease_/api/usage/{organizationId}/tenants/consumption-summary

将所有端点路径中的{accessURL}替换为您的云平台的基本 URL:

Cloud Platform访问 URL
Test Cloudhttps://cloud.uipath.com/
Test Cloud 公共部门版https://govcloud.uipath.us/
Test Cloud 专用版https://{customURL}.dedicated.uipath.com/

请求标头

--header 'Authorization: Bearer {access_token}'
--header 'Content-Type: application/json'
--header 'Authorization: Bearer {access_token}'
--header 'Content-Type: application/json'
备注:

要获取{access_token} ,请确保通过此处描述的 ROPC 方法进行身份验证。

路径参数

路径参数数据类型描述
organizationId (必填)字符串 (GUID)The ID of the organization for which to retrieve the consumption summary.

请求正文

The request body specifies the date range and the consumable code for which to retrieve the summary. For a detailed list of consumable codes, refer to Consumables.

{
  "startDate": 0,
  "endDate": 0,
  "consumableCode": "string"
}
{
  "startDate": 0,
  "endDate": 0,
  "consumableCode": "string"
}
备注:

startDate and endDate are Unix timestamps in milliseconds.

响应

200 OK

Returns the consumption summary across all tenants in the organization.

请求示例

调用应类似于以下示例 (cURL):

curl --location --request POST 'https://cloud.uipath.com/lease_/api/usage/11111111-1111-1111-1111-111111111111/tenants/consumption-summary' \
--header 'Authorization: Bearer 1234' \
--header 'Content-Type: application/json' \
--data-raw '{
  "startDate": 1704067200000,
  "endDate": 1706745600000,
  "consumableCode": "consumption_unit_code"
}'
curl --location --request POST 'https://cloud.uipath.com/lease_/api/usage/11111111-1111-1111-1111-111111111111/tenants/consumption-summary' \
--header 'Authorization: Bearer 1234' \
--header 'Content-Type: application/json' \
--data-raw '{
  "startDate": 1704067200000,
  "endDate": 1706745600000,
  "consumableCode": "consumption_unit_code"
}'

Here's the response body for a successful consumption summary retrieval:

{
  "consumedFromOrgWithoutTenant": 0,
  "tenantConsumptionItems": [
    {
      "tenantId": "string",
      "consumedFromTenantPool": 0,
      "consumedFromOrgPool": 0
    }
  ]
}
{
  "consumedFromOrgWithoutTenant": 0,
  "tenantConsumptionItems": [
    {
      "tenantId": "string",
      "consumedFromTenantPool": 0,
      "consumedFromOrgPool": 0
    }
  ]
}
  • API 端点
  • 请求标头
  • 路径参数
  • 请求正文
  • 响应
  • 200 OK
  • 请求示例

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新