Remove Blocked Members And Enforce Verified

For instructions on how to authenticate to use this endpoint, see API overview.

Endpoints

POST

Create remove blocked members and enforce verified domains

Remove the members whose email domain is outside the organization's verified domains and turn enforce_verified_domains on, in one transaction. Owners are never removed; they keep gated access and can disable the setting themselves. Admin only.

Use this only when the caller has confirmed the removals. To turn the setting on without touching memberships, PATCH enforce_verified_domains on the organization instead.

Path parameters

  • id
    string

Response


Example request

POST /api/organizations/:id/remove_blocked_members_and_enforce_verified_domains
export POSTHOG_PERSONAL_API_KEY=[your personal api key]
curl
-H 'Content-Type: application/json'\
-H "Authorization: Bearer $POSTHOG_PERSONAL_API_KEY" \
<ph_app_host>/api/organizations/:id/remove_blocked_members_and_enforce_verified_domains/

Example response

Status 200
RESPONSE
{
"success": true,
"removed_members": 0
}