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

# Update a rule result

> Update a rule result. Only the fields you send are changed.

Use this to assign an owner, or to exclude a single result from compliance without deactivating
the rule everywhere. `deactivatedReason` is required when setting `deactivated` to `true`.

A result's `status` is computed by Openlayer and cannot be set directly.




## OpenAPI

````yaml patch /rule-results/{ruleResultId}
openapi: 3.0.3
info:
  contact:
    email: support@openlayer.com
    name: Openlayer
    url: https://openlayer.com/
  description: API for interacting with the Openlayer server.
  title: Openlayer API
  version: '1.0'
  x-logo:
    url: https://logo.clearbit.com/openlayer.com
servers:
  - url: https://api.openlayer.com/v1
    description: Our prod backend
security:
  - bearerAuth: []
paths:
  /rule-results/{ruleResultId}:
    patch:
      tags:
        - Governance
      summary: Update a rule result
      description: >
        Update a rule result. Only the fields you send are changed.


        Use this to assign an owner, or to exclude a single result from
        compliance without deactivating

        the rule everywhere. `deactivatedReason` is required when setting
        `deactivated` to `true`.


        A result's `status` is computed by Openlayer and cannot be set directly.
      operationId: updateRuleResult
      parameters:
        - $ref: '#/components/parameters/ruleResultId'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                deactivated: b8c9653c-cd50-485b-93ad-32bca124efd8
                deactivatedReason: 203dde95-39d3-466e-8471-d70a38131078
                assigneeId: ace1afbd-dac5-4921-a628-4230609975de
                blockedBy: 62ade018-03f9-4052-9a28-9f86997a4540
                blocking: 5667e248-ef31-4b34-af3d-cccd42c2408a
      responses:
        '200':
          description: Status OK.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RuleResult'
        default:
          $ref: '#/components/responses/UnexpectedError'
      x-codeSamples:
        - lang: curl
          source: |
            curl --request PATCH \
              --url https://api.openlayer.com/v1/rule-results/2c4e6a8b-1d3f-4b5c-9e7a-0f1b2c3d4e5f \
              --header 'Authorization: Bearer <token>' \
              --header 'Content-Type: application/json' \
              --data '{
                "deactivated": true,
                "deactivatedReason": "Not applicable to this project."
              }'
components:
  parameters:
    ruleResultId:
      name: ruleResultId
      in: path
      description: The rule result id.
      required: true
      schema:
        type: string
        format: uuid
  schemas:
    RuleResult:
      type: object
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
          description: The rule result id.
          example: 5b7d9f1a-2c3e-4d5f-8a6b-9c0d1e2f3a4b
        workspaceId:
          type: string
          format: uuid
          readOnly: true
          description: The id of the workspace the rule result belongs to.
        ruleId:
          type: string
          format: uuid
          readOnly: true
          description: The rule this result belongs to.
        projectId:
          type: string
          format: uuid
          nullable: true
          readOnly: true
          description: >-
            The project this result was evaluated for. `null` for
            workspace-scoped rules.
        status:
          type: string
          enum:
            - running
            - passing
            - failing
            - skipped
            - error
            - pending
            - due_soon
          description: The compliance status of the rule for this entity.
          example: passing
        statusMessage:
          type: string
          nullable: true
          description: A human-readable explanation of the status.
        dateLastEvaluated:
          type: string
          format: date-time
          nullable: true
          readOnly: true
          description: When the rule was last evaluated. Platform rules only.
        dateOfNextEvaluation:
          type: string
          format: date-time
          nullable: true
          readOnly: true
          description: When the rule will next be evaluated. Platform rules only.
        dateOfLatestEvidence:
          type: string
          format: date-time
          nullable: true
          readOnly: true
          description: >-
            When the most recent piece of evidence was attached. Evidence rules
            only.
        dateOfRenewal:
          type: string
          format: date-time
          nullable: true
          readOnly: true
          description: >-
            When the evidence must be renewed. Evidence rules with a renewal
            cadence only.
        deactivated:
          type: boolean
          default: false
          description: Whether this result is excluded from compliance calculations.
        deactivatedReason:
          type: string
          nullable: true
          description: Why the result was excluded.
        assigneeId:
          type: string
          format: uuid
          nullable: true
          description: The user responsible for this result.
        blockedBy:
          type: array
          default: []
          description: Rule results that must pass before this one can be satisfied.
          items:
            type: object
            properties:
              id:
                type: string
                format: uuid
              status: f8525691-88dc-400b-a084-7ed44d40a6d2
        blocking:
          type: array
          default: []
          description: Rule results that this one blocks.
          items:
            type: object
            properties:
              id:
                type: string
                format: uuid
              status: f8525691-88dc-400b-a084-7ed44d40a6d2
        dateCreated:
          type: string
          format: date-time
          readOnly: true
          description: The creation date.
          example: '2026-03-22T11:31:01.185Z'
        dateUpdated:
          type: string
          format: date-time
          readOnly: true
          description: The last update date.
          example: '2026-03-22T11:31:01.185Z'
      required:
        - id
        - workspaceId
        - ruleId
        - status
        - deactivated
        - dateCreated
        - dateUpdated
  responses:
    UnexpectedError:
      description: Unexpected error.
      content:
        application/json:
          schema:
            type: object
            required:
              - code
              - error
            properties:
              code:
                type: integer
                format: int32
              error:
                type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >
        Bearer authentication header of the form `Bearer <token>`, where
        `<token>` is your workspace API key. See [Find your API
        key](https://www.openlayer.com/docs/workspace-and-projects/find-your-api-key)
        for more information.

````