Mediloop
PlatformUsers / Memberships / RolesTerminate membership

Terminate membership

Platform

End a user’s access to a tenant while preserving the historical membership and audit trail.

Identity

One user identity

Membership

Tenant affiliation

Role

Functional access

Context

Tenant + membership

POST/v1/memberships/{membership_id}/terminateScope: memberships.write

Endpoint summary

POST /v1/memberships/{membership_id}/terminate ends tenant access while retaining historical attribution.

Termination rules

Termination is not deletion. Historical clinical and operational actions must remain attributable to the membership that performed them.

Request body

FieldTypeDescription
reasonstringTermination reason
effective_atdate-timeOptional scheduled effective time

Example request

JSONCopy
{
  "reason": "affiliation_ended",
  "effective_at": "2026-08-31T18:00:00Z"
}

Responses

CodeMeaning
200Membership terminated
403Insufficient access
404Membership not found
409Membership already terminated or invalid state