Chat / Platform API
Current version: v3
    Chat Platform API v3
    Chat Platform API
    Chat
    Platform API
    Home
    /
    Chat
    /
    Platform API

    List reports on a user

    Retrieves a list of reports on a user who sends offensive messages.


    HTTP request

    GET https://api-{application_id}.sendbird.com/v3/report/users/{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 a user who has sent an offensive message.

    OptionalTypeDescription

    token

    string

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

    limit

    int

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

    ?token=aR94a4aOpl1alr4WXlVb44Kl&limit=3
    

    Response

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

    {
        "report_logs": [
            {
                "report_type": "user",
                "report_category": "harassing",
                "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 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 a user.
        ],
        "next": "kZA4V9nQda4E3udWrNeF25dFkFdQ~~"
    }
    

    List of response properties

    Property nameTypeDescription

    report_logs

    nested object

    A list of reports on a user.

    next

    string

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

    In the case of an error, an error object is returned. A detailed list of error codes is available here.