feat(market): add structured --type/--launchpad-platform/--limit options for trenches command

Replace raw --body JSON parameter with structured CLI flags for better AI agent readability.
Add full response key reference and SOL/BSC/Base examples to SKILL.md and docs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
gumponchain
2026-03-26 17:02:24 +08:00
co-authored by Claude Sonnet 4.6
parent 5a8879c6d2
commit 08b48c8e24
6 changed files with 202 additions and 16 deletions
+4 -1
View File
@@ -61,11 +61,14 @@ export function registerMarketCommands(program: Command): void {
.command("trenches")
.description("Get Trenches token data (new creation, near completion, completed)")
.requiredOption("--chain <chain>", "Chain: sol / bsc / base")
.option("--type <type...>", "Categories to query, repeatable: new_creation / near_completion / completed (default: all three)")
.option("--launchpad-platform <platform...>", "Launchpad platform filter, repeatable (default: all platforms for the chain)")
.option("--limit <n>", "Max results per category, max 80 (default: 80)", parseInt)
.option("--raw", "Output raw JSON")
.action(async (opts) => {
validateChain(opts.chain);
const client = new OpenApiClient(getConfig());
const data = await client.getTrenches(opts.chain).catch(exitOnError);
const data = await client.getTrenches(opts.chain, opts.type, opts.launchpadPlatform, opts.limit).catch(exitOnError);
printResult(data, opts.raw);
});
}