Claude Code Setup
One-command setup for automatic time tracking in Claude Code.
Overview
TeeckIn integrates with Claude Code to automatically track your development time. Setup takes less than a minute with our NPM package.
Browser-Based Authentication
Claude Code uses OAuth 2.0 with PKCE - a secure, browser-based authentication flow. This means:
- ✓No API keys or secrets to manage
- ✓No credentials stored in project files
- ✓Authenticate once, works across all projects
What you get:
- +Claude asks what topic you're working on at session start
- +Ask Claude to stop the timer when you're done
- +Switch topics mid-session by asking Claude
Quick Setup
One command to get started:
Run Setup
# Run in your project directory
npx @teeckin/agent init --claudeNo credentials needed! Authentication happens in your browser.
First Connection
When Claude Code first connects to TeeckIn, your browser will open automatically:
- 1.Sign in to TeeckIn (if not already logged in)
- 2.Select an existing agent or create a new one
- 3.Click "Authorize" to grant permissions
- 4.Return to Claude Code - you're connected!
Different from Other AI Tools
Personal vs Organization
What Gets Created
The setup command creates these files in your project:
.mcp.jsonMCP server URL (no credentials - auth happens via browser)
.claude/settings.jsonSessionEnd hook and MCP tool permissions
CLAUDE.mdInstructions for Claude to prompt for topics
Safe to Commit
.mcp.json file only contains the server URL - no secrets. You can safely commit it to version control.Per-Project Agents
By default, Claude Code authenticates once and uses the same agent across all projects. If you want different agents for different projects (e.g., separate time tracking for client work), you have two options.
Option 1: Local Scope (Recommended)
Use Claude Code's "local" scope to configure TeeckIn per-project without modifying the project's .mcp.json. This is ideal when working on client codebases where you don't want to add your own config files.
Add a unique query parameter to differentiate the URL per project:
# In project A
cd ~/projects/project-a
claude mcp add teeckin -s http -t streamable-http \
--url "https://api.teeckin.com/api/mcp?project=project-a"
# In project B
cd ~/projects/project-b
claude mcp add teeckin -s http -t streamable-http \
--url "https://api.teeckin.com/api/mcp?project=project-b"The query parameter (?project=...) makes Claude Code treat each URL as a separate MCP server, triggering separate OAuth flows. The server ignores the parameter - agent selection happens during the browser authorization.
How Local Scope Works
~/.claude.json file, organized by project path. It's not committed to the project repository, so you can use it on client codebases without modifying their files.Option 2: Project-Level Config
If you control the project, run the setup command with a unique URL:
# Creates .mcp.json in the project
TEECKIN_API_URL="https://api.teeckin.com/api/mcp?project=my-project" \
npx @teeckin/agent init --claudeThis creates a .mcp.json file that can be committed to version control. Team members will each authenticate with their own agent during the browser flow.
Switching Agents
Ending Sessions
When you're done working, ask Claude to stop the timer:
Ask Claude to stop the timer
Simply tell Claude: "Stop the timer" or . Claude will call the . Claude will call the tool.
Known Issue: SessionEnd hooks unreliable
/exit nor reliably trigger SessionEnd hooks in Claude Code. This is a reliably trigger SessionEnd hooks in Claude Code. This is a we're waiting on Anthropic to fix. In the meantime, always ask Claude to stop the timer before ending your session.Forgot to stop?
Security
Claude Code uses OAuth PKCE (Proof Key for Code Exchange) for secure authentication:
- +No credentials stored in project files
- +Authentication happens in your browser
- +Tokens are stored securely by Claude Code
- +You can revoke access anytime from Settings > Agents
Re-authorization
CLI Commands
The package provides commands for setup and manual timer control:
Config Commands
npx @teeckin/agent initInitial setup (creates config files)npx @teeckin/agent updateRefresh config with latest MCP tools and featuresTimer Commands
npx @teeckin/agent exec:statusCheck if a timer is runningnpx @teeckin/agent exec:update "notes"Update notes on the active timernpx @teeckin/agent exec:stopManually stop the active timerUpdating After TeeckIn Releases
Available Tools
Once configured, Claude has access to these MCP tools:
Timer Control
teeckin_get_statusCheck timer status; detects recent sessions for resumeteeckin_list_topicsList available topics and categoriesteeckin_start_timerStart tracking time on a topic (includes followup items)teeckin_stop_timerStop the active timerteeckin_log_timeLog a completed time entry retroactivelyChecklist Tracking
teeckin_add_checklist_itemAdd a task to the current topic (persists across sessions)teeckin_start_itemStart working on a task (tracks time, auto-pauses others)teeckin_check_itemMark a task as done (fuzzy matching)teeckin_uncheck_itemReset a completed or dismissed task to pendingteeckin_dismiss_itemMark a task as not needed (preserves time spent)teeckin_get_followupSee pending tasks on the current topicNotes & Tags
teeckin_update_timerUpdate notes on the active timer (text mode)teeckin_list_tagsList available tags for categorizing workteeckin_add_tagsAdd tags to the active timer (creates if needed)Checklist Mode
Tasks are scoped to topics, not individual time entries. This means incomplete tasks persist across sessions until you complete or dismiss them. Time spent on each task is tracked when you start working on it.
You:
Fix the login validation bug and add unit tests
Claude:
[adds tasks, starts working on first]
I'll track these tasks:
- Fix login validation bug (starting now)
- Add unit tests for auth module
Claude (after fixing bug):
[checks off task]
Fixed the validation issue (12 min). Moving on to tests.
When you check status, the checklist shows states and time:
Timer running: Project Alpha (45 minutes)
Currently working on: Add unit tests (8 min)
Tasks (1/2 done):
- [x] Fix login validation bug (12 min)
- [*] Add unit tests for auth module (ongoing)
Auto-Pause
Session Resume
If you clear a conversation or start a new session within 10 minutes of stopping, Claude detects this and offers to resume your previous session.
Claude (new session, within 10 min):
You were working on API Development 3 minutes ago.
Incomplete tasks:
- [ ] Add unit tests for auth module
Resume that session?
You:
Yes
Claude:
[starts timer on "API Development", carries over tasks]
Resumed! Ready to continue.
Quick Context Switch
Task Persistence
Tasks persist on topics automatically. When you start a new session on the same topic, pending tasks are still there - no need to "carry over" or accept anything.
Claude (new session):
Timer started on "Project Alpha".
Pending tasks (1):
- [ ] Add unit tests for auth module
Ready to continue where you left off?
You:
Yes, let's do the tests
Claude:
[starts working on task]
Working on unit tests now.
Dismiss vs Complete
Example Session
Claude (session start):
I see TeeckIn is configured. What topic are we working on today?
Available topics:
- Backend: API Development, Database
- Frontend: React Components, Styling
You:
API Development
Claude:
[starts timer on "API Development"]
Timer started! What would you like to work on?
You:
Add pagination to the users endpoint
Claude:
[implements the feature]
Done! I've added limit/offset pagination with a default of 20 items per page.
You:
Great, I'm done for today. Stop the timer.
Claude:
[stops timer]
Timer stopped. You worked 23 minutes on API Development today.
Troubleshooting
Claude doesn't ask about topics
Make sure the CLAUDE.md file was created. Check if TeeckIn section exists at the top.
Timer doesn't stop when session ends
SessionEnd hooks are currently unreliable in Claude Code (known Anthropic issue). Always ask Claude to stop the timer before ending your session.
Browser doesn't open for authorization
Try running /mcp reconnect teeckin in Claude Code. If that fails, check your default browser settings.
Authorization page shows error
Make sure you're logged in to TeeckIn. If the error persists, try clearing your browser cache for teeckin.com.
Want to switch to a different agent
Run /mcp reconnect teeckin in Claude Code. Your browser will open and you can select a different agent to authorize.