New Transparent capture is in preview. Record every app's traffic with no proxy configuration, on Windows, macOS and Linux. Learn more

absoluteUriFilter Filter

Select exchanges whose complete URI (scheme, host, path and query) matches a literal string, prefix, suffix or regular expression.

absoluteUriFilter is the broadest URL based selector available in a Fluxzy rule, it works on the canonical URI as parsed from the request line. Reach for it when no narrower filter is precise enough and pair it with one of the action types below to mutate, mock or observe the matched traffic.

When to use this filter

Use absoluteUriFilter when you need to match a complete URL including the scheme, host, path and query string. It is the right choice when neither the host nor the path alone is specific enough, for example when you want to target only the HTTPS variant of an endpoint, or when the query string carries the meaningful selector.

Typical situations:

  • Targeting a single canonical URL such as https://api.example.com/v2/checkout?region=eu.
  • Filtering by scheme to isolate cleartext HTTP versus HTTPS.
  • Matching a family of URLs with a regular expression that spans host and path.

The filter evaluates on the requestHeaderReceivedFromClient scope, so the full URI is already known when it fires. Prefer hostFilter or pathFilter if you only care about one component, the dedicated filters are faster and easier to read.

Real world examples

Throttle a specific HTTPS endpoint

Slow down traffic to one exact URL to reproduce a customer report about latency on the checkout API, without affecting any other call to the same host.

rules:
- filter:
    typeKind: AbsoluteUriFilter
    pattern: https://api.example.com/v2/checkout
    operation: Exact
  actions:
  - typeKind: AverageThrottleAction
    bandwidthBytesPerSeconds: 32000

Tag every cleartext HTTP exchange with a regex

Identify any request that is still going over plain HTTP so you can audit which clients need to be migrated to HTTPS.

rules:
- filter:
    typeKind: AbsoluteUriFilter
    pattern: ^http://
    operation: Regex
  actions:
  - typeKind: ApplyTagAction
    tag:
      value: cleartext-http

Mock a versioned endpoint family

Return a canned response for any call to v1 of the legacy payments API while leaving v2 untouched. The regex matches both query and pathless variants.

rules:
- filter:
    typeKind: AbsoluteUriFilter
    pattern: ^https://payments\.example\.com/v1/.*
    operation: Regex
  actions:
  - typeKind: MockedResponseAction
    response:
      statusCode: 410
      body:
        type: fromString
        text: "v1 has been retired"
        contentType: text/plain

Reference

absoluteUriFilter

Description

Select exchanges according to URI (scheme, FQDN, path and query). Supports common string search option and regular expression.

Evaluation scope

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

YAML configuration name

absoluteUriFilter

Settings

The following table describes the customizable properties available for this filter:

Property Type Description DefaultValue
pattern string The string pattern to search
operation exact | contains | startsWith | endsWith | regex The search operation performed contains
caseSensitive boolean true if the Search should be case sensitive false
inverted boolean Negate the filter result false

Example of usage

The following examples apply a comment to the filtered exchange

Select only exchanges with the URL matching exactly https://www.fluxzy.io/some-path.

rules:
- filter:
    typeKind: AbsoluteUriFilter
    pattern: https://www.fluxzy.io/some-path
    operation: Exact
  actions:
  - typeKind: ApplyCommentAction
    comment: filter was applied

Match all HTTPS exchanges by checking URL scheme with a regular expression.

rules:
- filter:
    typeKind: AbsoluteUriFilter
    pattern: ^https\:\/\/
    operation: Regex
  actions:
  - typeKind: ApplyCommentAction
    comment: filter was applied

.NET reference

View definition of AbsoluteUriFilter for .NET integration.

See also

The following filters are related to this filter:

Frequently asked questions

How is absoluteUriFilter different from hostFilter or pathFilter?

absoluteUriFilter inspects the entire URL including scheme, host, path and query. hostFilter only looks at the hostname, pathFilter only at the path. Use absoluteUriFilter when the scope of the match spans several URL components.

Does the pattern include the query string?

Yes. The filter evaluates the absolute URI exactly as Fluxzy receives it, so query parameters are part of the searchable text. Use regex if the query order is variable.

Is the comparison case sensitive?

No by default. URLs are normalized to lowercase before comparison unless you set caseSensitive to true.

Can I invert the match to exclude a URL?

Yes. Set inverted: true to select every exchange that does not match the pattern.

Learn more about Fluxzy rules