Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

getCodeHash

Read the current code hash for newly-created accounts.

Signature

function getCodeHash(
  client: Client,
  parameters?: { height?: number },
): Promise<Hex>

Example

import { createPublicClient, createTransport, testnet } from "@left-curve/sdk"
 
const client = createPublicClient({ chain: testnet, transport: createTransport() })
const codeHash = await client.getCodeHash()

Parameters

heightnumber, optional. Block height. Default 0 (latest).

Returns

Hex — the SHA-256 hash of the account contract's Wasm.

See also