> For the complete CircleCI developer hub index, see [llms.txt](https://circleci.com/developer/llms.txt)

# autify/autify-mobile

CircleCI integration with Autify for Mobile. Upload a build and/or run a test plan with this Orb.


## Commands

### build-upload

Upload a build file to Autify for Mobile.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `access-token` | env_var_name | AUTIFY_MOBILE_ACCESS_TOKEN | Environment variable storing the access token of Autify for Mobile. |
| `autify-cli-installer-url` | string | https://autify-cli-assets.s3.amazonaws.com/autify-cli/channels/stable/install-cicd.bash | Autify CLI installer URL |
| `autify-path` | string | autify | A path to `autify`. |
| `build-path` | string |  | File path to the iOS app (*.app) or Android app (*.apk). |
| `workspace-id` | string |  | Workspace ID to upload the build file. |

### test-run

Run a test plan on Autify for Mobile.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `access-token` | env_var_name | AUTIFY_MOBILE_ACCESS_TOKEN | Environment variable storing the access token of Autify for Mobile. |
| `autify-cli-installer-url` | string | https://autify-cli-assets.s3.amazonaws.com/autify-cli/channels/stable/install-cicd.bash | Autify CLI installer URL |
| `autify-path` | string | autify | A path to `autify`. |
| `autify-test-url` | string |  | URL of a test plan e.g. https://mobile-app.autify.com/projects/<ID>/test_plans/<ID> |
| `build-id` | string |  | ID of the already uploaded build. (Note: Either build-id or build-path is required but not both) |
| `build-path` | string |  | File path to the iOS app (*.app) or Android app (*.apk). (Note: Either build-id or build-path is required but not both) |
| `max-retry-count` | string |  | Maximum retry count while waiting. The command can take up to `timeout * (max-retry-count + 1)`. Only effective with `wait` |
| `timeout` | string |  | Timeout seconds when waiting. |
| `verbose` | boolean | true |  |
| `wait` | boolean | false | When true, the action waits until the test finishes. |

## Jobs

### build-upload

Upload a build file to Autify for Mobile.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `access-token` | env_var_name | AUTIFY_MOBILE_ACCESS_TOKEN | Environment variable storing the access token of Autify for Mobile. |
| `autify-cli-installer-url` | string | https://autify-cli-assets.s3.amazonaws.com/autify-cli/channels/stable/install-cicd.bash | Autify CLI installer URL |
| `autify-path` | string | autify | A path to `autify`. |
| `build-path` | string |  | File path to the iOS app (*.app) or Android app (*.apk) in the workspace. |
| `executor` | executor | autify-cli/default | Executor name for this job. |
| `workspace-id` | string |  | Workspace ID to upload the build file. |

### test-run

Run a test plan on Autify for Mobile.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `access-token` | env_var_name | AUTIFY_MOBILE_ACCESS_TOKEN | Environment variable storing the access token of Autify for Mobile. |
| `autify-cli-installer-url` | string | https://autify-cli-assets.s3.amazonaws.com/autify-cli/channels/stable/install-cicd.bash | Autify CLI installer URL |
| `autify-path` | string | autify | A path to `autify`. |
| `autify-test-url` | string |  | URL of a test plan e.g. https://mobile-app.autify.com/projects/<ID>/test_plans/<ID> |
| `build-id` | string |  | ID of the already uploaded build. (Note: Either build-id or build-path is required but not both) |
| `build-path` | string |  | File path to the iOS app (*.app) or Android app (*.apk) in the workspace. (Note: Either build-id or build-path is required but not both) |
| `executor` | executor | autify-cli/default | Executor name for this job. |
| `max-retry-count` | string |  | Maximum retry count while waiting. The command can take up to `timeout * (max-retry-count + 1)`. Only effective with `wait` |
| `timeout` | string |  | Timeout seconds when waiting. |
| `verbose` | boolean | true |  |
| `wait` | boolean | false | When true, the action waits until the test finishes. |

## Examples

### build-upload-android

Upload an Android build file to Autify for Mobile.


```yaml
version: '2.1'
orbs:
  android: circleci/android@2.0
  autify-mobile: autify/autify-mobile@3
jobs:
  build-android:
    executor:
      name: android/android-machine
    steps:
      - run: echo "Prepare build"
      - run: ./gradlew assembleRelease
      - persist_to_workspace:
          paths: android-release.apk
          root: app/build/outputs/apk/release
workflows:
  build-upload-android:
    jobs:
      - build-android
      - autify-mobile/build-upload:
          build-path: android-release.apk
          requires:
            - build-android
          workspace-id: AAA
```

### build-upload-ios

Upload an iOS build file to Autify for Mobile.


```yaml
version: '2.1'
orbs:
  autify-mobile: autify/autify-mobile@3
jobs:
  build-ios:
    macos:
      xcode: 13.4.1
    steps:
      - run: echo "Prepare build"
      - run: >-
          xcodebuild -configuration Debug -target hello-world -arch x86_64 -sdk
          iphonesimulator
      - persist_to_workspace:
          paths: hello-world.app
          root: build/Debug-iphonesimulator
workflows:
  build-upload-ios:
    jobs:
      - build-ios
      - autify-mobile/build-upload:
          build-path: hello-world.app
          requires:
            - build-ios
          workspace-id: AAA
```

### test-run-android

Run a test plan for Android build.


```yaml
version: '2.1'
orbs:
  android: circleci/android@2.0
  autify-mobile: autify/autify-mobile@3
jobs:
  build-android:
    executor:
      name: android/android-machine
    steps:
      - run: echo "Prepare build"
      - run: ./gradlew assembleRelease
      - persist_to_workspace:
          paths: android-release.apk
          root: app/build/outputs/apk/release
workflows:
  test-run-build-id:
    jobs:
      - autify-mobile/test-run:
          autify-test-url: https://mobile-app.autify.com/projects/<ID>/test_plans/<ID>
          build-id: AAA
  test-run-build-path-android:
    jobs:
      - build-android
      - autify-mobile/test-run:
          autify-test-url: https://mobile-app.autify.com/projects/<ID>/test_plans/<ID>
          build-path: android-release.apk
          requires:
            - build-android
```

### test-run-ios

Run a test plan for iOS build.


```yaml
version: '2.1'
orbs:
  autify-mobile: autify/autify-mobile@3
jobs:
  build-ios:
    macos:
      xcode: 13.4.1
    steps:
      - run: echo "Prepare build"
      - run: >-
          xcodebuild -configuration Debug -target hello-world -arch x86_64 -sdk
          iphonesimulator
      - persist_to_workspace:
          paths: hello-world.app
          root: build/Debug-iphonesimulator
workflows:
  test-run-build-id:
    jobs:
      - autify-mobile/test-run:
          autify-test-url: https://mobile-app.autify.com/projects/<ID>/test_plans/<ID>
          build-id: AAA
  test-run-build-path-ios:
    jobs:
      - build-ios
      - autify-mobile/test-run:
          autify-test-url: https://mobile-app.autify.com/projects/<ID>/test_plans/<ID>
          build-path: hello-world.app
          requires:
            - build-ios
```