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

# Logs

> Fastest way to search and filter logs across all CI jobs running on Blacksmith runners

## Overview

Whether you're triaging a broken build in a pull request or digging into a flaky test that only happens on main, logs are now a much better experience in GitHub Actions. You'll be able to zoom in locally or investigate patterns globally across all your CI runs.

<video controls playsInline preload="metadata" width="100%" src="https://pub-e2b06c433e4f400c841be3653e0cad01.r2.dev/LogsBetaDocsDemo.mp4#t=0" title="Searching and filtering logs in the Blacksmith dashboard" />

## Basics

### Query Syntax Guide

Let's break down the query syntax:

```plaintext theme={"system"}
branch:main level:error,warn failed -"econn refused"
```

### Property Filters

You can search and filter your logs using the following criteria:

| **Filter** | **Description** |
| - | - |
| `run_id:*` | Filter by workflow run instances (each run may contain multiple jobs) |
| `run_attempt:*` | Filter by the attempt number of a given workflow run |
| `workflow:*` | Filter by GitHub workflow name |
| `pr:*` | Filter by pull request number |
| `branch:*` | Filter by Git branch associated with the run |
| `repo:*` | Filter by repository name |
| `job_id:*` | Filter by specific job IDs |
| `job_name:*` | Filter by job names |
| `step_id:*` | Filter by specific step IDs |
| `step_name:*` | Filter by workflow step names |
| `user:*` | Filter by the user who triggered the workflow |
| `level:*` | Filter by severity (`info`, `warn`, `debug`, `error`) |

In this example, we are filtering for logs from the `main` branch and only showing logs with severity `error` or `warn`:

```plaintext theme={"system"}
branch:main level:error,warn
```

#### Substring Search

You can search for text across your logs using the log search bar. For multi-word phrases, use quotes. In this example, we are searching for logs containing the phrase "failed":

```plaintext theme={"system"}
failed
```

#### Exclude Matches

You can exclude matches by prefixing a search term with `-`. In this example, we are excluding logs containing the phrase "econn refused":

```plaintext theme={"system"}
-"econn refused"
```

#### Escaping Special Characters

* **Quotes**: Escape with backslash: `\"`
* **Backslashes**: Escape with backslash: `\\`
* **Keywords**: Wrap AND/OR in quotes to search literally: `"AND"` `"OR"`

## Pricing

There is no additional cost for using this feature. For all other pricing, please visit our [pricing page](https://www.blacksmith.sh/pricing).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.