CI/CD integration for App Low Code Automation
Integrate App Low Code Automation with your CI/CD pipeline using REST APIs to automate test execution and monitoring.
You can integrate App Low Code Automation with your CI/CD pipeline using the following three REST API endpoints:
- Upload app: Upload your mobile application to BrowserStack for testing.
- Test suite execution: Trigger a cloud replay for a specific test execution.
- Fetch build status: Retrieve the status of a specific build.
Rate limit
To ensure optimal performance and fair usage across all users, the following rate limits apply to the CI/CD integration APIs:
| Endpoint | Rate limit |
|---|---|
| Upload app | 1 request per minute |
| Test suite execution | 100 requests per minute |
| Fetch build status | 100 requests per minute |
If you exceed these limits, you will receive a 429 Too many requests error response.
Upload app
To test your apps on App Low Code Automation, you first need to upload an Android app (.apk file) or an iOS app(.ipa file) to BrowserStack servers. Use our REST API endpoints to upload and manage your apps on BrowserStack.
Request parameters
In the curl request, replace the YOUR_USERNAME and YOUR_ACCESS_KEY variables with your account’s username and access-key.
Request
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://app-lcnc-api.browserstack.com/api/v1/mobile-apps/upload" \
-F "file=@/path/to/app/file/application-debug.apk"
-
file* File
File to upload. Ensure that the request’s content type is set to
multipart/form-data. In cURL, you can do this using-Foption. The maximum supported file size is 1 GB.
Response attributes 200 application/json
Response (200 Success - Uploaded
.apkfile)
{
"status": "SUCCESS",
"message": "App uploaded successfully",
"appHashedId": "eb1681b9d64278e8c5f7cbe8e843cbb4f77ec7a0"
}
Response (400 Multiple apps uploaded at the same time)
{
"status": "FAILED",
"message": "Invalid request - only one file can be uploaded at a time",
}
Response (429 Rate limit exceeded)
{
"status": "FAILED",
"message": "Too many requests. Please try again later",
}
Response (401 Invalid auth)
{
"status": "FAILED",
"message": "Invalid username or access-key. Please provide valid credentials"
}
Response (413 File size exceeded: .apk file exceeds 1 GB limit)
<html>
<head>
<title>413 Request Entity Too Large</title>
</head>
<body>
<center>
<h1>413 Request Entity Too Large</h1>
</center>
<hr>
<center>nginx</center>
</body>
</html>
Response (422 Invalid formats, tried uploading
{
    "status": "FAILED",
    "message": "File is corrupted or not processable, please try again with a valid APK file (for Android apps) or a valid IPA file (for iOS apps)"
}
Response (422 Empty files, used a 0 byte .apk)
{
    "status": "FAILED",
    "message": "File is corrupted or not processable, please try again with a valid APK file (for Android apps) or a valid IPA file (for iOS apps)"
}
Response (400 Missing required fields, did not add file)
{
    "status": "FAILED",
    "message": "Invalid request - upload failed as file was not attached"
}
-
status string
Status of the app upload request.
Example:SUCCESS -
message string
Descriptive message about the upload result.
Example:App uploaded successfully -
appHashedId string
Unique hashed identifier for the uploaded app. This value can be used to specify the application under test in your test scripts.
Example:eb1681b9d64278e8c5f7cbe8e843cbb4f77ec7a0
Test suite execution
Trigger a cloud replay based on the specified test execution ID.
Request parameters
In the curl request, replace the YOUR_USERNAME and YOUR_ACCESS_KEY variables with your account’s username and access-key.
Request
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X POST "https://app-lcnc-api.browserstack.com/api/v1/test-suites/{test_suite_id}/run" \
-H "Content-Type: application/json" \
-d '{"android_app_id": "eb1681b9d64278e8c5f7cbe8e843cbb4f77ec7a0", "ios_app_id": "ab1681b9d64278e8c5f7cbe8e843cbb4f77ec7a0", "local_identifier": ""}'
-
test_suite_id* string
Unique identifier of the test suite to replay. Replace
test_suite_idin the request path with the ID of the test suite you want to replay. -
android_app_id string
Unique identifier of the Android app uploaded to BrowserStack. If not provided, uses the configured apps within this test suite.
-
ios_app_id string
Unique identifier of the iOS app uploaded to BrowserStack. If not provided, uses configured apps within this test suite.
-
local_identifier string
Unique identifier to distinguish between multiple concurrent local runs.
Response attributes 200 application/json
Response (200 Success)
{
"status": "SUCCESS",
"message": "Build triggered successfully.",
"build_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09",
"build_name": "Smoke Suite-1",
"test_suite_details": {
"test_suite_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09",
"name": "Smoke Suite",
"description": "Contains P0, P1 cases for Home page",
"devices": [
{
"device_name": "iPhone 16",
"os_version": "18.0"
}
],
"apps": {
"android": {
"app_hashed_id": "c7496a940530c60a239ff429a538bb0b32d90ed7",
"app_name": "WikipediaSample.apk"
},
"ios": {
"app_hashed_id": "c7496a940530c60a239ff429a538bb0b32d90ed7",
"app_name": "WikipediaSample.ipa"
}
},
"local": true,
"tests": [
{
"test_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09",
"name": "Sample Test 01 | Buy iPhone 14 on apple"
},
{
"test_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3fj38j",
"name": "Sample Test 02 | Bstackdemo add to cart"
}
]
}
}
Response (400 Invalid suite ID)
{
"status": "FAILED",
"message": "Test suite not found. Please provide a valid suite ID.",
}
Response (400 No tests present in the suite)
{
"status": "FAILED",
"message": "This test suite has 0 tests. Please add at least 1 test to the suite by visiting App LCA Dashboard",
}
Response (400 Invalid app ID)
{
"status": "FAILED",
"message": "App not found. Please upload a new version.",
}
Response (400 Expired app ID)
{
"status": "FAILED",
"message": "Unable to run the test suite as one or more of the configured apps have expired",
}
Response (401 Auth failure)
{
"status": "FAILED",
"message": "Invalid username or access-key. Please provide valid credentials"
}
Response (403 Forbidden)
{
"status": "FAILED",
"message": "API access is not available for Free Trial users.",
}
Response (429 Rate limit)
{
"status": "FAILED",
"message": "Too many requests. Please try again later.",
}
Response (500 Generic error)
{
"status": "FAILED",
"message": "Something went wrong. Please try again later"
}
Response (400 App is not configured in test suite)
{
    "status": "FAILED",
    "message": "This test suite is not configured to run on iOS(Android in case of Android), please add the necessary configurations for the test suite on App LCA Platform",
}
-
status string
Status of the API request.
Example:SUCCESS -
message string
Message indicating the result of the API request.
Example:Build triggered successfully. -
build_id string
Unique identifier for the build.
Example:315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09 -
build_name string
Name of the build.
Example:Smoke Suite-1 -
test_suite_details object
â–¶ SHOW VALUESDetails of the test suite including test suite ID, name, description, devices, apps, local testing configuration, and tests.
-
test_suite_id String
Unique identifier of the test suite.
Example:315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09 -
name String
Name of the test suite.
Example:Smoke Suite -
description String
Description of the test suite.
Example:Contains P0, P1 cases for Home page -
devices Array
â–¶ SHOW VALUESArray of device configurations for the test suite.
-
device_name String
Name of the device.
Example:Samsung Galaxy S22 -
os_version String
OS version of the device.
Example:12.0
-
-
apps Object
â–¶ SHOW VALUESApps configured for the test suite including Android and iOS apps.
-
android Object
â–¶ SHOW VALUESAndroid app details.
-
app_hashed_id String
Hashed identifier of the app.
Example:c7496a940530c60a239ff429a538bb0b32d90ed7 -
app_name String
Name of the app file.
Example:WikipediaSample.apk
-
-
ios Object
â–¶ SHOW VALUESiOS app details.
-
app_hashed_id String
Hashed identifier of the app.
Example:c7496a940530c60a239ff429a538bb0b32d90ed7 -
app_name String
Name of the app file.
Example:WikipediaSample.apk
-
-
-
local Boolean
Indicates whether local testing is enabled for the test suite.
Example:trueorfalse -
tests Array
â–¶ SHOW VALUESArray of tests in the test suite.
-
test_id String
Unique identifier of the test.
Example:abc123 -
name String
Name of the test.
Example:Login Test
-
-
Fetch build status
Fetch the build status based on the specified build ID.
Request parameters
In the curl request, replace the YOUR_USERNAME and YOUR_ACCESS_KEY variables with your account’s username and access-key.
Request
curl -u "YOUR_USERNAME:YOUR_ACCESS_KEY" \
-X GET "https://app-lcnc-api.browserstack.com/api/v1/builds/{build_id}/status"
-
build_id* string
Unique identifier of the build. Replace
build_idin the request path with the build ID value you receive from the Test Suite Execution API.
Response attributes 200 application/json
Response (200 Success)
{
"status": "SUCCESS",
"build_status": "passed",
"app_lca_build_url": "https://app-lca.browserstack.com/builds/315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09",
"triggered_by": "demo_user@example.com",
"triggered_at": "2024-03-07T07:36:02.695Z",
"build_execution_summary": {
"total": 12,
"passed": 8,
"failed": 4,
"running": 0,
"queued": 0,
"duration": 1200
},
"build_details": {
"build_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09",
"build_name": "Smoke Suite-1",
"apps": {
"android": {
"app_hashed_id": "c7496a940530c60a239ff429a538bb0b32d90ed7",
"app_name": "WikipediaSample.apk"
},
"ios": {
"app_hashed_id": "c7496a940530c60a239ff429a538bb0b32d90ed7",
"app_name": "WikipediaSample.ipa"
}
},
"test_executions": [
{
"test_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3fj38j",
"name": "Sample Test 02 | Bstackdemo add to cart",
"test_execution_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3fj38j",
"device_config": {
"os": "android",
"device_name": "Samsung Galaxy S22",
"os_version": "12.0"
},
"status": "passed",
"duration": 300
},
{
"test_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3fj38j",
"name": "Sample Test 02 | Bstackdemo add to cart",
"test_execution_id": "315d0cfdf7d77a42243ff87c0d6764cc8d3fj38j",
"device_config": {
"os": "ios",
"device_name": "iPhone 15",
"os_version": "16.0"
},
"status": "failed",
"duration": 300
}
]
}
}
Response (400 Invalid build ID)
{
"status": "FAILED",
"message": "Invalid request - build id not found.",
}
Response (400 Expired build ID)
{
"status": "FAILED",
"message": "Build id not found as it has expired.",
}
Response (401 Auth failure)
{
"status": "FAILED",
"message": "Invalid username or access-key. Please provide valid credentials"
}
Response (403 Forbidden)
{
"status": "FAILED",
"message": "API access is not available for Free Trial users.",
}
Response (429 Rate limit)
{
"status": "FAILED",
"message": "Too many requests. Please try again later.",
}
Response (500 Generic error)
{
"status": "FAILED",
"message": "Something went wrong. Please try again later."
}
Response (400 Missing/empty build ID)
{
"status": "FAILED",
"message": "Invalid request - build id not found."
}
-
status string
Status of the request.
Example:SUCCESS -
build_status string
Overall status of the build. Possible values include
passed,failed,running,queuedandstopped.
Example:passed -
app_lca_build_url string
URL to view the build details on the App LCA dashboard.
Example:https://app-lca.browserstack.com/builds/315d0cfdf7d77a42243ff87c0d6764cc8d3f9b09 -
triggered_by string
Email address of the user who triggered the build or
schedulerif triggered by a scheduler.
Example:demo_user@example.com -
triggered_at string
Timestamp when the build was triggered in ISO 8601 format.
Example:2024-03-07T07:36:02.695Z -
build_execution_summary object
â–¶ SHOW VALUESSummary of the build execution including total tests, passed, failed, running, queued, and duration in seconds.
-
total Number
Total number of test executions.
-
passed Number
Number of passed test executions.
-
failed Number
Number of failed test executions.
-
running Number
Number of currently running test executions.
-
queued Number
Number of queued test executions.
-
duration Number
Total duration of the build execution in seconds.
-
-
build_details object
â–¶ SHOW VALUESDetailed information about the build including build ID, build name, and test executions.
-
build_id String
Unique identifier of the build.
-
build_name String
Name of the build.
-
apps Object
â–¶ SHOW VALUESApps configured for the build including Android and iOS apps.
-
android Object
â–¶ SHOW VALUESAndroid app details.
-
app_hashed_id String
Hashed identifier of the app.
Example:c7496a940530c60a239ff429a538bb0b32d90ed7 -
app_name String
Name of the app file.
Example:WikipediaSample.apk
-
-
ios Object
â–¶ SHOW VALUESiOS app details.
-
app_hashed_id String
Hashed identifier of the app.
Example:c7496a940530c60a239ff429a538bb0b32d90ed7 -
app_name String
Name of the app file.
Example:WikipediaSample.apk
-
-
-
test_executions Array
â–¶ SHOW VALUESArray of test execution details.
-
test_id String
Unique identifier of the test.
-
name String
Name of the test.
-
test_execution_id String
Unique identifier of the test execution.
-
device_config Object
â–¶ SHOW VALUESDevice configuration on which the test was executed.
-
os String
Operating system of the device.
Example:android,ios -
device_name String
Name of the device.
Example:Samsung Galaxy S22,iPhone 15 -
os_version String
OS version of the device.
Example:12.0,16.0
-
-
status String
Status of the test execution.
Example:passed,failed,skipped -
duration Number
Duration of the test execution in seconds.
-
-
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.