Start new script execution
Starts a new asynchronous execution of the specified script.
Request syntax
https://mycloud.perfectomobile.com/services/executions?operation=execute&scriptKey=value&securityToken=mySecurityToken[&optionalParameter=value]
Parameters
Name | Default | Description |
---|---|---|
ScriptKey* |
|
The repository key of the automation script file stored in the scripts repository area. For example, PUBLIC:deviceMonitoring.xml or PRIVATE:android/test.xml. |
param.<name> |
|
The name and value of one or more run-time parameters for the script, each prefixed with When using an API call to invoke Scriptless Mobile tests, make sure the Device parameter is set. If the Device parameter is not set, the API call will pass, but the test will not start. You can set the Device parameter through the Scriptless Mobile UI or in the API call. To hard-code the parameter in Scriptless Mobile, on the top toolbar, use the Configure test variables button |
securedParam.<name> |
|
The name and value of one or more secured run-time parameters for the script, each prefixed with For example, to specify a string parameter called |
output.report |
true |
|
output.video |
true |
Applicable only when the output.report is not sepcified as |
output.visibility |
private |
The repository section where the report will be stored. The section determines the access to the report. Possible values: |
responseFormat |
json |
The format to use for the response. Possible values: |
handset.allocation.timeout |
Maximal duration to retry allocating a handset in script execution (in milliseconds). The default equals 90 minutes. To fail the script sooner when the device cannot be allocated, you can overwrite this parameter value with a shorter duration. |
|
handset.allocation.retryInterval |
Frequency of attempts to allocate a handset in script execution (in milliseconds). The default equals 1 minute. |
* Mandatory
Response
Name | Description |
---|---|
executionId |
The unique identifier that you can use to get the status of the running script or abort it. The identifier is only valid during, and for a short period after, the script execution. |
reportKey |
The identifier that you can use to download the execution report from the repository. The key is only valid once the script execution completes and does not expire. For example, PRIVATE:reportName.xml. |
testGridReportUrl |
The Perfecto report library URL. |
singleTestReportUrl |
The single test report URL. |
Example
This example shows the request and response for starting the execution of a script called simpleTest.xml located in the PRIVATE media repository without specifying any optional parameters.
Request
https://mycloud.perfectomobile.com/services/executions?operation=execute&scriptKey=PRIVATE:simpleTest.xml&securityToken=eyJhbGciOiJSUzI...6CO6fQ
JSON response
{
"executionId":"samb@perfectomobile.com_simpleTest_16-11-08_12_17_17_1013",
"testGridReportUrl":"https://mycloud.reporting-stg.perfectomobile.com?externalId[0]=samb@perfectomobile.com_simpleTest_16-11-08_12_17_17_1013",
"singleTestReportUrl":"https://mycloud.perfectomobile.com/nexperience/singletest/report/?reportRepositoryKey=PRIVATE:161108/simpleTest_16-11-08_12_17_17_1013.xml&ownerId=samb@perfectomobile.com&sharingCode=8c5aace9-1233-4c6d-af6f-1a1b19443276",
"reportKey":"PRIVATE:161108/simpleTest_16-11-08_12_17_17_1013.xml"}