> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usepitboard.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Use Pitboard with Codex

> Add Codex accounts and restart what runs Codex after a switch.

Until you enrol a Codex account, Pitboard lists nothing about OpenAI's Codex CLI, not even the account Codex is signed in to, and asks OpenAI nothing.

## Add Codex accounts

Add each one as [Add another account](https://docs.usepitboard.com/guides/accounts.md#add-another-account) shows: in the app, choose **Codex** under **Tool**, and on the command line, start the label with `codex/`.

In the app, start with **Add** beside Codex in the welcome window, or **Add Codex Account** in the tip **Use Pitboard with Codex**. Pitboard reads which account Codex is signed in to only then, adds it and asks for its name. On the command line, `pitboard enroll codex/personal` enrols that account at once.

Adding an account runs `codex login` from OpenAI's Codex CLI, not the copy inside the ChatGPT app. If the dialog says Pitboard cannot find the Codex CLI, see [Pitboard cannot find a tool](https://docs.usepitboard.com/troubleshooting/accounts.md#pitboard-cannot-find-a-tool).

If Pitboard refuses to enrol a Codex account, its message says why, and [Fix Codex accounts](https://docs.usepitboard.com/troubleshooting/codex.md) says what to change.

## Restart what runs Codex

Nothing that runs Codex follows a switch, so restart each:

| What runs Codex | What to do |
| - | - |
| A `codex` session | Quit it and start it again. |
| The ChatGPT app on macOS | Quit it with Command-Q, not by closing its windows, and open it again. |
| The ChatGPT app on Windows | Quit it from its icon in the notification area, and open it again. |
| The ChatGPT app on Linux | Quit it and open it again. |
| Codex's background app server on macOS | Click **Restart App Server…** in the app's switch notice, or run `codex app-server daemon restart`. |
| Codex's background app server on Linux | Run `codex app-server daemon restart`. |
| Codex's background app server on Windows | Run `codex app-server daemon restart` from a terminal that is not elevated. |
| Codex in an editor | Run **Developer: Reload Window** in each window that uses Codex. |

Read in the ChatGPT app 26.928.31416 for macOS and Codex 0.159.3. The app server's Windows row is read in Codex 0.164.0 for Windows, and the ChatGPT app's Linux row in its `.deb`, `.rpm` and Arch packages 26.1021.22027 for Linux. Quitting the ChatGPT app on Windows, by hand or for a switch, has not been measured, and neither has the editor row.

After a Codex switch, Pitboard lists which of these still run. If it cannot read the process list, it warns with `sessions_unknown`.

In the app, a Codex switch while the ChatGPT app is open asks first, then quits it, switches and opens it again. [Quitting Claude or the ChatGPT app](https://docs.usepitboard.com/reference/mac-app.md#quitting-claude-or-the-chatgpt-app) says how long it waits. The command line never quits an app.

In the macOS app, **Restart App Server…** asks first, then runs `codex app-server daemon restart` in the Codex home Pitboard switched. Codex gives running work up to `shutdownGraceSeconds` in `app-server-daemon/settings.json` to finish, 60 seconds by default, then stops the server, so work it is running may be cut short. If the restart fails, the app says why and offers it again. Read in Codex 0.172.0.

The restarted server takes the app's environment, not your shell's. If Codex needs variables your shell exports, such as a proxy, run `codex app-server daemon restart` in a terminal instead.

> [!WARNING]
>
> Do not sign out in anything that ran Codex before the switch, such as `/logout` in a `codex` session or **Log Out** in the ChatGPT app. Each holds the parked login, and signing out revokes it at OpenAI: see [Why Codex logins are moved, not copied](https://docs.usepitboard.com/concepts/switching.md#why-codex-logins-are-moved-not-copied).
>
> If you did, [sign in to the old account again](https://docs.usepitboard.com/guides/sign-in-again.md), or run `pitboard enroll codex/personal --sign-in`.

## How Codex accounts differ

* Pitboard never switches Codex by itself.
* Pitboard identifies a Codex login from the login itself, without asking OpenAI. See [How Pitboard knows whose login it is](https://docs.usepitboard.com/concepts/identity.md).
* A switch asks OpenAI whether the parked login works by [reading that account's usage](https://docs.usepitboard.com/concepts/usage.md#where-the-numbers-come-from), which spends none of its limits.
* Pitboard reads the [banked resets](https://docs.usepitboard.com/guides/banked-resets.md) a Codex account holds from the same usage reading.
* A parked Codex login shows `ready` with no `good for` time, because Codex states no lifetime for its login (read in 0.154.0).
* On macOS, Pitboard passes every parked Codex login to `security` as an argument: see [Large logins on macOS](https://docs.usepitboard.com/security.md#large-logins-on-macos).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.