Skip to content

增加claude的count_token路由,在分布式部署下支持claude code#915

Open
liuhetian wants to merge 1 commit intoMartialBE:mainfrom
liuhetian:support-claude-code
Open

增加claude的count_token路由,在分布式部署下支持claude code#915
liuhetian wants to merge 1 commit intoMartialBE:mainfrom
liuhetian:support-claude-code

Conversation

@liuhetian
Copy link
Contributor

claude code正式请求之前要请求count_token计算一下input token,似乎还没办法通过 CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC 关闭,所以做一个简易版的 count_token 接口

这个问题对于分布式部署的时候会很严重,因为会重定向回master, post降级为get,直接报错, 造成claude code 无限等待

我已确认该 PR 已自测通过

@vercel
Copy link

vercel bot commented Feb 24, 2026

@liuhetian-t4f is attempting to deploy a commit to the martialbe's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants