Authorized Request Validator rule
API rule to perform generic validation steps on requests after authorization
Rule execution order
- The Early Request Validator rule executes before authentication.
- The Authorized Request Validator rule executes after authorization.
Field | Description |
---|---|
When this rule should be applied | An expression that defines one or more conditions that must be
true for the rule to execute.
Example: The expression |
Validation Checks | A table of checks to perform on the request.
Default value: N/A Example: N/A |
Condition | An expression that should return true if the request should be aborted.
Note:
You cannot use Default value: False Example: isNaN(parseInt(request.headers['X-My-Header'])) |
Status | The HTTP Status code to use in the response.
Default value: 400 (Bad Request) Example: 413 (Request Entity Too Large) |
Response | The response to send to the client.
Default value: N/A Example: To return a custom HTML page:
To return a Location header for a 3xx status code:
|
Description |
Required. A brief description of this rule. Default value: Requests are being authorized against specified rules |
These rules allow a great deal of flexibility in determining how a request is handled before it reaches a Pipeline; as such, you must carefully consider the request flow of your API when configuring this rule.