AttestedSigner.getKeyId
Computes a program key's ID, as the registry's KeyRegistered event carries it: keccak256(policyId ‖ x ‖ y).
Imports
Named
import { AttestedSigner } from 'ox/tempo'Examples
import { P256 } from 'ox'
import { AttestedSigner } from 'ox/tempo'
const { publicKey } = P256.createKeyPair()
const keyId = AttestedSigner.getKeyId({
policyId: `0x${'aa'.repeat(32)}`,
programKey: publicKey
})Definition
function getKeyId(
options: getKeyId.Options,
): Hex.HexSource: src/tempo/AttestedSigner.ts
Parameters
options
- Type:
getKeyId.Options
The policy ID and program key.
options.policyId
- Type:
0x${string}
Attested Key Registry policy ID.
options.programKey
- Type:
{ prefix: number; x: bigint; y: bigint; }
Uncompressed P256 program key.
Return Type
The key ID.
Hex.Hex

