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

# Get a trigger

> Fetch a single trigger by its ID, including its activation type and type-specific configuration. Returns 404 if no trigger matches.



## OpenAPI

````yaml /api-reference/workflows.yaml get /triggers/{triggerId}
openapi: 3.1.0
info:
  title: Workflows
  version: v1
servers:
  - url: https://api.mobilerun.ai
    description: Droidrun Cloud API
security:
  - bearerAuth: []
paths:
  /triggers/{triggerId}:
    get:
      tags:
        - Triggers
      summary: Get a trigger
      description: >-
        Fetch a single trigger by its ID, including its activation type and
        type-specific configuration. Returns 404 if no trigger matches.
      operationId: getTrigger
      parameters:
        - schema:
            type: string
            format: uuid
          required: true
          name: triggerId
          in: path
      responses:
        '200':
          description: Trigger details
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    allOf:
                      - $ref: '#/components/schemas/Trigger'
                      - properties:
                          id:
                            type: string
                            format: uuid
                          userId:
                            type: string
                            format: uuid
                            description: >-
                              Deprecated: use ownerId (tenancy) / createdBy
                              (actor).
                            deprecated: true
                          ownerId:
                            type: string
                            format: uuid
                          createdBy:
                            type:
                              - string
                              - 'null'
                            format: uuid
                          name:
                            type: string
                          description:
                            type:
                              - string
                              - 'null'
                          activation:
                            type: string
                            enum:
                              - event
                              - schedule
                              - custom
                          scheduleRule:
                            allOf:
                              - $ref: '#/components/schemas/ScheduleRule'
                              - type:
                                  - object
                                  - 'null'
                          timezone:
                            type:
                              - string
                              - 'null'
                          nextFireTime:
                            type:
                              - string
                              - 'null'
                          eventType:
                            type:
                              - string
                              - 'null'
                          conditions: {}
                          customPayloadSchema:
                            type:
                              - object
                              - 'null'
                            additionalProperties: {}
                          createdAt:
                            type:
                              - string
                              - 'null'
                          updatedAt:
                            type:
                              - string
                              - 'null'
                required:
                  - data
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Mobilerun from '@mobilerun/sdk';


            const client = new Mobilerun({
              apiKey: process.env['MOBILERUN_CLOUD_API_KEY'], // This is the default and can be omitted
            });


            const trigger = await
            client.workflows.triggers.retrieve('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');


            console.log(trigger.data);
        - lang: Python
          source: |-
            import os
            from mobilerun_sdk import Mobilerun

            client = Mobilerun(
                api_key=os.environ.get("MOBILERUN_CLOUD_API_KEY"),  # This is the default and can be omitted
            )
            trigger = client.workflows.triggers.retrieve(
                "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            )
            print(trigger.data)
        - lang: Go
          source: "package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\n\t\"github.com/stainless-sdks/droidrun-cloud-go\"\n\t\"github.com/stainless-sdks/droidrun-cloud-go/option\"\n)\n\nfunc main() {\n\tclient := mobileruncloud.NewClient(\n\t\toption.WithAPIKey(\"My API Key\"),\n\t)\n\ttrigger, err := client.Workflows.Triggers.Get(context.TODO(), \"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e\")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf(\"%+v\\n\", trigger.Data)\n}\n"
        - lang: CLI
          source: |-
            mobilerun-cloud workflows:triggers retrieve \
              --api-key 'My API Key' \
              --trigger-id 182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e
components:
  schemas:
    Trigger:
      type: object
      properties:
        id:
          type: string
          format: uuid
        userId:
          type: string
          format: uuid
          description: 'Deprecated: use ownerId (tenancy) / createdBy (actor).'
          deprecated: true
        ownerId:
          type: string
          format: uuid
        createdBy:
          type:
            - string
            - 'null'
          format: uuid
        name:
          type: string
        description:
          type:
            - string
            - 'null'
        activation:
          type: string
          enum:
            - event
            - schedule
            - custom
        scheduleRule:
          $ref: '#/components/schemas/ScheduleRule'
        timezone:
          type:
            - string
            - 'null'
        nextFireTime:
          type:
            - string
            - 'null'
        eventType:
          type:
            - string
            - 'null'
        conditions: {}
        customPayloadSchema:
          type:
            - object
            - 'null'
          additionalProperties: {}
        createdAt:
          type:
            - string
            - 'null'
        updatedAt:
          type:
            - string
            - 'null'
      required:
        - id
        - userId
        - ownerId
        - createdBy
        - name
        - description
        - activation
        - scheduleRule
        - timezone
        - eventType
        - customPayloadSchema
        - createdAt
        - updatedAt
    ScheduleRule:
      type: object
      properties:
        type:
          type: string
          enum:
            - once
            - cron
            - recurring
        dateTime:
          type: string
          description: ISO 8601 datetime (for type=once)
        expression:
          type: string
          description: Cron expression (for type=cron)
        rrule:
          type: string
          description: RRULE string (for type=recurring)
      required:
        - type
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Opaque
      description: Bearer token via Authorization header

````