- Add finetune video create subcommand (wan2.7/2.5/2.2 i2v + kf2v)
- Align video hyperparams with official docs (n_epochs=50, per-model batch_size/max_pixels)
- Add --last-frame flag to video generate for kf2v (image2video endpoint)
- Fix wan2.1-2.6 i2v input format (img_url instead of media[])
- Add training_cost field to finetune get/watch (catalog ft price, API-key domain only)
- Add --aigc-* flags to deploy create (optional, for video LoRA prompt config)
Move all credential handling out of commands into one place. authStage
resolves the credential for the command's declared `auth` and bakes it into
`ctx.client`, gating (throw) when missing; commands reach the network only
through `ctx.client` and never touch tokens or baseUrl.
- add Client (request/requestJson/uploadFile/mcp/console/url) wrapping the
token + baseUrl; commands call it instead of self-resolving
- run(config, flags) → run(ctx) + CommandContext; migrate all 45 commands
- split domains: model = pure api-key (drop access-token fallback), console =
config.json only (drop DASHSCOPE_ACCESS_TOKEN env)
- consolidate env reads in loadConfig; CredentialSource = flag | env | config;
priority flag > env > config
- endpoints return paths (xxxPath) instead of full URLs; baseUrl owned by Client
- auth status now uses describeAuth
- video/download: auth "none" → "apiKey" (it needs the model API)
- dedupe fetchModelList behind an injected console-call function
- remove ensureApiKey/ensure-key.ts, prompt.ts + isInteractive, and the old
resolveCredential/resolveConsoleGatewayCredential resolvers
- tests: adapt auth.e2e to the new auth status shape; drop the
DASHSCOPE_ACCESS_TOKEN branch from console-readiness gates
- endpoints: encodeURIComponent the id segments (task_id, app_id, node_id,
schema_id) interpolated into request URLs. task_id in particular comes from
the server's async-submit response and is fetched back with the bearer token
attached, so an unencoded value could steer the authenticated follow-up
request to a different path on the host.
- stream (SSE parser): cap the in-memory buffer (16 MiB). A stream that never
emits a newline, or that builds one enormous event from many data: lines,
could otherwise grow the buffer without bound and exhaust process memory.
https://claude.ai/code/session_017ZGQCjwNQF5Pz96gLUnnG1