different-ai/openwork · warning

This deployment uses one managed organization.

Error message

This deployment uses one managed organization.

What it means

createOrganization throws this immediately when the deployment is in single-org mode (isSingleOrgMode). In such deployments the org is provisioned and managed centrally, so end users are not allowed to create additional organizations — the call is rejected client-side before any network request.

Source

Thrown at ee/apps/den-web/app/(den)/dashboard/_providers/org-dashboard-provider.tsx:421

      pendingReauthMutationsRef.current = [];
      setReauthDialogOpen(false);

      if (retryAfterReauth.length > 0) {
        pendingReauthMutationsRef.current = [
          ...retryAfterReauth,
          ...queuedDuringRetry,
        ];
        setReauthDialogOpen(true);
        return;
      }

      queuedActions = queuedDuringRetry;
    }
  }

  async function createOrganization(name: string) {
    if (isSingleOrgMode) {
      throw new Error("This deployment uses one managed organization.");
    }

    const trimmed = name.trim();
    if (!trimmed) {
      throw new Error("Enter an organization name.");
    }

    setMutationBusy("create-organization");
    setOrgError(null);
    try {
      const { response, payload } = await requestJson(
        "/v1/org",
        {
          method: "POST",
          body: JSON.stringify({ name: trimmed }),
        },
        12000,
      );

View on GitHub (pinned to 2b7df46e8a)

Solutions

  1. Hide the create-organization affordance in the UI when isSingleOrgMode is true instead of letting the user hit the guard.
  2. If org creation should be allowed, update the deployment configuration to disable single-org mode and redeploy.
  3. Catch the error in the UI and show an explanatory message ('your organization manages this setting').
  4. Route the request through the org's admins/Den control plane rather than self-serve creation.

Example fix

// before
await createOrganization("New Org"); // throws in single-org mode
// after
if (!isSingleOrgMode) {
  await createOrganization("New Org");
} else {
  showNotice("Organization creation is managed by your administrator.");
}
Defensive patterns

Strategy: validation

Validate before calling

if (isSingleOrgMode) {
  hideCreateOrganizationButton();
}

Try / catch

try {
  await createOrganization(name);
} catch (err) {
  if (String(err.message).includes("one managed organization")) {
    showManagedModeNotice();
  } else throw err;
}

Prevention

When it happens

Trigger: Calling createOrganization while the Den deployment is configured with single managed organization mode (server/config flag), regardless of the name argument.

Common situations: Users on an enterprise/managed Den instance trying the 'Create organization' UI action; a desktop client connected to a self-hosted single-tenant server; a feature flag recently flipped to single-org mode while UI still shows the create button.

Related errors


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