MCPcopy Create free account
hub / github.com/GoogleCloudPlatform/nodejs-docs-samples / updateKeySetPrimary

Function updateKeySetPrimary

kms/updateKeySetPrimary.js:43–51  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

41 const keyName = client.cryptoKeyPath(projectId, locationId, keyRingId, keyId);
42
43 async function updateKeySetPrimary() {
44 const [key] = await client.updateCryptoKeyPrimaryVersion({
45 name: keyName,
46 cryptoKeyVersionId: versionId,
47 });
48
49 console.log(`Set primary to ${versionId}`);
50 return key;
51 }
52
53 return updateKeySetPrimary();
54 // [END kms_update_key_set_primary]

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected