You can either get a list of all your rules or look up a specific rule using its unique ID.
Get All Rules
Retrieve all rules associated with your Requestly Interceptor workspace. This endpoint supports pagination for managing large sets of data. For a live view and to test this API interactively, visit the API Playground.Endpoint
- Method: GET
-
URL:
https://api2.requestly.io/v1/rules
Query Parameters
| Parameter | Type | Description | Required | Default Value |
|---|---|---|---|---|
offset | Integer | The index from where the results should start. Use the value received in nextOffset from the previous response. | No | 0 |
pageSize | Integer | Number of results to return. Maximum value is 75. | No | 30 |
cURL Example:
Sample Responses
Retrieve a Specific Rule
This endpoint allows you to fetch details about a specific rule in your Requestly Interceptor account by its uniqueruleId.
For a live view and to test this API interactively, visit the API Playground.
Endpoint
- Method: GET
-
URL:
https://api2.requestly.io/v1/rules/{ruleId}
Path Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
ruleId | String | The unique ID of the rule to be retrieved. | Yes |
cURL Example
Sample Response
Response Codes
| Status Code | Description |
|---|---|
| 200 | Rule retrieved successfully. |
| 400 | Invalid rule pairs or payload. |
| 401 | Unauthorized action. |
| 404 | Rule or group not found. |
| 429 | Too many requests. |

