> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tester.army/llms.txt
> Use this file to discover all available pages before exploring further.

# Trigger a test run

> Trigger a saved dashboard test remotely using API-key authentication. Returns the queued run ID.



## OpenAPI

````yaml /openapi.json post /v1/tests/{testId}/runs
openapi: 3.0.0
info:
  title: TestArmy API
  version: 1.0.0
  description: >-
    AI-powered browser automation API for QA testing. Automate web testing
    workflows using natural language prompts.
servers:
  - url: https://tester.army/api
    description: Production API server
security: []
paths:
  /v1/tests/{testId}/runs:
    post:
      tags:
        - Tests
      summary: Trigger a test run
      description: >-
        Trigger a saved dashboard test remotely using API-key authentication.
        Returns the queued run ID.
      parameters:
        - schema:
            type: string
            format: uuid
            description: Test ID
          required: true
          description: Test ID
          name: testId
          in: path
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                mode:
                  type: string
                  enum:
                    - fast
                    - deep
                platform:
                  type: string
                  enum:
                    - web
                    - ios
                    - android
                  description: >-
                    Run platform for the test. Mobile tests default to ios when
                    omitted, so Android runs must set platform: android -
                    including when the mobile app is selected by appId.
                deviceModel:
                  type: string
                  enum:
                    - iphone
                    - ipad
                  description: >-
                    Mobile device variant within the run platform (iOS: iphone |
                    ipad). Omit for the platform default phone-sized device;
                    explicitly requesting the default (e.g. iphone) is
                    equivalent to omitting it.
                appId:
                  type: string
                  format: uuid
                projectEnvironmentId:
                  type: string
                  format: uuid
      responses:
        '202':
          description: Test run queued successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - queued
                  runId:
                    type: string
                    format: uuid
                  testId:
                    type: string
                    format: uuid
                required:
                  - status
                  - runId
                  - testId
        '400':
          description: Bad Request - Invalid input parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error code or type
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - error
                  - message
        '401':
          description: Unauthorized - Invalid or missing API key
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error code or type
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - error
                  - message
        '429':
          description: Too Many Requests - Usage limit exceeded
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error code or type
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - error
                  - message
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error code or type
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - error
                  - message
        '504':
          description: Gateway Timeout - Test execution exceeded time limit
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error code or type
                  message:
                    type: string
                    description: Human-readable error message
                required:
                  - error
                  - message
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: API key authentication using Bearer token format

````