---
title: "Update a rule"
method: PATCH
path: "/api/rules/{ruleId}"
tags: ["Rules"]
---

# Update a rule

`PATCH /api/rules/{ruleId}`

## Request

- Base URL: `https://api.historis.app`
- URL: `https://api.historis.app/api/rules/{ruleId}`
- Auth: HTTP bearer

## Request body

- RuleInput
  - `name` string, required
  - `body` string, required: Markdown rule body
  - `enabled` boolean

## Response `200`

Updated rule

- object

## Other responses

- `400`: Request failed schema validation
- `401`: Missing or invalid credentials
- `429`: Rate limit exceeded for the caller's identity/plan
- `500`: Internal server error

---

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