Key Management Service API, gRPC: SymmetricKeyService.ListVersions
Returns the list of versions of the specified symmetric KMS key.
gRPC request
rpc ListVersions (ListSymmetricKeyVersionsRequest) returns (ListSymmetricKeyVersionsResponse)
ListSymmetricKeyVersionsRequest
{
"key_id": "string",
"page_size": "int64",
"page_token": "string"
}
Field |
Description |
key_id |
string Required field. ID of the symmetric KMS key to list versions for. |
page_size |
int64 The maximum number of results per page to return. If the number of available |
page_token |
string Page token. To get the next page of results, set |
ListSymmetricKeyVersionsResponse
{
"key_versions": [
{
"id": "string",
"key_id": "string",
"status": "Status",
"algorithm": "SymmetricAlgorithm",
"created_at": "google.protobuf.Timestamp",
"primary": "bool",
"destroy_at": "google.protobuf.Timestamp",
"hosted_by_hsm": "bool"
}
],
"next_page_token": "string"
}
Field |
Description |
key_versions[] |
List of versions for the specified symmetric KMS key. |
next_page_token |
string This token allows you to get the next page of results for list requests. If the number |
SymmetricKeyVersion
Symmetric KMS key version: metadata about actual cryptographic data.
Field |
Description |
id |
string ID of the key version. |
key_id |
string ID of the symmetric KMS key that the version belongs to. |
status |
enum Status Status of the key version.
|
algorithm |
enum SymmetricAlgorithm Encryption algorithm that should be used when using the key version to encrypt plaintext.
|
created_at |
Time when the key version was created. |
primary |
bool Indication of a primary version, that is to be used by default for all cryptographic |
destroy_at |
Time when the key version is going to be destroyed. Empty unless the status |
hosted_by_hsm |
bool Indication of the version that is hosted by HSM. |