API REFERENCE
Remove Member from Organization
On this page
/api/organizations/membersRemove a member from an organization. This endpoint is idempotent - Removing an account that is not a member succeeds without error.
Authentication
x-api-key in header
bearerAuth bearer
Request
curl --request DELETE \
--url 'https://api.recoupable.dev/api/organizations/members?organization_id=YOUR_ORGANIZATION_ID&account_id=YOUR_ACCOUNT_ID' \
--header 'x-api-key: YOUR_API_KEY'Replace the YOUR_ placeholders with your values. Required query parameters are included; optional parameters are listed below.
Try it
Fill in the fields, send the request from your browser, and read the live response. The curl below updates as you type.
Kept in this browser tab only and cleared when it closes.
curl --request DELETE \
--url 'https://recoup-api.vercel.app/api/organizations/members'Parameters
Query parameters
organization_idstringrequiredThe account ID of the organization
account_idstringrequiredThe account ID of the member to remove
Responses
200Member removed from organization (or was not a member)+
application/json
statusstring · enumrequiredStatus of the request
Values: "success"
400Bad request - invalid or missing parameters+
application/json
statusstring · enumrequiredStatus of the request
Values: "error"
errorstringrequiredError message describing what went wrong
401Unauthorized - missing or invalid authentication+
application/json
statusstring · enumrequiredStatus of the request
Values: "error"
errorstringrequiredError message describing what went wrong
403Forbidden - caller is not a member of the organization+
application/json
statusstring · enumrequiredStatus of the request
Values: "error"
errorstringrequiredError message describing what went wrong
Full specification
Download the OpenAPI file for complete schemas, constraints, and examples.
Download accounts.jsonView operation source
{
"description": "Remove a member from an organization. This endpoint is idempotent - Removing an account that is not a member succeeds without error.",
"security": [
{
"apiKeyAuth": []
},
{
"bearerAuth": []
}
],
"parameters": [
{
"name": "organization_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"format": "uuid"
},
"description": "The account ID of the organization"
},
{
"name": "account_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"format": "uuid"
},
"description": "The account ID of the member to remove"
}
],
"responses": {
"200": {
"description": "Member removed from organization (or was not a member)",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/RemoveOrganizationMemberResponse"
}
}
}
},
"400": {
"description": "Bad request - invalid or missing parameters",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorEnvelope"
}
}
}
},
"401": {
"description": "Unauthorized - missing or invalid authentication",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorEnvelope"
}
}
}
},
"403": {
"description": "Forbidden - caller is not a member of the organization",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorEnvelope"
}
}
}
}
}
}