API Documentation
Bulk Reporting
18 min
the bulk reporting api allows you to submit multiple cases to nima in a single request, enabling efficient processing of large volumes of reports overview the bulk reporting api enables you to submit multiple reports in a single api call process reports more efficiently with reduced api overhead maintain transactional integrity across multiple submissions scale your integration for high volume reporting scenarios api endpoint post /queues/process file how it works the bulk action api accepts an array of items in the request body processes multiple reports in a single transaction returns a summary response indicating the number of cases created example request below is an example payload showing how to submit multiple cases { "items" \[ { "priority" "severe", "channel" "user report", "reason for request" "lorem abuse reason for request", "customerspecific" { }, "content" { "content id" "{{$randompassword}}", "title" "dangerous customisation of characters {{$randompassword}}", "body" "caseylegacy", "rawtext" "caseylegacy", "token" "", "type" { "id" "txt", "name" "text" }, "status" "published", "customerspecific" {} }, "reporter" { "id" "{{$randompassword}}", "name" "reporter james", "lang" "en", "phonenumber" "070 123456", "emailaddress" "joel\@tremau com", "customerspecific" {} }, "reportee" { "id" "{{$randompassword}}", "name" "reportee john", "lang" "en", "phonenumber" "070 564123", "emailaddress" "joel\@tremau com", "customerspecific" {} }, "location" { "city" "stockholm", "postalcode" "111 57", "region" "stockholm", "countrycode" "se", "ipaddress" "192 168 0 1", "customerspecific" {} }, "label" \[ "terrorist propaganda" ] }, { "priority" "severe", "channel" "user report", "reason for request" "lorem abuse reason for request", "customerspecific" { }, "content" { "content id" "{{$randompassword}}", "title" "dangerous customisation of characters {{$randompassword}}", "body" "caseysupporter01", "rawtext" "caseysupporter01", "token" "", "type" { "id" "txt", "name" "text" }, "status" "published", "customerspecific" {} }, "reporter" { "id" "{{$randompassword}}", "name" "reporter james", "lang" "en", "phonenumber" "070 123456", "emailaddress" "joel\@tremau com", "customerspecific" {} }, "reportee" { "id" "{{$randompassword}}", "name" "reportee john", "lang" "en", "phonenumber" "070 564123", "emailaddress" "joel\@tremau com", "customerspecific" {} }, "location" { "city" "stockholm", "postalcode" "111 57", "region" "stockholm", "countrycode" "se", "ipaddress" "192 168 0 1", "customerspecific" {} }, "label" \[ "terrorist propaganda" ] } ] } api response success response the api returns a summary indicating the number of cases successfully scheduled for moderation { "message" "2 cases scheduled for moderation" } request structure while proactive detection in nima and automated moderation will moderate the majority of harmful content and check all content posted, it may be the case that your users will report content in nima, you can integrate your existing and current user reporting flow to make sure user reports are promptly reviewed by human moderators note this reporting flow is separate from the dsa reporting flow, which is instead detailed here \[link to be added] overview the user reports api of nima allows you to connect your reporting flows to nima this enables your moderation team to review user generated content reports from your platform and take action on flagged content through a centralized console api endpoint post /queues/process file the review workflow to integrate user reports from your platform into nima, use the user reports api the workflow is as follows a user flags content on your platform your system sends the report to nima via the user reports api nima routes the report into a dedicated moderation queue your moderators review the report in the nima console and take appropriate action api integration making a request submit user reports by making a post request to /queues/process file the request must include the required headers and a json payload containing the report details curl location g '{{url}}/queues/process file' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data raw '{ "priority" "severe", "channel" "user report", "reason for request" "lorem abuse reason for request", "customerspecific" {}, "content" { "content id" "098765434567", "title" "content title", "body" "an optional text description of the submitted content ", "url" "https //images unsplash com/photo 1585589266882 2cb137ba7db6?ixlib=rb 4 0 3\&ixid=m3wxmja3fdb8mhxwag90by1wywdlfhx8fgvufdb8fhx8fa%3d%3d\&auto=format\&fit=crop\&w=725\&q=80", "token" "a livestreaming video token when content type is livestream", "type" { "id" "img" }, "status" "published", "customerspecific" { "post likes" "12", "post views" "12" } }, "reporter" { "id" "321", "name" "reporter james", "phonenumber" "070 123456", "emailaddress" "reporter\@tremau net", "customerspecific" { "reporter account creation date" "2023 04 03", "reporter account verified" "true" } }, "reportee" { "id" "123", "name" "reportee john", "phonenumber" "070 564123", "emailaddress" "reportee\@tremau net", "customerspecific" { "reportee account creation date" "2023 04 03", "reportee account verified" "true" } }, "location" { "city" "stockholm", "postalcode" "111 57", "region" "stockholm", "countrycode" "se", "ipaddress" "192 168 0 1", "customerspecific" {} }, "label" \[ "nudity" ] }' request parameters global parameters true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type content true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type reporter true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type reportee true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type location the location attribute is optional if provided, it can contain any of the following location data points true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type a note on customerspecific the global, content, reportee and reporter attributes all possess an optional field which accepts an object customerspecific key value pairs will always be accepted; however, to observe these customerspecific attributes in the metadata on the moderation dashboard, you must configure these custom attributes in the "admin settings > custom attributes" configuration page api response the api returns a structured response to confirm successful processing or indicate validation errors success response a successful call to /queues/process file returns the following response { "message" "success", "ok" true } error response if mandatory fields are missing or contain invalid data, the api will return a validation error detailing the specific failures { "statuscode" 400, "message" \[ "content title must be a string", "content title should not be empty" ], "error" "bad request" } error handling the following error may occur when submitting user reports true 172,172,172,175 left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type left unhandled content type key points array format wrap all reports in an items array individual structure each item must contain all required fields (content, reporter, reportee, etc ) validation all items are validated before processing if any item fails validation, the entire request may be rejected transaction the bulk submission is processed as a single transaction