different-ai/openwork · error

OpenWork server unavailable. Connect to manage imported clou

Error message

OpenWork server unavailable. Connect to manage imported cloud plugins.

What it means

Same persistence guard as error 106 but for imported cloud plugins: persistImportedCloudPlugins writes the merged workspace config and throws when writeWorkspaceOpenworkConfigRecord returns false, i.e. neither the desktop local-write path nor the OpenWork server path is available. In-memory plugin state is intentionally not updated so it doesn't mask the lost write.

Source

Thrown at apps/app/src/react-app/domains/settings/state/extensions-store.ts:658

    const persisted = await writeWorkspaceOpenworkConfigRecord(nextConfig);
    if (!persisted) {
      throw new Error("OpenWork server unavailable. Connect to manage imported cloud marketplaces.");
    }
    setStateField("importedCloudMarketplaces", nextMarketplaces);
    void refreshPendingCloudPluginChanges();
  };

  const persistImportedCloudPlugins = async (nextPlugins: Record<string, CloudImportedPlugin>) => {
    const config = await readWorkspaceOpenworkConfigRecord();
    const cloudImports = readWorkspaceCloudImports(config);
    const nextCloudImports = {
      ...cloudImports,
      plugins: nextPlugins,
    };
    const nextConfig = withWorkspaceCloudImports(config, nextCloudImports);
    const persisted = await writeWorkspaceOpenworkConfigRecord(nextConfig);
    if (!persisted) {
      throw new Error("OpenWork server unavailable. Connect to manage imported cloud plugins.");
    }
    setStateField("importedCloudPlugins", nextPlugins);
    void refreshPendingCloudPluginChanges(nextPlugins);
  };

  const findCloudMarketplace = (marketplaceId: string) =>
    snapshot.cloudOrgMarketplaces.find((entry) => entry.marketplace.id === marketplaceId)?.marketplace ?? null;

  const buildCloudSkillContent = (name: string, description: string, body: string) => {
    const safeDescription = description.replace(/\s+/g, " ").trim();
    const normalizedBody = body.replace(/^\s*\n?/, "");
    return [
      "---",
      `name: ${JSON.stringify(name)}`,
      `description: ${JSON.stringify(safeDescription)}`,
      "---",
      "",
      normalizedBody,

View on GitHub (pinned to 2b7df46e8a)

Solutions

  1. Connect to the OpenWork server and retry the plugin import.
  2. Check the server endpoint is reachable (network, VPN, correct URL).
  3. On desktop, confirm a local workspace is open so the .opencode file write path can be used.
  4. Re-authenticate if the session token expired.

Example fix

// before
const persisted = await writeWorkspaceOpenworkConfigRecord(nextConfig);
if (!persisted) {
  throw new Error("OpenWork server unavailable. Connect to manage imported cloud plugins.");
}
// after
const persisted = await writeWorkspaceOpenworkConfigRecord(nextConfig);
if (!persisted) {
  const connected = await ensureServerConnected();
  if (!connected) throw new Error("OpenWork server unavailable. Connect to manage imported cloud plugins.");
  return persistImportedCloudPlugins(nextPlugins); // retry after connect
}
Defensive patterns

Strategy: validation

Validate before calling

if (!canUseOpenworkServer && !(isDesktopRuntime() && workspaceRoot)) {
  // cannot persist cloud plugins; prompt for server connection first
  return;
}

Try / catch

try {
  await importCloudPlugin(plugin);
} catch (err) {
  if (err.message.includes("server unavailable")) openServerConnectDialog();
  else throw err;
}

Prevention

When it happens

Trigger: Importing or updating cloud plugins while no persistence target exists: server unreachable/not connected and (non-desktop runtime, or desktop with no local workspace root).

Common situations: Signed-out session; Den/openwork-server down; plugin import attempted from a remote workspace without server connection; desktop app running without a detected workspace root.

Related errors


AI-assisted analysis of different-ai/openwork@2b7df46e8a (2026-09-01). Data as JSON: /api/errors/557e8873a307b376. Report an issue: GitHub.