# find

## Usage

```bash
bdy pipeline run find [options] <identifier>
```

## Arguments

| **Argument** | **Description** |
| :--- | :--- |
| `identifier` | Human-readable ID of the pipeline (required) |

## Options

| **Option** | **Description** |
| :--- | :--- |
| `--context <name>` | Connection and scope context: default, git, link or a saved name. Overrides the globally active context for this invocation. |
| `--examples` | Show only examples; with this flag --format accepts text, json or jsonl |
| `--verbose` | Show REST API requests, responses, timing and retries on stderr |
| `-w, --workspace <domain>` | Workspace URL handle. Can be set via variable: BUDDY_WORKSPACE |
| `-p, --project <name>` | Project name. Can be set via variable: BUDDY_PROJECT |
| `--last <number>` | Search the last N runs (1-1000). Limits scanned runs, not matches (default: "100") |
| `--branch <name>` | Match the execution branch name exactly |
| `--tag <name>` | Match the execution tag name exactly |
| `--pr <number>` | Match the execution pull request (number or pull/number) |
| `--revision <revision>` | Match the complete execution to_revision.revision exactly |
| `--from-revision <revision>` | Match the complete execution from_revision.revision exactly |
| `--environment <identifier>` | Match the execution environment identifier exactly |
| `--artifact <identifier[:version]>` | Match the execution artifact identifier, optionally with an exact :version |
| `--status <status>` | Match the execution status (e.g. FAILED, SUCCESSFUL, INPROGRESS) |
| `--format <text|json>` | Output format: json, text. JSON CLI errors: {error:{code,message,hint}}, exit 1. Default: text (choices: "text", "json") |
| `-h, --help` | display help for command |

## Examples

### Find failed runs, including runs without repository context

```bash
bdy pip run find my-pipeline --status FAILED
```

### Search the last 500 runs for an exact branch and status

```bash
bdy pip run find my-pipeline --last 500 --branch main --status FAILED
```

### Find pull request runs as JSON

```bash
bdy pip run find my-pipeline --pr 123 --format json
```

### Find the newest run for a branch; pass executions[0].id to bdy pip run status

```bash
bdy pip run find my-pipeline --branch main --format json
```

### Find runs for an artifact in an environment without a repository filter

```bash
bdy pip run find my-pipeline --environment staging --artifact my-app:1.2.3
```


---
Original source: https://buddy.works/docs/cli/pipeline/run/find