- Resource: Key
- KeyAlgorithm
- KeySpec
- UserKeyShares
- KeyShareNode
- State
- PublicKeyInfo
- BlockchainAddresses
- Secp256k1Addresses
- BitcoinAddresses
- Ed25519Addresses
- Methods
Resource: Key
A Key is a cryptographic key pair generated and used through threshold MPC. The private key never exists in one place: it is split into key shares held by Users, as defined by the KeyPolicy of the parent KeyRing.
Keys cannot be deleted or moved between KeyRings. They can only be disabled.
| JSON representation |
|---|
{ "name": string, "algorithm": enum ( |
| Fields | |
|---|---|
name |
Identifier. The resource name of the Key. Format: projects/{project}/locations/{location}/instances/{instance}/keyRings/{keyRing}/keys/{key} |
algorithm |
Required. Immutable. The signing algorithm of the Key. |
keyShares |
Output only. The Users that hold the Key's key shares, and the thresholds needed to sign. The server fills this from the parent KeyRing's KeyPolicy when the Key is created. |
state |
Output only. The lifecycle state of the Key. |
publicKeyInfo |
Output only. The public key and derived addresses. Set once the Key is |
createTime |
Output only. The time at which the Key was created. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
updateTime |
Output only. The time at which the Key was last updated. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
uid |
Output only. The unique server-generated identifier of the Key. |
KeyAlgorithm
The signing algorithm of a Key.
| Enums | |
|---|---|
KEY_ALGORITHM_UNSPECIFIED |
Not specified. |
EC_SIGN_SECP256K1 |
ECDSA on curve secp256k1 (Bitcoin, Ethereum, and EVM-compatible chains). |
EC_SIGN_ED25519 |
EdDSA on curve Ed25519 (Solana, NEAR, Cardano, Sui). |
KeySpec
A node in the tree of key-share holders.
| JSON representation |
|---|
{ // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "userKeyShares": { object ( |
| Fields | |
|---|---|
| The kind of node. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
userKeyShares |
Output only. The key shares held by one User. |
keyShareNode |
Output only. A nested threshold rule over child nodes. |
| End of mutually exclusive fields. | |
State
The lifecycle state of a Key.
| Enums | |
|---|---|
STATE_UNSPECIFIED |
Not specified. |
CREATING |
Distributed key generation is in progress. The Key cannot sign yet. |
ACTIVE |
Distributed key generation succeeded. The Key can sign. |
DISABLED |
The Key is disabled and cannot sign. Its key shares are kept. |
FAILED |
Distributed key generation failed. No usable key material exists. This state is terminal. |
PublicKeyInfo
The public half of the Key and the addresses derived from it.
| JSON representation |
|---|
{
"publicKey": string,
"blockchainAddresses": {
object ( |
| Fields | |
|---|---|
publicKey |
Output only. The public key. For A base64-encoded string. |
blockchainAddresses |
Output only. Blockchain addresses derived from |
BlockchainAddresses
Blockchain addresses derived from a public key, grouped by curve.
| JSON representation |
|---|
{ // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "secp256k1Addresses": { object ( |
| Fields | |
|---|---|
| The addresses for the key's curve. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
secp256k1Addresses |
Output only. Addresses derived from a SECP256K1 public key. |
ed25519Addresses |
Output only. Addresses derived from an Ed25519 public key. |
| End of mutually exclusive fields. | |
Secp256k1Addresses
Addresses derived from a SECP256K1 public key.
| JSON representation |
|---|
{
"ethereumAddress": string,
"bitcoinMainnetAddresses": {
object ( |
| Fields | |
|---|---|
ethereumAddress |
Output only. The Ethereum address derived from the public key. Formatted as a hex string with a |
bitcoinMainnetAddresses |
Output only. The Bitcoin mainnet addresses derived from the public key. |
BitcoinAddresses
Single-key Bitcoin addresses derived from the compressed SECP256K1 public key. Taproot (P2TR) addresses are not included because they require Schnorr signatures.
| JSON representation |
|---|
{ "p2wpkhAddress": string, "p2shP2wpkhAddress": string, "p2pkhAddress": string } |
| Fields | |
|---|---|
p2wpkhAddress |
Output only. The native SegWit (P2WPKH) address. Formatted as a bech32 string, e.g. |
p2shP2wpkhAddress |
Output only. The nested SegWit (P2SH-P2WPKH) address. Formatted as a base58check string, e.g. |
p2pkhAddress |
Output only. The legacy (P2PKH) address. Formatted as a base58check string, e.g. |
Ed25519Addresses
Addresses derived from an Ed25519 public key.
| JSON representation |
|---|
{ "solanaAddress": string } |
| Fields | |
|---|---|
solanaAddress |
Output only. The Solana address derived from the public key. Formatted as a base58 string. |
Methods |
|
|---|---|
|
Creates a new Key in a KeyRing by running distributed key generation (DKG). |
|
Disables a Key so it can no longer sign. |
|
Gets details of a single Key. |
|
Lists Keys in a KeyRing. |