Codex Setup
One-command setup for automatic time tracking in OpenAI Codex.
Overview
TeeckIn integrates with OpenAI Codex to automatically track your development time. Setup takes less than a minute with our NPM package.
What you get:
- +Codex asks what topic you're working on at session start
- +MCP tools for seamless time tracking control
- +Switch topics mid-session by asking Codex
Quick Setup
Two steps to get started:
1. Create an Agent
Go to Settings → Automation → Agents and create a new agent:
- - Select Codex as type
- - Give it a name (e.g., "My Codex Agent")
- - Copy both the Client ID and Client Secret
Save Your Secret Now
2. Run Setup
# Run in your project directory
npx @teeckin/agent init --codex
# The CLI will prompt for your credentialsYour credentials are saved securely in the local config files.
Personal vs Billing entity
What Gets Created
The setup command creates these files:
~/.codex/config.tomlMCP server configuration (user-level, shared across projects)
.codex/hooks.jsonProject-level hooks for session events
AGENTS.mdInstructions for Codex to prompt for topics
One Agent, Multiple Projects
npx @teeckin/agent init --codex in each project directory.Security
Keep Secrets Secure
Secret Rotation
npx @teeckin/agent init again to update your local config.CLI Commands
The package provides commands for setup and manual timer control:
Config Commands
npx @teeckin/agent initInitial setup (creates files, prompts for credentials)npx @teeckin/agent authUpdate credentials (for secret rotation)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
npx @teeckin/agent update to refresh your configuration without re-entering credentials.Available Tools
Once configured, Codex 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 track on the active timerteeckin_check_itemMark a task as done (fuzzy matching)teeckin_uncheck_itemReopen a completed taskteeckin_get_followupSee incomplete tasks from last sessionteeckin_accept_followupCarry over incomplete tasks to current sessionNotes & 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
Codex can track work as a checklist of tasks, checking them off as it goes. This creates a living document of what was accomplished during the session.
When tasks are added, Codex tracks them on the active timer. As work completes, it checks off items using fuzzy matching. The checklist persists with the time entry, giving you a record of exactly what was done.
Timer running: Project Alpha (45 minutes)
Checklist (2/3 done):
- [x] Fix login validation bug
- [x] Add unit tests
- [ ] Update documentation
Session Resume
If you start a new session within 10 minutes of stopping, Codex detects this and offers to resume your previous session.
This prevents losing context when you clear a conversation to start fresh but want to keep working on the same topic. The teeckin_get_status tool returns recent session info including incomplete tasks.
No timer running.
Recent session available:
- Topic: API Development
- Stopped: 3 minute(s) ago
- Incomplete tasks: 1
Ask user if they want to resume.
Followup Between Sessions
If a session ends with incomplete tasks, they're saved. When starting a new session on the same topic, Codex can carry them over automatically.
Use teeckin_get_followup to check for incomplete items from the last session, then teeckin_accept_followup to add them to the current checklist.
Automatic Workflow
Config.toml Reference
The MCP server is configured in your user config with OAuth authentication:
# ~/.codex/config.toml
[mcp_servers.teeckin]
url = "https://api.teeckin.com/api/mcp"
required = false
oauth_client_id = "teeckin_agent_..."
oauth_client_secret = "tcs_..."Troubleshooting
Codex doesn't ask about topics
Make sure the AGENTS.md file was created. Check if TeeckIn section exists at the bottom.
MCP tools not available
Check ~/.codex/config.toml has the [mcp_servers.teeckin] section with valid credentials.
'Authentication failed' during init
Verify your credentials in Settings → Automation → Agents. If the secret was lost, create a new one in the Secrets tab.
'invalid_client' error
Check credentials in ~/.codex/config.toml. The client_id starts with 'teeckin_agent_' and client_secret starts with 'tcs_'. Run init again to re-enter them.