I Made AI Code for Me from My Phone (Slack Codex CLI)

Published: (January 1, 2026 at 04:52 AM EST)
3 min read
Source: Dev.to

Source: Dev.to

Introduction

Have you ever wished you could work while lying in bed?

Well, you can.

I built a system where you just send a mention in Slack, and AI writes the code and even creates a PR (Pull Request) for you. You can request coding from your phone, on the train, or even from your bed.

In this article, I’ll show you how this system works and demonstrate it in action.

How It Works

The architecture is simple.

Architecture diagram

  1. Mention from your phone via Slack → Message goes to Slack Cloud
  2. Bot on your home PC detects it → Python bot connected via Socket Mode receives the message
  3. Launches Codex CLI → Automatically performs the requested task
  4. Reports progress to Slack → Sends progress and results via Slack MCP (Model Context Protocol)
  5. Creates Pull Request on GitHub → Commits and creates a PR via GitHub MCP

Since all processing happens on your home PC, you can use a GPU and run heavy tasks with Docker.

See It in Action

1. Send a Mention in Slack

Just mention the bot in Slack to start the work.

@codex-bot create simple todo app in new folder and run with host 0.0.0.0

Slack mention example

Once the bot starts working, progress updates are posted to the thread. When complete, the app URL and PR link are shared.

2. Check the App

Access the created app from your phone to verify it works.

App running on phone

If you’re on the same Wi‑Fi network, you can directly access the development server. Checking the design and giving feedback is easy from your phone.

3. Review and Merge the PR

Review the PR on GitHub and merge it if everything looks good.

GitHub PR view

Check the code diff, add comments if needed, and merge. Done!

What You Can Do

  • Coding: Implement new features, fix bugs, refactor code.
  • App Development: Create web‑app scaffolding, adjust UI.
  • Docker Tasks: Run ML training, batch processing (completion detection via health checks).
  • Automated Testing: Simple E2E tests with Playwright MCP.

The workflow of “checking app design on your phone while giving feedback via Slack” feels like pair programming with a designer.

Setup

The code is available on GitHub. Setup instructions are in the README.

🔗 Repository:

Requirements

  • Slack App (Socket Mode)
  • ChatGPT account (for Codex CLI)
  • GitHub token (for PR creation)

See the repository README for detailed setup instructions.

Conclusion

Once you experience having AI code for you from your phone, you’ll be hooked.

  • Request bug fixes while lounging in bed
  • Implement new app features on the train
  • Give design feedback while relaxing on the couch

Make the most of your commute and spare time—build your own AI pair programmer.

  • Repository:
  • Codex CLI:
  • MCP (Model Context Protocol):
Back to Blog

Related posts

Read more »

The RGB LED Sidequest 💡

markdown !Jennifer Davishttps://media2.dev.to/dynamic/image/width=50,height=50,fit=cover,gravity=auto,format=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%...

Mendex: Why I Build

Introduction Hello everyone. Today I want to share who I am, what I'm building, and why. Early Career and Burnout I started my career as a developer 17 years a...