> For the complete documentation index, see [llms.txt](https://docs.digit.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digit.org/complaints-management/design/architecture/cms-workflows.md).

# CMS Workflows

The default workflow configured for CMS is based on this [functional flow](/complaints-management/access/pgr-functional-specifications/pgr-workflows.md). The functional spec is translated into JSON.  Refer to the [Workflow service here](https://core.digit.org/platform/core-services/workflow) for details. The workflow JSON for the default workflow is given below.&#x20;

To know more about how to use this to configure the workflow, refer to the [configuration document here.](/complaints-management/deploy/configure/workflow.md)

```
{
  "RequestInfo": {
    "apiId": "Rainmaker",
    "action": "",
    "did": 1,
    "key": "",
    "msgId": "20170310130900|en_IN",
    "requesterId": "",
    "ts": 1513579888683,
    "ver": ".01",
    "userInfo": {
      "id": 73,
      "userName": null,
      "name": null,
      "type": "EMPLOYEE",
      "mobileNumber": null,
      "emailId": null,
      "roles": [
        {
          "id": 2,
          "name": "Customer Support Representative",
          "code": null,
          "tenantId": null
        }
      ],
      "tenantId": null,
      "uuid": "uuid"
    }
  },
  "BusinessServices": [
    {
      "tenantId": "{{tenantId}}",
      "businessService": "PGR",
      "business": "pgr-services",
      "businessServiceSla": 432000000,
      "states": [
        {
          "sla": null,
          "state": null,
          "applicationStatus": null,
          "docUploadRequired": false,
          "isStartState": true,
          "isTerminateState": false,
          "isStateUpdatable": true,
          "actions": [
            {
              "action": "APPLY",
              "nextState": "PENDINGFORASSIGNMENT",
              "roles": [
                "CITIZEN",
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER"
              ]
            }
          ]
        },
        {
          "sla": null,
          "state": "PENDINGFORASSIGNMENT",
          "applicationStatus": "PENDINGFORASSIGNMENT",
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": false,
          "isStateUpdatable": false,
          "actions": [
            {
              "action": "COMMENT",
              "nextState": "PENDINGFORASSIGNMENT",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "ASSIGN",
              "nextState": "PENDINGATLME",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER"
              ]
            },
            {
              "action": "REJECT",
              "nextState": "REJECTED",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER"
              ]
            }
          ]
        },
        {
          "sla": null,
          "state": "PENDINGFORREASSIGNMENT",
          "applicationStatus": "PENDINGFORREASSIGNMENT",
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": false,
          "isStateUpdatable": false,
          "actions": [
            {
              "action": "COMMENT",
              "nextState": "PENDINGFORREASSIGNMENT",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "REASSIGN",
              "nextState": "PENDINGATLME",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER"
              ]
            },
            {
              "action": "REJECT",
              "nextState": "REJECTED",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER"
              ]
            }
          ]
        },
        {
          "sla": 259200000,
          "state": "PENDINGATLME",
          "applicationStatus": "PENDINGATLME",
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": false,
          "isStateUpdatable": false,
          "actions": [
            {
              "action": "COMMENT",
              "nextState": "PENDINGATLME",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "RESOLVE",
              "nextState": "RESOLVED",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "RESOLVER"
              ]
            },
            {
              "action": "REASSIGN",
              "nextState": "PENDINGFORREASSIGNMENT",
              "roles": [
                "SUPERUSER",
                "ADMIN",
                "COMPLAINTS_ADMIN",
                "ASSIGNER",
                "RESOLVER"
              ]
            }
          ]
        },
        {
          "sla": null,
          "state": "REJECTED",
          "applicationStatus": "REJECTED",
          "isStateUpdatable": false,
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": true,
          "actions": [
            {
              "action": "COMMENT",
              "nextState": "REJECTED",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "REOPEN",
              "nextState": "PENDINGFORASSIGNMENT",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "RATE",
              "nextState": "CLOSEDAFTERREJECTION",
              "roles": [
                "CITIZEN"
              ]
            }
          ]
        },
        {
          "sla": null,
          "state": "RESOLVED",
          "applicationStatus": "RESOLVED",
          "isStateUpdatable": false,
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": true,
          "actions": [
            {
              "action": "COMMENT",
              "nextState": "RESOLVED",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "REOPEN",
              "nextState": "PENDINGFORASSIGNMENT",
              "roles": [
                "CITIZEN"
              ]
            },
            {
              "action": "RATE",
              "nextState": "CLOSEDAFTERRESOLUTION",
              "roles": [
                "CITIZEN"
              ]
            }
          ]
        },
        {
          "sla": null,
          "state": "CLOSEDAFTERREJECTION",
          "applicationStatus": "CLOSEDAFTERREJECTION",
          "isStateUpdatable": false,
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": true
        },
        {
          "sla": null,
          "state": "CLOSEDAFTERRESOLUTION",
          "applicationStatus": "CLOSEDAFTERRESOLUTION",
          "isStateUpdatable": false,
          "docUploadRequired": false,
          "isStartState": false,
          "isTerminateState": true
        }
      ]
    }
  ]
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.digit.org/complaints-management/design/architecture/cms-workflows.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
