---
title: "PUT /api/v1/groups/rules/{ruleId}"
method: PUT
path: "/api/v1/groups/rules/{ruleId}"
tags: ["Group"]
---

# PUT /api/v1/groups/rules/{ruleId}

`PUT /api/v1/groups/rules/{ruleId}`

## Request

- Base URL: `https://your-subdomain.okta.com`
- URL: `https://your-subdomain.okta.com/api/v1/groups/rules/{ruleId}`
- Auth: API key in header `Authorization`

Updates a group rule. Only `INACTIVE` rules can be updated.

## Path parameters

- `ruleId` string, required

## Request body

- GroupRule
  - `actions` GroupRuleAction
    - `assignUserToGroups` GroupRuleGroupAssignment
      - `groupIds` string[]
  - `conditions` GroupRuleConditions
    - `expression` GroupRuleExpression
      - `type` string
      - `value` string
    - `people` GroupRulePeopleCondition
      - `groups` GroupRuleGroupCondition
        - `exclude` string[]
        - `include` string[]
      - `users` GroupRuleUserCondition
        - `exclude` string[]
        - `include` string[]
  - `created` string, date-time
  - `id` string
  - `lastUpdated` string, date-time
  - `name` string
  - `status` 'ACTIVE' | 'INACTIVE' | 'INVALID'
  - `type` string

## Response `200`

Success

- GroupRule
  - `actions` GroupRuleAction
    - `assignUserToGroups` GroupRuleGroupAssignment
      - `groupIds` string[]
  - `conditions` GroupRuleConditions
    - `expression` GroupRuleExpression
      - `type` string
      - `value` string
    - `people` GroupRulePeopleCondition
      - `groups` GroupRuleGroupCondition
        - `exclude` string[]
        - `include` string[]
      - `users` GroupRuleUserCondition
        - `exclude` string[]
        - `include` string[]
  - `created` string, date-time
  - `id` string
  - `lastUpdated` string, date-time
  - `name` string
  - `status` 'ACTIVE' | 'INACTIVE' | 'INVALID'
  - `type` string

---

[API](https://skmtc.dev/okta/apis/okta-api.md) - [All operations](https://skmtc.dev/okta/apis/okta-api/llms.txt) - [OpenAPI document](https://skmtc.dev/okta/apis/okta-api/revisions/7e5249c30571?raw)
