Tearleads

PUT/organization-memberships/{organizationId}/leave-request

Request to leave an organization

Operation organizationMemberships.leaveRequest.put

Description

Files the caller's signed request to leave an organization, which administrators see in the organization read model and act on; members cannot remove themselves. The request must be signed by the caller within the last ten minutes and cite a stored Members group head the caller has belonged to ever since. A personal organization, or a caller who is its only administrator, is refused.

Authentication

Requires a signed-in session: the client sends its session token as a bearer token in the Authorization header.

Parameters

NameInTypeDetails
organizationIdpathstringrequired
  • lowercase UUID v4

Request body

application/jsonOrganizationLeaveRequest

5 fields
  • organizationIdstringrequired
    • lowercase UUID v4
  • userIdstringrequired
    • lowercase UUID v4
  • requestedAtstringrequired
    • pattern ^(?:19[7-9]\d|[2-9]\d{3})-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$
  • membersHeadobjectrequired
    5 fields
    • principalIdstringrequired
      • lowercase UUID v4
    • versionintegerrequired
      • at least 1
    • keyEpochintegerrequired
      • at least 1
    • stateHashstringrequired
      • not empty
    • keyFingerprintstringrequired
      • not empty
  • signaturestringrequired
    • not empty

Responses

200 OK

application/jsonOrganizationMembershipResponse

One organization the caller belongs to, as the caller's own settings for it; it grants nothing.

4 fields
  • isPersonalOrganizationOwnerbooleanrequired

    True for the caller's personal organization, which can be neither paused nor left.

  • leaveRequestedAtstringrequirednullable

    When the caller asked to leave, or null.

  • organizationIdstringrequired
  • syncPausedbooleanrequired

    True when the caller paused this organization's sync to their devices.

Other fields are allowed.

Other responses

StatusMeaningBody
400Bad Request

application/jsonErrorResponse

401Unauthorized

application/jsonSessionFailureResponse

404Not Found

application/jsonErrorResponse

409Conflict

application/jsonErrorResponse

500Internal Server Error

application/jsonErrorResponse

503Service Unavailable

application/jsonErrorResponse