feat: add canOperateReports and canFlagReportContent functions for report management
This commit is contained in:
+4
-3
@@ -32,13 +32,14 @@ Authorization: Bearer <token>
|
||||
- `GET /reports/{id}/intervention-summary`: operator-facing report summary with
|
||||
citizen contact data, media and latest messages.
|
||||
- `PATCH /reports/{id}/status`: update status.
|
||||
- `POST /reports/{id}/take`: operator/admin takes an open report.
|
||||
- `POST /reports/{id}/take`: assigned-queue operator takes an open report.
|
||||
- `POST /reports/{id}/messages`: write a report message.
|
||||
- `GET /reports/{id}/messages`: list report messages.
|
||||
- `POST /reports/{id}/messages/{message_id}/flags`: flag a message for moderation.
|
||||
- `POST /reports/{id}/messages/{message_id}/flags`: assigned operator flags a
|
||||
report message for moderation.
|
||||
- `POST /reports/{id}/assignments`: assign a team.
|
||||
- `POST /reports/{id}/feedback`: add citizen feedback.
|
||||
- `POST /reports/{id}/flags`: flag a report for moderation.
|
||||
- `POST /reports/{id}/flags`: assigned operator flags a report for moderation.
|
||||
- `POST /reports/{id}/media`: upload up to five multipart media files. Supported
|
||||
types are JPEG, PNG, WebP, MP4, WebM and QuickTime.
|
||||
|
||||
|
||||
@@ -8,7 +8,8 @@ assign and resolve interventions while preserving history and basic analytics.
|
||||
- `citizen`: registers, requests OTP login, creates reports, follows own reports,
|
||||
sends messages and leaves feedback after resolution.
|
||||
- `operator`: views reports, takes open reports, assigns teams, updates managed
|
||||
reports and messages citizens.
|
||||
reports, messages citizens and flags abusive/fake citizen content on managed
|
||||
reports.
|
||||
- `admin`: manages users, roles, reference data, teams, areas and all reports.
|
||||
|
||||
The system admin seed must change password before using protected operational
|
||||
@@ -25,7 +26,7 @@ or administrative APIs.
|
||||
|
||||
Valid milestone 2 transitions:
|
||||
|
||||
- `OPEN -> UNDER_REVIEW` when an operator/admin takes the report.
|
||||
- `OPEN -> UNDER_REVIEW` when an operator takes the report.
|
||||
- `UNDER_REVIEW -> ASSIGNED` when a team is assigned.
|
||||
- `ASSIGNED -> IN_PROGRESS`.
|
||||
- `IN_PROGRESS -> RESOLVED`.
|
||||
|
||||
@@ -3056,7 +3056,7 @@
|
||||
},
|
||||
"/api/v1/reports/{id}/flags": {
|
||||
"post": {
|
||||
"description": "Creates a moderation flag for a report.",
|
||||
"description": "Creates a moderation flag for a report by assigned operator only.",
|
||||
"operationId": "ReportController.flagReport",
|
||||
"parameters": [
|
||||
{
|
||||
@@ -3313,7 +3313,7 @@
|
||||
},
|
||||
"/api/v1/reports/{id}/messages/{message_id}/flags": {
|
||||
"post": {
|
||||
"description": "Creates a moderation flag for a report message.",
|
||||
"description": "Creates a moderation flag for a report message by assigned operator only.",
|
||||
"operationId": "ReportController.flagMessage",
|
||||
"parameters": [
|
||||
{
|
||||
@@ -3436,7 +3436,7 @@
|
||||
},
|
||||
"/api/v1/reports/{id}/take": {
|
||||
"post": {
|
||||
"description": "Assigns an open report to the current operator.",
|
||||
"description": "Assigns an open report to current non-admin operator.",
|
||||
"operationId": "ReportController.takeReport",
|
||||
"parameters": [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user