> ## Documentation Index
> Fetch the complete documentation index at: https://cpgrams.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Grievance Status

> Update the status of a grievance

Updates the status of an existing grievance. This endpoint requires authentication via a bearer token. The required field is `status`, which must be one of the valid status options (pending, in\_progress, resolved, rejected). Optional fields include `resolution_notes` which can provide additional information about the status change.

If the grievance is not found, a 404 error is returned. If an invalid status is provided, a 400 error is returned with details about the valid status options.

The response includes the ID of the updated grievance, a status message indicating successful update, and the fields that were updated.


## OpenAPI

````yaml PUT /grievances/{grievance_id}
openapi: 3.1.0
info:
  title: CPGRAMS Simulation API
  description: >-
    An API that simulates the Centralized Public Grievance Redress and
    Monitoring System (CPGRAMS) in India
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://grm-api.vercel.app
security:
  - bearerAuth: []
externalDocs:
  description: API Documentation
  url: https://grm-api.vercel.app/docs
paths:
  /grievances/{grievance_id}:
    put:
      description: Update the status of a grievance
      parameters:
        - name: grievance_id
          in: path
          description: ID of grievance to update
          required: true
          schema:
            type: string
      requestBody:
        description: Status update for the grievance
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GrievanceUpdate'
        required: true
      responses:
        '200':
          description: Updated grievance
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GrievanceUpdateResponse'
        '400':
          description: Bad request - Invalid status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Grievance not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    GrievanceUpdate:
      type: object
      properties:
        status:
          description: New status for the grievance
          type: string
          enum:
            - Active
            - Pending
            - Closed with resolution
            - Closed without resolution
            - Tender Issued
        resolution_notes:
          description: Notes explaining the resolution or status change
          type: string
        officer_closed_by:
          description: Officer who closed the grievance
          type: string
        final_status:
          description: Final status of the grievance
          type: string
        grievance_closing_date:
          description: Date when the grievance was closed
          type: string
          format: date-time
    GrievanceUpdateResponse:
      type: object
      properties:
        id:
          type: string
          description: ID of the updated grievance
        status:
          type: string
          description: Status message
        updated_fields:
          type: object
          description: Fields that were updated
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````