Claude Code
Anthropic's Claude Code agent for AI-assisted coding
Claude Code is Anthropic's official coding agent, powered by Claude. It excels at understanding complex codebases and making thoughtful, well-reasoned changes.
Overview
| Feature | Details |
|---|---|
| Provider | Anthropic |
| CLI Tool | claude |
| Auth Methods | API key, Claude Max/Pro subscription |
| Strengths | Complex reasoning, large context, code quality |
Authentication
API Key
- Get an API key from Anthropic Console
- Add to Sesame:
- Per-user: Settings → API Keys → Anthropic
- System-wide: Set
ANTHROPIC_API_KEYenvironment variable
Subscription (Claude Max/Pro)
Use your Claude Max ($200/mo) or Claude Pro ($20/mo) subscription:
-
Install the Claude CLI:
npm install -g @anthropic-ai/claude-code -
Run the setup command:
claude setup-token -
Complete the browser authentication
-
Copy the token (starts with
sk-ant-oat01-) -
In Sesame: Avatar → Agent Credentials → Claude Code → Paste token
Environment Variables
| Variable | Description |
|---|---|
ANTHROPIC_API_KEY | API key for Claude |
CLAUDE_CODE_OAUTH_TOKEN | Subscription OAuth token |
Capabilities
Claude Code can:
- Read and understand entire codebases
- Make multi-file changes
- Write tests alongside code changes
- Explain complex code patterns
- Refactor and improve existing code
- Debug issues with detailed reasoning
Best Practices
Effective Prompts
Good: "Refactor the authentication module to use JWT tokens
instead of sessions. Update all affected routes and tests."
Bad: "Fix auth"Context Hints
Claude Code works best when you:
- Specify which files or directories are relevant
- Mention the tech stack if not obvious
- Describe the expected behavior clearly
Large Codebases
For large repositories:
- Claude Code handles large contexts well (200K tokens)
- Consider using specific file paths in prompts
- Break massive changes into smaller tasks
Troubleshooting
"Authentication failed"
- API key: Verify key is valid at Anthropic Console
- Subscription: Re-run
claude setup-tokenand update credentials
"Rate limited"
- API has rate limits based on your plan
- Subscription users: Check your plan's usage limits
- Consider upgrading your plan for higher limits
Agent hangs
- Claude Code may pause for complex reasoning
- Check task logs for progress
- Large context operations take longer
Token expired
Subscription tokens may expire. Re-authenticate:
claude setup-tokenThen update the token in Sesame's Agent Credentials.
CLI Reference
The Claude CLI supports various options that Sesame uses internally:
# Basic usage
claude "Your prompt here"
# With specific model
claude --model claude-sonnet-4-20250514 "prompt"
# Continue previous conversation
claude --continue "follow up prompt"Pricing
| Method | Cost |
|---|---|
| API (Claude Sonnet) | ~$3 / 1M input tokens, ~$15 / 1M output tokens |
| API (Claude Opus) | ~$15 / 1M input tokens, ~$75 / 1M output tokens |
| Claude Pro | $20/month (usage limits apply) |
| Claude Max | $200/month (higher limits) |
For current pricing, see Anthropic Pricing.