Reference documentation and code samples for the Cloud KMS V1 Client class AutokeyConfig.
Cloud KMS Autokey configuration for a folder.
Generated from protobuf messagegoogle.cloud.kms.v1.AutokeyConfig
Namespace
Google \ Cloud \ Kms \ V1
Methods
__construct
Constructor.
Parameters
Name
Description
data
array
Optional. Data for populating the Message object.
↳ name
string
Identifier. Name of theAutokeyConfigresource, e.g.folders/{FOLDER_NUMBER}/autokeyConfig.
↳ key_project
string
Optional. Name of the key project, e.g.projects/{PROJECT_ID}orprojects/{PROJECT_NUMBER}, where Cloud KMS Autokey will provision a newCryptoKeywhen aKeyHandleis created. OnUpdateAutokeyConfig, the caller will requirecloudkms.cryptoKeys.setIamPolicypermission on this key project. Once configured, for Cloud KMS Autokey to function properly, this key project must have the Cloud KMS API activated and the Cloud KMS Service Agent for this key project must be granted thecloudkms.adminrole (or pertinent permissions). A request with an empty key project field will clear the configuration.
↳ state
int
Output only. The state for the AutokeyConfig.
↳ etag
string
Optional. A checksum computed by the server based on the value of other fields. This may be sent on update requests to ensure that the client has an up-to-date value before proceeding. The request will be rejected with an ABORTED error on a mismatched etag.
getName
Identifier. Name of theAutokeyConfigresource, e.g.folders/{FOLDER_NUMBER}/autokeyConfig.
Returns
Type
Description
string
setName
Identifier. Name of theAutokeyConfigresource, e.g.folders/{FOLDER_NUMBER}/autokeyConfig.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getKeyProject
Optional. Name of the key project, e.g.projects/{PROJECT_ID}orprojects/{PROJECT_NUMBER}, where Cloud KMS Autokey will provision a newCryptoKeywhen aKeyHandleis created. OnUpdateAutokeyConfig,
the caller will requirecloudkms.cryptoKeys.setIamPolicypermission on
this key project. Once configured, for Cloud KMS Autokey to function
properly, this key project must have the Cloud KMS API activated and the
Cloud KMS Service Agent for this key project must be granted thecloudkms.adminrole (or pertinent permissions). A request with an empty
key project field will clear the configuration.
Returns
Type
Description
string
setKeyProject
Optional. Name of the key project, e.g.projects/{PROJECT_ID}orprojects/{PROJECT_NUMBER}, where Cloud KMS Autokey will provision a newCryptoKeywhen aKeyHandleis created. OnUpdateAutokeyConfig,
the caller will requirecloudkms.cryptoKeys.setIamPolicypermission on
this key project. Once configured, for Cloud KMS Autokey to function
properly, this key project must have the Cloud KMS API activated and the
Cloud KMS Service Agent for this key project must be granted thecloudkms.adminrole (or pertinent permissions). A request with an empty
key project field will clear the configuration.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getState
Output only. The state for the AutokeyConfig.
Returns
Type
Description
int
setState
Output only. The state for the AutokeyConfig.
Parameter
Name
Description
var
int
Returns
Type
Description
$this
getEtag
Optional. A checksum computed by the server based on the value of other
fields. This may be sent on update requests to ensure that the client has
an up-to-date value before proceeding. The request will be rejected with an
ABORTED error on a mismatched etag.
Returns
Type
Description
string
setEtag
Optional. A checksum computed by the server based on the value of other
fields. This may be sent on update requests to ensure that the client has
an up-to-date value before proceeding. The request will be rejected with an
ABORTED error on a mismatched etag.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Cloud KMS V1 Client - Class AutokeyConfig (2.3.1)\n\nVersion latestkeyboard_arrow_down\n\n- [2.3.1 (latest)](/php/docs/reference/cloud-kms/latest/V1.AutokeyConfig)\n- [2.3.0](/php/docs/reference/cloud-kms/2.3.0/V1.AutokeyConfig)\n- [2.2.0](/php/docs/reference/cloud-kms/2.2.0/V1.AutokeyConfig)\n- [2.1.6](/php/docs/reference/cloud-kms/2.1.6/V1.AutokeyConfig)\n- [2.0.0](/php/docs/reference/cloud-kms/2.0.0/V1.AutokeyConfig)\n- [1.23.0](/php/docs/reference/cloud-kms/1.23.0/V1.AutokeyConfig)\n- [1.22.1](/php/docs/reference/cloud-kms/1.22.1/V1.AutokeyConfig)\n- [1.21.4](/php/docs/reference/cloud-kms/1.21.4/V1.AutokeyConfig)\n- [1.20.3](/php/docs/reference/cloud-kms/1.20.3/V1.AutokeyConfig)\n- [1.19.0](/php/docs/reference/cloud-kms/1.19.0/V1.AutokeyConfig)\n- [1.18.1](/php/docs/reference/cloud-kms/1.18.1/V1.AutokeyConfig)\n- [1.17.0](/php/docs/reference/cloud-kms/1.17.0/V1.AutokeyConfig)\n- [1.16.4](/php/docs/reference/cloud-kms/1.16.4/V1.AutokeyConfig)\n- [1.15.3](/php/docs/reference/cloud-kms/1.15.3/V1.AutokeyConfig) \nReference documentation and code samples for the Cloud KMS V1 Client class AutokeyConfig.\n\nCloud KMS Autokey configuration for a folder.\n\nGenerated from protobuf message `google.cloud.kms.v1.AutokeyConfig`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Kms \\\\ V1\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getName\n\nIdentifier. Name of the [AutokeyConfig](/php/docs/reference/cloud-kms/latest/V1.AutokeyConfig)\nresource, e.g. `folders/{FOLDER_NUMBER}/autokeyConfig`.\n\n### setName\n\nIdentifier. Name of the [AutokeyConfig](/php/docs/reference/cloud-kms/latest/V1.AutokeyConfig)\nresource, e.g. `folders/{FOLDER_NUMBER}/autokeyConfig`.\n\n### getKeyProject\n\nOptional. Name of the key project, e.g. `projects/{PROJECT_ID}` or\n`projects/{PROJECT_NUMBER}`, where Cloud KMS Autokey will provision a new\n[CryptoKey](/php/docs/reference/cloud-kms/latest/V1.CryptoKey) when a\n[KeyHandle](/php/docs/reference/cloud-kms/latest/V1.KeyHandle) is created. On\n[UpdateAutokeyConfig](/php/docs/reference/cloud-kms/latest/V1.Client.AutokeyAdminClient#_Google_Cloud_Kms_V1_Client_AutokeyAdminClient__updateAutokeyConfig__),\nthe caller will require `cloudkms.cryptoKeys.setIamPolicy` permission on\nthis key project. Once configured, for Cloud KMS Autokey to function\nproperly, this key project must have the Cloud KMS API activated and the\nCloud KMS Service Agent for this key project must be granted the\n`cloudkms.admin` role (or pertinent permissions). A request with an empty\nkey project field will clear the configuration.\n\n### setKeyProject\n\nOptional. Name of the key project, e.g. `projects/{PROJECT_ID}` or\n`projects/{PROJECT_NUMBER}`, where Cloud KMS Autokey will provision a new\n[CryptoKey](/php/docs/reference/cloud-kms/latest/V1.CryptoKey) when a\n[KeyHandle](/php/docs/reference/cloud-kms/latest/V1.KeyHandle) is created. On\n[UpdateAutokeyConfig](/php/docs/reference/cloud-kms/latest/V1.Client.AutokeyAdminClient#_Google_Cloud_Kms_V1_Client_AutokeyAdminClient__updateAutokeyConfig__),\nthe caller will require `cloudkms.cryptoKeys.setIamPolicy` permission on\nthis key project. Once configured, for Cloud KMS Autokey to function\nproperly, this key project must have the Cloud KMS API activated and the\nCloud KMS Service Agent for this key project must be granted the\n`cloudkms.admin` role (or pertinent permissions). A request with an empty\nkey project field will clear the configuration.\n\n### getState\n\nOutput only. The state for the AutokeyConfig.\n\n### setState\n\nOutput only. The state for the AutokeyConfig.\n\n### getEtag\n\nOptional. A checksum computed by the server based on the value of other\nfields. This may be sent on update requests to ensure that the client has\nan up-to-date value before proceeding. The request will be rejected with an\nABORTED error on a mismatched etag.\n\n### setEtag\n\nOptional. A checksum computed by the server based on the value of other\nfields. This may be sent on update requests to ensure that the client has\nan up-to-date value before proceeding. The request will be rejected with an\nABORTED error on a mismatched etag."]]