Skip to content

Open-source Grok Bot alternative with a virtual machine that bots can use

Composio: only a server with one person takes over an earlier install's apps

milind-soni4528a112c347
diff --git a/docs/composio.md b/docs/composio.md
index d4978dd8ef..d9959da7bc 100644
--- a/docs/composio.md
+++ b/docs/composio.md
@@ -76,7 +76,7 @@ COMPOSIO_API_KEY=ak_your_project_key pnpm dev:server
The browser-only development UI can also save a key to the owner-only `~/.openmausbot/config.json` file. Using the environment variable is preferred for headless and shared development machines.
-OpenMausBot creates a stable random user identifier for the installation, stores the returned Session identifier, and reuses that Session across launches. A fresh personal installation that connects a project key uses the Composio user of an earlier OpenMausBot installation in that project when there is exactly one such user and it still has a live connection, so the apps connected there come back after a reinstall or on another computer. A Team Cloud never does this and does not even list the project's accounts, because every member's bots would then get that person's apps. No Gmail, GitHub, Slack, or other provider tokens are stored by OpenMausBot; Composio owns their connection lifecycle.
+OpenMausBot creates a stable random user identifier for the installation, stores the returned Session identifier, and reuses that Session across launches. A fresh personal installation that connects a project key uses the Composio user of an earlier OpenMausBot installation in that project when there is exactly one such user and it still has a live connection, so the apps connected there come back after a reinstall or on another computer. A Team Cloud, or a self-hosted server several people sign in to, never does this and does not even list the project's accounts, because every member's bots would then get that person's apps. No Gmail, GitHub, Slack, or other provider tokens are stored by OpenMausBot; Composio owns their connection lifecycle.
Sessions created by older OpenMausBot versions are upgraded in place by creating a multi-account Session for the same stable Composio user. Connected accounts belong to that user, so existing grants remain available while the new Session adds explicit multi-account routing. Each toolkit is capped at five usable accounts.
diff --git a/server/composio-reuse.test.ts b/server/composio-reuse.test.ts
index 9e2c48d227..f37ccf3bd4 100644
--- a/server/composio-reuse.test.ts
+++ b/server/composio-reuse.test.ts
@@ -1,5 +1,5 @@
// A fresh personal installation that connects a Composio project an earlier installation used picks up that installation's
-// Composio user, so the apps connected there come back without connecting each one again. A Team Cloud never looks.
+// Composio user, so the apps connected there come back without connecting each one again. A server several people share never looks.
import { createServer, type Server } from "node:http";
import { afterAll, beforeAll, beforeEach, describe, expect, it } from "vitest";
@@ -131,11 +131,11 @@ describe("who may look for an earlier installation's user", () => {
const earlier = () => { accounts = [account("openmausbot_earlier", "gmail"), account("openmausbot_earlier", "slack")]; };
// Composio refuses the Session, so the route answers before it saves anything.
- async function saveKeyThroughConfigRoute(teamCloud: boolean) {
+ async function saveKeyThroughConfigRoute(shared: boolean) {
sessionsRefused = true;
const replies: Array<{ status: number; body: unknown }> = [];
const deps = {
- teamCloud,
+ sharedMembership: () => shared,
cfg: {},
hostedModels: false,
cloudHome: false,
@@ -165,7 +165,7 @@ describe("who may look for an earlier installation's user", () => {
expect(accountQueries).toEqual([]);
});
- it("makes no account listing on a Team Cloud, and starts a new user", async () => {
+ it("makes no account listing on a server several people share, and starts a new user", async () => {
earlier();
const replies = await saveKeyThroughConfigRoute(true);
expect(replies.map((reply) => reply.status)).toEqual([400]);
diff --git a/server/index.ts b/server/index.ts
index adb892452a..2c338b9781 100644
--- a/server/index.ts
+++ b/server/index.ts
@@ -12392,7 +12392,7 @@ const postiz = createPostiz({ cfg: () => cfg, mcpOAuth, persistMcpServers: persi
store, cfg, registry, sessions, browserCleanup, browserLive, browserRuntime, usedBrowserSessions, decider,
sharedComputers, sharedComputerControl, closeBrowser, browserEngineSwitched,
hostedModels: Boolean(hostedModels),
- cloudHome: Boolean(CLOUD_HOME), teamCloud: CLOUD_TEAM !== null,
+ cloudHome: Boolean(CLOUD_HOME), sharedMembership,
lendingEnabled: () => lendingEnabled() || ownerLends(), providerConfigs, localVmIdleMs, localVmIdles, localVmActiveThreads, localVmLifecycleBusy,
localVmImageBusy: { get: () => localVmImageBusy },
localVmModeChangeBusy: { set: (busy) => { localVmModeChangeBusy = busy; } },
diff --git a/server/routes/config.ts b/server/routes/config.ts
index 07abb6a270..23d84fc554 100644
--- a/server/routes/config.ts
+++ b/server/routes/config.ts
@@ -74,7 +74,7 @@ export interface ConfigRouteDeps {
hostedModels: boolean;
cloudHome: boolean;
/** Security: a Team Cloud never takes over another installation's Composio user, since every member's bots would then get that person's apps. */
- teamCloud: boolean;
+ sharedMembership: () => boolean;
lendingEnabled(): boolean;
providerConfigs(): InstanceConfigMap;
localVmIdleMs(): number;
@@ -109,7 +109,7 @@ export interface ConfigRouteDeps {
export function createConfigRoutes(deps: ConfigRouteDeps): RouteHandler {
const {
store, cfg, registry, sessions, browserCleanup, browserLive, browserRuntime, usedBrowserSessions, decider,
- closeBrowser, browserEngineSwitched, sharedComputers, sharedComputerControl, hostedModels, cloudHome: CLOUD_HOME, teamCloud, lendingEnabled, providerConfigs,
+ closeBrowser, browserEngineSwitched, sharedComputers, sharedComputerControl, hostedModels, cloudHome: CLOUD_HOME, sharedMembership, lendingEnabled, providerConfigs,
localVmIdleMs, localVmIdles, localVmActiveThreads, localVmLifecycleBusy, localVmImageBusy, localVmModeChangeBusy,
providerConfigBusy, computerProviderConfigTransitions, managedBoatOwners, providerOperationConflict,
perBotLocalVmCountForModeChange, checkedModelSelection, policyModelRefusal, browserSessionSpec, configStatus,
@@ -360,7 +360,7 @@ export function createConfigRoutes(deps: ConfigRouteDeps): RouteHandler {
if (requestedComposioKey !== undefined) {
if (requestedComposioKey.trim()) {
try {
- const prepared = await composio.prepareProjectSession(requestedComposioKey, cfg.composio, undefined, { reuseEarlierUser: !teamCloud });
+ const prepared = await composio.prepareProjectSession(requestedComposioKey, cfg.composio, undefined, { reuseEarlierUser: !sharedMembership() });
patch.composio = { ...patch.composio, ...prepared };
} catch (error) {
return json(res, 400, { error: error instanceof Error ? error.message : String(error) });