Remove workspace members in bulk
<Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>
Removes up to 200 people from a workspace at once, the same way as Remove workspace member.
Removing someone takes away their access to the workspace and its apps right away:
- Apps they own move to the workspace owner, and their webhooks go to the owner too.
- Their personal access tokens for the workspace are deleted, and integrations they connected in the workspace are disconnected.
- They leave every custom group.
- If this was the last workspace they could sign in to, their Base44 account is disabled.
Removing someone whose invitation is still pending cancels the invitation.
You can't remove yourself or the workspace owner.
Every item is checked before anything changes. If any item can't be applied, nothing changes and the request returns a 400 whose detail.errors lists each rejected item with its email, a message, and an error_code when there is one. A member who isn't in the workspace, or a change you couldn't make on the single-member endpoint, is reported there rather than as a 403 or 404. A 200 lists every person removed in results, in request order. Retrying a request that succeeded returns a 400 listing those people as not found.
People are handled one at a time before any membership is deleted. If a 409 stops the request, nobody is removed, but the people handled before the blocked one have already lost their app access and personal access tokens. Send the request again once the block clears.
This is limited to 5 requests per minute, shared by Update workspace member roles in bulk, Remove workspace members in bulk, and Set member credit limits in bulk. A signed-in session has its own limit, and every personal access token for the workspace shares one. Some workspaces have a different limit.
<Note>Call this as an owner or admin of the workspace, with a personal access token for that workspace sent as a Bearer token, or from a signed-in session. A read-only token is refused, and workspace API keys aren't accepted.</Note>
Query parameters
ID of the workspace. With a personal access token, use the token's workspace. Get it from organization_id in Get app.
ID of the workspace. With a personal access token, use the token's workspace. Get it from organization_id in Get app.
Request body
Example request
{
"emails": [
"dana@acme.com",
"sam@acme.com"
]
}Response
Everyone was removed.
Example response
{
"results": [
{
"email": "dana@acme.com",
"message": "Member role updated to editor.",
"status": "success"
}
]
}Changes
Changed in 1 of the 28 revisions of this API.1
- ○
endpoint added
endpoint-added
This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ○
Of the 28 revisions, 1 has no diff computed.