Browse Platform API
Platform API

Before sending a group message

Copy

Use this callback for content moderation, policy enforcement, or field validation before a group message is sent.

HTTP request

POST {WEBHOOK_ADDRESS}/callbackBeforeSendGroupMsgCommand

Request body

The payload contains callbackCommand: callbackBeforeSendGroupMsgCommand, groupID, and the message fields described on Before sending a one-to-one message. Group messages also expose these fields:

PropertyTypeDescription
recvID EnterprisestringRecipient identifier supplied for the group message.
keyVersion EnterpriseintMessage encryption key version.

Response

Return the common before-event response from Webhooks overview. Use nextCode: 1 to reject the message.

Processing rules

  • Configuration key: beforeSendGroupMsg.
  • OpenIM waits synchronously; timeout behavior follows failedContinue.