Network Logs

Network Logs capture performance data such as network traffic, latency, HTTP requests and responses in the HAR (HTTP Archive) format. You can download network logs using both the App Automate dashboard, as well as using our REST API. You can visualise HAR files using a HAR Viewer.

Network logs are disabled by default. To enable network logs, you need to pass the networkLogs parameter in the REST API request to start XCUITest test execution.

REST API endpoint :

POST /app-automate/xcuitest/build
Parameter Description Values
networkLogs Capture network logs for your test. true, false
Default: false

Example cURL request :

Enable network logs for an XCUI test execution :

curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://api-cloud.browserstack.com/app-automate/xcuitest/build" \
-d '{"networkLogs" : "true", "devices": ["iPhone 8 Plus-11.0"], "app": "bs://f5L3azt9pLzE995f49376eb1fa3c284dc321f8d", "testSuite": "bs://6eb1fa3c284ddbe9971b2d1aee0d52943b9c081"}' \
-H "Content-Type: application/json"


View network logs on the dashboard:

On the test details page of App Automate dashboard, you can view instrumentation logs for each executed test case :

view network logs

Import network logs using REST API:

curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" -X GET "https://api-cloud.browserstack.com/app-automate/builds/<build-id>/sessions/<session-id>/networklogs"
Note:
  1. You may experience minor impact on test execution speed when Network Logs are enabled.
  2. Certain apps such as Play Store, App Store, TestFlight etc. might not work on all OS versions when network logs are enabled.

We're sorry to hear that. Please share your feedback so we can do better







Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked






Thank you for your valuable feedback

Is this page helping you?

Yes
No

We're sorry to hear that. Please share your feedback so we can do better







Contact our Support team for immediate help while we work on improving our docs.

We're continuously improving our docs. We'd love to know what you liked






Thank you for your valuable feedback!

Talk to an Expert
Talk to an Expert