skills/treasury-managers/SKILL.md
# Treasury Managers Control how trading fees are distributed with treasury managers. This is the power feature that sets Flaunch apart from other launchpads. ## Why Treasury Managers? When you launch a token on Flaunch, you receive an ERC721 NFT that represents ownership of the token's fee stream. By default, fees go to the NFT holder. But with treasury managers, you can program sophisticated fee distribution logic. **What you can do:** - Split fees between multiple addresses - Create stakin
npx skillsauth add flayerlabs/flaunchgg-contracts skills/treasury-managersInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Control how trading fees are distributed with treasury managers. This is the power feature that sets Flaunch apart from other launchpads.
When you launch a token on Flaunch, you receive an ERC721 NFT that represents ownership of the token's fee stream. By default, fees go to the NFT holder. But with treasury managers, you can program sophisticated fee distribution logic.
What you can do:
Every trade on a Flaunch token generates fees that flow to the BidWall. The creatorFeeAllocation you set at launch determines your share.
Trading Fees → BidWall → Creator Fee Allocation → Treasury Manager → Distribution
Managers that extend FeeSplitManager (AddressFeeSplit, Staking, BuyBack, ERC721Owner) support three tiers:
| Tier | Description | |------|-------------| | Creator Share | Goes to the address that deposited the token | | Owner Share | Goes to the manager owner (you) | | Split Share | Distributed per manager logic |
Shares use 5 decimal places: 100_00000 = 100%
Note: RevenueManager uses a different model with protocolRecipient and protocolFee instead.
| Manager | Use Case |
|---------|----------|
| AddressFeeSplitManager | Split fees between fixed addresses |
| StakingManager | Distribute fees to token stakers |
| BuyBackManager | Route fees to token buybacks |
| RevenueManager | Simple creator + protocol split |
| ERC721OwnerFeeSplitManager | Split based on NFT ownership |
See references/manager-types.md for detailed parameters.
import { createFlaunch } from "@flaunch/sdk";
const sdk = createFlaunch({ publicClient, walletClient });
// Launch with AddressFeeSplitManager
const txHash = await sdk.readWriteFlaunchZap.flaunchWithSplitManager({
name: "Split Token",
symbol: "SPLIT",
tokenUri: "ipfs://Qm...",
fairLaunchPercent: 0,
fairLaunchDuration: 0,
initialMarketCapUSD: 10000,
creator: "0xYourAddress",
creatorFeeAllocationPercent: 20,
creatorSplitPercent: 10, // 10% to creator
managerOwnerSplitPercent: 5, // 5% to manager owner
splitReceivers: [
{ address: "0xTreasury", percent: 50 },
{ address: "0xMarketing", percent: 35 },
],
});
address manager = treasuryManagerFactory.deployAndInitializeManager(
addressFeeSplitManagerImpl,
owner,
initializeData
);
See references/factory-usage.md for factory details.
Split trading fees between team, treasury, and marketing:
const splitReceivers = [
{ address: "0xTeamWallet", percent: 40 },
{ address: "0xTreasury", percent: 35 },
{ address: "0xMarketing", percent: 25 },
];
Let holders stake tokens to earn from trading fees:
StakingManager.InitializeParams({
stakingToken: tokenAddress,
minEscrowDuration: 30 days,
minStakeDuration: 7 days,
creatorShare: 10_00000, // 10%
ownerShare: 5_00000 // 5%
})
// Remaining 85% split among stakers proportionally
Route all fees to buy and burn tokens:
BuyBackManager.InitializeParams({
creatorShare: 10_00000,
ownerShare: 0,
buyBackPoolKey: poolKey
})
The ERC721 NFT represents fee stream ownership. You can move this ownership to:
deposit)// Direct transfer to another wallet
await nftContract.transferFrom(owner, newOwner, tokenId);
// Deposit into a treasury manager (proper method)
await nftContract.approve(managerAddress, tokenId);
await treasuryManager.deposit(flaunchToken, creatorAddress, depositData);
Important: Don't use safeTransferFrom directly to a manager. Managers track deposits via their deposit() function which handles internal accounting.
Extend TreasuryManager or FeeSplitManager for custom logic:
contract MyCustomManager is FeeSplitManager {
function _initialize(address _owner, bytes calldata _data) internal override {
// Your initialization logic
}
function balances(address recipient) public view override returns (uint) {
// Your balance calculation
}
}
See references/custom-managers.md for the full interface.
development
# Token Launching Launch memecoins on Base via Flaunch. Choose between the gasless API for simplicity or the SDK for programmatic control. ## Why Flaunch? - **No upfront cost**: Gasless API requires no wallet or ETH - **100% fee control**: You own all trading fee revenue - **Instant liquidity**: Tokens are immediately tradeable on Uniswap V4 - **Built-in protection**: BidWall prevents rug pulls ## Two Paths to Launch | Method | Wallet Needed | Best For | |--------|---------------|----------
development
Maintainer-only workflow for handling GitHub Secret Scanning alerts on OpenClaw. Use when Codex needs to triage, redact, clean up, and resolve secret leakage found in issue comments, issue bodies, PR comments, or other GitHub content.
development
Maintainer workflow for OpenClaw releases, prereleases, changelog release notes, and publish validation. Use when Codex needs to prepare or verify stable or beta release steps, align version naming, assemble release notes, check release auth requirements, or validate publish-time commands and artifacts.
development
Run, watch, debug, and extend OpenClaw QA testing with qa-lab and qa-channel. Use when Codex needs to execute the repo-backed QA suite, inspect live QA artifacts, debug failing scenarios, add new QA scenarios, or explain the OpenClaw QA workflow. Prefer the live OpenAI lane with regular openai/gpt-5.4 in fast mode; do not use gpt-5.4-pro or gpt-5.4-mini unless the user explicitly overrides that policy.