---
title: "Delete one of this customer's merchant rules"
method: DELETE
path: "/accountant/companies/{customerId}/merchant-rules/{id}"
tags: ["Accountant Portal"]
---

# Delete one of this customer's merchant rules

`DELETE /accountant/companies/{customerId}/merchant-rules/{id}`

## Request

- Base URL: `https://api.medianfi.com/api/v1`
- URL: `https://api.medianfi.com/api/v1/accountant/companies/{customerId}/merchant-rules/{id}`
- Auth: HTTP bearer

#3039. Accountant login only: the service token is refused. Later rows the rule would have matched fall back to the other rules and the engine, and so to review. Only a rule that belongs to this customer can be deleted; another company's rule and a global rule are 404. Writes an audit_logs row (entity_type merchant_rule, action delete) with the rule as it was.

## Response `204`

Deleted

## Other responses

- `401`: Authentication required
- `403`: Insufficient permissions or not a company member
- `404`: Resource not found

---

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