claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[Bug] Model Alias Not Supported in Custom Slash Command Configuration

Open cyreb7 opened this issue 5 months ago • 4 comments

Bug Description When using model: in custom slash commands, it doesn't support aliases (sonnet, opus, etc) model names, only exact API model names are supported.

Environment Info

  • Platform: linux
  • Terminal: vscode
  • Version: 1.0.120
  • Feedback ID: 9771a916-2c8f-452f-bd3b-96c7ac8b3889

Errors

[{"error":"Error: 404 {\"type\":\"error\",\"error\":{\"type\":\"not_found_error\",\"message\":\"model: sonnet\"},\"request_id\":\"req_011CTS8mGz3Wo5D2Zzyp2L3M\"}\n    at i9.generate (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:992:2516)\n    at IP.makeStatusError (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1009:2131)\n    at IP.makeRequest (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1009:5344)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n    at async RJB.ZI1.showErrors (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:29907)\n    at async ZI1 (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:18054)\n    at async RJB (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:29690)\n    at async file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:24439\n    at async aq0 (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:4362)\n    at async u01 (file:///usr/lib/node_modules/@anthropic-ai/claude-code/cli.js:1919:24409)","timestamp":"2025-09-23T22:38:33.445Z"}]

cyreb7 avatar Sep 23 '25 22:09 cyreb7

im pretty certain that I've just encountered this issue too, but with a particular nuance

Bug Description

Slash commands installed from plugin marketplace fail with invalid model identifier error if using an alias. This particular case arises solely through marketplace installed plugins that define model using aliases haiku, sonnet or opus. These work fine with my Claude Pro account, but fail with the indicated error when using Claude Bedrock API models. I've confirmed that changing the model in marketplace installed commands to exactly match the AWS Bedrock ID works correctly. This isn't actually a solution and therefore this aspect of the plugins system is broken for corporate use cases via AWS & GCP. The only option is to use skills without model values defined, which may be cost prohibitive.

Environment Info

Platform: darwin Terminal: vsCode Version: 2.0.13

Errors

/my-plugin:commit
API Error (haiku): 400 The provided identifier is invalid.
/my-plugin:commit
API Error (claude-haiku-4-5-20251001): 400 The provided model identifier is invalid.

rjlasko avatar Dec 05 '25 01:12 rjlasko

I think that #9243 is the same issue

rjlasko avatar Dec 05 '25 01:12 rjlasko

I think that this looks like but is not related to #7304

rjlasko avatar Dec 05 '25 02:12 rjlasko

This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.

github-actions[bot] avatar Jan 06 '26 10:01 github-actions[bot]

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

github-actions[bot] avatar Jan 21 '26 14:01 github-actions[bot]