Claude Platform Docs

列出工作區速率限制

organization.workspaces.rate_limits.list(workspace_id, **kwargs) -> PageCursor<WorkspaceRateLimit>
GET/v1/organizations/workspaces/{workspace_id}/rate_limits

列出工作區的速率限制。

預設情況下,僅傳回具有工作區層級覆寫的群組與限制器類型。設定 include_inherited=true 時,會傳回工作區可見且具有組織層級限制的每個群組,並針對每個群組列出其從組織繼承的值以及其自身的覆寫值。每個值的 source 會指出其屬於哪一種。

省略 limit 時,所有符合的項目會在單一頁面中傳回;當 limit 截斷結果時,請依循 next_page 擷取其餘項目。

Parameters
workspace_id: String⁠Path parameter

The ID of the workspace.

group_type: :batch | :files | :model_group | 3 more⁠Query parameter

Filter by group type.

One of the following:
:batch
:files
:model_group
:skills
:token_count
:web_search
include_inherited: bool⁠Query parameter

Also list the limiter values the workspace inherits from the organization, including groups with no workspace-level override.

limit: Integer⁠Query parameter

Maximum number of items to return per page. Ranges from 1 to 1000.

When omitted, every remaining entry is returned in a single page and next_page is null.

minimum1
maximum1000
page: String⁠Query parameter

Opaque cursor from a previous response's next_page.

Returns
class WorkspaceRateLimit { type: :workspace_rate_limit, group, limits, 3 more }
列出工作區速率限制
require "anthropic"

anthropic = Anthropic::Client.new(api_key: "my-anthropic-api-key")

page = anthropic.organization.workspaces.rate_limits.list("workspace_id")

puts(page)
Returns Examples
Response 200
{
  "data": [
    {
      "group": {
        "id": "id",
        "display_name": "display_name",
        "type": "model_group"
      },
      "group_type": "batch",
      "limits": [
        {
          "org_limit": 0,
          "source": {
            "type": "workspace"
          },
          "type": "type",
          "value": 0
        }
      ],
      "models": [
        "string"
      ],
      "rate_limit_id": "rate_limit_id",
      "type": "workspace_rate_limit",
      "workspace_id": "workspace_id"
    }
  ],
  "next_page": "next_page"
}