# ReplaceIncentiveRules

> Replace an incentive's rules; the old ones are not kept. Irreversible. Write access, incentives toolset, MCP tool replace_incentive_rules.

> **Warning:**
> Irreversible. This operation removes or replaces something. MCP clients see it with `destructiveHint` set, and an agent should tell you what it will change and wait for your yes.

**Access:** [Write](https://developer.missin.co.uk/get-started/authentication.md#access-levels)

## Variables

| Variable | Type | Required | Accepts | Description |
|---|---|---|---|---|
| `input` | `ReplaceIncentiveRulesInput!` | yes | Input object, below |  |

## Input types

### ReplaceIncentiveRulesInput

| Field | Type | Required | Accepts | Description |
|---|---|---|---|---|
| `incentiveId` | `UUID!` | yes |  |  |
| `rules` | `JSON!` | yes | Any JSON value. at most 3 items |  |

## Call it

```bash curl
curl https://api.missin.co.uk/graphql/v1 \
  -H "Authorization: Bearer $MISSIN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"operationName":"ReplaceIncentiveRules","variables":{"input":{"incentiveId":"00000000-0000-0000-0000-000000000000","rules":[]}},"extensions":{"persistedQuery":{"version":1,"sha256Hash":"b20d55bf2da8d4a058f4830a6b277a2babe4afb2dcca7579954516624a4db5d3"}}}'
```

## Document

```graphql
mutation ReplaceIncentiveRules($input: ReplaceIncentiveRulesInput!) { __typename replaceIncentiveRules(input: $input) { __typename incentiveId userErrors { __typename code field message } } }
```

Source: https://developer.missin.co.uk/reference/incentives/replace-incentive-rules
