Claude Platform Docs

更新插件

client.Beta.Organization.Plugins.Update(ctx, pluginID, params) (*BetaPlugin, error)
POST/v1/organizations/plugins/{plugin_id}

更改向成员提供的组织所有插件的已存储版本,例如回滚到较早的版本。此操作会固定所提供的版本:之后上传的版本仍会被存储,但不再改变所提供的内容,并且固定目前无法撤销,无论是在此处还是在 claude.ai 中。

将版本作为 served_version_id 传入:传入较早的版本以回滚;传入较晚的版本以开始提供一个已存储但尚未提供的版本;或传入当前已提供的版本,以在不改变所提供内容的情况下将其固定。此操作不会创建新版本。

当组织启用了内容扫描时,扫描仍在进行中的版本会被拒绝并返回 409(error_code 为 scan_pending;请在扫描完成后重试);扫描失败、出错或未得出结论的版本会被拒绝并返回 400(scan_failed;warn 结果可被接受)。当插件位于组织的库市场中时,如果某个非当前提供版本中的某个技能名称此后已被组织技能(管理员在 claude.ai 中为整个组织上传的技能)占用,该版本也会被拒绝并返回 409:error_code 为 skill_name_taken,该名称位于 details.skill_name 中。成员所有的插件无法在此处更新(403)。

此端点不写入安装设置;安装设置通过 /v1/organizations/plugins/{plugin_id}/installation_settings/{target} 写入。

接受的凭据:具有 write:plugins 作用域的 Admin API 密钥。

每个请求都必须包含 beta 标头 anthropic-beta: ce-plugins-2026-09-01。缺少该标头的请求将返回 404,与端点不存在时完全相同。Plugins API 目前处于 beta 阶段,仅适用于 Claude Enterprise 组织。Claude Platform(Claude Console)组织以及启用了 HIPAA 就绪功能的组织无法使用。

Parameters
pluginID string⁠Path parameter

ID of the Plugin (prefixed plugin_).

params BetaOrganizationPluginUpdateParams
ServedVersionID string

Serve this version of the Plugin (prefixed pluginver_) and pin the served version to it; latest is not accepted.

Betas []AnthropicBeta OptionalHeader parameter

This endpoint is in beta: requests must send ce-plugins-2026-09-01 in this header.

const AnthropicBetaMessageBatches2024_09_24 AnthropicBeta = "message-batches-2024-09-24"
const AnthropicBetaPromptCaching2024_07_31 AnthropicBeta = "prompt-caching-2024-07-31"
const AnthropicBetaComputerUse2024_10_22 AnthropicBeta = "computer-use-2024-10-22"
const AnthropicBetaComputerUse2025_01_24 AnthropicBeta = "computer-use-2025-01-24"
const AnthropicBetaPDFs2024_09_25 AnthropicBeta = "pdfs-2024-09-25"
const AnthropicBetaTokenCounting2024_11_01 AnthropicBeta = "token-counting-2024-11-01"
const AnthropicBetaTokenEfficientTools2025_02_19 AnthropicBeta = "token-efficient-tools-2025-02-19"
const AnthropicBetaOutput128k2025_02_19 AnthropicBeta = "output-128k-2025-02-19"
const AnthropicBetaFilesAPI2025_04_14 AnthropicBeta = "files-api-2025-04-14"
const AnthropicBetaMCPClient2025_04_04 AnthropicBeta = "mcp-client-2025-04-04"
const AnthropicBetaMCPClient2025_11_20 AnthropicBeta = "mcp-client-2025-11-20"
const AnthropicBetaDevFullThinking2025_05_14 AnthropicBeta = "dev-full-thinking-2025-05-14"
const AnthropicBetaInterleavedThinking2025_05_14 AnthropicBeta = "interleaved-thinking-2025-05-14"
const AnthropicBetaCodeExecution2025_05_22 AnthropicBeta = "code-execution-2025-05-22"
const AnthropicBetaExtendedCacheTTL2025_04_11 AnthropicBeta = "extended-cache-ttl-2025-04-11"
const AnthropicBetaContext1m2025_08_07 AnthropicBeta = "context-1m-2025-08-07"
const AnthropicBetaContextManagement2025_06_27 AnthropicBeta = "context-management-2025-06-27"
const AnthropicBetaModelContextWindowExceeded2025_08_26 AnthropicBeta = "model-context-window-exceeded-2025-08-26"
const AnthropicBetaSkills2025_10_02 AnthropicBeta = "skills-2025-10-02"
const AnthropicBetaFastMode2026_02_01 AnthropicBeta = "fast-mode-2026-02-01"
const AnthropicBetaOutput300k2026_03_24 AnthropicBeta = "output-300k-2026-03-24"
const AnthropicBetaUserProfiles2026_03_24 AnthropicBeta = "user-profiles-2026-03-24"
const AnthropicBetaUserProfiles2026_08_18 AnthropicBeta = "user-profiles-2026-08-18"
const AnthropicBetaUserProfiles2026_09_04 AnthropicBeta = "user-profiles-2026-09-04"
const AnthropicBetaAdvisorTool2026_03_01 AnthropicBeta = "advisor-tool-2026-03-01"
const AnthropicBetaManagedAgents2026_04_01 AnthropicBeta = "managed-agents-2026-04-01"
const AnthropicBetaCacheDiagnosis2026_04_07 AnthropicBeta = "cache-diagnosis-2026-04-07"
const AnthropicBetaDreaming2026_04_21 AnthropicBeta = "dreaming-2026-04-21"
const AnthropicBetaThinkingTokenCount2026_05_13 AnthropicBeta = "thinking-token-count-2026-05-13"
const AnthropicBetaServerSideFallback2026_06_01 AnthropicBeta = "server-side-fallback-2026-06-01"
const AnthropicBetaServerSideFallback2026_07_01 AnthropicBeta = "server-side-fallback-2026-07-01"
const AnthropicBetaFallbackCredit2026_06_01 AnthropicBeta = "fallback-credit-2026-06-01"
const AnthropicBetaFallbackCredit2026_07_01 AnthropicBeta = "fallback-credit-2026-07-01"
const AnthropicBetaAgentMemory2026_07_22 AnthropicBeta = "agent-memory-2026-07-22"
const AnthropicBetaMidConversationToolChanges2026_07_01 AnthropicBeta = "mid-conversation-tool-changes-2026-07-01"
const AnthropicBetaCompact2026_01_12 AnthropicBeta = "compact-2026-01-12"
const AnthropicBetaComputerUse2025_11_24 AnthropicBeta = "computer-use-2025-11-24"
const AnthropicBetaMCPTunnels2026_06_22 AnthropicBeta = "mcp-tunnels-2026-06-22"
const AnthropicBetaStructuredOutputs2025_11_13 AnthropicBeta = "structured-outputs-2025-11-13"
const AnthropicBetaTaskBudgets2026_03_13 AnthropicBeta = "task-budgets-2026-03-13"
const AnthropicBetaThinkingDisplayUpdates2026_08_18 AnthropicBeta = "thinking-display-updates-2026-08-18"
const AnthropicBetaCEUserManagement2026_07_13 AnthropicBeta = "ce-user-management-2026-07-13"
const AnthropicBetaMidConversationOutputConfig2026_07_01 AnthropicBeta = "mid-conversation-output-config-2026-07-01"
const AnthropicBetaThinkingBindingControls2026_08_01 AnthropicBeta = "thinking-binding-controls-2026-08-01"
const AnthropicBetaMidConversationSystemClearAt2026_08_21 AnthropicBeta = "mid-conversation-system-clear-at-2026-08-21"
const AnthropicBetaCompact2026_09_04 AnthropicBeta = "compact-2026-09-04"
const AnthropicBetaInlineTools2026_09_15 AnthropicBeta = "inline-tools-2026-09-15"
const AnthropicBetaMCPClient2026_09_15 AnthropicBeta = "mcp-client-2026-09-15"
const AnthropicBetaCEPlugins2026_09_01 AnthropicBeta = "ce-plugins-2026-09-01"
const AnthropicBetaSpendLimitReads2026_09_26 AnthropicBeta = "spend-limit-reads-2026-09-26"
const AnthropicBetaTelemetryDestinations2026_08_11 AnthropicBeta = "telemetry-destinations-2026-08-11"
Returns
type BetaPlugin struct { Type: "plugin"; ID; Components; /* 16 more */ }
更新插件
package main

import (
	"context"
	"fmt"

	"github.com/anthropics/anthropic-sdk-go"
	"github.com/anthropics/anthropic-sdk-go/option"
)

func main() {
	client := anthropic.NewClient(
		option.WithAPIKey("my-anthropic-api-key"),
	)
	betaPlugin, err := client.Beta.Organization.Plugins.Update(
		context.TODO(),
		"plugin_id",
		anthropic.BetaOrganizationPluginUpdateParams{
			ServedVersionID: "pluginver_01KaZmQpRsTuVwXyZ2b4c6d8",
		},
	)
	if err != nil {
		panic(err.Error())
	}
	fmt.Printf("%+v\n", betaPlugin.ID)
}
Returns Examples
Response 200
{
  "id": "plugin_01JyHfbRkZvD1gW7oTqXc3Ne",
  "components": [
    {
      "description": "description",
      "name": "review-pr",
      "type": "skill"
    }
  ],
  "content_scan": {
    "assessment": "warn",
    "reason": "credential-exposure",
    "status": "completed"
  },
  "created_at": "2026-03-14T09:26:53.589793Z",
  "created_by": {
    "email_address": "user@example.com",
    "type": "user_actor",
    "user_id": "user_01WCz1FkmYMm4gnmykNKUu3Q"
  },
  "description": "Reviews pull requests against your team's conventions.",
  "display_name": "Code Review Helper",
  "latest_version_id": "pluginver_01KaZmQpRsTuVwXyZ2b4c6d8",
  "manifest_version": "1.2.0",
  "marketplace_id": "marketplace_01HxQ3v9KpZ2mTn8RwLc4Ys7",
  "name": "code-review-helper",
  "organization_installation_preference": "available",
  "organization_installation_preference_inherited": true,
  "owner": {
    "type": "organization"
  },
  "reach": "contained",
  "served_version_id": "pluginver_01K9wPcHd4Rm2Tx8Vq6Ln3Sb",
  "served_version_pinned": true,
  "type": "plugin",
  "updated_at": "2026-03-14T09:26:53.589793Z"
}