---
title: "Set Edge Rule Enabled"
method: POST
path: "/pullzone/{pullZoneId}/edgerules/{edgeRuleId}/setEdgeRuleEnabled"
tags: ["Pull Zone"]
---

# Set Edge Rule Enabled

`POST /pullzone/{pullZoneId}/edgerules/{edgeRuleId}/setEdgeRuleEnabled`

## Request

- Base URL: `https://api.bunny.net`
- URL: `https://api.bunny.net/pullzone/{pullZoneId}/edgerules/{edgeRuleId}/setEdgeRuleEnabled`
- Auth: API key in header `AccessKey`
- TypeScript: <https://skmtc.dev/bunny/apis/bunny-net-api/docs/pullzone/:pullZoneId/edgerules/:edgeRuleId/setEdgeRuleEnabled/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `pullZoneId` integer, required
- `edgeRuleId` string, nullable, required

## Request body

- ToggleRequestModel
  - `Id` integer
  - `Value` boolean

## Response `204`

The Edge Rule was successfully updated

## Other responses

- `400`: Failed configuring the Edge Rule. Model validation failed
- `401`: The request authorization failed
- `404`: The Pull Zone or Edge Rule with the requested ID does not exist.
- `500`: Internal Server Error

---

[API](https://skmtc.dev/bunny/apis/bunny-net-api.md) - [All operations](https://skmtc.dev/bunny/apis/bunny-net-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bunny/apis/bunny-net-api/revisions/2b06f94dbfbf?raw)
