PGR Services v1.0

Overview

The objective of this service is to provide a service that enables users to file complaints and get them resolved. PGR facilitates live tracking of status of the complaint, provides features to upload images, post comments, workflow for complaint resolution and more. The system has a citizen interface and an employee interface.

Pre-requisites

Before you proceed with the configuration, make sure the following pre-requisites are met -

  • Java 8

  • Kafka server is up and running

  • egov-persister service is running and has pgr-services v1 persister config path added in it

  • PSQL server is running and database is created to store complaint data

  • (Optional) Indexer config for pgr-services v1 is added in egov-indexer yaml paths to index the generated data. Index are required for data visualisation in kibana or in DSS.

  • (Optional) Report config for pgr-services v1 is added in Report service config paths. Required if reports are to be provided to the user.

  • Following services should be up and running:

    • egov-user

    • egov-perister

    • egov-localization

    • egov-notification-sms

    • egov-mdms

    • egov-idgen

    • egov-url-shortening

    • egov-hrms

Key Functionalities

  • PGR is the Public Grievance Redressal system on the DIGIT platform that exposes APIs to create, fetch and manage complaints filed by the citizen or CSR on behalf of the citizen.

  • This application also provides a assignment-resolution workflow with defined SLAs. Actors involved in PGR are GRO (Grievance Routing officer who assigns complaints to the LME), DGRO (GRO at the Department level), LME (Last Mile Employee who resolves the complaint), CSR (Citizen Service Representative who can file and act on complaints on behalf of the citizen.), CITIZEN (who files complaint.

Deployment Details

  1. Deploy the latest version of pgr-services

  2. Add pgr-service-persister.yml file in config folder in git and add that path in persister . (The file path is to be added in environment yaml file in param called persist-yml-path )

  3. If any Report Config is created, the config should be added to config folder in git and that path should be added in Report service. (The file path is to be added in file called “reportFileLocationsv1.txt” in Config folder)

  4. If index are to be created add the indexer config path in indexer service. (The file path is to be added in environment yaml file in param called egov-indexer-yaml-repo-path)

Configuration Details

  1. Add master data in MDMS service with module name as RAINMAKER-PGR. Following is some sample master data for the service:

    { "tenantId": "pb", "moduleName": "RAINMAKER-PGR", "ServiceDefs": [ { "serviceCode": "NoStreetlight", "keywords": "streetlight, light, repair, work, pole, electric, power, repair, damage, fix", "department": "Streetlights", "slaHours": 336, "menuPath": "StreetLights", "active": false, "order": 1 }, { "serviceCode": "StreetLightNotWorking", "keywords": "streetlight, light, repair, work, pole, electric, power, repair, fix", "department": "DEPT_1", "slaHours": 336, "menuPath": "StreetLights", "active": true, "order": 2 }, { "serviceCode": "GarbageNeedsTobeCleared", "keywords": "garbage, collect, litter, clean, door, waste, remove, sweeper, sanitation, dump, health, debris, throw", "department": "DEPT_25", "slaHours": 336, "menuPath": "Garbage", "active": true, "order": 3 } ] }

     

  2. Add Role-Action mapping for the API’s in MDMS. Following are the required entries. They should be mapped to both CITIZEN and appropriate employee roles.

    { "id": {{ID_PLACEHOLDER}}, "name": "RainmakerPgrCreate", "url": "/rainmaker-pgr/v1/requests/_create", "displayName": "Rainmaker Pgr Create", "orderNumber": 1, "parentModule": "", "enabled": false, "serviceCode": "rainmaker pgr", "code": "null", "path": "" }, { "id": {{ID_PLACEHOLDER}}, "name": "RainmakerPgrUpdate", "url": "/rainmaker-pgr/v1/requests/_update", "displayName": "Rainmaker Pgr Update", "orderNumber": 1, "parentModule": "", "enabled": false, "serviceCode": "rainmaker pgr", "code": "null", "path": "" }, { "id": {{ID_PLACEHOLDER}}, "name": "RainmakerPgrSearch", "url": "/rainmaker-pgr/v1/requests/_search", "displayName": "Rainmaker Pgr Search", "orderNumber": 1, "parentModule": "", "enabled": false, "serviceCode": "rainmaker pgr", "code": "null", "path": "" }, { "id": {{ID_PLACEHOLDER}}, "name": "RainmakerPgrCount", "url": "/rainmaker-pgr/v1/requests/_count", "displayName": "Rainmaker Pgr Count", "orderNumber": 1, "parentModule": "", "enabled": false, "serviceCode": "rainmaker pgr", "code": "null", "path": "" }

     

  3. Using /localization/messages/v1/_upsert , add localisation (templates) for notification messages to be sent. Following are the product notification templates:

    { "messages": [ { "code": "pgr.sms.notification.assign.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> with ID <id> submitted on <date> has been assigned to <emp_name>, <emp_designation>, <emp_department>. You can track your complaint status and connect with our officials on the on the mSeva Punjab mobile App (download here - <download_link>) or your local municipal web portal.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.assign.employee", "message": "Shri <emp_name>, Complaint for '<complaint_type>' with ID <id> has been assigned to you. Please take appropriate action. <ao_designation> - <ulb>", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.close.employee", "message": "Shri <emp_name>, Complaint for <complaint_type> with ID <id> has received <rating>/5 feedback from the citizen. Thank you for your service.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.comment", "message": "<emp_name> has commented on your complaint for <complaint_type> with complaint ID <id>. Comment - <comment>.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.comment.default", "message": "You have received a comment on your complaint. You can track your complaint status on the mSeva app or your local government web portal.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.default", "message": "Your complaint has been <status>. You can track your complaint status on the mSeva app or your local government web portal", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.reassign.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> with ID <id> submitted on <date> has been re-assigned to <emp_name>, <emp_designation>, <emp_department>. You can track your complaint status and connect with our officials on the on the mSeva Punjab mobile App (download here - <download_link>) or your local municipal web portal.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.reassign.employee", "message": "Shri <emp_name>, Complaint for '<complaint_type>' with ID <id> has been re-assigned as per your request. <ao_designation> - <ulb>", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.reject.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> with ID <id> submitted on <date> has been rejected. Reason for Rejection: <reason>, Additional Comments: <additional_comments> If you wish to re-open the complaint, you can download the mSeva Punjab mobile app (download here - <download_link>) or visit your local municipal website.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.reopen.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> with ID <id> submitted on <date> has been RE-OPEN as per your request. You can track your complaint status and connect with our officials on the mSeva Punjab mobile App (download here - <download_link>) or your local municipal web portal.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.reopen.employee", "message": "Shri <emp_name>, Complaint for <complaint_type> with ID <id> has been re-opened by the citizen. It is being reviewed by Assigning officer - <ulb>.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.resolve.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> with ID <id> submitted on <date> has been resolved by <emp_name>. If you are not satisfied with service you can RE-OPEN complaint through mSeva Punjab mobile App (download here - <download_link>) or your local municipal web portal or by calling our CSR.", "module": "rainmaker-pgr", "locale": "en_IN" }, { "code": "pgr.sms.notification.submit.citizen", "message": "Dear Citizen, Your complaint for <complaint_type> has been submitted with ID <id> on <date>. You can track your complaint status on the mSeva Punjab mobile App (download here - <download link>) or your local municipal web portal.", "module": "rainmaker-pgr", "locale": "en_IN" } ] }

 

Configurable Properties:

 Following are the properties in application.properties file in rainmaker-pgr service which are configurable.

Property

Value

Remarks

kafka.topics.save.service

 

 

save-pgr-service

 

This is the persister topic onto which pgr pushes records for persistence. This is for creating complaints. 

kafka.topics.update.service

 

 

update-pgr-service

 

This is the persister topic onto which pgr pushes records for persistence. This is for updating complaints.

kafka.topics.save.index.service

 

 

save-pgr-index-service

 

This is the indexer topic onto which pgr pushes records for indexing. This is for creating complaints.

kafka.topics.save.index.service

 

 

update-pgr-index-service

 

This is the indexer topic onto which pgr pushes records for indexing. This is for updating complaints.

kafka.topics.notification.complaint

pgr.complaint.notif

Topic to which the pg-notification consumer is subscribed. PGR pushes records to this topic in order to send out sms notifs

notification.sms.enabled

 

true

Key to enable and disable sms notifications

reassign.complaint.enabled

 

true

 

Key to enable notifications on re-assign.

reopen.complaint.enabled

 

true

Key to enable notifications on re-open.

comment.by.employee.notif.enabled

 

false

Key to enable notifications on comment.

notification.allowed.on.status

 

open,assigned,rejected,resolved,closed

 

List of statuses on which notification is allowed.

notification.fallback.locale

 

en_IN

Fallback locale incase the client doesn’t send the locale.

egov.usr.events.notification.enabled

 

true

Key to enable mseva notifications.

egov.usr.events.create.topic

 

persist-user-events-async

 

Topic to which PGR builds and pushes the SYSTEMGENERATED user-events.

egov.usr.events.review.link

 

/citizen/otpLogin?mobileNo=$mobile&redirectTo=complaint-details/$servicerequestid

 

Link to complaint review page.

egov.usr.events.review.code

 

REVIEW

Code to be displayed for the review link.

egov.usr.events.rate.link

 

/citizen/otpLogin?mobileNo=$mobile&redirectTo=feedback/$servicerequestid

 

Link to rate the complaint, accessible to the citizen.

egov.usr.events.rate.code

 

RATE

Code to be displayed for the rate link

egov.usr.events.reopen.link

 

/citizen/otpLogin?mobileNo=$mobile&redirectTo=reopen-complaint/$servicerequestid

 

Link to reopen the complaint, accessible to the citizen.

egov.usr.events.reopen.code

 

REOPEN

Code to be displayed for the reopen link

egov.pgr.app.playstore.link

 

https://dev.digit.org/playstore/download/pgr

UI App link of PGR/mseva to be sent in the sms.

are.inactive.complaintcategories.enabled

 

false

Key to control creation of complaints belonging to inactive complaint categories

is.update.on.inactive.categories.enabled

 

true

Key to control updates on complaints belonging to inactive category

egov.default.expiry.time.before.reopen.in.hours

 

120

No of hours after which a resolved complaint moves to closed state by default. Citizens will not be able to reopen such a complaint.

Integration

Integration Scope

PGR service v1 can be integrated with any organisation or system which wants to track customer queries or complaint.

Integration Benefits

  • Easy tracking and resolution of complaints.

Steps to Integration

  1. Customer can raise a complaint using the /rainmaker-pgr/v1/requests/_create

  2. Organisation or System can search the complaint using /rainmaker-pgr/v1/requests/_searchendpoint

  3. Once the complaint is raised the organisation or system can call /rainmaker-pgr/v1/requests/_update endpoint to move the application further in workflow until it get resolved

Interaction Diagram

 

Reference Docs

Doc Links

Title 

Link

 User Technical Document

User Service  

MDMS Technical Document

https://digit-discuss.atlassian.net/l/c/qxJa051b

IDGen Technical Document

NEEDS TO BE UPDATED

Localization Technical Document

NEEDS TO BE UPDATED

Persister Technical Document

https://digit-discuss.atlassian.net/l/c/5j1Xav10

SMS Notification Technical Document

https://digit-discuss.atlassian.net/l/c/5LxrgCaC

HRMS Technical Document

https://digit-discuss.atlassian.net/l/c/CF5UfyD1

API List