# \[Guide\] Reporting API FAQ & Guide

**URL:** <https://community.sendbird.com/t/guide-reporting-api-faq-guide/208>\
**Category:** FAQs & Guides\
**Tags:** chatsdk, reporting-api, reporting\
**Created:** [April 22, 2020, 7:37am UTC](https://community.sendbird.com/t/guide-reporting-api-faq-guide/208 "2020-04-22T07:37:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sendbird](https://sea2.discourse-cdn.com/flex020/user_avatar/community.sendbird.com/sendbird/32/5002_2.png) [@Sendbird](https://community.sendbird.com/u/Sendbird)\
**Post date:** [April 22, 2020, 7:37am UTC](https://community.sendbird.com/t/guide-reporting-api-faq-guide/208/1 "2020-04-22T07:37:20Z")

</div>

# [SendBird] Reporting API FAQ

Date: 2020-04-01

Prepared By: Solutions Engineering  
Published By: Jason Allshorn

### Background

- The document answers questions regarding describing the reporting feature of SendBird.
- You can build your own in-app system for reporting and removal of objectionable content and subject when using our SDKs and [API.](https://docs.sendbird.com/platform/report_content_and_subject#2_report_content_and_subject)
- We support APIs to report, moderate, and prohibit offensive and abusive messages, users, or channels.

### What is the SendBird Reporting API?

SendBird’s reporting API is a system designed to allow your users to report abusive and or objectionable SendBird message content, SendBird users, or SendBird channels. The image below displays an example of where a user has clicked a message and is able to report the message.

### ![|208x420.0333822580645](https://us1.discourse-cdn.com/flex020/uploads/sendbird/original/1X/1327da03e421c6c54b3d997111772d08319ebeb4.jpeg)

### Why would we need to use the SendBird Reporting API?

The Reporting API is for you, if you have concerns about what your users are communicating and how they are communicating it to other users. The reporting API is for you if you would like your users to have the ability to call out, and flag other users for their abusive behavior.

Furthermore, the reporting API was built to accommodate the Apple App store requirement that applications providing chat functionality should also provide abusive behavior reporting tools. If you are building an app for the Apple Store then this API is very useful.

### How does the Reporting API work?

As of writing the reporting API is a powerful scalable, but bare metal service. The following flow is currently possible.

1. SendBird SDK users and SendBird’s Platform API can call to report a user, message or channel.

2. The reporting call can include both the target of the report, the reporter’s details, and also the type of abuse, and a description.

3. The reporting call triggers two actions to occur.

4. A webhook is triggered which can be targeted at your webhook endpoint.  
1. [message:report](https://docs.sendbird.com/platform/webhooks#3_message_report) A message is reported by a user.  
2. [User:report](https://docs.sendbird.com/platform/webhooks#3_user_report) A user is reported by another user.  
3. [Open\_channel:report](https://docs.sendbird.com/platform/webhooks#3_open_channel_report) An open channel is reported by a user.  
4. [Group\_channel:report](https://docs.sendbird.com/platform/webhooks#3_group_channel_report) A group channel is reported by a user.

5. A database entry is made to store the generated report.

6. Currently it is possible to retrieve the reports if the channel id, user id, or message id are known. This means that the current optimal method of capturing report data is to build your own database of reports by ingesting the webhook service.

### How could my application implement the Reporting API?

Consider providing familiar tools for your users that are used across industries to report abuse.

- [Android](https://docs.sendbird.com/android/group_channel#3_report_a_message_a_user_or_a_channel), [iOS](https://docs.sendbird.com/ios/open_channel#3_report_a_message_a_user_or_a_channel), [JavaScript](https://docs.sendbird.com/javascript/group_channel#3_report_a_message_a_user_or_a_channel), [Platform API](https://docs.sendbird.com/platform/report_content_and_subject#2_report_content_and_subject)
- Reporting Messages:
  - Consider providing little flags that can be clicked and trigger a modal for filling in report details.
  - For the report details consider providing a set menu of reporting reasons so as to minimize the users effort to make a report.

- Reporting Users:
  - Perhaps provide the ability for your user to open another users profile and have an interaction in there where the have a choice to “report this user”
  - As with the other reporting methods consider providing a menu of reporting options so as to reduce effort on the part of the reporting user.

- Reporting Channels:
  - In this case consider providing a flag similar to that seen on messages.
  - Again give the user an easy selection of reporting options.

### What actions can be taken based on reporting actions?

#### SendBird Dashboard

- Once a report is received and logged through a webhook action on the report can be made by a SendBird Dashboard member with a Dashboard role that gives them access to the following where moderation actions are available:
  - Group Channels and Open channels
    - Send Admin message to whole channel
      - With or without push notifications

    - Delete channel
    - Ban users from channel
    - Mute users in the channel
    - Delete messages

  - Users
    - Deactivate a user with the ability to remove them from all joined group channels
    - Delete a user

#### Channel Operators: Banning users

- [Single channel channel banning](https://docs.sendbird.com/android/group_channel#3_ban_and_unban_a_user)

- Multiple channel banning

### Channel Operators: Channel freeze

- If you need all regular members to stop sending messages then consider allowing the channel owner/operator to [freeze the channel](https://docs.sendbird.com/android/group_channel#3_freeze_and_unfreeze_a_channel). You can also download the [Channel Freeze FAQ](https://www.dropbox.com/s/5xi2hb7lmjgg8t6/Channel%20Freeze%20FAQ.pdf?dl=0)

### Channel Operators: Channel Hide

- One more option, if needed, is to hide a channel.

- Here is the latest description:

- To permanently delete a channel, please refer to the Platform API’s [delete endpoint](https://docs-st.sendbird.com/platform/group_channel#3_delete_a_channel). SendBird dashboard admin can also delete channels.

- There are two methods associated with the visibility of a channel. All channel objects have the `.hide()` and `.unhide()` methods:

- `.hide()` can be invoked on any referenced channel object. The method will set the channel’s hidden state value according to the parameters of `.hide()`.

- `.unhide()` can be invoked on any referenced channel object.

```auto
     groupChannel.hide(IS_HIDE_PREVIOUS_MESSAGES, IS_ALLOW_AUTO_UNHIDE, new GroupChannel.GroupChannelHideHandler() {
    @Override
    public void onResult(SendBirdException e) {
    if (e != null) { // Error.
    return;
    }
    }
    });

    groupChannel.unhide(new GroupChannel.GroupChannelUnhideHandler() {
    @Override
    public void onResult(SendBirdException e) {
    if (e != null) { // Error.
    return;
    }
    }
    });

```

- `IS_HIDE_PREVIOUS_MESSAGES`: a boolean (default false). when set to true, if the channel at any point becomes unhidden - by invoking `.unhide()` or by automatic unhide, the channel will again appear in the `.createMyGroupChannelListQuery()` list. However that channel’s lastMessage parameter value will be set to null. Invocations of `createPreviousMessageListQuery`, and `getPreviousMessagesByTimestamp` will continue to return all historical messages.
- `IS_ALLOW_AUTO_UNHIDE`: a boolean. if set to true, after being hidden any subsequent messages sent on that channel will unhide the channel for all channel members. Messages sent from admin will also cause the channel to be unhidden. If set to false the channel will remain hidden until `.unhide()` is invoked on it.
