That tends to work quite poorly because Claude Code does not use standard completions APIs. I tried it with Kimi, using litellm[proxy], and it failed in too many places.
You can try Kimi's Anthropic-compatible API.
Just connect Claude Code to Kimi's API endpoint and everything works well