---
title: "Add a rule to a rule set"
method: POST
path: "/rule-sets/{id}/rules"
tags: ["Rule Sets"]
---

# Add a rule to a rule set

`POST /rule-sets/{id}/rules`

## Request

- Base URL: `https://next.frase.io/api/v1`
- URL: `https://next.frase.io/api/v1/rule-sets/{id}/rules`
- Auth: API key in header `X-API-KEY`

Attach an existing rule to a rule set at an optional sort position. System rule sets cannot be modified.

## Path parameters

- `id` string, uuid, required

## Request body

- object
  - `rule_id` string, uuid, required: Required. The rule to attach.
  - `sort_order` integer: Optional position of the rule within the set.

## Response `201`

Rule attached to the set

- object
  - `data` object
    - `id` string, uuid: The rule-set-to-rule link ID.
    - `rule_set_id` string, uuid
    - `rule_id` string, uuid
    - `sort_order` integer, nullable
  - `request_id` string

## Other responses

- `400`: Validation failed
- `401`: Authentication failed
- `403`: System rule set cannot be modified
- `404`: Resource not found
- `409`: The rule is already attached to this set
- `429`: Rate limited, or the org's monthly brief limit blocked minting the refreshed brief (only the FIRST supersession of a brief is billing-exempt; repeats meter normally)

---

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