Skip to content

Business operating system for Claude Code — 57 skills, 21 agents, smart daemon. Unified inbox (WhatsApp/Email/Slack/Telegram), autonomous PR merge, full-AWS monitoring, revenue (Stripe+RevenueCat), e-commerce (Shopify), marketing (Klaviyo/Meta/GA4), voice (Bland/ElevenLabs), APM (Datadog/NewRelic/OTEL), YOLO mode.

fix(rotation): prefer private accounts over teams/org; release 2.11.4 (#355)

Aurora Capital3895d1e0b892
diff --git a/.claude-plugin/marketplace.json b/.claude-plugin/marketplace.json
index a229c40d..16bd52fa 100644
--- a/.claude-plugin/marketplace.json
+++ b/.claude-plugin/marketplace.json
@@ -11,7 +11,7 @@
"name": "ops",
"description": "Business operations command center for Claude Code — 37 skills, 19 agents, smart background daemon. Manage communications (WhatsApp/Email/Slack/Telegram), projects, infrastructure (AWS), revenue (Stripe+RevenueCat), e-commerce, marketing, monitoring (Datadog/New Relic/OTEL), voice, and smart home (Homey Pro). Includes /gtm go-to-market planner, /ops:projects portfolio dashboard, /ops:ops-home control surface, and YOLO autonomous mode with 4 parallel C-suite agents.",
"source": "./claude-ops",
- "version": "2.11.2",
+ "version": "2.11.4",
"category": "productivity",
"keywords": [
"ops",
diff --git a/claude-ops/.claude-plugin/plugin.json b/claude-ops/.claude-plugin/plugin.json
index d8829952..9b6730bc 100644
--- a/claude-ops/.claude-plugin/plugin.json
+++ b/claude-ops/.claude-plugin/plugin.json
@@ -1,6 +1,6 @@
{
"name": "ops",
- "version": "2.11.3",
+ "version": "2.11.4",
"description": "Business operations command center for Claude Code — 37 skills, 19 agents, and a smart background daemon that manage communications (WhatsApp/Email/Slack/Telegram), projects, infrastructure (all AWS services), revenue (Stripe + RevenueCat), e-commerce (Shopify), marketing (Klaviyo/Meta/GA4/GSC), monitoring (Datadog/New Relic/OTEL), and voice (Bland AI/ElevenLabs/Whisper). Includes /gtm go-to-market planner, /ops:projects portfolio dashboard, YOLO mode for autonomous operation with 4 parallel C-suite agents, and /ops:ops-home smart home control via Homey Pro.",
"author": {
"name": "Lifecycle Innovations Limited",
diff --git a/claude-ops/CHANGELOG.md b/claude-ops/CHANGELOG.md
index b4c1c576..5adaa2b2 100644
--- a/claude-ops/CHANGELOG.md
+++ b/claude-ops/CHANGELOG.md
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
## [Unreleased]
+## [2.11.4] — 2026-05-27
+
+### Fixed
+
+- **Rotation prefers PRIVATE accounts over TEAMS/org accounts** — `scripts/account-rotation/rotate.mjs` account selection now treats team-ness (accounts carrying `orgName`/`orgUuid`) as the PRIMARY sort key and utilization as secondary, so a personal Max account is always chosen over an org/Teams account when viable. Org accounts route through claude.ai's org chooser + Google Workspace push-2FA, which headless browser auth cannot clear — picking one on raw utilization (e.g. a low-util Teams account) caused rotation to stall on 2FA and fail. A team account is now only ever selected when no private account is viable.
+
### Added
- **`ops-telegram-bot-send`** — lightweight bot-token push to the operator's own Telegram chat, the companion to the user-account MCP server. Reads `TELEGRAM_BOT_TOKEN` + `TELEGRAM_OWNER_ID` from env or `preferences.json .channels.telegram.*` (zero hardcoded ids, Rule 0). Default recipient is the operator; `--to <chat_id>` overrides; `OPS_DRY_RUN=1` previews without sending.
diff --git a/claude-ops/scripts/account-rotation/rotate.mjs b/claude-ops/scripts/account-rotation/rotate.mjs
index 54a6bc3c..f38f6db9 100644
--- a/claude-ops/scripts/account-rotation/rotate.mjs
+++ b/claude-ops/scripts/account-rotation/rotate.mjs
@@ -409,6 +409,21 @@ function pickNextAccount(config, state, liveUtil = {}, opts = {}) {
const excludeKey = (a) =>
a.disabled === true || accountKey(a) === activeKey || (!allowExtraUsage && hasExtraUsageEnabled(a));
+ // Prefer PRIVATE (personal) accounts over TEAMS/org accounts. Org accounts
+ // (those carrying orgName/orgUuid) route through claude.ai's org chooser and
+ // Google Workspace push-2FA, which headless browser auth cannot clear — so a
+ // team account that wins on raw utilization still fails to rotate. Treat
+ // team-ness as the PRIMARY sort key (private first), utilization secondary,
+ // so a team account is only ever picked when no private account is viable.
+ const isTeamAccount = (a) =>
+ !!(a.orgUuid || (a.orgName && String(a.orgName).toLowerCase() !== String(a.email || '').toLowerCase()));
+ const byPrivateThenScore = (a, b) => {
+ const ta = isTeamAccount(a) ? 1 : 0;
+ const tb = isTeamAccount(b) ? 1 : 0;
+ if (ta !== tb) return ta - tb; // private (0) before team (1)
+ return score(a) - score(b);
+ };
+
// Separate normal and low-priority, excluding current active + extra-usage accounts
const normal = config.accounts.filter((a) => a.priority !== 'low' && !excludeKey(a));
const low = config.accounts.filter((a) => a.priority === 'low' && !excludeKey(a));
@@ -422,8 +437,8 @@ function pickNextAccount(config, state, liveUtil = {}, opts = {}) {
for (const candidates of [fresh, exhausted]) {
const viable = candidates.filter((a) => score(a) < UTIL_HARD_BLOCK);
const blocked = candidates.filter((a) => score(a) >= UTIL_HARD_BLOCK);
- const sorted = [...viable].sort((a, b) => score(a) - score(b));
- const pool2 = sorted.length ? sorted : [...blocked].sort((a, b) => score(a) - score(b));
+ const sorted = [...viable].sort(byPrivateThenScore);
+ const pool2 = sorted.length ? sorted : [...blocked].sort(byPrivateThenScore);
if (pool2.length > 0) {
const best = pool2[0];