File Server
File Server
Getting Started
Getting Started
Guides
Guides
HTTP Rules (Modify Traffic)
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 Rule
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
Test this Rule
Inspect Traffic
Inspect Traffic
Installation
Installation
New Section
New Section
TroubleShooting
TroubleShooting
Getting Started
Getting Started
Installation
Installation
Inspect Traffic
Inspect Traffic
HTTP Rules (Modify Traffic)
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 Rule
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
Test this Rule
File Server
File Server
Guides
Guides
New Section
New Section
Â
To start debugging the network traffic of your apps running inside iOS simulator, follow these steps
- Download & install Requestly Desktop app
- To install Requestly Root Certificate on your Mac:
a. Navigate toÂ
Connected Apps in the sidebar and choose target Everywhere: System Wideb. Enter system password if prompted
c. Ensure that theÂ
Install & Trust Certs step is successful- Note the proxy URL and port shown at the top of the App. This is where requestly is running it's proxy and where you need to redirect your traffic to from iOS emulator
- Open XCode and choose your project. In the menu clickÂ
Product > Scheme > Edit Scheme
- Set enivronment variablesÂ
http_proxy and Âhttps_proxy to the proxy URL given by Requestly (refer step #3)
- Start the emulatorÂ
Xcode > Open Developer Tool > Simulator
- To verify the proxy settings: Open Safari and navigate toÂ
http://amiusing.requestly.io/Â If it saysÂSuccess, all good till now. Else retry from step #2
- Now you need to install Requestly's Root Certificate in the emulator
- In Safari, navigate toÂ
http://requestly.io/ssl (Use http here, not https) and tapÂAllow to download the Requestly Root Certificate - After downloading the certificate, navigate toÂ
General inÂSettings and chooseÂDevice Management - OpenÂ
RQProxyCAÂ and clickÂInstall
Â
- Since this certificate has been installed, we need to mark it as trusted. Navigate toÂ
Settings > About > Certificate Trust Settings and enable trust forÂRQProxy CA
- Once the certificate has been trusted, you can now intercept traffic using Requestly and create rules to modify them as required
You should now be able to see your rules being applied in the traffic table inside Requestly.
But here are a few more tips to fully utilize requestly with the debugging tools that iOS simulator offers
Â
Open native Web Inspector or Developer Tool for Safari
In case you want to also see the requests in the safari devtools of your simulator:
- Launch Safari in iOS Simulator:
- Launch Safari on your mac and navigate toÂ
Develop in the menu bar,
- Find your Simulator device and tap the webpage you want to inspect.
Â
Bypass CORS for Safari running in simulator
You might sometimes run into CORS issues when trying to apply rules during debugging.
To disable CORS for safari inside the iOS simulator:
- Navigate to theÂ
Develop menu in Safari and
- CheckÂ
Disable Cross-Origin Restrictions andÂLocal FIle Restrictions