# Reorder shield rules

> Replace the whole evaluation order in one call.

`PUT https://inboundr.net/api/v1/shield-rules`

Sets the order every [shield rule](/concepts/shield) is evaluated in. Position 0
is checked first.

This is the collection endpoint because that is what the operation is about: it
names every rule at once. To nudge a single rule one place, the per-rule
[`{ "move": "up" }`](/api-reference/shield-rules/update) spelling is shorter.

<ParamField body="order" type="array" required>
  Rule ids (`sr_…`) in the order you want them evaluated. Must be a permutation
  of **exactly** the account's rules — every rule present, none repeated.
</ParamField>

```json
{ "order": ["sr_456", "sr_123", "sr_789"] }
```

<ResponseExample>
```json 200
{
  "order": ["sr_456", "sr_123", "sr_789"]
}
```
</ResponseExample>

<Note>
  A list that is missing a rule, repeats one, or names a rule that isn't yours
  is rejected with `409` and **nothing is written**. That is deliberate: the
  usual cause is a client holding a list from before a rule was created or
  deleted somewhere else, and partially applying it would leave two rules
  fighting over one position. Re-read
  [the list](/api-reference/shield-rules/list) and send the order again.
</Note>

<Note>
  Priorities are rewritten to a dense `0…n-1` on every call, so gaps left by
  deleted rules are tidied up as a side effect.
</Note>
