---
title: "Update a catalog rule"
method: PUT
path: "/marketing/catalog-rules/{id}"
tags: ["Admin Marketing: Promotions"]
---

# Update a catalog rule

`PUT /marketing/catalog-rules/{id}`

## Request

- Base URL: `http://localhost:8000/api/admin`
- URL: `http://localhost:8000/api/admin/marketing/catalog-rules/{id}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/bagisto/apis/bagisto-admin-api/docs/marketing/catalog-rules/:id/put.ts> (a function with typed inputs; its response is checked against the schema)

Partial update — send only the fields you change. channels + customer_groups, when supplied, fully replace the current pivots.

## Path parameters

- `id` string, required

## Request body

- object
  - `name` string
  - `description` string
  - `channels` integer[]
  - `customer_groups` integer[]
  - `condition_type` 1 | 2
  - `conditions` object[]
  - `end_other_rules` 0 | 1
  - `action_type` 'by_percent' | 'by_fixed'
  - `discount_amount` number
  - `sort_order` integer
  - `starts_from` string
  - `ends_till` string
  - `status` 0 | 1

## Response `200`

Catalog rule updated; returns the updated detail.

## Other responses

- `400`: Invalid input
- `404`: Catalog rule not found.
- `422`: Validation failure.

---

[API](https://skmtc.dev/bagisto/apis/bagisto-admin-api.md) - [All operations](https://skmtc.dev/bagisto/apis/bagisto-admin-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bagisto/apis/bagisto-admin-api/revisions/3198f11be70f?raw)
