Delete organization from settings#1340
Draft
RhysSullivan wants to merge 5 commits into
Draft
Conversation
Admins can permanently delete their organization from Organization settings. Deletion tears down WorkOS, cancels the Autumn customer, and purges all tenant data and secrets in one transaction, then clears the caller's session. Requires re-typing the org name to confirm.
The danger-zone admin check now also requires an active membership (a pending admin invite no longer surfaces the delete control). If the local purge fails after the WorkOS org delete already succeeded, log an error so the orphaned tenant data and secrets get swept.
@effect/vitest's expect has no Playwright toBeDisabled/toBeEnabled matchers.
The success path hard-navigates and the SSR gate redirects, which aborts waitForURL; wait for the danger zone to detach instead.
The WorkOS org delete route lands in emulate 0.13.3.
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
executor-marketing | d6e890d | Commit Preview URL Branch Preview URL |
Jul 07 2026, 12:13 AM |
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
executor-cloud | d6e890d | Jul 07 2026, 12:14 AM |
Contributor
Cloudflare preview
Sign-in is Cloudflare Access (one-time PIN to an allowed email). The preview has its own database and encryption key; it is destroyed when this PR closes. |
@executor-js/cli
@executor-js/config
@executor-js/execution
@executor-js/sdk
@executor-js/plugin-file-secrets
@executor-js/plugin-graphql
@executor-js/plugin-keychain
@executor-js/plugin-mcp
@executor-js/plugin-onepassword
@executor-js/plugin-openapi
@executor-js/codemode-core
@executor-js/runtime-quickjs
executor
commit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds an admin-only way to permanently delete an organization from Organization settings.
Deleting requires re-typing the org name to confirm. It removes the org in WorkOS, cancels the Autumn customer, and purges all of the org's tenant data and secrets in one transaction, then clears the caller's session so everyone drops out of the workspace.
Proven by a new cloud e2e (
e2e/cloud/org-delete.test.ts): create org, open settings, confirm-gated delete, org torn down. Needs the WorkOS emulator's org-delete route, shipped in @executor-js/emulate 0.13.3.