export RUN_API_TOKEN=YOUR_TOKEN

#Create External Run for Browser, This is an example of how to create run. Please check Readme.md for more information
#Step 0
  # Search for existing browsers, please modify params accordingly (More information is inside Readme.md)
    testlio create-automated-browser --checkExisting true --platformName "Microsoft Windows"
  # If you haven't found your browser, create a new one
    testlio create-automated-browser --externalId linux-Bravo-latest --browserName "Bravo" --platformName "Linux" --provider local
#Step 1
testlio create-run --externalResults true --resultProvider local --automatedBrowserIds <REPLACE_ID_FROM_STEP_0>
#Step 2
testlio parse-run-results --path allure-results-demo-package.zip --automatedBrowserId <REPLACE_ID_FROM_STEP_0> --browserVersion 101.23
#Step 3
testlio upload-asset --type screenshot --source unknown --automatedBrowserId <REPLACE_ID_FROM_STEP_0> --path ./TokenManagement.png
#Step 4
testlio finalize-results


#Create External Run for Device, This is an example of how to create run. Please check Readme.md for more information
#Step 0
  # Search for existing device, please modify params accordingly (More information is inside Readme.md)
    testlio create-automated-device --checkExisting true --manufactureName Samsung --typeName Mobile --operatingSystemName Android
  # If you haven't found your device, create a new one
    testlio create-automated-device --externalId <device-name-someGuid> --provider local --model "Custom S21" --manufactureName Samsung --typeName Mobile --operatingSystemName Android --operatingSystemVersion 14
#Step 1
testlio create-run --externalResults true --resultProvider local --automatedDeviceIds  <REPLACE_ID_FROM_STEP_0>
#Step 2
testlio parse-run-results --path allure-results-demo-package.zip --automatedDeviceId <REPLACE_ID_FROM_STEP_0>
#Step 3
testlio upload-asset --type screenshot --source unknown --automatedDeviceId <REPLACE_ID_FROM_STEP_0> --path ./TokenManagement.png
#Step 4
testlio finalize-results
