Update an HMAC key

To update the state of an HMAC key for the specified service account, make a POST request that is scoped to a project. The authenticated user must have storage.hmacKeys.update permission for the project in which the key will be updated.

For general information about HMAC keys in Cloud Storage, see HMAC Keys .

HTTP Request

POST https://storage.googleapis.com/?Action=UpdateAccessKey&AccessKeyId= AccessKeyId 
&Status= Status 

Query string parameters

Parameter
Description
Required
Action
The HMAC key operation to be performed.
Yes
AccessKeyId
Access Key ID for the HMAC key.
Yes
Status
Update the status of this HMAC key. Valid values are:
  • Active : This key can be used to sign requests.
  • Inactive : Requests signed with this key will be denied.
Yes
UserName
The email address of a service account in the project. This is only used to validate that the specified service account owns the key before updating. The service account owner of a key cannot be updated.
No

Request headers

Use the common request headers .

Response

If successful, this method returns a response body with the following structure:

<UpdateAccessKeyResponse>
 <ResponseMetadata>
    <RequestId>EXAMPLE-REQUEST-ID</RequestId>
 </ResponseMetadata>
</UpdateAccessKeyResponse>
Parameter name Value Description
RequestId
string Unique ID for the request.
Create a Mobile Website
View Site in Mobile | Classic
Share by: