Class ExternalKey

  • All Implemented Interfaces:

    
    public final class ExternalKey
    
                        

    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).

    • Constructor Detail

    • Method Detail

      • id

         final String id()

        Identifier of the external key config: a tagged ID prefixed ekey_, or, on Claude Platform on AWS, an AWS KMS key's ARN.

      • attachment

         final ExternalKey.Attachment attachment()

        Whether any workspace uses this config to encrypt its data — counting live and archived workspaces (an archived workspace's data remains encrypted under the config), excluding deleted ones. Only an attached config is used by the encryption path; an unattached config is inert and can be deleted.

      • geo

         final String geo()

        Data residency geo. Selects the region this key is used in.

      • userProfileId

         final Optional<String> userProfileId()

        ID of the user profile the key is bound to, or null if the key is not bound to one. A key bound to a user profile can only be attached to a Workspace that has the same user profile. A key that isn't bound can only be attached to a Workspace that has no user profile.

      • _type

         final JsonValue _type()

        Expected to always return the following:

        JsonValue.from("external_key")

        However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).

      • _id

         final JsonField<String> _id()

        Returns the raw JSON value of id.

        Unlike id, this method doesn't throw if the JSON field has an unexpected type.

      • _createdAt

         final JsonField<OffsetDateTime> _createdAt()

        Returns the raw JSON value of createdAt.

        Unlike createdAt, this method doesn't throw if the JSON field has an unexpected type.

      • _displayName

         final JsonField<String> _displayName()

        Returns the raw JSON value of displayName.

        Unlike displayName, this method doesn't throw if the JSON field has an unexpected type.

      • _geo

         final JsonField<String> _geo()

        Returns the raw JSON value of geo.

        Unlike geo, this method doesn't throw if the JSON field has an unexpected type.

      • _updatedAt

         final JsonField<OffsetDateTime> _updatedAt()

        Returns the raw JSON value of updatedAt.

        Unlike updatedAt, this method doesn't throw if the JSON field has an unexpected type.

      • _userProfileId

         final JsonField<String> _userProfileId()

        Returns the raw JSON value of userProfileId.

        Unlike userProfileId, this method doesn't throw if the JSON field has an unexpected type.

      • validate

         final ExternalKey validate()

        Validates that the types of all values in this object match their expected types recursively.

        This method is not forwards compatible with new types from the API for existing fields.

      • builder

         final static ExternalKey.Builder builder()

        Returns a mutable builder for constructing an instance of ExternalKey.

        The following fields are required:

        .id()
        .attachment()
        .createdAt()
        .displayName()
        .geo()
        .providerConfig()
        .updatedAt()
        .userProfileId()