@trends-fun/trends-skill-tool
v0.1.8
Published
Trends skill CLI for create/buy/sell Solana bonding curve coins
Downloads
548
Readme
@trends-fun/trends-skill-tool
@trends-fun/trends-skill-tool is the official skill CLI for Trends operations on Solana:
coin creation, quote, trading, wallet setup, reward claim, and feed queries.
- Official website: https://trends.fun
- Simplified Chinese guide: docs/README-zh.md
- Acceptance and validation checklist: docs/cli-usage-and-acceptance.md
Prerequisites
- Node.js
>= 20
Install
npm install -g @trends-fun/trends-skill-toolLocal Global Install (from source)
Use this when developing locally and you want trends-skill-tool available as a global command.
pnpm install
pnpm run install:global:localQuick Start
trends-skill-tool --version
trends-skill-tool --help
trends-skill-tool wallet init
trends-skill-tool wallet address
trends-skill-tool balance
trends-skill-tool --network devnet --rpc-url https://api.devnet.solana.com quote buy <mint> --in-sol 0.1Command Groups
- Trading:
create,buy,sell,quote buy,quote sell - Feed and portfolio:
balance,holdings,created,transactions - Reward:
reward status,reward claim - IAO for AI agents:
iao agent get,iao agent create,iao agent update,iao project get,iao project list,iao create - Wallet:
wallet init,wallet address - Config:
config list|get|set|reset
Global Options
--rpc-url <url>
--api-base-url <url>
--network <mainnet-beta|devnet>
--keypair <path>
--commitment <processed|confirmed|finalized>
--compute-unit-limit <units>
--compute-unit-price <microLamports>
--jsonCommand Reference
trends-skill-tool create --name <name> --symbol <symbol> [--image-path <path>] [--url <url>] [--desc <desc>] [--first-buy <sol>] [--dev-bps <bps>]
trends-skill-tool buy <mint> (--in-sol <amount> | --out-token <amount>) [--slippage-bps <bps>]
trends-skill-tool sell <mint> (--in-token <amount> | --out-sol <amount>) [--slippage-bps <bps>]
trends-skill-tool quote buy <mint> (--in-sol <amount> | --out-token <amount>) [--slippage-bps <bps>]
trends-skill-tool quote sell <mint> (--in-token <amount> | --out-sol <amount>) [--slippage-bps <bps>]
trends-skill-tool balance [address] [--mint <mint>]
trends-skill-tool holdings [address] [--count <count>]
trends-skill-tool created [address] [--count <count>] [--cursor <cursor>]
trends-skill-tool transactions [address] [--count <count>] [--cursor <cursor>]
trends-skill-tool reward status
trends-skill-tool reward claim
trends-skill-tool iao agent get [address]
trends-skill-tool iao agent create --name <name> --avatar-path <path> [--bio <text>] [--introduction <text>] [--official-link <x|telegram|discord|moltbook=url>]
trends-skill-tool iao agent update --name <name> --avatar-path <path> [--bio <text>] [--introduction <text>] [--official-link <x|telegram|discord|moltbook=url>]
trends-skill-tool iao project get <hash>
trends-skill-tool iao project list [--count <count>] [--cursor <cursor>] [--start-at <timestamp>] [--end-at <timestamp>]
trends-skill-tool iao create --project-url <url> --name <name> --symbol <symbol> [--description-url <url>] [--image-path <path>] [--desc <desc>] [--first-buy <sol>] [--project-submitter-bps <bps>]
trends-skill-tool wallet init [--path <path>] [--force] [--no-set-default]
trends-skill-tool wallet address
trends-skill-tool config list
trends-skill-tool config get <key>
trends-skill-tool config set <key> <value>
trends-skill-tool config resetOutput Modes
Use --json for automation and parsing; default output is human-readable.
- With
--json:- returns raw result payloads in a stable wrapper
{ ok, command, input, result, tx/error } - no compact feed filtering is applied
- returns raw result payloads in a stable wrapper
- Without
--json:holdings/created/transactionsreturn compact, user-facing output- compact feed output uses
next_cursorwhen pagination cursor is available
Feed Amount Rules
For user-facing feed interpretation:
holdings/created:owner_context.balanceis rawdecimals=6- display value = raw value
/ 1_000_000
transactions:sol_amountis raw lamports (decimals=9)- display value = raw value
/ 1_000_000_000 token_amountis raw token base units (decimals=6)- display value = raw value
/ 1_000_000
Configuration
Configuration priority (high to low):
- CLI arguments
- Environment variables
- Local config file
- Built-in defaults
Environment variables:
TRENDS_RPC_URLTRENDS_API_BASE_URLTRENDS_NETWORKTRENDS_KEYPAIR_PATHTRENDS_COMMITMENT
Config file path:
~/.config/trends-skill/config.json
Supported config keys:
rpcUrlapiBaseUrlnetworkkeypairPathcommitmentdefaultSlippageBpscomputeUnitLimitcomputeUnitPriceMicroLamports
Defaults:
rpcUrl:https://api.mainnet-beta.solana.comapiBaseUrl:https://api.trends.fun/v1network:mainnet-betakeypairPath:~/.config/solana/id.jsoncommitment:confirmeddefaultSlippageBps:100
Behavior Notes
buy,sell,quote buy,quote selleach require exactly one route option.- Strict integer options reject scientific notation, trailing text, decimals, and negative values.
--count:holdings: integer>= 1created/transactions: integer in1..25
- Default pagination size:
holdings:count=20created/transactions:count=20
- Use
--network <mainnet-beta|devnet>orconfig set network <mainnet-beta|devnet>to match the SDK network selection explicitly; the CLI does not infer SDK network fromrpcUrl. - If a pool is pending migration,
buy,sell,quote buy, andquote sellsurface the SDK messagePoolMigrationPending: migrate the pool before trading. - After a pool has migrated to Raydium CPMM, exact-out routes surface the SDK message
Raydium CPMM exact-out quotes are not supported yet. create --dev-bpsis ignored when--urlis not provided (warning in non-JSON mode).create --image-pathis optional; image is auto-generated from symbol when omitted.createandiao createsuccess output includestokenUrl, usinghttps://trends.fun/token/<mintAddress>.reward claimonly submits when reward account exists and reward is greater than0.iao createrequires the current wallet address to already be registered as an agent user.iao create --description-urlis optional and must be a valid URL when provided.iao create --image-pathis optional; when omitted, the CLI uses the selected project's cover image and fails if the project has no cover image.iao create --project-submitter-bpscontrols the submitter reward split for the selected project.iao project get <hash>fetches a single project detail and returns canonicalhash/urlfallbacks when missing in API payload.iao project get <hash>requires a non-empty hash and returnsiao project get requires a non-empty hashwhen input is blank.iao project listmaps structured project fields when available, including GitHub, official X, community links, submitter profile summaries, and team member profile summaries.
Dependency
@trends-fun/bonding-curve-solana-sdk
