dApp: Create Token and manager console for community tax CW20 #593
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:implement
agent:implement
agent:open_issues
agent:ready
agent:research
agent:security_audit
agent:verify
architecture
backend
blocker:hybrid
blocker:launch
blocker:limit-orders
blocker:v2
block:log_only
block:security
bug
ci
contracts
correctness
deploy
dev
devops
docs
documentation
duplicate
e2e
enhancement
epic
feature
frontend
functional-completion
gas
good first issue
governance
help wanted
high-risk
hooks
hybrid
indexer
infra
infrastructure
integrators
invalid
launch-blocker
limit-orders
localnet
localterra
low priority
missing-implementation
needs-design
ops
performance
priority
high
priority
medium
product
qa
QA
question
ready
ready
research
scripts
security
security-hardening
smartcontracts
tech-debt
testing
ux
UX
v2
verification
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/cl8y-dex-terraclassic#593
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent
Depends on #592 (on-chain launcher, SKUs, manager vs CMM admin). Indexer catalog is a sibling.
Payment (amendment)
Paid checkout must not be UST1-only. Use the shared Pay with any token card from #595. Do not duplicate Swap/router construction on Create Token / Manage.
50 UST1 × SKU countShow 50 UST1 (not per-field) before sign (“Save settings batch → 50 UST1”). Disable fields whose SKU is not unlocked; no-op Save disabled. Do not mix Enable Feature into the same Save (unlock is its own 50 UST1). Mint (issue supply) does not use this settings invoice.
This issue is blocked on #595 for every paid path (SKU and settings batch). A LocalTerra stub that pays UST1-only is acceptable only as an interim, not as the shipped UX.
Problem statement
The dApp can create pairs (
/create) and drip soft-launch tokens (/mint) but cannot create or manage a community tax token. Leaders need a retail flow: pick free vs paid features (50 UST1 each), instantiate via the launcher, then a management page (rates, ratios, exemptions, mint/revoke) that only the manager can submit — with clear warnings that wasm upgrades are CMM-only.Current codebase
frontend-dapp/src/App.tsx—/create→CreatePairPage,/mint→ faucet only,/ust1→ oracle window. No/token/createor/token/manage.frontend-dapp/src/components/common/navItems.ts— More menu has Create Pair, Protocol, Wrap, Mint (conditional). No “Create token”.CreatePair(#542, #382). Copy rules:skills/AGENTS_FRONTEND_COPY_COGNITIVE_LOAD.md— short labels, no lecture on the card.frontend-dapp/src/services/terraclassic/transactions.ts(gas envelopes, CW20 send). UST1 is a CW20 — paid SKUs needsend/increase_allowanceto the launcher, not native uluna.tokenIdentity.ts, PairTokenLinks (#541).frontend-dapp/src/services/indexer/— will consume new list/detail endpoints from the indexer issue.Why needed
Without a dApp, only CosmWasm CLI users can launch. The product promise is PinkSale-style: free basic tax token, optional 50 UST1 modules, then a manager console. Mis-copy (calling this “mint” like
/mintfaucet, or implying the leader can upgrade wasm) is a trust-boundary bug.Constraints / guardrails
/mintor/ust1. New routes e.g./token/createand/token/:addr/manage(or/create-token+/token/:addr). Nav label Create Token ≠ Mint ≠ Create Pair.manager, read-only (queries + explorer). Do not hide config — transparency.ContractInfo.admin≠ CMM → banner Unverified admin (do not pretend launcher-attested).isValidTerraBech32Addresson every address field.VITE_COMMUNITY_TOKEN_LAUNCHER,VITE_COMMUNITY_TAX_CODE_ID, CMM admin for banner compare. Unset → page unavailable (same pattern as faucet/wrap).Relevant files
frontend-dapp/src/App.tsx,components/common/navItems.ts, nav testspages/CreatePairPage.tsx,components/create/CreatePairTokenField.tsxservices/terraclassic/transactions.ts, newcommunityToken.ts(queries + execute)utils/maxSpendableAmount.ts— new context for taxed selldocs/design-system.mdglossary (add community tax token vs DEX fee),docs/frontend.mdmake test-e2eonly if launcher deployed)Recommended direction
Unauthorized-safe.?manager=or LCD; empty state.TaxPreviewfor sell max and show “Sell tax extra” one-liner — not a paragraph./createwith token prefill only if#542query prefill is explicitly added; otherwise copy the address + link/create.Acceptance criteria
docs/frontend.md+ glossary;make verify-issue-NNN.Test plan (all paths)
/mintwithout faucet).Attack / abuse / hack test plan
GetConfigfail → error, no blind execute.increase_allowanceto third party.manager, not a URL param.Verification criteria
make test-frontend/make lint-frontendgreen.make verify-issue-NNN(env grep + Vitest file list + optional LocalTerra screenshot/script).Labels / owner / priority
enhancementUXQA· Owner: frontend · Priority: P2 · Blocked by: on-chain template/launchermarked as related to #592
marked as related to #594
mentioned in issue #592
mentioned in issue #595
marked as related to #595
changed the description
Create Token / Manage paid checkout must use the shared Pay-with-any-token module: https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/issues/595 — do not ship a UST1-only picker.
changed the description
Manage Save: invoice 50 UST1 × N changed settings, paid via #595 (any token). Show N + total before sign. No-op Save disabled.
changed the description
Manage Save: always 50 UST1 for the batch, not per field. Locked SKU fields cannot be included. Unlock SKU is a separate 50 UST1 action.
mentioned in issue #597
marked as related to #597
mentioned in commit
995b85039cmentioned in merge request !1117
!1117 / #595 v1 is on
main(quotePayInvoice/buildPayInvoiceMsgs/PayWithAnyToken). Create Token and Manage settings Save must import that card — do not assemble router ops on those pages. LocalTerra SKU / settings-batch pay is still blocked on the #592 launcher.mentioned in merge request !1119
mentioned in issue #601
Columbus-5 pins (from #601, 2026-08-23)
Factory listed 11611. Launcher / AutoLP are stored only — 0 instantiates, so there is no
VITE_COMMUNITY_TOKEN_LAUNCHERaddress yet. Pages stay unavailable until ops instantiates launcher (wasm admin /cmm_governance= CMM) and Coolify is set.VITE_COMMUNITY_TAX_CODE_IDdata_hash9D33BF2539A9A5B2F13FD4B321CDBD0B0FD86D936D5D6BD6681955FA30210EC2VITE_COMMUNITY_TOKEN_LAUNCHER3907A435…. HashA0F95FBA548F4EA6F5536CE564922EC39B9ECE691CF3F01FF8733B7A93223F1984A8501C…ContractInfo.admin)terra16j5u6ey7a84g40sr3gd94nzg5w5fm45046k9s2347qhfpwm5fr6sem3lr2terra1f0eqgy9w7e5e7up97vjudqwx38tesf8ylx75x2lv3nwm0clry0pqmgfy72VITE_UST1_TOKEN_ADDRESSterra1ejpgvv7g3hj0u6fpcnxhflqp84g0w3cnaskqkg5733ygwlmf963sfchseaGetWhitelistedCodeIdsincludes 11611 (tx241FE20E…height 30071160)terra1e7s0h9ftxakwca5gxspyt4haeuaqxds6swr08ul3tsepq7el924sprrsrwDo not hardcode a LocalTerra store id. Confused-deputy: manage UI must require LCD
code_id == 11611, not 10184/8266/6036.Launcher address (columbus-5)
VITE_COMMUNITY_TOKEN_LAUNCHER=terra1af9xm63mev4hnf4z0nmmcsnd9f4lpac2vs205rmaeg3kdqlqudhq894lyzVITE_COMMUNITY_TAX_CODE_IDVITE_COMMUNITY_TOKEN_LAUNCHERterra1af9xm63mev4hnf4z0nmmcsnd9f4lpac2vs205rmaeg3kdqlqudhq894lyzterra16j5u6ey7a84g40sr3gd94nzg5w5fm45046k9s2347qhfpwm5fr6sem3lr2Instantiate tx
F7FCF13FB59148832AFA717FE3889830C19ACA33B18BFFB0122FB237BBDC2317height 30071219. LCDContractInfo: code 11612, admin = CMM. Unset → page unavailable still applies until Coolify ships these.mentioned in commit
4ed227a4b1mentioned in commit
6916d274b8mentioned in merge request !1120
mentioned in commit
5acbe574f5mentioned in commit
e2b098ab72!1120 merge note (conflicts + AC)
!1120 is merged. Conflicts vs
main(#601) were resolved by keeping the #601 free-profile launcher (execute_create_free+FreeProfileOnly, CMM-admin +GetLauncherOrigintest) and adding #593/#594 verify targets/docs. Did not wait for CI (ci_quota/ pipeline failed on the MR head).Automated AC re-run after the merge commit (
5acbe574):make verify-issue-593— PASS (5/5): Vitest 105, PayWithAnyToken import (no router fork), extra-debit Max, C593 docs,CreateTokenexecute existscargo test -p cl8y-community-token-launcher— PASS (3/3), includingcreate_free_profile_via_execute_stamps_cmm_adminStill open (not merge blockers — do not reopen this issue):
VITE_COMMUNITY_TAX_CODE_ID=11611,VITE_COMMUNITY_TOKEN_LAUNCHER=terra1af9xm63mev4hnf4z0nmmcsnd9f4lpac2vs205rmaeg3kdqlqudhq894lyz. Unset → Create Token stays hidden (C593-1).ExecuteMsg::CreateToken. Free create on mainnet will fail until migrate/re-store (C593-12 / O601-3). Paid SKUReceivestill works on current 11612./createis copy-address only (no #542 query prefill) — confirm in that LocalTerra pass.Tracking: follow-up issue after this comment.
mentioned in issue #602
marked as related to #602
Post-merge leftovers tracked in #602 (do not reopen this issue).
Post-merge leftovers tracked in #602 (do not reopen this issue).
mentioned in commit
84049b10ebmentioned in issue #558
mentioned in issue #603
marked as related to #603
mentioned in issue #604
marked as related to #604
mentioned in issue #605
marked as related to #605
mentioned in issue #606
marked as related to #606
mentioned in issue #609
marked as related to #609
Audit INTERNAL_KIMIK3_1787468843 — H-6 buy-side quote (note only)
On-chain pair→EOA Transfer is Buy by design (T592-7, 11611 REPORT B6): limit maker payouts and refunds of the tax token take buy tax. Do not file that as a contract bug.
dApp gap:
useCommunityTaxSellBps/ C593-9 only size sell extra-debit. Swap You Receive and Trade buy still use pairSimulation/simulate_swap_operations, which do not model the outbound split. Users see a quote they will not receive.Please treat buy-side
TaxPreview(or equivalent) on Swap + Trade receive as a follow-up on this issue — no new ticket. No PoC in the audit for this half.mentioned in issue #622
marked as related to #622
mentioned in issue #626
marked as related to #626
mentioned in issue #633
mentioned in issue #634
mentioned in merge request !1137
mentioned in issue #669
marked as related to #669
mentioned in issue #670
marked as related to #670