cksol
БесплатноБез исполняемых скриптовНе проверенIntegrate ckSOL (chain-key SOL) into an IC app. Covers converting SOL to ckSOL via per-account Solana deposit addresses (get_deposit_address + deposit_sol…
от jiayaoqijia★ 81 звезда на GitHubОб этом скилле
ckSOL Integration
What This Is
ckSOL is an ICRC-1/ICRC-2 token backed 1:1 by SOL (9 decimals, 1 ckSOL = 1_000_000_000 lamports). The ckSOL minter derives one Solana deposit address per ICRC account from its threshold-Ed25519 key. It sweeps deposited SOL to its main address and mints once the sweep is finalized. For withdrawals it burns ckSOL via an ICRC-2 allowance and sends SOL using durable-nonce transactions, which never expire. It talks to Solana through the SOL RPC canister. Only native SOL is supported: no SPL tokens.
Source: github.com/dfinity/cksol. Minter v0.1.0 has run on mainnet since 2026-10.
Canister IDs
| Mainnet (Solana mainnet) | Staging (Solana Devnet, token "ckDevnetSOL") | |
|---|---|---|
| Minter | lh22c-kyaaa-aaaar-qb5nq-cai |
ljyxk-riaaa-aaaar-qb5mq-cai |
| Ledger | ls5lp-lqaaa-aaaar-qb5oa-cai |
la34w-haaaa-aaaar-qb5na-cai |
| Index | 2ezyf-hqaaa-aaaar-qb6ga-cai |
2r6ji-gyaaa-aaaar-qb6fq-cai |
| Minter main Solana address | GXVewvv6HehcLFYCmwpqh5CrMjqN9zJ8rqzGq3HEt9Ax |
Br8eRkeya8hy3sHCYqtWqGeNNZ349aPSUKGVYFWKKer1 |
The ledger fee is 500 lamports. get_minter_info (query) on 2026-11-02 returned: minimum_deposit_amount = 20_000_000 (0.02 SOL), minimum_withdrawal_amount = 2_000_000 (0.002 SOL), withdrawal_fee = 1_000_000 (0.001 SOL), deposit_sol_required_cycles = 1_000_000_000_000, and deposit_sol_fee = 45_000_000_000. deposit_sol_fee is in cycles, not lamports. Read these values at runtime.
How the deposit address is computed
The minter uses non-hardened derivation from the IC threshold Ed25519 key key_1, with path [minter canister id bytes, [0x01], owner principal bytes, 32-byte subaccount (zeros for default)]. The Solana address is the base58 of the derived 32-byte public key. It is deterministic and stable, one address per (owner, subaccount), and is a plain system account. The minter's main address is the key at the empty path, so it can never collide with a deposit address. You can derive it offline (deriveDepositAddressOffline below) or call get_deposit_address, an update call that anyone may make for any non-anonymous owner.
Deposit: SOL → ckSOL (deployed "manual" flow)
- Address.
get_deposit_address(record { owner = opt <principal>; subaccount = opt <32 bytes> | null })returns a base58 address. Ifowneris null, it defaults to the caller. - Send SOL to that address from any wallet or exchange, in one or several transfers (no memo). The total balance must reach
minimum_deposit_amount. - Notify.
deposit_sol(record { owner = opt <principal>; subaccount })with cycles attached (≥deposit_sol_required_cycles). The minter reads the finalized balance and charges about 2.3B cycles forgetBalanceplusdeposit_sol_fee(45B), refunding the rest. It then queuessweepable = balance − 890_880(the rent-exemption threshold stays on the address, once per address) and returnsOk(deposit_id : nat64). Only canisters can attach cycles, so a frontend cannot calldeposit_soldirectly: route it through your backend canister.ownermay be any principal, so a backend can pay for a user-owned account. - Sweep and mint happen on minter timers, about a minute each. Up to 10 deposits are swept per Solana transaction, and each deposit pays a 5_000-lamport fee share. ckSOL is minted only after the sweep is finalized. The user receives
sweepable − 5_000lamports. - Track with
deposit_sol_status(deposit_id)(query):Queued { sweepable_amount } → Swept { signature } → Finalized { signature } → Minted { block_index; minted_amount }. ADropped { signature }status means the sweep failed or expired, nothing was minted, and the funds are still on the address: calldeposit_solagain. AQuarantined { signature }status needs a minter upgrade: use a different subaccount for new deposits.
At most one deposit per account is in flight. Calling deposit_sol again while one is queued, swept or finalized returns the same deposit_id and refunds all cycles, so retries are safe. Example: the first deposit of exactly 1 SOL mints 999_104_120 lamports, the minimum 0.02 SOL mints 19_104_120, and a later deposit to the same address loses only the 5_000 fee share.
Upcoming automatic flow, not on mainnet as of 2026-11-02. watch_deposit_address(record { subaccount }) is free, needs no cycles, and has owner = caller. The minter then scans the address for about 24 h and sweeps automatically, deducting automatic_deposit_fee (0.002 SOL). Status is Watching | Detected { deposit_id }, and you follow it with deposit_sol_status. Before using it, check that the endpoint exists: icp canister metadata lh22c-kyaaa-aaaar-qb5nq-cai candid:service -n ic.
Withdrawal: ckSOL → SOL
icrc2_approveon the ckSOL ledger, with spender = minter and amount ≥ the withdrawal amount. Burns are fee-free, and the approve itself costs 500 lamports.- `withdraw_sol(reco
Установить cksol в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл cksol?
Integrate ckSOL (chain-key SOL) into an IC app. Covers converting SOL to ckSOL via per-account Solana deposit addresses (get_deposit_address + deposit_sol with cycles, works from exchanges), withdrawing ckSOL to SOL (icrc2_approve + withdraw_sol), tracking deposit/withdrawal status, deposit-address derivation, fees, minimums, and which calls belong in the frontend vs a backend canister. Use when the user mentions ckSOL, Solana deposits or withdrawals on ICP, or moving SOL to/from the Internet Computer. Do NOT use for plain ICRC-1 ckSOL transfers (use icrc-ledger), SPL tokens, or signing arbitrary Solana transactions from a canister (use the SOL RPC canister / threshold Ed25519 directly).
Как установить скилл cksol?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл cksol запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
frontend-design
Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
от Anthropicwebapp-testing
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
от Anthropicbrand-guidelines
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
от Anthropicweb-artifacts-builder
Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…
от Anthropic