Get started
Webhooks

organization.member

organization.member

Subscribe an endpoint to every event on this page with organization.member.*. Each is the envelope every webhook event shares, with the OrganizationMemberEventObject object as its data.object.

Event typeWhat happened
organization.member.createdSomebody joined an organization.
organization.member.updatedA member's role changed.
organization.member.deletedA member left an organization or was removed from it.

The OrganizationMemberEventObject object

A membership as a webhook event carries it: the member's account and the role they hold. The member's address and name are not carried: getOrganizationMembers lists them while they are a member.

object

string

required

One of: organization.member

The kind of object this is, always organization.member: the family of the event types that carry it, and what tells the members of WebhookEventObject apart.

user_id

string (uuid)

required

Identifier of the member's account, the user_id that names them on patchOrganizationMember and deleteOrganizationMember.

role

string

required

One of: owner, admin, contributor, viewer

The role the member holds once this change was made, or held when they left.

joined_at

string (date-time)

required

When the member joined the organization.

reason

string

One of: removed, left

Why the membership ended. Present on organization.member.deleted alone.

organization.member.created

Somebody joined the organization: the owner of an organization just created, or a person accepting an invitation.

Triggered by

  • organization.create: Always, for its owner, the user who created it.
    • POST /v1/organizations: postOrganization, mountaya.admin.organizations.postOrganization() in TypeScript. Every organization created.
    • Mountaya's web application: An organization created signed in to Mountaya's web application.
  • organization.invitation.accept: When the person was not a member already.
    • POST /v1/me/invitations/{invitation_id}/accept: postMyInvitationAccept, mountaya.admin.users.postMyInvitationAccept() in TypeScript. Every invitation accepted.
    • Mountaya's web application: An invitation accepted signed in to Mountaya's web application.

Payload

type

string

required

One of: organization.member.created

Always organization.member.created.

data.object

OrganizationMemberEventObject

required

The organization member.

See the OrganizationMemberEventObject object.

Every other field is the envelope every webhook event shares.

organization.member.updated

A member's role changed: through patchOrganizationMember, or when ownership was handed on, which records one for each of the two members.

Triggered by

  • organization.ownership.transfer: Twice: for the member who becomes owner, and for the former owner, who becomes an admin.
    • Mountaya's web application: The owner hands the organization on, signed in to Mountaya's web application.
  • organization.member.update: When the role changes. A request naming the role the member holds records nothing.
    • PATCH /v1/organizations/{organization_id}/members/{user_id}: patchOrganizationMember, mountaya.admin.members.patchOrganizationMember() in TypeScript. Every request.
    • Mountaya's web application: A role changed signed in to Mountaya's web application.

Payload

type

string

required

One of: organization.member.updated

Always organization.member.updated.

data.object

OrganizationMemberEventObject

required

The organization member.

See the OrganizationMemberEventObject object.

data.previous_attributes

object

The former value of each field of data.object the change moved, and of no other.

Every other field is the envelope every webhook event shares.

organization.member.deleted

A membership ended: the member was removed by somebody else, or left. reason says which.

Triggered by

  • organization.member.delete: When the user was a member, with reason removed.
    • DELETE /v1/organizations/{organization_id}/members/{user_id}: deleteOrganizationMember, mountaya.admin.members.deleteOrganizationMember() in TypeScript. A request naming a member other than the user it acts as.
    • Mountaya's web application: A member removed signed in to Mountaya's web application.
  • organization.member.leave: When the user was a member, with reason left.
    • DELETE /v1/organizations/{organization_id}/members/{user_id}: deleteOrganizationMember, mountaya.admin.members.deleteOrganizationMember() in TypeScript. A request naming the user it acts as.
    • Mountaya's web application: A member leaving signed in to Mountaya's web application.

Payload

type

string

required

One of: organization.member.deleted

Always organization.member.deleted.

data.object

OrganizationMemberEventObject

required

The organization member.

See the OrganizationMemberEventObject object.

Every other field is the envelope every webhook event shares.