Offboarding convenience — remove a user from this workspace and the descendants you can reach
Overview
useRemoveWorkspaceMemberFromSubtree returns a callable that removes a user’s direct memberships on this workspace and every descendant you can reach, in one action. Each deletion fires workspace.member.removed.Authorization: capability-gated + rank-bounded, evaluated per node. Requires remove-member, and the sweep is refused if you are outranked by the target at any node where you both hold a direct member row. An owner (or ancestor owner) reaches the whole subtree via the god-path; a non-owner only reaches descendants through an unbroken open inherit chain, so a sealed sub-workspace (inheritsFromParent = false) is left untouched for a non-owner.
A non-owner’s sweep may be partial — check skipped before you call someone offboarded. If the target still holds a membership in a descendant you cannot reach, it comes back in skippedCount / skipped instead of being removed. removedCount alone does not mean the user is gone from the subtree. An owner or ancestor owner always gets skippedCount: 0.
Owned workspaces block, they do not cascade. Because an owner is not a member of what they own, this sweep cannot offboard the target from a workspace they own. If they own this workspace or any descendant the call fails with 409 workspace/owns-descendants and nothing is removed. A workspace you have standing on always counts. One you have no standing on (for example a sealed sub-workspace) counts only when the target holds a membership this call would remove; it is then listed without an id or name. An owner of each workspace (or an ancestor owner) reassigns it via useTransferWorkspaceOwnership or deletes it, then retry.
Usage Example
import { useRemoveWorkspaceMemberFromSubtree } from "@sublay/react-js";function OffboardButton({ workspaceId, targetUserId,}: { workspaceId: string; targetUserId: string;}) { const removeWorkspaceMemberFromSubtree = useRemoveWorkspaceMemberFromSubtree(); const offboard = async () => { const { removedCount, removed, skippedCount, skipped } = await removeWorkspaceMemberFromSubtree({ workspaceId, targetUserId }); console.log(`Removed from ${removedCount} workspaces`, removed); // Do NOT treat the user as offboarded on `removedCount` alone. if (skippedCount > 0) { const named = skipped.filter((w) => w.id !== null); console.warn( `Still a member of ${skippedCount} workspace(s) you cannot reach` + (named.length ? `: ${named.map((w) => w.name).join(", ")}` : ` (identities withheld — ask an owner of those branches)`) ); } };}
Parameters
string
required
The workspace UUID — the subtree root.
string
required
The target user to offboard — a path param, not an acting user.
Returns
Field
Type
Description
removedCount
number
How many membership rows were torn down.
removed
{ workspaceId: string; userId: string }[]
One entry per removed membership.
skippedCount
number
How many memberships the target retained because your authority did not reach them. 0 for an owner or ancestor owner. Equals skipped.length.
Each entry names a descendant where the target is still a member after this call.
id / name are null when you have no standing on that workspace. The call tells you a membership survived without disclosing the existence or name of a sealed sub-workspace you have no authority over — the same sealing fence useFetchWorkspaceMembers applies to include=descendants. Escalate to an owner or ancestor owner of that branch.
reason is currently always "out-of-reach".
Only descendants where the target actually still holds a direct membership are listed — unreachable descendants they were never in are never disclosed.
Reading the owned-workspaces block
The 409 body carries ownedWorkspaces: { id: string | null; name: string | null }[] and ownedCount: number (the number of entries in ownedWorkspaces). Entries for workspaces you have standing on carry id and name and are always reported. Owned workspaces you have no standing on are reported as { id: null, name: null }, and only when the target holds a membership this call would remove; otherwise they are left out. Named entries come first, in tree order, then the anonymous ones. Only an owner can transfer ownership, so anonymous entries mean you need an owner of this workspace to resolve them.
try { await removeWorkspaceMemberFromSubtree({ workspaceId, targetUserId });} catch (err) { // `SublayError` is exported by @sublay/react-js. The 409's extra fields are // on its `body`. if (err instanceof SublayError && err.code === "workspace/owns-descendants") { const body = err.body as { ownedWorkspaces: { id: string | null; name: string | null }[]; ownedCount: number; }; const named = body.ownedWorkspaces.filter((w: any) => w.id !== null); const hidden = body.ownedCount - named.length; console.warn( `Owns ${body.ownedCount} workspace(s)` + (named.length ? `: ${named.map((w: any) => w.name).join(", ")}` : "") + (hidden ? ` (${hidden} you can't see — ask an owner)` : "") ); }}
Error codes
Code
Status
Meaning
workspace/owns-descendants
409
The target owns this workspace or a descendant (see below for when one you can’t see counts). Nothing was removed. See Reading the owned-workspaces block.
workspace/insufficient-rank
403
You are outranked by the target at some node in the sweep.
workspace/forbidden
403
You can see the workspace but lack the remove-member capability.
workspace/not-found
404
No such workspace, or you have no relation to it (answered alike).
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Sublay Documentation","colors":{"primary":"#D22F55","light":"#F06789","dark":"#9E1E3E"},"logo":{"light":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-dark.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=b95cabb32c98884aa4bca294b07238cc","dark":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-light.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=871e10ec08b164c26f260e845b44c5c5"},"favicon":"https://mintcdn.com/replyke/v1bBipIMITFr7df3/favicon.svg?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=4988ad1acfb2c3909d214fd1ea72e5d8","api":{"playground":{"display":"none"},"mdx":{"auth":{"method":"bearer"},"server":"https://api.sublay.io"}},"navbar":{"links":[{"href":"https://dash.sublay.io","label":"Dashboard"}]},"footer":{"socials":{"github":"https://github.com/sublay-io"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"replyke","hasAudioNarration":false,"actualSubdomain":"replyke","customDomains":["docs.sublay.io"],"gitSource":{"type":"github","owner":"sublay-io","repo":"monorepo","deployBranch":"v8","contentDirectory":"docs","isPrivate":false,"mountPath":"","label":""},"entitlements":{},"buildId":"6b0c04a2f26c07143e91bd0b","clientVersion":"0.0.4347","searchFilterCounts":[{"language":"default","tag":"API Reference","count":522},{"language":"default","tag":"Hooks Reference","count":487},{"language":"default","tag":"SDK Reference","count":145},{"language":"default","tag":"Components","count":92},{"language":"default","tag":"Modules","count":84},{"language":"default","tag":"Spaces","count":68},{"language":"default","tag":"Data Models","count":55},{"language":"default","tag":"Models","count":55},{"language":"default","tag":"Workspaces","count":50},{"language":"default","tag":"JS SDK","count":44}]},"assistantConfig":{"enableStarterQuestions":false},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"site-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[]}
{"page":{"pagePath":"v8/hooks/workspaces/use-remove-workspace-member-from-subtree","slug":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree","pageMetadata":{"title":"Remove workspace member from subtree","description":"Offboarding convenience — remove a user from this workspace and the descendants you can reach","icon":"plug","href":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Offboarding convenience — remove a user from this workspace and the descendants you can reach\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,em:`em`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,ParamField,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`overview`,children:`Overview`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`useRemoveWorkspaceMemberFromSubtree`}),` returns a callable that removes a user’s `,_jsx(_components.strong,{children:`direct`}),` memberships on this workspace and every descendant `,_jsx(_components.strong,{children:`you can reach`}),`, in one action. Each deletion fires `,_jsx(_components.code,{children:`workspace.member.removed`}),`.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Authorization:`}),` capability-gated + rank-bounded, evaluated `,_jsx(_components.strong,{children:`per node`}),`. Requires `,_jsx(_components.code,{children:`remove-member`}),`, and the sweep is refused if you are outranked by the target at any node where you both hold a direct member row. An `,_jsx(_components.strong,{children:`owner`}),` (or ancestor owner) reaches the whole subtree via the god-path; a `,_jsx(_components.strong,{children:`non-owner`}),` only reaches descendants through an unbroken open inherit chain, so a `,_jsx(_components.strong,{children:`sealed`}),` sub-workspace (`,_jsx(_components.code,{children:`inheritsFromParent = false`}),`) is left untouched for a non-owner.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsxs(_components.strong,{children:[`A non-owner’s sweep may be partial — check `,_jsx(_components.code,{children:`skipped`}),` before you call someone offboarded.`]}),` If the target still holds a membership in a descendant you cannot reach, it comes back in `,_jsx(_components.code,{children:`skippedCount`}),` / `,_jsx(_components.code,{children:`skipped`}),` instead of being removed. `,_jsx(_components.code,{children:`removedCount`}),` alone does `,_jsx(_components.strong,{children:`not`}),` mean the user is gone from the subtree. An owner or ancestor owner always gets `,_jsx(_components.code,{children:`skippedCount: 0`}),`.`]})}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Owned workspaces block, they do not cascade.`}),` Because an owner is not a member of what they own, this sweep cannot offboard the target from a workspace they `,_jsx(_components.em,{children:`own`}),`. If they own this workspace or any descendant the call fails with `,_jsx(_components.code,{children:`409 workspace/owns-descendants`}),` and nothing is removed. A workspace you have standing on always counts. One you have no standing on (for example a sealed sub-workspace) counts only when the target holds a membership this call would remove; it is then listed without an id or name. An owner of each workspace (or an ancestor owner) reassigns it via `,_jsx(_components.a,{href:`/v8/hooks/workspaces/use-transfer-workspace-ownership`,children:_jsx(_components.code,{children:`useTransferWorkspaceOwnership`})}),` or deletes it, then retry.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`usage-example`,children:`Usage Example`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`30`,language:`tsx`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`tsx`,children:_jsxs(_components.code,{language:`tsx`,numberOfLines:`30`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`useRemoveWorkspaceMemberFromSubtree`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"@sublay/react-js\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` OffboardButton`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` workspaceId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` targetUserId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` workspaceId`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` string`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` targetUserId`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` string`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}) {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` removeWorkspaceMemberFromSubtree`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` useRemoveWorkspaceMemberFromSubtree`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` offboard`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` async`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` () `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`removedCount`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`removed`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`skippedCount`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`skipped`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` removeWorkspaceMemberFromSubtree`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`workspaceId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`targetUserId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` console`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`log`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`Removed from \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`removedCount`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" workspaces`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`removed`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:\" // Do NOT treat the user as offboarded on `removedCount` alone.\"})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`skippedCount`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` >`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` named`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` skipped`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`filter`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`w`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` w`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`id`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` !==`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` console`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`warn`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `Still a member of \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`skippedCount`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" workspace(s) you cannot reach`\"}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` +`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`named`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`length`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ?`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `: \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`named`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`map`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`w`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` w`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`).`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`join`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\", \"`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`\"})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" ` (identities withheld — ask an owner of those branches)`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` );`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` };`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`parameters`,children:`Parameters`}),`\n`,_jsx(ParamField,{path:`workspaceId`,type:`string`,required:true,id:`param-workspace-id`,children:_jsx(_components.p,{children:`The workspace UUID — the subtree root.`})}),`\n`,_jsx(ParamField,{path:`targetUserId`,type:`string`,required:true,id:`param-target-user-id`,children:_jsxs(_components.p,{children:[`The `,_jsx(_components.strong,{children:`target`}),` user to offboard — a path param, not an acting user.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`returns`,children:`Returns`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Field`}),_jsx(_components.th,{children:`Type`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`removedCount`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`number`})}),_jsx(_components.td,{children:`How many membership rows were torn down.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`removed`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`{ workspaceId: string; userId: string }[]`})}),_jsx(_components.td,{children:`One entry per removed membership.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`skippedCount`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`number`})}),_jsxs(_components.td,{children:[`How many memberships the target `,_jsx(_components.strong,{children:`retained`}),` because your authority did not reach them. `,_jsx(_components.code,{children:`0`}),` for an owner or ancestor owner. Equals `,_jsx(_components.code,{children:`skipped.length`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`skipped`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`{ id: string | null; name: string | null; reason: \"out-of-reach\" }[]`})}),_jsx(_components.td,{children:`One entry per retained membership.`})]})]})]}),`\n`,_jsxs(Heading,{level:`3`,id:`reading-skipped`,children:[`Reading `,_jsx(_components.code,{children:`skipped`})]}),`\n`,_jsxs(_components.p,{children:[`Each entry names a descendant where the target is `,_jsx(_components.strong,{children:`still a member`}),` after this call.`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`id`}),` / `,_jsx(_components.code,{children:`name`}),` are `,_jsx(_components.code,{children:`null`}),` when you have no standing on that workspace. The call tells you a membership survived without disclosing the existence or name of a sealed sub-workspace you have no authority over — the same sealing fence `,_jsx(_components.a,{href:`/v8/hooks/workspaces/use-fetch-workspace-members`,children:_jsx(_components.code,{children:`useFetchWorkspaceMembers`})}),` applies to `,_jsx(_components.code,{children:`include=descendants`}),`. Escalate to an owner or ancestor owner of that branch.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`reason`}),` is currently always `,_jsx(_components.code,{children:`\"out-of-reach\"`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Only descendants where the target `,_jsx(_components.strong,{children:`actually still holds a direct membership`}),` are listed — unreachable descendants they were never in are never disclosed.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`3`,id:`reading-the-owned-workspaces-block`,children:`Reading the owned-workspaces block`}),`\n`,_jsxs(_components.p,{children:[`The 409 body carries `,_jsx(_components.code,{children:`ownedWorkspaces: { id: string | null; name: string | null }[]`}),` and `,_jsx(_components.code,{children:`ownedCount: number`}),` (the number of entries in `,_jsx(_components.code,{children:`ownedWorkspaces`}),`). Entries for workspaces you have standing on carry `,_jsx(_components.code,{children:`id`}),` and `,_jsx(_components.code,{children:`name`}),` and are always reported. Owned workspaces you have no standing on are reported as `,_jsx(_components.code,{children:`{ id: null, name: null }`}),`, and only when the target holds a membership this call would remove; otherwise they are left out. Named entries come first, in tree order, then the anonymous ones. Only an owner can transfer ownership, so anonymous entries mean you need an owner of this workspace to resolve them.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`tsx`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`tsx`,children:_jsxs(_components.code,{language:`tsx`,numberOfLines:`19`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`try`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` removeWorkspaceMemberFromSubtree`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`workspaceId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`targetUserId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`} `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`catch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:\" // `SublayError` is exported by @sublay/react-js. The 409's extra fields are\"})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:\" // on its `body`.\"})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` instanceof`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` SublayError`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026\u0026`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` err`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`code`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ===`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"workspace/owns-descendants\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` body`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` err`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`body`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` as`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` ownedWorkspaces`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`id`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` string`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` |`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`; `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`name`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` string`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` |`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }[];`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` ownedCount`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` number`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` };`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` named`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` body`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ownedWorkspaces`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`filter`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`w`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` any`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` w`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`id`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` !==`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` hidden`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` body`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ownedCount`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` -`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` named`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`length`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` console`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`warn`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `Owns \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`body`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`ownedCount`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" workspace(s)`\"}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` +`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`named`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`length`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ?`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" `: \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`named`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`map`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`w`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` any`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` w`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`name`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`).`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`join`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\", \"`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`\"}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`+`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`hidden`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ?`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" ` (\"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`hidden`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\" you can't see — ask an owner)`\"}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` );`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`error-codes`,children:`Error codes`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Code`}),_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Meaning`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`workspace/owns-descendants`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:`409`}),_jsxs(_components.td,{children:[`The target owns this workspace or a descendant (see below for when one you can’t see counts). Nothing was removed. See `,_jsx(_components.a,{href:`#reading-the-owned-workspaces-block`,children:`Reading the owned-workspaces block`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`workspace/insufficient-rank`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:`403`}),_jsx(_components.td,{children:`You are outranked by the target at some node in the sweep.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`workspace/forbidden`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:`403`}),_jsxs(_components.td,{children:[`You can see the workspace but lack the `,_jsx(_components.code,{children:`remove-member`}),` capability.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`workspace/not-found`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:`404`}),_jsx(_components.td,{children:`No such workspace, or you have no relation to it (answered alike).`})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`related`,children:`Related`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.a,{href:`/v8/hooks/workspaces/use-remove-workspace-member`,children:_jsx(_components.code,{children:`useRemoveWorkspaceMember`})}),` — this node only`]}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/v8/api-reference/workspaces/members/remove-from-subtree`,children:`Remove From Subtree API`})}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Remove workspace member from subtree","description":"Offboarding convenience — remove a user from this workspace and the descendants you can reach","icon":"plug","href":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Overview","slug":"overview","depth":2,"children":[]},{"title":"Usage Example","slug":"usage-example","depth":2,"children":[]},{"title":"Parameters","slug":"parameters","depth":2,"children":[]},{"title":"Returns","slug":"returns","depth":2,"children":[{"title":"Reading skipped","slug":"reading-skipped","depth":3,"children":[]},{"title":"Reading the owned-workspaces block","slug":"reading-the-owned-workspaces-block","depth":3,"children":[]}]},{"title":"Error codes","slug":"error-codes","depth":2,"children":[]},{"title":"Related","slug":"related","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"replyke","siteName":"Sublay Documentation","title":"Remove workspace member from subtree - Sublay Documentation","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{"8.0.0":{"href":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree","matchLevel":0},"7.0.0":{"href":"/v7/hooks/workspaces/use-remove-workspace-member-from-subtree","matchLevel":1},"6.0.0":{"href":"/v6","matchLevel":4}},"firstHrefInLanguage":{}},"lastModified":"2026-11-26T14:39:40.489Z","originalFileLocation":"v8/hooks/workspaces/use-remove-workspace-member-from-subtree.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Offboarding convenience — remove a user from this workspace and the descendants you can reach\">\u003cmeta data-mint-head name=\"application-name\" content=\"Sublay Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Remove workspace member from subtree - Sublay Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Offboarding convenience — remove a user from this workspace and the descendants you can reach\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Sublay Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://replyke.mintlify.site/_mintlify/api/og/v2?division=Workspaces\u0026amp;title=Remove+workspace+member+from+subtree\u0026amp;description=Offboarding+convenience+%E2%80%94+remove+a+user+from+this+workspace+and+the+descendants+you+can+reach\u0026amp;theme=1f560c5aaf3e1f0507c7e36a\u0026amp;signature=ea83e4a6592303cd499a9c894d10885d945f287546d58612361254482cfafb88\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Remove workspace member from subtree - Sublay Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Offboarding convenience — remove a user from this workspace and the descendants you can reach\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://replyke.mintlify.site/_mintlify/api/og/v2?division=Workspaces\u0026amp;title=Remove+workspace+member+from+subtree\u0026amp;description=Offboarding+convenience+%E2%80%94+remove+a+user+from+this+workspace+and+the+descendants+you+can+reach\u0026amp;theme=1f560c5aaf3e1f0507c7e36a\u0026amp;signature=ea83e4a6592303cd499a9c894d10885d945f287546d58612361254482cfafb88\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/replyke/a1LNRWO56FGzWHgw/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Sublay Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#D22F55\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.sublay.io/#organization\",\"name\":\"Sublay Documentation\",\"url\":\"https://docs.sublay.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/replyke/v1bBipIMITFr7df3/logo/wordmark-dark.png?fit=max\u0026auto=format\u0026n=v1bBipIMITFr7df3\u0026q=85\u0026s=b95cabb32c98884aa4bca294b07238cc\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.sublay.io#website\",\"name\":\"Sublay Documentation\",\"url\":\"https://docs.sublay.io\",\"publisher\":{\"@id\":\"https://docs.sublay.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree#webpage\",\"url\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree\",\"name\":\"Remove workspace member from subtree\",\"description\":\"Offboarding convenience — remove a user from this workspace and the descendants you can reach\",\"dateModified\":\"2026-11-26T14:39:40.489Z\",\"isPartOf\":{\"@id\":\"https://docs.sublay.io#website\"},\"breadcrumb\":{\"@id\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Workspaces\",\"item\":\"https://docs.sublay.io/v8/hooks/workspaces/use-create-workspace\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Remove workspace member from subtree\",\"item\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree#article\",\"headline\":\"Remove workspace member from subtree\",\"name\":\"Remove workspace member from subtree\",\"description\":\"Offboarding convenience — remove a user from this workspace and the descendants you can reach\",\"url\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree\",\"mainEntityOfPage\":{\"@id\":\"https://docs.sublay.io/v8/hooks/workspaces/use-remove-workspace-member-from-subtree#webpage\"},\"dateModified\":\"2026-11-26T14:39:40.489Z\",\"publisher\":{\"@id\":\"https://docs.sublay.io/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.sublay.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Sublay Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Sublay Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree.md","siteName":"Sublay Documentation","nav":{"global":null,"versions":[{"version":"8.0.0","tag":"Beta","tabs":[{"tab":"Overview","pages":[{"title":"Overview","href":"/v8"}]},{"tab":"SDK Reference","pages":[{"title":"SDK Reference","href":"/v8/sdk/getting-started"}]},{"tab":"Hooks Reference","groups":[{"group":"Overview","pages":[{"title":"Hooks Reference","href":"/v8/hooks/overview"}]},{"group":"Auth Hooks","pages":[{"title":"Use auth","icon":"cube","href":"/v8/hooks/auth/use-auth"},{"title":"Use accounts","icon":"cube","href":"/v8/hooks/auth/use-accounts"},{"title":"Add account","icon":"plug","href":"/v8/hooks/auth/use-add-account"},{"title":"Remove account","icon":"plug","href":"/v8/hooks/auth/use-remove-account"},{"title":"Switch account","icon":"plug","href":"/v8/hooks/auth/use-switch-account"},{"title":"Sign out all","icon":"plug","href":"/v8/hooks/auth/use-sign-out-all"},{"title":"Fetch OAuth identities","icon":"plug","href":"/v8/hooks/auth/use-oauth-identities"},{"title":"Use OAuth sign-in","icon":"cube","href":"/v8/hooks/auth/use-oauth-sign-in"},{"title":"Request password reset","icon":"plug","href":"/v8/hooks/auth/use-request-password-reset"},{"title":"Send verification email","icon":"plug","href":"/v8/hooks/auth/use-send-verification-email"},{"title":"Verify email","icon":"plug","href":"/v8/hooks/auth/use-verify-email"},{"title":"Request account deletion","icon":"plug","href":"/v8/hooks/auth/use-request-account-deletion"},{"title":"Confirm account deletion","icon":"plug","href":"/v8/hooks/auth/use-confirm-account-deletion"}]},{"group":"Current User","pages":[{"title":"Use user","icon":"cube","href":"/v8/hooks/user/use-user"},{"title":"Use user actions","icon":"cube","href":"/v8/hooks/user/use-user-actions"}]},{"group":"User Profiles","pages":[{"title":"Fetch user","icon":"plug","href":"/v8/hooks/users/use-fetch-user"},{"title":"Fetch user by foreign ID","icon":"plug","href":"/v8/hooks/users/use-fetch-user-by-foreign-id"},{"title":"Fetch user by username","icon":"plug","href":"/v8/hooks/users/use-fetch-user-by-username"},{"title":"Fetch user suggestions","icon":"plug","href":"/v8/hooks/users/use-fetch-user-suggestions"},{"title":"Check username availability","icon":"plug","href":"/v8/hooks/users/use-check-username-availability"},{"title":"Use user mentions","icon":"cube","href":"/v8/hooks/users/use-user-mentions"}]},{"group":"Entities","pages":[{"title":"Use entity","icon":"cube","href":"/v8/hooks/entities/use-entity"},{"title":"Fetch entity","icon":"plug","href":"/v8/hooks/entities/use-fetch-entity"},{"title":"Fetch entity by foreign ID","icon":"plug","href":"/v8/hooks/entities/use-fetch-entity-by-foreign-id"},{"title":"Fetch or create entity by foreign ID","icon":"plug","href":"/v8/hooks/entities/use-fetch-or-create-entity-by-foreign-id"},{"title":"Fetch entity by short ID","icon":"plug","href":"/v8/hooks/entities/use-fetch-entity-by-short-id"},{"title":"Fetch many entities","icon":"plug","href":"/v8/hooks/entities/use-fetch-many-entities"},{"title":"Use entities","icon":"cube","href":"/v8/hooks/entities/use-fetch-many-entities-wrapper"},{"title":"Create entity","icon":"plug","href":"/v8/hooks/entities/use-create-entity"},{"title":"Update entity","icon":"plug","href":"/v8/hooks/entities/use-update-entity"},{"title":"Delete entity","icon":"plug","href":"/v8/hooks/entities/use-delete-entity"},{"title":"Fetch drafts","icon":"plug","href":"/v8/hooks/entities/use-fetch-drafts"},{"title":"Publish draft","icon":"plug","href":"/v8/hooks/entities/use-publish-draft"}]},{"group":"Entity Lists","pages":[{"title":"Use entity list","icon":"cube","href":"/v8/hooks/entity-lists/use-entity-list"},{"title":"Use entity list actions","icon":"cube","href":"/v8/hooks/entity-lists/use-entity-list-actions"},{"title":"Use infused data","icon":"cube","href":"/v8/hooks/entity-lists/use-infused-data"}]},{"group":"Spaces","pages":[{"title":"Use space","icon":"cube","href":"/v8/hooks/spaces/use-space"},{"title":"Fetch space","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space"},{"title":"Fetch space by short ID","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space-by-short-id"},{"title":"Fetch space by slug","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space-by-slug"},{"title":"Fetch many spaces","icon":"plug","href":"/v8/hooks/spaces/use-fetch-many-spaces"},{"title":"Fetch my spaces","icon":"plug","href":"/v8/hooks/spaces/use-fetch-my-spaces"},{"title":"Fetch mutual spaces","icon":"plug","href":"/v8/hooks/spaces/use-fetch-mutual-spaces"},{"title":"Fetch space breadcrumb","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space-breadcrumb"},{"title":"Fetch space members","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space-members"},{"title":"Fetch space team","icon":"plug","href":"/v8/hooks/spaces/use-fetch-space-team"},{"title":"Check my membership","icon":"plug","href":"/v8/hooks/spaces/use-check-my-membership"},{"title":"Check slug availability","icon":"plug","href":"/v8/hooks/spaces/use-check-slug-availability"},{"title":"Create space","icon":"plug","href":"/v8/hooks/spaces/use-create-space"},{"title":"Update space","icon":"plug","href":"/v8/hooks/spaces/use-update-space"},{"title":"Delete space","icon":"plug","href":"/v8/hooks/spaces/use-delete-space"},{"title":"Join space","icon":"plug","href":"/v8/hooks/spaces/use-join-space"},{"title":"Leave space","icon":"plug","href":"/v8/hooks/spaces/use-leave-space"},{"title":"Add member","icon":"plug","href":"/v8/hooks/spaces/use-add-member"},{"title":"Approve member","icon":"plug","href":"/v8/hooks/spaces/use-approve-member"},{"title":"Decline member","icon":"plug","href":"/v8/hooks/spaces/use-decline-member"},{"title":"Ban member","icon":"plug","href":"/v8/hooks/spaces/use-ban-member"},{"title":"Update member role","icon":"plug","href":"/v8/hooks/spaces/use-update-member-role"},{"title":"Unban member","icon":"plug","href":"/v8/hooks/spaces/use-unban-member"},{"title":"Moderate space entity","icon":"plug","href":"/v8/hooks/spaces/use-moderate-space-entity"},{"title":"Set space entity NSFW","icon":"plug","href":"/v8/hooks/spaces/use-set-space-entity-nsfw"},{"title":"Moderate space comment","icon":"plug","href":"/v8/hooks/spaces/use-moderate-space-comment"},{"title":"Use space mentions","icon":"cube","href":"/v8/hooks/spaces/use-space-mentions"},{"title":"Use space permissions","icon":"cube","href":"/v8/hooks/spaces/use-space-permissions"}]},{"group":"Spaces — Rules","pages":[{"title":"Fetch many rules","icon":"plug","href":"/v8/hooks/spaces/rules/use-fetch-many-rules"},{"title":"Fetch rule","icon":"plug","href":"/v8/hooks/spaces/rules/use-fetch-rule"},{"title":"Create rule","icon":"plug","href":"/v8/hooks/spaces/rules/use-create-rule"},{"title":"Update rule","icon":"plug","href":"/v8/hooks/spaces/rules/use-update-rule"},{"title":"Delete rule","icon":"plug","href":"/v8/hooks/spaces/rules/use-delete-rule"},{"title":"Reorder rules","icon":"plug","href":"/v8/hooks/spaces/rules/use-reorder-rules"}]},{"group":"Space Lists","pages":[{"title":"Use space list","icon":"cube","href":"/v8/hooks/space-lists/use-space-list"},{"title":"Use space list actions","icon":"cube","href":"/v8/hooks/space-lists/use-space-list-actions"}]},{"group":"Workspace Lists","pages":[{"title":"Use workspace list","icon":"cube","href":"/v8/hooks/workspace-lists/use-workspace-list"},{"title":"Use workspace list actions","icon":"cube","href":"/v8/hooks/workspace-lists/use-workspace-list-actions"}]},{"group":"Workspaces","pages":[{"title":"Create workspace","icon":"plug","href":"/v8/hooks/workspaces/use-create-workspace"},{"title":"Fetch workspace","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-workspace"},{"title":"Fetch many workspaces","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-many-workspaces"},{"title":"Fetch mutual workspaces","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-mutual-workspaces"},{"title":"Update workspace","icon":"plug","href":"/v8/hooks/workspaces/use-update-workspace"},{"title":"Update workspace inherit flag","icon":"plug","href":"/v8/hooks/workspaces/use-update-workspace-inherit-flag"},{"title":"Delete workspace","icon":"plug","href":"/v8/hooks/workspaces/use-delete-workspace"},{"title":"Transfer workspace ownership","icon":"plug","href":"/v8/hooks/workspaces/use-transfer-workspace-ownership"},{"title":"Fetch workspace members","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-workspace-members"},{"title":"Fetch workspace member standing","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-workspace-member-standing"},{"title":"Fetch my workspace membership","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-my-workspace-membership"},{"title":"Update workspace member","icon":"plug","href":"/v8/hooks/workspaces/use-update-workspace-member"},{"title":"Update my workspace membership","icon":"plug","href":"/v8/hooks/workspaces/use-update-my-workspace-membership"},{"title":"Remove workspace member","description":"Remove a member from this workspace node (rank-bounded; sole-owner protected)","icon":"plug","href":"/v8/hooks/workspaces/use-remove-workspace-member"},{"title":"Remove workspace member from subtree","icon":"plug","href":"/v8/hooks/workspaces/use-remove-workspace-member-from-subtree"},{"title":"Leave workspace","description":"Self-service departure — remove your own membership on this node","icon":"plug","href":"/v8/hooks/workspaces/use-leave-workspace"},{"title":"Create workspace invite","icon":"plug","href":"/v8/hooks/workspaces/use-create-workspace-invite"},{"title":"Fetch workspace invites","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-workspace-invites"},{"title":"Revoke workspace invite","icon":"plug","href":"/v8/hooks/workspaces/use-revoke-workspace-invite"},{"title":"Resend workspace invite","icon":"plug","href":"/v8/hooks/workspaces/use-resend-workspace-invite"},{"title":"Fetch my workspace invites","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-my-workspace-invites"},{"title":"Accept workspace invite","icon":"plug","href":"/v8/hooks/workspaces/use-accept-workspace-invite"},{"title":"Decline workspace invite","icon":"plug","href":"/v8/hooks/workspaces/use-decline-workspace-invite"},{"title":"Fetch workspace authority","icon":"plug","href":"/v8/hooks/workspaces/use-fetch-workspace-authority"}]},{"group":"Events","pages":[{"title":"useEvent \u0026 useEventData","icon":"plug","href":"/v8/hooks/events/use-event"},{"title":"useFetchEvent","icon":"plug","href":"/v8/hooks/events/use-fetch-event"},{"title":"useFetchManyEvents","icon":"plug","href":"/v8/hooks/events/use-fetch-many-events"},{"title":"useFetchManyEventsWrapper","icon":"plug","href":"/v8/hooks/events/use-fetch-many-events-wrapper"},{"title":"useCreateEvent","icon":"plug","href":"/v8/hooks/events/use-create-event"},{"title":"useUpdateEvent","icon":"plug","href":"/v8/hooks/events/use-update-event"},{"title":"useCancelEvent","icon":"plug","href":"/v8/hooks/events/use-cancel-event"},{"title":"useDeleteEvent","icon":"plug","href":"/v8/hooks/events/use-delete-event"},{"title":"useSetRsvp","icon":"plug","href":"/v8/hooks/events/use-set-rsvp"},{"title":"useWithdrawRsvp","icon":"plug","href":"/v8/hooks/events/use-withdraw-rsvp"},{"title":"useAddHost","icon":"plug","href":"/v8/hooks/events/use-add-host"},{"title":"useRemoveHost","icon":"plug","href":"/v8/hooks/events/use-remove-host"},{"title":"useAddInvite","icon":"plug","href":"/v8/hooks/events/use-add-invite"},{"title":"useRemoveInvite","icon":"plug","href":"/v8/hooks/events/use-remove-invite"},{"title":"useFetchInvitees","icon":"plug","href":"/v8/hooks/events/use-fetch-invitees"},{"title":"useFetchEventRsvps","icon":"plug","href":"/v8/hooks/events/use-fetch-event-rsvps"}]},{"group":"Comments","pages":[{"title":"Use comment section","icon":"cube","href":"/v8/hooks/comments/use-comment-section"},{"title":"Use entity comments","icon":"cube","href":"/v8/hooks/comments/use-entity-comments"},{"title":"Use replies","icon":"cube","href":"/v8/hooks/comments/use-replies"},{"title":"Create comment","icon":"plug","href":"/v8/hooks/comments/use-create-comment"},{"title":"Update comment","icon":"plug","href":"/v8/hooks/comments/use-update-comment"},{"title":"Delete comment","icon":"plug","href":"/v8/hooks/comments/use-delete-comment"},{"title":"Fetch comment","icon":"plug","href":"/v8/hooks/comments/use-fetch-comment"},{"title":"Fetch comment by foreign ID","icon":"plug","href":"/v8/hooks/comments/use-fetch-comment-by-foreign-id"},{"title":"Fetch many comments","icon":"plug","href":"/v8/hooks/comments/use-fetch-many-comments"},{"title":"Use comments","icon":"cube","href":"/v8/hooks/comments/use-fetch-many-comments-wrapper"},{"title":"Fetch comments by user","icon":"plug","href":"/v8/hooks/comments/use-fetch-comments-by-user-id"},{"title":"Use user comments","icon":"cube","href":"/v8/hooks/comments/use-fetch-comments-by-user-id-wrapper"}]},{"group":"Reactions","pages":[{"title":"Add reaction","icon":"plug","href":"/v8/hooks/reactions/use-add-reaction"},{"title":"Remove reaction","icon":"plug","href":"/v8/hooks/reactions/use-remove-reaction"},{"title":"Toggle reaction","icon":"plug","href":"/v8/hooks/reactions/use-reaction-toggle"},{"title":"Fetch entity reactions","icon":"plug","href":"/v8/hooks/reactions/use-fetch-entity-reactions"},{"title":"Use entity reactions","icon":"cube","href":"/v8/hooks/reactions/use-fetch-entity-reactions-wrapper"},{"title":"Fetch comment reactions","icon":"plug","href":"/v8/hooks/reactions/use-fetch-comment-reactions"},{"title":"Use comment reactions","icon":"cube","href":"/v8/hooks/reactions/use-fetch-comment-reactions-wrapper"}]},{"group":"Reputation","pages":[{"title":"useCreateReputationGrant","icon":"plug","href":"/v8/hooks/reputation/use-create-reputation-grant"},{"title":"useFetchManyReputationGrants","icon":"plug","href":"/v8/hooks/reputation/use-fetch-many-reputation-grants"},{"title":"useFetchManyReputationGrantsWrapper","icon":"plug","href":"/v8/hooks/reputation/use-fetch-many-reputation-grants-wrapper"}]},{"group":"Follows","pages":[{"title":"Use follow manager","icon":"cube","href":"/v8/hooks/follows/use-follow-manager"},{"title":"Follow user","icon":"plug","href":"/v8/hooks/follows/use-follow-user"},{"title":"Unfollow by follow ID","icon":"plug","href":"/v8/hooks/follows/use-unfollow-by-follow-id"},{"title":"Unfollow by user ID","icon":"plug","href":"/v8/hooks/follows/use-unfollow-user-by-user-id"},{"title":"Fetch follow status","icon":"plug","href":"/v8/hooks/follows/use-fetch-follow-status"},{"title":"Fetch followers","icon":"plug","href":"/v8/hooks/follows/use-fetch-followers"},{"title":"Fetch followers by user ID","icon":"plug","href":"/v8/hooks/follows/use-fetch-followers-by-user-id"},{"title":"Fetch followers count","icon":"plug","href":"/v8/hooks/follows/use-fetch-followers-count"},{"title":"Fetch followers count by user ID","icon":"plug","href":"/v8/hooks/follows/use-fetch-followers-count-by-user-id"},{"title":"Fetch following","icon":"plug","href":"/v8/hooks/follows/use-fetch-following"},{"title":"Fetch following by user ID","icon":"plug","href":"/v8/hooks/follows/use-fetch-following-by-user-id"},{"title":"Fetch following count","icon":"plug","href":"/v8/hooks/follows/use-fetch-following-count"},{"title":"Fetch following count by user ID","icon":"plug","href":"/v8/hooks/follows/use-fetch-following-count-by-user-id"}]},{"group":"Connections","pages":[{"title":"Use connection manager","icon":"cube","href":"/v8/hooks/connections/use-connection-manager"},{"title":"Request connection","icon":"plug","href":"/v8/hooks/connections/use-request-connection"},{"title":"Accept connection","icon":"plug","href":"/v8/hooks/connections/use-accept-connection"},{"title":"Decline connection","icon":"plug","href":"/v8/hooks/connections/use-decline-connection"},{"title":"Remove connection","icon":"plug","href":"/v8/hooks/connections/use-remove-connection"},{"title":"Remove connection by user ID","icon":"plug","href":"/v8/hooks/connections/use-remove-connection-by-user-id"},{"title":"Fetch connections","icon":"plug","href":"/v8/hooks/connections/use-fetch-connections"},{"title":"Fetch connections by user ID","icon":"plug","href":"/v8/hooks/connections/use-fetch-connections-by-user-id"},{"title":"Fetch connections count","icon":"plug","href":"/v8/hooks/connections/use-fetch-connections-count"},{"title":"Fetch connections count by user ID","icon":"plug","href":"/v8/hooks/connections/use-fetch-connections-count-by-user-id"},{"title":"Fetch connection status","icon":"plug","href":"/v8/hooks/connections/use-fetch-connection-status"},{"title":"Fetch sent pending connections","icon":"plug","href":"/v8/hooks/connections/use-fetch-sent-pending-connections"},{"title":"Fetch received pending connections","icon":"plug","href":"/v8/hooks/connections/use-fetch-received-pending-connections"}]},{"group":"Blocks","pages":[{"title":"Use block manager","icon":"cube","href":"/v8/hooks/blocks/use-block-manager"},{"title":"Use block user","icon":"plug","href":"/v8/hooks/blocks/use-block-user"},{"title":"Use unblock user","icon":"plug","href":"/v8/hooks/blocks/use-unblock-user"},{"title":"Fetch block status","icon":"plug","href":"/v8/hooks/blocks/use-fetch-block-status"},{"title":"Fetch blocked users","icon":"plug","href":"/v8/hooks/blocks/use-fetch-blocked-users"}]},{"group":"Collections","pages":[{"title":"Use collections","icon":"cube","href":"/v8/hooks/collections/use-collections"},{"title":"Use collections actions","icon":"cube","href":"/v8/hooks/collections/use-collections-actions"},{"title":"Use collection entities","icon":"cube","href":"/v8/hooks/collections/use-collection-entities-wrapper"}]},{"group":"App Notifications","pages":[{"title":"Use app notifications","icon":"cube","href":"/v8/hooks/app-notifications/use-app-notifications"}]},{"group":"Push Notifications","pages":[{"title":"usePushRegistration","icon":"cube","href":"/v8/hooks/push/use-push-registration"},{"title":"useAccountPushToggle","icon":"toggle-on","href":"/v8/hooks/push/use-account-push-toggle"},{"title":"Use notification preferences","icon":"bell-slash","href":"/v8/hooks/push/use-notification-preferences"}]},{"group":"Chat — Conversations","pages":[{"title":"Use conversations","icon":"cube","href":"/v8/hooks/chat/conversations/use-conversations"},{"title":"Use conversation","icon":"cube","href":"/v8/hooks/chat/conversations/use-conversation"},{"title":"Use fetch conversation","icon":"plug","href":"/v8/hooks/chat/conversations/use-fetch-conversation"},{"title":"Use update conversation","icon":"plug","href":"/v8/hooks/chat/conversations/use-update-conversation"},{"title":"Use delete conversation","icon":"plug","href":"/v8/hooks/chat/conversations/use-delete-conversation"},{"title":"Create direct conversation","icon":"plug","href":"/v8/hooks/chat/conversations/use-create-direct-conversation"},{"title":"Use conversation members","icon":"cube","href":"/v8/hooks/chat/conversations/use-conversation-members"},{"title":"Check my conversation membership","icon":"plug","href":"/v8/hooks/chat/conversations/use-check-my-conversation-membership"},{"title":"Fetch space conversation","icon":"plug","href":"/v8/hooks/chat/conversations/use-fetch-space-conversation"},{"title":"Use mute conversation","icon":"bell-slash","href":"/v8/hooks/chat/conversations/use-mute-conversation"}]},{"group":"Chat — Messages","pages":[{"title":"Use live chat messages","icon":"cube","href":"/v8/hooks/chat/messages/use-live-chat-messages"},{"title":"Fetch many chat messages","icon":"plug","href":"/v8/hooks/chat/messages/use-fetch-many-chat-messages"},{"title":"Fetch many chat messages (wrapper)","icon":"plug","href":"/v8/hooks/chat/messages/use-fetch-many-chat-messages-wrapper"},{"title":"Send message","icon":"plug","href":"/v8/hooks/chat/messages/use-send-message"},{"title":"Edit message","icon":"plug","href":"/v8/hooks/chat/messages/use-edit-message"},{"title":"Delete message","icon":"plug","href":"/v8/hooks/chat/messages/use-delete-message"},{"title":"Toggle reaction","icon":"plug","href":"/v8/hooks/chat/messages/use-toggle-reaction"},{"title":"Use message thread","icon":"cube","href":"/v8/hooks/chat/messages/use-message-thread"},{"title":"Use chat messages (deprecated)","icon":"cube","href":"/v8/hooks/chat/messages/use-chat-messages"}]},{"group":"Chat — Core","pages":[{"title":"Use chat socket","icon":"cube","href":"/v8/hooks/chat/use-chat-socket"},{"title":"Mark conversation as read","icon":"plug","href":"/v8/hooks/chat/use-mark-conversation-as-read"},{"title":"Use total unread count","icon":"cube","href":"/v8/hooks/chat/use-total-unread-count"},{"title":"Use typing indicator","icon":"cube","href":"/v8/hooks/chat/use-typing-indicator"},{"title":"Use unread conversation count","icon":"cube","href":"/v8/hooks/chat/use-unread-conversation-count"}]},{"group":"Search","pages":[{"title":"Search content","icon":"plug","href":"/v8/hooks/search/use-search-content"},{"title":"Search users","icon":"plug","href":"/v8/hooks/search/use-search-users"},{"title":"Search spaces","icon":"plug","href":"/v8/hooks/search/use-search-spaces"},{"title":"Ask content","icon":"plug","href":"/v8/hooks/search/use-ask-content"},{"title":"Match users","icon":"plug","href":"/v8/hooks/search/use-match-users"}]},{"group":"Reports","pages":[{"title":"Create report","icon":"plug","href":"/v8/hooks/reports/use-create-report"},{"title":"Fetch moderated reports","icon":"plug","href":"/v8/hooks/reports/use-fetch-moderated-reports"},{"title":"Handle space report","icon":"plug","href":"/v8/hooks/reports/use-handle-space-report"}]},{"group":"Storage","pages":[{"title":"Upload file","icon":"plug","href":"/v8/hooks/storage/use-upload-file"},{"title":"Upload image","icon":"plug","href":"/v8/hooks/storage/use-upload-image"},{"title":"File links","icon":"plug","href":"/v8/hooks/storage/use-file-links"}]},{"group":"Crypto","pages":[{"title":"Sign testing JWT","icon":"plug","href":"/v8/hooks/crypto/use-sign-testing-jwt"}]},{"group":"Project","pages":[{"title":"Use project","icon":"cube","href":"/v8/hooks/project/use-project"}]},{"group":"Custom Tables","pages":[{"title":"Use table","icon":"table","href":"/v8/hooks/tables/use-table"},{"title":"Use table row","icon":"table","href":"/v8/hooks/tables/use-table-row"}]}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/v8/api-reference/getting-started"}]},{"tab":"Data Models","pages":[{"title":"Data Models","href":"/v8/data-models/user"}]},{"tab":"Node SDK","pages":[{"title":"Node SDK","href":"/v8/node-sdk/overview"}]},{"tab":"JS SDK","pages":[{"title":"JS SDK","href":"/v8/js-sdk/overview"}]},{"tab":"Components","pages":[{"title":"Components","href":"/v8/components/overview"}]}],"global":{"anchors":[{"anchor":"Dashboard","icon":"gauge","href":"https://dash.sublay.io"}]}},{"version":"7.0.0","default":true,"pages":[{"title":"7.0.0","href":"/v7/hooks/workspaces/use-remove-workspace-member-from-subtree"}]},{"version":"6.0.0","pages":[{"title":"6.0.0","href":"/v6"}]}]},"basePath":"","title":"Remove workspace member from subtree - Sublay Documentation","deploymentId":"dpl_6UE2cqB47X6P7P3F2hD3UphW6ijc","buildId":"dpl_6UE2cqB47X6P7P3F2hD3UphW6ijc","dynamics":[],"chunks":[]}