Block the request and return a custom HTTP error response. Allows specifying the status code (e.g., 403, 404, 502) to return to the client. The response body will contain the standard reason phrase for the status code.
Evaluation scope defines the timing where this filter will be applied.
requestHeaderReceivedFromClient This scope occurs the moment fluxzy parsed the request header receiveid from client
rejectWithStatusCodeAction
This action has no specific characteristic
The following examples apply this action to any exchanges
Block with 404 Not Found (hide resource existence).
rules:
- filter:
typeKind: AnyFilter
actions:
- typeKind: RejectWithStatusCodeAction
statusCode: 404
Block with 502 Bad Gateway (simulate server unavailability).
rules:
- filter:
typeKind: AnyFilter
actions:
- typeKind: RejectWithStatusCodeAction
statusCode: 502
View definition of RejectWithStatusCodeAction for .NET integration.
The following actions are related to this action:
What is rule file? | How to integrate rule with Fluxzy Desktop? | How to integrate rule with Fluxzy CLI?