Skip to content

rahulb-yb/meeting-to-coda

Repository files navigation

Mic-to-Coda

A macOS background service that detects when your microphone stops being used (end of a call), prompts you to log the activity, and auto-fills a Coda timesheet form in a browser.

Works with any app that uses your microphone — Zoom, Slack, Google Meet, FaceTime, Teams, etc.

How it works

  1. The service polls your Mac's default audio input device every 5 seconds using the CoreAudio framework.
  2. When the microphone goes from active to inactive, a macOS dialog asks if you want to log the activity.
  3. If you click Yes, a Chromium browser opens with your Coda form, auto-fills the fields with your configured defaults (account name, role, activity type, sentiment) and the calculated time spent, then waits for you to review, edit anything, and submit manually.
  4. Close the browser window when done.

On first use, you'll need to log into Coda/Google in the browser. The login session is saved so you won't need to log in again.

Requirements

  • macOS (Intel or Apple Silicon)
  • Python 3.10+
  • Access to the Coda form you want to fill

Setup

1. Clone / copy to your Mac

Copy the project folder to your home directory:

cp -r meeting-to-coda ~/meeting-to-coda
cd ~/meeting-to-coda

2. Create config.json

Copy the example config and edit it with your values:

cp config.example.json config.json

Then edit config.json:

  • form_url — the full URL of your Coda form.
  • defaults — pre-filled values for each form field. These must match the exact dropdown option text in your Coda form. Remove any you don't need.

3. Run the installer

chmod +x install.sh
./install.sh

This will:

  1. Check that config.json exists.
  2. Create a Python virtual environment (.venv).
  3. Install dependencies (playwright, pyobjc-framework-CoreAudio).
  4. Download Chromium for Playwright.
  5. Register and start a launchd service that runs automatically on login.

4. Grant permissions

On first run, macOS may prompt you to allow:

  • Accessibility access (for the native dialog prompts)
  • Microphone access (for detecting audio input activity — the script does not record audio, it only checks if the device is in use)

Usage

The service runs automatically in the background after installation. No manual intervention needed.

When your microphone becomes inactive (you leave a call), a dialog appears:

Your microphone was just in use (2:00 PM - 2:30 PM, ~30 min). Log this activity to Coda?

  • Yes — opens a browser, fills the form with defaults, and waits for you to review and submit.
  • No — dismisses the prompt.

Managing the service

# Check status
launchctl list | grep meeting-to-coda

# Stop the service
launchctl stop com.user.meeting-to-coda

# Start the service
launchctl start com.user.meeting-to-coda

# Unload (disable until next login)
launchctl unload ~/Library/LaunchAgents/com.user.meeting-to-coda.plist

# Reload (after updating the script)
launchctl unload ~/Library/LaunchAgents/com.user.meeting-to-coda.plist
launchctl load ~/Library/LaunchAgents/com.user.meeting-to-coda.plist

Logs

# Live log output
tail -f ~/meeting-to-coda/logs/meeting_to_coda.log

# Stdout/stderr from launchd
tail -f ~/meeting-to-coda/logs/stdout.log
tail -f ~/meeting-to-coda/logs/stderr.log

Uninstall

launchctl unload ~/Library/LaunchAgents/com.user.meeting-to-coda.plist
rm ~/Library/LaunchAgents/com.user.meeting-to-coda.plist
rm -rf ~/meeting-to-coda

Customization

Changing defaults

Edit config.json and restart the service. The default values must match the exact text of the dropdown options in your Coda form.

Changing the poll interval

Edit POLL_INTERVAL_SECONDS in meeting_to_coda.py (default: 5 seconds).

Adapting to a different Coda form

The script fills fields in the order defined by FORM_FIELD_ORDER in meeting_to_coda.py. If your form has different field names, update that list and the DROPDOWN_FIELDS list to match. The field-filling logic uses the form's visible label text to locate each field.

Troubleshooting

Problem Fix
Dialog doesn't appear Check that the service is running: launchctl list | grep meeting-to-coda
Microphone not detected Ensure pyobjc-framework-CoreAudio is installed in the venv
Form fields not filling Coda may have changed its DOM structure — check logs for warnings
Browser opens but shows login Log in manually; the session is saved in .browser-profile/ for next time
Need to re-login to Coda Delete .browser-profile/ and the next run will prompt a fresh login

Project structure

meeting-to-coda/
├── meeting_to_coda.py              # Main script
├── config.json                  # Your form URL and default values
├── requirements.txt             # Python dependencies
├── install.sh                   # One-time setup script
├── com.user.meeting-to-coda.plist  # launchd service template
├── .venv/                       # Python virtual environment (created by install.sh)
├── .browser-profile/            # Persistent Chromium profile (created on first run)
└── logs/                        # Log files (created on first run)

About

Automate HR tasks away so you can be the engineer you were meant to be!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors