KCC20 SDKTap2Tip · Base44

sdk v167 · BUILD 169

Tap2Tip — buy any KRON token

Base44 must not build a KRON PSKT. Call buyKron on a Buy tap. The KCC20 PWA quotes + builds + user PIN-signs — same as Home → TRADE.

sendToken is still Fund DD (send KKDAG the user already holds). Different button.

buyKron

await kcc.buyKron({ tick: 'KKDAG', amount: '10' }) → { txId, quote, explorer }

amount is KAS to spend. Any KRON tick on idx.kron.technology. Mainnet only.

Optional: quoteKron({ tick, side:'buy', amount }) for a preview (works in the KCC20 iframe). Buy still quotes on the Sign sheet.

Sell: sellKron({ tick, amount }) — amount is tokens, not KAS.

sendToken — Fund, not a buy

await kcc.sendToken({ tick:'KKDAG', amount:'10', dest: treasuryKaspaQ })

Transfers a bag the wallet already holds. User must buy KKDAG first (Home TRADE or buyKron).

Only on a tap

Connect, Buy, Pay, Disconnect — never on load, never on app switch. No TTT PIN pad.

Copy into Base44

You are the tttz.xyz Base44 agent. Do not invent a DEX. Do not build KRON PSKTs. Do not fake KKDAG grants.

Load once: https://kcc-20-wallet.vercel.app/sdk.js?v=167
window.kcc20.sdkVersion must be "167" or higher (buyKron exists).

CLICK ONLY (never useEffect / route / app switch):
- Connect → await kcc.connect()
- Disconnect → await kcc.disconnect()
- Fund DD → await kcc.sendToken({ tick:'KKDAG', amount, dest: FULL kaspa:q treasury })
- Buy KRON → await kcc.buyKron({ tick, amount })  // amount = KAS to spend, tick = KKDAG/KRON/IFWEN/any KRON token

buyKron opens KCC20. Wallet quotes and builds the same Home TRADE swap. User PIN-signs. You get { txId, quote, explorer }.

kcc20test UI: tick input (default KKDAG), KAS amount (default 10), Buy KRON button. Show live getTokenBalance(tick). Show txId. Do not open a TTT PIN pad. Do not call kasware.requestAccounts. Do not call signPskt for this buy (that is Nilla’s job).

Test: Connect once → Buy 10 KAS of KKDAG → Sign in KCC20 → holdings increase. Switching apps = zero popups.