For Developers
Update Team Member
PATCH https://ed.link/api/v2/teams/:team_id/members/:membership_id
Updates the lifecycle state of a team membership.
Self-Service Only: This endpoint is self-service. Only the authenticated user associated with the membership (membership.user.id) can update their membership state. Moving from active to inactive is rejected. To manage role assignments for a member, use the Create Member Assignment and Delete Member Assignment endpoints.
Permissions
No explicit role permission is required; callers must be authenticated members of the team and the subject of the membership record.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
:team_id | UUID | Yes | The ID of the team. |
:membership_id | UUID | Yes | The ID of the membership record. |
Request Body
| Property | Type | Required | Description |
|---|---|---|---|
state | String | Yes | Membership state (active). |
Sample Request
const response = await axios.patch(
`https://ed.link/api/v2/teams/${team_id}/members/${membership_id}`,
{
state: 'active'
},
{
headers: {
authorization: `Bearer ${user_session_token}`,
'content-type': 'application/json'
}
}
);
Sample Response
{
"$data": {}
}
