onGroupCreated( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a group is created.

Method Declaration
Copy
function wixSocialGroupsV2_onGroupCreated(event: GroupCreated): void;
Method Parameters
eventGroupCreated
onGroupCreated example
JavaScript
export function wixSocialGroupsV2_onGroupCreated(event) { const eventId = event.metadata.id; const entityId = event.entity._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupDeleted( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a group is deleted.

Method Declaration
Copy
function wixSocialGroupsV2_onGroupDeleted(event: GroupDeleted): void;
Method Parameters
eventGroupDeleted
onGroupDeleted example
JavaScript
export function wixSocialGroupsV2_onGroupDeleted(event) { const eventId = event.metadata.id; const entityId = event.entity._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupCoverChanged( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a group's logo is changed.

Method Declaration
Copy
function wixSocialGroups_onGroupCoverChanged(
  event: GroupCoverChangedEvent,
): void;
Method Parameters
eventGroupCoverChangedEvent

Group cover data.

onGroupCoverChanged example
JavaScript
export function wixSocialGroups_onGroupCoverChanged(event) { const eventId = event.metadata.id; const entityId = event.data.group._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupDescriptionChanged( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a group's description is changed.

Method Declaration
Copy
function wixSocialGroups_onGroupDescriptionChanged(
  event: GroupDescriptionChangedEvent,
): void;
Method Parameters
eventGroupDescriptionChangedEvent

Group description data.

onGroupDescriptionChanged example
JavaScript
export function wixSocialGroups_onGroupDescriptionChanged(event) { const eventId = event.metadata.id; const entityId = event.data.group._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupMemberAdded( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a new member is added to a group, either directly by an admin or when a Join Request is approved.

Method Declaration
Copy
function wixSocialGroupsV2_onGroupMemberAdded(event: GroupMemberAdded): void;
Method Parameters
eventGroupMemberAdded
onGroupMemberAdded example
JavaScript
export function wixSocialGroupsV2_onGroupMemberAdded(event) { const eventId = event.metadata.id; const entityId = event.data.groupMember._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupMemberRemoved( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Method Declaration
Copy
function wixSocialGroupsV2_onGroupMemberRemoved(
  event: GroupMemberRemoved,
): void;
Method Parameters
eventGroupMemberRemoved
onGroupMemberRemoved example
JavaScript
export function wixSocialGroupsV2_onGroupMemberRemoved(event) { const eventId = event.metadata.id; const entityId = event.data.groupMember._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onGroupRequestApproved( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a Group Request is approved.

Method Declaration
Copy
function wixSocialGroupsV2_onGroupRequestApproved(
  event: GroupRequestApprovedEvent,
): void;
Method Parameters
eventGroupRequestApprovedEvent
onGroupRequestApproved example
JavaScript
export function wixSocialGroupsV2_onGroupRequestApproved(event) { const eventId = event.metadata.id; const entityId = event.data.groupRequest._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onJoinGroupRequestApproved( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a join group request is approved by a group admin or a groups manager.

Method Declaration
Copy
function wixSocialGroupsV2_onJoinGroupRequestApproved(
  event: JoinGroupRequestApprovedEvent,
): void;
Method Parameters
eventJoinGroupRequestApprovedEvent
onJoinGroupRequestApproved example
JavaScript
export function wixSocialGroupsV2_onJoinGroupRequestApproved(event) { const eventId = event.metadata.id; const entityId = event.data.joinGroupRequest._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?

onJoinGroupRequestRejected( )


Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when a join group request is rejected by a group admin or a groups manager.

Method Declaration
Copy
function wixSocialGroupsV2_onJoinGroupRequestRejected(
  event: JoinGroupRequestRejectedEvent,
): void;
Method Parameters
eventJoinGroupRequestRejectedEvent
onJoinGroupRequestRejected example
JavaScript
export function wixSocialGroupsV2_onJoinGroupRequestRejected(event) { const eventId = event.metadata.id; const entityId = event.data.joinGroupRequest._id; }
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?