⚠️ Two possible outcomes — check auto_addedin the response:Auto-added instantly: if the invited user already has an account and is already a member of at least one workspace in the same organization as the target workspace, they are added to the workspace immediately — no invitation email is sent and no acceptance is needed. The response returns auto_added: trueand_id: null.Manual acceptance required: in every other case an invitation email is sent, and the invited user must accept it themselves (signed in with the invited email address) before they join the workspace. Each invitation must be accepted individually. The response returns auto_added: falseand_idset to the invitation ID.
curl --location 'https://api.plusvibe.ai/api/v1/workspaces/invite' \
--header 'x-api-key: <api-key>' \
--header 'Content-Type: application/json' \
--data-raw '{
"workspace_id": "66c5860c0d3839cddfe96a31",
"email": "jane@example.com",
"role_name": "WORKSPACE_ADMIN"
}'{
"_id": "675fb8aca8d7a0a931119c58",
"auto_added": false,
"workspace_id": "66c5860c0d3839cddfe96a31",
"role_name": "WORKSPACE_MEMBER"
}