Platform API
Report Content And Subject

Report Content and Subject

You can build your own in-app system for reporting and removal of objectionable content and subject when using our SDKs and API. We support APIs to report, moderate, and prohibit offensive and abusive messages, users, or channels.

Note: Reported messages can be moderated automatically or manually by our text moderation feature. For more information, see the Text moderation section in the Filter and Moderation page.

Resource representation

Property nameTypeDescription

reporting_user

nested object

The user who reports offensive and abusive messages, users, and channels.

report_type

string

An object type which is reported by the reporting_user. Valid values are message, user, and channel.

report_category

string

A report category which indicates the reason for reporting. Valid values are suspicious, harassing, inappropriate, and spam.

reported_message

nested object

The message which is reported for its suspicious, harassing, or inappropriate content.

offending_user

nested object

The user who is reported for using offensive or abusive language such as sending explicit messages or inappropriate comments.

channel

nested object

Either an open or a group channel which is reported for offensive messages or inappropriate activities within the channel.

report_description

string

Additional information included in the report.

created_at

long

The time that the report was created, in Unix seconds format.

Actions

  • API endpoints are relative to the base URL allocated to your application. In this page, the /report endpoint refers to https://api-{application_id}.sendbird.com/v3/report.

Note: If you want to know the ID and base URL of your application, sign in to your dashboard, select the application, open the Overview, and then check the App credentials > App ID, API request URL.

ActionHTTP Request

List reports on a message

GET /report/{channel_type}/{channel_url}/messages/{message_id}
Retrieves a list of reports on the message which contains suspicious, harassing, or inappropriate content.

Report a message

POST /report/{channel_type}/{channel_url}/messages/{message_id}
Reports the message which contains suspicious, harassing, or inappropriate content.

List reports on a user

GET /report/users/{offending_user_id}
Retrieves a list of reports on the user who sends an offensive message.

Report a user

POST /report/users/{offending_user_id}
Reports the user who sends an offensive message in a channel.

List reports on a channel

GET /report/{channel_type}/{channel_url}
Retrieves a list of reports on a specific channel that has offensive messages or abusive activities.

Report a channel

POST /report/{channel_type}/{channel_url}
Reports a specific channel that has offensive messages or abusive activities.


List reports on a message

Retrieves a list of reports on a message which contains suspicious, harassing, or inappropriate content.

HTTP request

Light Color Skin
Copy
GET https://api-{application_id}.sendbird.com/v3/report/{channel_type}/{channel_url}/messages/{message_id} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

channel_type

string

Specifies the type of the channel. Either open_channel or group_channel.

channel_url

string

Specifies the URL of the channel where the reported message is in.

message_id

string

Specifies the unique ID of the reported message.

OptionalTypeDescription

token

string

Specifies a token that indicates the starting index of a chunk of results to retrieve. If not specified, the index is set as 0.

limit

int

Specifies the number of results to return per page. Acceptable values are 1 to 100, inclusive. (Default: 10)

Query string example
Light Color Skin
Copy
?token=rQ24R4aSpl1alE1WXlVb4SL1&limit=3

Response

If successful, this action returns a list of report resources on the message in the response body.

Status: 200 OK
Light Color Skin
Copy
{
    "report_logs": [
        {
            "report_type": "message",
            "report_category": "suspicious",
            "reporting_user": {
                "user_id": "Matthew",
                "nickname": "Mooch",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_44_512px.png",
                "metadata": {
                    "location": "Singapore",
                    "marriage": "N"
                }
            },
            "offending_user": {
                "user_id": "Jane",
                "nickname": "Trinity",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_432_512px.png",
                "metadata": {
                    "location": "London",
                    "marriage": "N"
                }
            },
            "reported_message": {
                "message_id": 592281302,
                "type": "MESG",
                "custom_type": "",
                "channel_url": "sendbird_group_channel_15110744_67c34500c14ffa4f9ad23a80d4426e40467ebb91",
                "user": {
                    "user_id": "Jane",
                    "nickname": "Trinity",
                    "profile_url": "https://sendbird.com/main/img/profiles/profile_432_512px.png",
                    "metadata": {
                        "location": "London",
                        "marriage": "N"
                    }
                },
                "mention_type": "users",
                "mentioned_users": [],
                "is_removed": false,
                "message": "Seriously, I am waiting for you at my secret website. Would you join me?",
                "translations": {},
                "data": "",
                "created_at": 1568784875135,
                "updated_at": 0,
                "file": {}
            },
            "channel": {
                "name": "Looking for someone to spend my time with...",
                "channel_url": "sendbird_group_channel_15110744_67c34500c14ffa4f9ad23a80d4426e40467ebb91",
                "cover_url": "",
                "custom_type": "",
                "unread_message_count": 0,
                "unread_mention_count": 0,
                "data": "",
                "is_distinct": true,
                "is_public": false,
                "is_super": false,
                "is_ephemeral": false,
                "is_discoverable": false,
                "is_access_code_required": false,
                "member_count": 4,
                "joined_member_count": 4,
                "members": [
                    ... # A list of the channel members.
                ],
                "max_length_message": -1,
                "last_message": {
                    ... # The information of the channel's last message. 
                },
                "created_at": 15687923728,
                "freeze": false
            },
            "report_description": "",
            "created_at": 1568791754
        },
        ... # More reports on the message. 
    ],
    "next": "LMZ2aVnQdE4EU3XWFNeF25dFkF~Ad~"
}
Property nameTypeDescription

report_logs

nested object

A list of reports on the message.

next

string

The value for the token parameter to retrieve the next page in the result set.


Report a message

Reports a message which contains suspicious, harassing, or inappropriate content.

HTTP request

Light Color Skin
Copy
POST https://api-{application_id}.sendbird.com/v3/report/{channel_type}/{channel_url}/messages/{message_id} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

channel_type

string

Specifies the type of the channel. Either open_channel or group_channel.

channel_url

string

Specifies the URL of the channel where the message to report is in.

message_id

string

Specifies the unique ID of the message to report.

Request body

The following table lists the properties of an HTTP request that this action supports.

Properties
RequiredTypeDescription

report_category

string

Specifies the category which indicates the reason for reporting. Acceptable values are suspicious, harassing, inappropriate, and spam.

offending_user_id

string

Specifies the unique ID of the user who has sent the message to report.

OptionalTypeDescription

reporting_user_id

string

Specifies the unique ID of the user who reports the message.

report_description

string

Specifies additional information to be included in the report.

Request body example
Light Color Skin
Copy
{
    "report_category": "suspicious",
    "offending_user_id": "Julie",
    "reporting_user_id": "Simon"
}

Response

If successful, this action returns a report resource on the message in the response body.


List reports on a user

Retrieves a list of reports on a user who sends an offensive message.

HTTP request

Light Color Skin
Copy
GET https://api-{application_id}.sendbird.com/v3/report/{offending_user_id} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

offending_user_id

string

Specifies the unique ID of the user who has sent the message to report.

OptionalTypeDescription

token

string

Specifies a token that indicates the starting index of a chunk of results to retrieve. If not specified, the index is set as 0.

limit

int

Specifies the number of results to return per page. Acceptable values are 1 to 100, inclusive. (Default: 10)

Query string example
Light Color Skin
Copy
?token=aR94a4aOpl1alr4WXlVb44Kl&limit=3

Response

If successful, this action returns a list of report resources on the user in the response body.

Status: 200 OK
Light Color Skin
Copy
{
    "report_logs": [
        {
            "report_type": "user",
            "report_category": "harassing",
            "reporting_user": {
                "user_id": "Elizabeth",
                "nickname": "Rolly Rolly",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_471_512px.png",
                "metadata": {
                    "location": "London",
                    "marriage": "Y"
                }
            },
            "offending_user": {
                "user_id": "Drake",
                "nickname": "TooLate",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_432_512px.png",
                "metadata": {
                    "location": "Toronto",
                    "marriage": "N"
                }
            },
            "reported_message": null,
            "channel": {
                "name": "PBR&B songs",
                "channel_url": "sendbird_group_channel_15458190_3ce474cfbb465c513de1728c7283bec63f00deea",
                "cover_url": "",
                "custom_type": "",
                "unread_message_count": 0,
                "unread_mention_count": 0,
                "data": "",
                "is_distinct": true,
                "is_public": false,
                "is_super": false,
                "is_ephemeral": false,
                "is_discoverable": false,
                "is_access_code_required": false,
                "member_count": 3,
                "joined_member_count": 3,
                "members": [
                    ... # A list of the channel members.
                ],
                "max_length_message": -1,
                "last_message": {
                    ... # The information of the channel's last message.
                },
                "created_at": 1568775527,
                "freeze": false
            },
            "report_description": "using dirty words too much",
            "created_at": 1568816730
        },
        ... # More reports on the user.
    ],
    "next": "kZA4V9nQda4E3udWrNeF25dFkFdQ~~"
}
Property nameTypeDescription

report_logs

nested object

A list of reports on the user.

next

string

The value for the token parameter to retrieve the next page in the result set.


Report a user

Reports a user who sends an offensive message in a channel.

HTTP request

Light Color Skin
Copy
POST https://api-{application_id}.sendbird.com/v3/report/{offending_user_id} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

offending_user_id

string

Specifies the unique ID of the user to report for using offensive or abusive language such as sending explicit messages or inappropriate comments.

Request body

The following table lists the properties of an HTTP request that this action supports.

Properties
RequiredTypeDescription

channel_type

string

Specifies the type of the channel. Either open_channel or group_channel.

channel_url

string

Specifies the URL of the channel where the user to report is in.

report_category

string

Specifies the category which indicates the reason for reporting. Acceptable values are suspicious, harassing, inappropriate, and spam.

OptionalTypeDescription

reporting_user_id

string

Specifies the unique ID of the user who reports the offending user.

report_description

string

Specifies additional information to be included in the report.

Request body example
Light Color Skin
Copy
{
    "channel_type": "group_channels",
    "channel_url": "sendbird_group_channel_15458190_3ce474cfbb465c513de1728c7283bec63f00deea",
    "report_category": "spam"
}

Response

If successful, this action returns a report resource on the user in the response body.


List reports on a channel

Retrieves a list of reports on a channel that has offensive messages or abusive activities.

HTTP request

Light Color Skin
Copy
GET https://api-{application_id}.sendbird.com/v3/report/{channel_type}/{channel_url} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

channel_type

string

Specifies the type of the channel. Either open_channel or group_channel.

channel_url

string

Specifies the URL of the channel which is reported for offensive messages or inappropriate activities.

OptionalTypeDescription

token

string

Specifies a token that indicates the starting index of a chunk of results to retrieve. If not specified, the index is set as 0.

limit

int

Specifies the number of results to return per page. Acceptable values are 1 to 100, inclusive. (Default: 10)

Query string example
Light Color Skin
Copy
?token=wPr94LaSpl1alE1wXAkb4dN9&limit=3

Response

If successful, this action returns a list of report resources on the channel in the response body.

Status: 200 OK
Light Color Skin
Copy
{
    "report_logs": [
        {
            "report_type": "channel",
            "report_category": "inappropriate",
            "reporting_user": {
                "user_id": "Debbie",
                "nickname": "Eclipse",
                "profile_url": "https://sendbird.com/main/img/profiles/profile_183_512px.png",
                "metadata": {
                    "location": "Seoul",
                    "marriage": "N"
                }
            },
            "offending_user": null,
            "reported_message": null,
            "channel": {
                "name": "Talking dirty with me tonight...",
                "channel_url": "sendbird_group_channel_15458667_8d00f8ff213349e24b8c6e0fc17bc5111d66f0fc",
                "cover_url": "",
                "custom_type": "",
                "unread_message_count": 0,
                "unread_mention_count": 0,
                "data": "",
                "is_distinct": true,
                "is_public": false,
                "is_super": false,
                "is_ephemeral": false,
                "is_discoverable": false,
                "is_access_code_required": false,
                "member_count": 6,
                "joined_member_count": 6,
                "members": [
                    ... # A list of the channel members.
                ],
                "max_length_message": -1,
                "last_message": { 
                    ... # The information of the channel's last message.
                },
                "created_at": 1568782131,
                "freeze": false
            },
            "report_description": "sexual content showing now allowed",
            "created_at": 1568923510
        },
        ... # More reports on the channel.
    ],
    "next": "dAa3Ln2TLd4E3ud4Ec5F25dFkdRp~~"
}
Property nameTypeDescription

report_logs

nested object

A list of reports on the channel.

next

string

The value for the token parameter to retrieve the next page in the result set.


Report a channel

Reports a channel that has offensive messages or abusive activities.

HTTP request

Light Color Skin
Copy
POST https://api-{application_id}.sendbird.com/v3/report/{channel_type}/{channel_url} 

Parameters

The following table lists the parameters that this action supports.

Parameters
RequiredTypeDescription

channel_type

string

Specifies the type of the channel. Either open_channel or group_channel.

channel_url

string

Specifies the URL of the channel to report for offensive messages or inappropriate activities.

Request body

The following table lists the properties of an HTTP request that this action supports.

Properties
RequiredTypeDescription

report_category

string

Specifies the category which indicates the reason for reporting. Acceptable values are suspicious, harassing, inappropriate, and spam.

OptionalTypeDescription

reporting_user_id

string

Specifies the unique ID of the user who reports the channel.

report_description

string

Specifies additional information to be included in the report.

Request body example
Light Color Skin
Copy
{
    "report_category": "inappropriate",
    "report_description": "Seems that people here are sharing something wrong."
}

Response

If successful, this action returns a report resource on the channel in the response body.