docs: chain-key tokens guide#76
Conversation
Covers ckBTC and ckETH minting (deposit), redemption (withdrawal), ledger transfers, and subaccount derivation. Includes Motoko and Rust implementations with language tabs. Renamed stub from .md to .mdx for language tabs.
Review: Chain-Key TokensMust fix
Suggestions
Verified
|
- Fix factually incorrect ckETH deposit flow: remove false minter_address function claim and unique-per-principal address claim; describe the correct flow using the deposit function on the shared helper contract with ICP principal as call data, and the minter monitoring ReceivedEth events - Change chain-key cryptography link from external Learn Hub URL to internal page (docs/concepts/chain-key-cryptography.md) per CLAUDE.md linking rules - Add ckBTC Checker canister ID (oltsj-fqaaa-aaaar-qal5q-cai) to the canister table since the page already references the checker's public audit - Add created_at_time for dedup protection in withdrawal code (Motoko and Rust) with explanatory comment per icrc-ledger skill pitfall #5 - Update Upstream comment to reference .sources/ repos instead of external URL
|
Feedback addressed for PR #76 (chain-key tokens guide): Changes appliedMust fix — ckETH deposit flow corrected (lines 431–434)
Must fix — Internal link for chain-key cryptography (line 20) Suggestion — ckBTC Checker canister ID added to table Suggestion — Suggestion — Upstream comment updated Items skippedSuggestion — "currently" in confirmation count wording Suggestion — JS SDK examples not present Note — .mdx file extension Build note |
Summary
get_btc_address→update_balanceto mint;icrc2_approve→retrieve_btc_with_approvalto redeem) with Motoko and Rust examplesupdate_balance, minimum withdrawal amounts, fee handling, subaccount byte size.mdxfor Motoko/Rust language tab componentsSync recommendation
informed by dfinity/icskills — ckbtc skill, icrc-ledger skill; dfinity/portal — chain-key-tokens pages