Skip to main content

HttpResponseFilter

A filter that is used to select on properties of the HTTP response received. When used with additional filters, a response will be selected if it matches any of the filter's criteria.

  • type: object
  • required: ["type"]

type​

  • Required: Yes
  • type: string
  • enum: ["HttpResponseFilter"]

action​

Action to execute if a response matches the filter.

  • Required: No
  • type: string
  • enum: ["SUCCESS","FAIL","RETRY","IGNORE","RESET_PAGINATION","RATE_LIMITED","REFRESH_TOKEN_THEN_RETRY","REDUCE_PAGE_SIZE","SPLIT_REQUEST_WINDOW"]

Examples:

SUCCESS
FAIL
RETRY
IGNORE
RESET_PAGINATION
RATE_LIMITED
REFRESH_TOKEN_THEN_RETRY
REDUCE_PAGE_SIZE
SPLIT_REQUEST_WINDOW

failure_type​

Failure type of traced exception if a response matches the filter.

  • Required: No
  • type: string
  • enum: ["system_error","config_error","transient_error"]

Examples:

system_error
config_error
transient_error

error_message​

Error Message to display if the response matches the filter.

Examples:

Skipping {{ request_url }} (HTTP 404).

error_message_contains​

Match the response if its error message contains the substring.

  • Required: No
  • type: string

http_codes​

Match the response if its HTTP code is included in this list.

  • Required: No
  • type: array
  • uniqueItems: true

Examples:

- 420
- 429
- 500
  • items:

    • type: integer

predicate​

Match the response if the predicate evaluates to true.

Examples:

{{ 'Too much requests' in response }}
{{ response.get('message') == 'Not Found' and request_url.endswith('/stargazers') }}
{{ 'error_code' in response and response['error_code'] == 'ComplexityException' }}

$parameters​

  • Required: No
  • type: object