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

# Create Run

> Trigger a new run of your deployed crew

## Request

<ParamField body="deployment_id" type="string" required>
  Deployment ID
</ParamField>

<ParamField body="input" type="object">
  Input data passed to your crew's kickoff function
</ParamField>

<ParamField body="environment" type="string" default="production">
  Environment to run in: `production` or `staging`
</ParamField>

## Response

Returns HTTP 202 (Accepted).

<ResponseField name="run_id" type="string">
  Run ID (e.g., `run_abc123xyz`)
</ResponseField>

<ResponseField name="version_id" type="string">
  Version ID used for this run
</ResponseField>

<ResponseField name="version_number" type="integer">
  Version number used for this run
</ResponseField>

<ResponseField name="status" type="string">
  Run status: `running`
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.crewship.dev/v1/runs \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "deployment_id": "dep_abc123xyz",
      "input": {
        "topic": "AI agents",
        "style": "technical"
      }
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json Success theme={null}
  {
    "run_id": "run_xyz789abc",
    "version_id": "ver_abc123xyz",
    "version_number": 3,
    "status": "running"
  }
  ```

  ```json Error theme={null}
  {
    "error": {
      "message": "No running version found for production environment"
    }
  }
  ```
</ResponseExample>

## Notes

* Runs are created and executed asynchronously
* Use the [Stream Events](/api-reference/runs/events) endpoint to get real-time updates
* Poll the [Get Run](/api-reference/runs/get) endpoint for completion status
