Update a membership
PATCH
/v1/memberships/:id
curl -X PATCH "https://api.summerbase.com/v1/memberships/:id" \ -H "Authorization: Bearer sb_..." \ -H "Content-Type: application/json" \ -d '{ "role": "writer" }'const response = await fetch("https://api.summerbase.com/v1/memberships/:id", { method: "PATCH", headers: { Authorization: "Bearer sb_...", "Content-Type": "application/json", }, body: JSON.stringify({ "role": "writer" }),})const data = await response.json()Change what a member may do in this organization.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string format: uuid
Example
0198f1a2-6c40-7a9e-8d1b-3f5e7c9a2b64Query Parameters
Section titled “Query Parameters”expand[]
Array<string>
Relationships to include in the response instead of fetching separately. A dotted path expands what an expanded record can expand in turn — at most 4 deep, 10 paths a request, and never back to a record already on the path.
Request Body
Section titled “Request Body”Media typeapplication/json
object
role
What the user may do in the organization, and in every project under it.
string
Example
{ "role": "writer"}Response
Section titled “Response”Returns the membership object.
Media typeapplication/json
Example
{ "created_at": "2025-09-08T14:02:37Z", "id": "0198f1a2-6c40-7a9e-8d1b-3f5e7c9a2b64", "object": "membership", "organization_id": "0198f1a2-6c3d-7e41-9a2b-5c8d1e4f7a90", "role": "admin", "user_id": "0198f1a2-6b10-7d2a-b4c5-9e8f7a6b5c41"}