> ## Documentation Index
> Fetch the complete documentation index at: https://mintlify.manicule.dev/llms.txt
> Use this file to discover all available pages before exploring further.
> For every page in one file, fetch https://mintlify.manicule.dev/llms-full.txt (large).
> To search and read these docs as tools, connect the MCP server at https://mintlify.manicule.dev/api/mcp.
> Every agent surface: https://mintlify.manicule.dev/.well-known/llms-manifest.json

# Trigger automation (/api/automations/trigger)

<!-- agent-signals: reading_time_min: 3 · est_tokens: 1286 · updated: 2026-07-31 -->
Related: [Trigger preview deployment](/api/preview/trigger.md), [Detect AI-sounding prose](/api/admin/deslop.md)

Use this endpoint to trigger a scheduled automation on demand, instead of waiting for its next scheduled run. The automation behaves identically to a regular scheduled run: it picks up everything that has changed since the last completed run.

This endpoint only supports automations configured with a **Custom schedule** trigger. Requests for automations with other triggers, like **Code change** or **Content update**, return a `400` error.

## Use cases

* **CI/CD pipelines**: Run the **Update from code changes** automation on every merge to `main`, so docs update at your release cadence rather than on a fixed schedule.
* **Release events**: Run the **Draft changelog** automation when you cut a release tag, so the changelog drafts at the same time the release ships.
* **Custom tooling**: Trigger automations from internal tools, Slack commands, or scheduled jobs you already run.

## Find the automation ID

Copy the automation ID from the automation's settings panel on the [Automations](https://app.mintlify.com/products/automations) page in your dashboard.

## Example

Trigger an automation from a GitHub Action whenever code merges to `main`:

```yaml title=".github/workflows/trigger-docs.yml"
on:
  push:
    branches: [main]

jobs:
  trigger:
    runs-on: ubuntu-latest
    steps:
      - run: |
          curl -fsS -X POST \
            "https://api.mintlify.com/v1/workflow/$PROJECT_ID/$WORKFLOW_ID/trigger" \
            -H "Authorization: Bearer ${{ secrets.MINTLIFY_API_KEY }}"
        env:
          PROJECT_ID: ${{ vars.MINTLIFY_PROJECT_ID }}
          WORKFLOW_ID: ${{ vars.MINTLIFY_WORKFLOW_ID }}
```

## Rate limits

This endpoint shares a rate limit with [Trigger update](/api/update/trigger): up to 10 requests per 10 seconds per organization. Triggered runs consume credits at the same rate as scheduled runs.

`POST /workflow/{projectId}/{workflowSchemaId}/trigger`

> Trigger a scheduled automation to run immediately, instead of waiting for its next scheduled time. Useful for running automations from CI/CD pipelines, like a GitHub Action that runs on every merge to your default branch. Only scheduled (custom schedule) automations can be triggered. The run picks up changes since the last completed run, identical to a regular scheduled run.
>
> Authenticate with an admin API key.

Base URL: `https://api.mintlify.com/v1`

## OpenAPI

```json
{
  "servers": [
    {
      "url": "https://api.mintlify.com/v1"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "securitySchemes": {
    "bearerAuth": {
      "type": "http",
      "scheme": "bearer",
      "description": "The Authorization header expects a Bearer token. Use an admin API key. This is a server-side secret key. Generate one on the [API keys page](https://app.mintlify.com/settings/organization/api-keys) in your dashboard."
    }
  },
  "parameters": [
    {
      "name": "projectId",
      "in": "path",
      "description": "Your project ID. Can be copied from the [API keys](https://app.mintlify.com/settings/organization/api-keys) page in your dashboard.",
      "required": true,
      "schema": {
        "type": "string"
      }
    },
    {
      "name": "workflowSchemaId",
      "in": "path",
      "description": "The ID of the automation to trigger. Can be copied from the automation's settings panel on the [Automations](https://app.mintlify.com/products/automations) page in your dashboard.",
      "required": true,
      "schema": {
        "type": "string"
      }
    }
  ],
  "responses": {
    "202": {
      "description": "Automation run queued successfully.",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "schemaId": {
                "type": "string",
                "description": "The ID of the triggered automation."
              },
              "instanceId": {
                "type": "string",
                "description": "The ID of the queued automation run. Appears in the run history on the [Automation Runs](https://app.mintlify.com/products/automations) page."
              },
              "jobId": {
                "type": "string",
                "description": "The ID of the background job processing the run."
              }
            }
          }
        }
      }
    },
    "400": {
      "description": "Invalid request. The automation ID is malformed, the automation is not active, or the automation is not configured with a custom schedule.",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "error": {
                "type": "string"
              }
            }
          }
        }
      }
    },
    "404": {
      "description": "The automation was not found or does not belong to this project.",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "error": {
                "type": "string"
              }
            }
          }
        }
      }
    }
  }
}
```
