Remove User from Tenant
DELETE
/tenant/{tenantId}/user/{userId}
const url = 'https://api.exolink.cloud/tenant/example/user/example';const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://api.exolink.cloud/tenant/example/user/example \ --header 'Authorization: Bearer <token>'Remove user from the tenant. Refused for the tenant’s last owner.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”tenantId
required
string
Tenant domain prefix
userId
required
string
User ID
Responses
Section titled “Responses”User removed successfully
Media typeapplication/json
Empty object
object
Example generated
{}Missing, invalid or expired credentials
Media typeapplication/json
Error response. Some rejections carry only message.
object
message
required
Error message
string
errorCode
Error code
string
details
Failed validations, for requests checked against a schema
Array<object>
object
path
Path of the invalid field
string
message
string
code
string
Example
{ "message": "Not authorized", "errorCode": "ERR_API_NOT_AUTHORIZED"}The caller may not perform this action
Media typeapplication/json
Error response. Some rejections carry only message.
object
message
required
Error message
string
errorCode
Error code
string
details
Failed validations, for requests checked against a schema
Array<object>
object
path
Path of the invalid field
string
message
string
code
string
Example
{ "message": "Forbidden", "errorCode": "ERR_API_FORBIDDEN"}A dependency prevents the request
Media typeapplication/json
Error response. Some rejections carry only message.
object
message
required
Error message
string
errorCode
Error code
string
details
Failed validations, for requests checked against a schema
Array<object>
object
path
Path of the invalid field
string
message
string
code
string
Example
{ "message": "User is last owner of tenant 'abc123'", "errorCode": "ERR_API_FAILED_DEPENDENCY"}