URL patterns
A condition that keeps a page by matching parts of its URL.
A condition decides whether a fetched page is processed and its result kept. Conditions are configured inside a condition step under a pipeline's steps; a single condition step holds a list of conditions. This page documents the url_patterns condition.
The url_patterns condition matches individual parts of the URL, each given as its own pattern. A page is kept when its URL matches an allow pattern and no deny pattern; default_allow decides the outcome for a URL that matches neither list.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
allow | list of URL patterns | no | empty | Patterns a URL may match to keep the page. |
deny | list of URL patterns | no | empty | Patterns that exclude the page. |
default_allow | boolean | no | false | Whether a URL matching neither list is kept. |
A URL pattern is an object whose fields match URL components such as hostname and pathname. Its fields are documented in the URL pattern table on the Filters page.
steps:
- kind: condition
params:
- kind: url_patterns
params:
allow:
- hostname: example.com
pathname: /products/*