I. Installing the Claude Plugin in VSCode
II. Create a new configuration file
- Add a
config.jsonfile to the~/.claudedirectory
- The content of
config.jsonis as follows: Replaceconfig.jsonwith the API key you applied for yourself at Zhipu:
{
"primaryApiKey": "sk-test"
}
- Restart VS Code. You no longer need to log in, but it still won't work.
III. Modify the configuration file
Claude Code -> Settings -> Edit in settings.json
Add the following field:
"claudeCode.environmentVariables": [
{
"name": "ANTHROPIC_BASE_URL",
"value": "https://open.bigmodel.cn/api/anthropic"
},
{
"name": "ANTHROPIC_AUTH_TOKEN",
"value": "Replace with the API key you applied for yourself at Zhipu"
}
] Close and reopen VS Code.
IV. Claude Code Usage Tips
parse the project and generate or update the CLAUDE.md documentation.
/init
Clear the conversation and restart
/clear
Compact the context
/compact
Exit the session
/exit
Deep Thinking
ultrathink+query
























