Getting Started

Introduction

Installation

API Client

Overview

Make an API Request

Replay request from History

Import from cURL

Inspect Traffic

Overview

Filtering Traffic

Save Session

View Request/Response Details

HTTP Rules (Modify Traffic)

Overview

Redirect URL (Map Local, Map Remote)

Replace Strings (Switch Hosts, API Endpoints)

Modify Headers

Modify Request Body

Modify Response Body

Modify Query Params

Modify Cookies

Modify DOM/Inject scripts

Modify User Agents

Delay Request

Cancel Rule

Organizing Rules

Import/Export Rules from File

Pause/Resume Requestly

Rule Operators

Advance Targeting

Sharing Rules

Map Local

Map Remote

Pinning Rules

GraphQL Support

Edit and Replay

Import Setting from Charles Proxy

Test URL Condition

Mock Server

Overview

Create New Mock API

Test Mock API

Pre-Configured Mocks

File Server

Overview

Create New Mock File

Sessions

Overview

Test URL Condition

Test URL condition feature helps you validate whether the rule source url condition you have setup works for the request URL you want it work with. This helps improving your rule creation and editing experience more fluent especially when using regex or wildcard operators.

To test a URL condition:

  1. Open any rule editor
  2. Enter the source url condition which suits your case
  3. Click on the flask icon, this opens a test URL popup modal

test url condition walkthrough.gif

This popup modal has these following components:

  1. Source condition: This is the source condition which was earlier defined in the rule editor. This is editable, you can change the source condition to satisfy the rule condition if required.
  2. URL field: Enter the complete URL on which you want the rule to be applied
  3. Result: Here the test results show up indicating if the rule will be applied on the URL entered in the URL field or not**.**

Testing URL with Regex Condition

To test a URL with a regex pattern in source url condition, In the URL field, enter the complete URL on which you want to apply the rule. The result will show whether the rule will be applied on the URL or not based on the regex pattern.

Screenshot 2023-07-25 at 9.41.53 AM.png

Examples:

Source condition: /^https://.*github.*/ URL entered: https://subdomain.github.io/ Result: ✅ The URL matches the source condition defined

Source condition: /^https://blog\\..*\\.com$/ URL entered: https://blog.example.com/ Result: ✅ The URL matches the source condition defined

Source condition: /^((?!example).)*$/ URL entered: https://www.examplewebsite.com/ Result: ❌ The URL does not matches the source condition defined

<aside> 💡 NOTE Make sure that the regex pattern in source condition is valid and enclosed with slashes(/). Example:
/^https://.*github.* ❌ Invalid regex /^https://.*github.*/ ✅ Valid regex /(.+)://(.+).example.com/ig ✅ Valid regex

</aside>

Testing URL with Wildcard Condition

To test a URL with a wildcard pattern in source url condition, In the URL field, enter the complete URL on which you want to apply the rule. The result will show whether the rule will be applied on the URL or not based on the wildcard pattern.

Screenshot 2023-07-25 at 5.14.02 PM.png

Examples:

Source condition: *://*.yahoo.com URL entered: http://cricket.yahoo.com Result: ✅ The URL matches the source condition defined

Source condition: *google*.com?param=* URL entered: https://www.google.com/page?param=value Result: ✅ The URL matches the source condition defined

Source condition: *example*.com?param=* URL entered: https://www.examplewebsite.com/page?param=test Result: ❌ The URL does not matches the source condition defined