Public Grievance Redressal Service API

Rainmaker-PGR Service Contract

Get service requests

post

Gets the list of service requests for a particular ULB based on search criteria.

  • name: group in: query description: Attribute of service config, it indicate the "Department" for which service type is defined. required: false type: string format: varchar
  • name: serviceCode in: query description: Allows search for service type - comma separated list. type: array items: type: string format: varchar
  • name: startDate in: query description: Earliest epoch time to include in search - request created time | required: false type: integer format: int64
  • name: endDate in: query description: Latest epoch time to include in search - request created time | If search is on start date then end date is mandatory, if end date is null then server will take current date as end date. required: false type: integer format: int64
  • name: lastUpdatedSince in: query description: searches all requests that have been modified/created since last modified epoch time as provided here required: false type: integer format: int64
Responses
200
Successful response sorted by reverse chrnological order of creation
application/json
post
POST /rainmaker-pgr/v2/requests/_search HTTP/1.1
Host: egov-micro-dev.egovernments.org
Accept: */*
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "services": [
    {
      "citizen": {
        "tenantId": "text",
        "name": "text",
        "mobileNumber": "text"
      },
      "tenantId": "text",
      "serviceCode": "text",
      "serviceRequestId": "text",
      "description": "text",
      "lat": 1,
      "long": 1,
      "address": "text",
      "addressId": "text",
      "email": "text",
      "deviceId": "text",
      "accountId": "text",
      "firstName": "text",
      "lastName": "text",
      "phone": "text",
      "attributes": {},
      "status": "New",
      "source": "sms",
      "expectedTime": 1,
      "feedback": "text",
      "rating": "text",
      "landmark": "text",
      "auditDetails": {
        "createdBy": "text",
        "lastModifiedBy": "text",
        "createdTime": 1,
        "lastModifiedTime": 1
      }
    }
  ],
  "actionHistory": [
    {
      "actions": [
        {
          "tenantId": "text",
          "by": "text",
          "isInternal": "text",
          "when": 1,
          "businessKey": "text",
          "action": "text",
          "status": "text",
          "assignee": "text",
          "media": [
            "text"
          ],
          "comment": "text"
        }
      ]
    }
  ]
}

Create service requests

post

Create new service requests - supports batch - please note that in case of errors entire batch is rejected

Body

Request object to fetch the report data

Responses
200
Service Request Created
application/json
post
POST /rainmaker-pgr/v2/requests/_create HTTP/1.1
Host: egov-micro-dev.egovernments.org
Content-Type: application/json
Accept: */*
Content-Length: 685

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "services": [
    {
      "citizen": {
        "tenantId": "text",
        "name": "text",
        "mobileNumber": "text"
      },
      "tenantId": "text",
      "serviceCode": "text",
      "description": "text",
      "lat": 1,
      "long": 1,
      "address": "text",
      "addressId": "text",
      "email": "text",
      "deviceId": "text",
      "accountId": "text",
      "firstName": "text",
      "lastName": "text",
      "phone": "text",
      "attributes": {},
      "status": "New",
      "source": "sms",
      "expectedTime": 1,
      "feedback": "text",
      "rating": "text",
      "landmark": "text"
    }
  ],
  "actionInfo": [
    {
      "tenantId": "text",
      "isInternal": "text",
      "action": "text",
      "assignee": "text",
      "media": [
        "text"
      ],
      "comment": "text"
    }
  ]
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "services": [
    {
      "citizen": {
        "tenantId": "text",
        "name": "text",
        "mobileNumber": "text"
      },
      "tenantId": "text",
      "serviceCode": "text",
      "serviceRequestId": "text",
      "description": "text",
      "lat": 1,
      "long": 1,
      "address": "text",
      "addressId": "text",
      "email": "text",
      "deviceId": "text",
      "accountId": "text",
      "firstName": "text",
      "lastName": "text",
      "phone": "text",
      "attributes": {},
      "status": "New",
      "source": "sms",
      "expectedTime": 1,
      "feedback": "text",
      "rating": "text",
      "landmark": "text",
      "auditDetails": {
        "createdBy": "text",
        "lastModifiedBy": "text",
        "createdTime": 1,
        "lastModifiedTime": 1
      }
    }
  ],
  "actionHistory": [
    {
      "actions": [
        {
          "tenantId": "text",
          "by": "text",
          "isInternal": "text",
          "when": 1,
          "businessKey": "text",
          "action": "text",
          "status": "text",
          "assignee": "text",
          "media": [
            "text"
          ],
          "comment": "text"
        }
      ]
    }
  ]
}

Update service requests

post

Updates service request - supports batch - please note that in case of errors entire batch is rejected

Body

Request object to fetch the report data

Responses
200
Service Request updated
application/json
post
POST /rainmaker-pgr/v2/requests/_update HTTP/1.1
Host: egov-micro-dev.egovernments.org
Content-Type: application/json
Accept: */*
Content-Length: 685

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "services": [
    {
      "citizen": {
        "tenantId": "text",
        "name": "text",
        "mobileNumber": "text"
      },
      "tenantId": "text",
      "serviceCode": "text",
      "description": "text",
      "lat": 1,
      "long": 1,
      "address": "text",
      "addressId": "text",
      "email": "text",
      "deviceId": "text",
      "accountId": "text",
      "firstName": "text",
      "lastName": "text",
      "phone": "text",
      "attributes": {},
      "status": "New",
      "source": "sms",
      "expectedTime": 1,
      "feedback": "text",
      "rating": "text",
      "landmark": "text"
    }
  ],
  "actionInfo": [
    {
      "tenantId": "text",
      "isInternal": "text",
      "action": "text",
      "assignee": "text",
      "media": [
        "text"
      ],
      "comment": "text"
    }
  ]
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "services": [
    {
      "citizen": {
        "tenantId": "text",
        "name": "text",
        "mobileNumber": "text"
      },
      "tenantId": "text",
      "serviceCode": "text",
      "serviceRequestId": "text",
      "description": "text",
      "lat": 1,
      "long": 1,
      "address": "text",
      "addressId": "text",
      "email": "text",
      "deviceId": "text",
      "accountId": "text",
      "firstName": "text",
      "lastName": "text",
      "phone": "text",
      "attributes": {},
      "status": "New",
      "source": "sms",
      "expectedTime": 1,
      "feedback": "text",
      "rating": "text",
      "landmark": "text",
      "auditDetails": {
        "createdBy": "text",
        "lastModifiedBy": "text",
        "createdTime": 1,
        "lastModifiedTime": 1
      }
    }
  ],
  "actionHistory": [
    {
      "actions": [
        {
          "tenantId": "text",
          "by": "text",
          "isInternal": "text",
          "when": 1,
          "businessKey": "text",
          "action": "text",
          "status": "text",
          "assignee": "text",
          "media": [
            "text"
          ],
          "comment": "text"
        }
      ]
    }
  ]
}

Last updated

Was this helpful?