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

# PATCH - Rubric Criteria

>  This API allows authenticated users to partially update  an existing rubric criteria using its ID. Only the fields that need modification should be sent in the request body.


 **Key Notes:** 
 - This is a **partial update**, so all fields are optional. 
 - Useful when you want to update just one or two properties like `maxScore` or `scoringLogic`. 
 - Returns the updated rubric criteria along with its metadata.


 **Fields You Can Update:** 
 - `name`: Title of the criteria (e.g., *Cohesiveness*). 
 - `description`: (Optional) More context or explanation of the criteria. 
 - `maxScore` / `minScore`: Scoring range (e.g., *1 Star* to *5 Star*). 
 - `scoringLogic`: Array of objects defining logic per score.


 **Scenario: Editing Scoring Logic**

 A teacher wants to improve clarity in the scoring explanation for a specific score value. 



## OpenAPI

````yaml PATCH /rubrics/v1/rubric/{id}/criteria/{criteriaId}/
openapi: 3.0.1
info:
  title: Evaluation Report API
  description: An API for retrieving evaluation reports.
  version: 1.0.0
servers:
  - url: https://api-staging.crazygoldfish.com
    description: SandBox endpoint
  - url: https://api.crazygoldfish.com
    description: Prod End Point
security: []
paths:
  /rubrics/v1/rubric/{id}/criteria/{criteriaId}/:
    patch:
      tags:
        - Rubrics
      summary: Update Rubric Criteria
      description: >-
        Allows authenticated users to partially update a specific rubric
        criteria by ID.
      operationId: updateRubricCriteria
      parameters:
        - name: id
          in: path
          required: true
          description: ID of the rubric the criteria belongs to
          schema:
            type: string
        - name: criteriaId
          in: path
          required: true
          description: ID of the rubric criteria to be updated
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  example: Cohesiveness
                  description: Name of the rubric criteria
                description:
                  type: string
                  example: Optional detailed info about this criteria
                  description: Description of the rubric criteria
                maxScore:
                  type: string
                  example: 5 Star
                  description: Maximum score for the criterion
                minScore:
                  type: string
                  example: 1 Star
                  description: Minimum score for the criterion
                scoringLogic:
                  type: array
                  items:
                    type: object
                    properties:
                      score:
                        type: string
                        example: 5 Star
                        description: Score for the criterion
                      scoringLogic:
                        type: string
                        example: >-
                          Logical & coherent sequence with a smooth beginning, a
                          solid middle & an impactful conclusion
                        description: Scoring logic for the criterion
                    required:
                      - score
                      - scoringLogic
      responses:
        '200':
          description: Rubric criteria updated successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    example: d102b0ff-1111-4235-b8e9-764ef03c57cb
                    description: Unique identifier for the rubric criteria
                  name:
                    type: string
                    example: Cohesiveness
                    description: Name of the rubric criteria
                  maxScore:
                    type: string
                    example: 5 Star
                    description: Maximum score for the criterion
                  minScore:
                    type: string
                    example: 1 Star
                    description: Minimum score for the criterion
                  scoringLogic:
                    type: array
                    items:
                      type: object
                      properties:
                        score:
                          type: string
                          example: 5 Star
                          description: Score for the criterion
                        scoringLogic:
                          type: string
                          example: >-
                            Logical & coherent sequence with a smooth beginning,
                            a solid middle & an impactful conclusion
                          description: Scoring logic for the criterion
                  createdAt:
                    type: string
                    format: date-time
                    example: '2025-03-27T11:34:53.172550Z'
                    description: Timestamp when the rubric criteria was created
                  modifiedAt:
                    type: string
                    format: date-time
                    example: '2025-03-27T11:35:17.739952Z'
                    description: Timestamp when the rubric criteria was last modified
        '400':
          description: Bad Request - Invalid input or missing required fields
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: integer
                        example: 400
                      message:
                        type: object
                        properties:
                          scoringLogic:
                            type: array
                            items:
                              type: object
                              properties:
                                score:
                                  type: array
                                  items:
                                    type: string
                                    example: This field is required.
        '403':
          description: Authentication failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/403Response'
      security:
        - bearerAuth: []
components:
  schemas:
    403Response:
      type: object
      properties:
        detail:
          type: string
          example: Token has expired
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````