Claude Platform Docs

创建隧道证书

Deprecated
POST/v1/organizations/tunnels/{tunnel_id}/certificates

已弃用。 此 Admin API 端点已被 Claude API 上的 /v1/tunnels 取代,并将在迁移窗口期后移除。新集成应使用 /v1/tunnels,并附带 anthropic-beta: mcp-tunnels-2026-06-22 标头和携带 workspace:manage_tunnels 范围的 WIF 令牌。在迁移窗口期内,现有集成可继续使用 mcp-tunnels-2026-05-19 标头和 org:manage_tunnels 范围。

为隧道注册公共 CA 证书。

Anthropic 在终止内部 TLS 会话时,会根据此 CA 验证网关的服务器证书。PEM 正文必须恰好包含一个 X.509 证书,且不得包含私钥材料。一个隧道最多持有两个未归档的证书。

Path parameters
tunnel_id: string

ID of the Tunnel.

Headers
"anthropic-beta": array of "mcp-tunnels-2026-05-19"

Required for all Tunnel endpoints.

Body
ca_certificate_pem: string

PEM-encoded X.509 CA certificate. Must contain exactly one certificate and no private-key material.

maxLength8192
Returns
id: string

ID of the Tunnel Certificate.

archived_at: string or null

RFC 3339 datetime string indicating when the certificate was archived, or null if it is not archived.

formatdate-time
created_at: string

RFC 3339 datetime string indicating when the certificate was registered.

formatdate-time
expires_at: string or null

RFC 3339 datetime string indicating when the certificate expires, or null if it does not expire.

formatdate-time
fingerprint: string

The certificate's SHA-256 fingerprint, as a lowercase hex string.

tunnel_id: string

ID of the Tunnel this certificate is registered against.

type: "tunnel_certificate"

Object type. Always tunnel_certificate for Tunnel Certificates.

defaulttunnel_certificate
创建隧道证书
cURL
curl https://api.anthropic.com/v1/organizations/tunnels/$TUNNEL_ID/certificates \
    -H 'Content-Type: application/json' \
    -H 'anthropic-version: 2023-06-01' \
    -H "Authorization: Bearer $ANTHROPIC_AUTH_TOKEN" \
    -d '{
          "ca_certificate_pem": "-----BEGIN CERTIFICATE-----\nMIIBexampleEXAMPLEexampleEXAMPLEexampleEXAMPLEexampleEXAMPLEexa\n...illustrative placeholder, not a real certificate...\n-----END CERTIFICATE-----\n"
        }'
Returns Examples
Response 200
{
  "id": "tcrt_01JmWq4ZxnBvR7tKpY2sLdH9",
  "archived_at": "2024-11-01T23:59:27.427722Z",
  "created_at": "2024-10-30T23:58:27.427722Z",
  "expires_at": "2024-10-30T23:58:27.427722Z",
  "fingerprint": "9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08",
  "tunnel_id": "tnl_01Hx9Kp2RtQvMn3sWbYdLcF8",
  "type": "tunnel_certificate"
}