Documentation Index
Fetch the complete documentation index at: https://docs.mobileboost.io/llms.txt
Use this file to discover all available pages before exploring further.
Driver classes
The SDK provides drop-in replacements for Appium driver classes:
| MobileBoost class | Extends | Platform |
|---|
GptDriverAndroid | AndroidDriver | Android |
GptDriverIOS | IOSDriver | iOS |
GptDriverAppium | AppiumDriver | Cross-platform |
Constructor options
| Parameter | Type | Description |
|---|
url | URL | Appium server URL |
options | Capabilities | Appium capabilities (must include gptdriver:apiKey) |
additionalUserContext | String | Optional context to guide AI behavior across all steps |
enableSelfHealing | Boolean | Enable/disable self healing globally (default: true) |
Self healing
By default, all findElement and findElements calls are wrapped with self-healing. When a NoSuchElement exception is thrown, the SDK attempts to resolve it automatically.
// Self healing enabled (default)
WebElement el = driver.findElement(By.id("login-button"));
// Self healing disabled for this call
WebElement el = driver.findElement(By.id("successMessage"), false);
# Self healing is automatic for all find_element calls
el = gptd.find_element(By.ID, "login-button")
AI commands
aiExecute
Execute a natural language instruction on the current screen.
driver.aiExecute("Tap the login button and wait for the home screen");
gptd.execute("Tap the login button and wait for the home screen")
await driver.aiExecute("Tap the login button and wait for the home screen");
aiAssert
Verify a condition without taking any action. Throws an error if the assertion fails.
driver.aiAssert("The home screen is displayed with a welcome message");
gptd.assert_condition("The home screen is displayed with a welcome message")
aiAssertBulk
Check multiple conditions in one call. Throws an error if any assertion fails.
driver.aiAssertBulk(
"The username is displayed",
"The profile picture is visible",
"The settings icon is in the top right"
);
aiCheckBulk
Check multiple conditions in one call. Returns an object with true/false for each condition instead of throwing.
Map<String, Boolean> results = driver.aiCheckBulk(
"The username is displayed",
"The notification badge is visible"
);
Extract information from the current screen. Returns an object with the extracted values.
Map<String, String> data = driver.aiExtract(
"username",
"email address",
"account balance"
);
Caching
The SDK supports caching to reduce AI calls for repetitive executions:
| Mode | Description |
|---|
NONE | No caching |
FULL_SCREEN | Cache hit only if the full screen matches a previous successful execution |
INTERACTION_REGION | Cache hit if the interaction region matches (e.g., the area around a tapped element) |
Set caching globally in the constructor or override per step.