Claude Platform Docs

Chiavi esterne

Crea chiave esterna
beta.organization.external_keys.create(**kwargs) -> BetaExternalKey
POST/v1/organizations/external_keys

Crea una configurazione di chiave esterna di proprietà dell'organizzazione del chiamante.

Elenca le chiavi esterne
beta.organization.external_keys.list(**kwargs) -> PageCursor<BetaExternalKey>
GET/v1/organizations/external_keys

Elenca le configurazioni di chiavi esterne nell'organizzazione del chiamante.

Ottieni chiave esterna
beta.organization.external_keys.retrieve(external_key_id) -> BetaExternalKey
GET/v1/organizations/external_keys/{external_key_id}

Recupera una singola configurazione di chiave esterna nell'organizzazione del chiamante tramite ID.

Aggiorna chiave esterna
beta.organization.external_keys.update(external_key_id, **kwargs) -> BetaExternalKey
POST/v1/organizations/external_keys/{external_key_id}

Aggiorna parzialmente una configurazione di chiave esterna. I campi omessi restano invariati.

Elimina chiave esterna
beta.organization.external_keys.delete(external_key_id) -> ExternalKeyDeleteResponse
DELETE/v1/organizations/external_keys/{external_key_id}

Elimina una configurazione di chiave esterna.

Convalida chiave esterna
beta.organization.external_keys.validate(external_key_id) -> ExternalKeyValidateResponse
POST/v1/organizations/external_keys/{external_key_id}/validate

Convalida una configurazione di chiave esterna rispetto al KMS del cliente.

Models
class BetaAWSExternalKeyConfig { type: :aws, kms_arn, region, role_arn }
type: :aws
kms_arn: String

Full ARN of the AWS KMS key. On Claude Platform on AWS the key must be a single-Region key in your organization's own AWS account; cross-account keys, multi-Region keys, and alias ARNs are rejected.

maxLength2048
region: String

AWS region. Derived from kms_arn if omitted.

role_arn: String⁠Deprecated

IAM role ARN. Deprecated — Anthropic reaches the KMS key through its own intermediate role (or, on Claude Platform on AWS, with credentials AWS issues for the Workspace); this field is ignored.

class BetaAzureExternalKeyConfig { type: :azure, key_name, tenant_id, 2 more }
type: :azure
key_name: String

Name of the key within the vault.

tenant_id: String

Azure AD tenant ID.

vault_uri: String

Key Vault data-plane URI — https://{vault-name}.vault.azure.net or https://{hsm-name}.managedhsm.azure.net.

client_id: String

Azure AD application (client) ID. Omit to use Anthropic's multitenant app. Provide only if using a single-tenant app registration in the customer's directory.

class BetaAzureExternalKeyConfigParam { type: :azure, key_name, tenant_id, 2 more }

Azure Key Vault provider configuration.

type: :azure
key_name: String

Name of the key within the vault.

tenant_id: String

Azure AD tenant ID.

vault_uri: String

Key Vault data-plane URI — https://{vault-name}.vault.azure.net or https://{hsm-name}.managedhsm.azure.net.

client_id: String

Azure AD application (client) ID. Omit to use Anthropic's multitenant app. Provide only if using a single-tenant app registration in the customer's directory.

class BetaExternalKey { type: :external_key, id, attachment, 5 more }

CMEK external key config belonging to the caller's organization.

Configs are organization-scoped. Workspaces attach to a config; once any workspace references it, the provider fields become effectively immutable (existing encrypted data needs the config for decrypt).

class BetaExternalKeyAttachedAttachment { type: :attached }
type: :attached
class BetaExternalKeyUnattachedAttachment { type: :unattached }
type: :unattached
class BetaGCPExternalKeyConfig { type: :gcp, key_name }
type: :gcp
key_name: String

Full resource name of the Cloud KMS key.

class ExternalKeyDeleteResponse { type: :external_key_deleted, id }
type: :external_key_deleted
id: String

ID of the deleted External Key.

class ExternalKeyValidateResponse { type: :external_key_validation, error, status }

Result of a validation roundtrip against the customer's KMS.

HTTP 200 for both outcomes — the operation completed; status says whether the key works.

type: :external_key_validation
error: String

Error message when status is failure. Null otherwise.

status: :failure | :success

success — encrypt/decrypt roundtrip succeeded. failure — the roundtrip failed or timed out; see error.

One of the following:
:failure
:success