Skip to main content
Version: 5.9.6

ReportUser

public BackendReturnObject ReportUser(string ReportedNickname, string Details);
public BackendReturnObject ReportUser(string ReportedNickname, string Reason, string Details);

Parameters

ValueTypeDescription
ReportedNicknamestringNickname of the user being reported
Reasonstring(Optional) Reason for report
DetailsstringContent of the report(max 500 characters)

Description

A report of a specific user is made to the admin. The content of the report can be found in the console.

Example

Synchronous

Backend.Chat.ReportUser("ReportedNickname" , "Reasons", "Details");

Asynchronous

Backend.Chat.ReportUser("ReportedNickname" , "Reasons", "Details", callback => 
{
// Post-process
});

SendQueue

SendQueue.Enqueue(Backend.Chat.ReportUser, "ReportedNickname" , "Reasons", "Details", callback => 
{
// Post-process
});

Return cases

Success cases

When the report is successful
statusCode : 200

returnValue : {"result":"The report of id1(on id2) has been accepted."}

Error cases

When details are not entered
statusCode : 400
errorCode : BadParameterException

When the details are too long
statusCode : 400
errorCode : BadParameterException

When the nickname of the reported user does not exist
statusCode : 404
errorCode : NotFoundException