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

# Quickstart

This quickstart will guide you through performing your first attestation.

An [attestation](https://docs.chainloop.dev/concepts/attestations.md) is a **signed and verifiable unit of data** sent to Chainloop. It can capture metadata about any artifact or process in your Software Delivery Lifecycle. From references to source code, a reference to an artifact, a Software Bill of Materials, a Vulnerability Scan results, environment details, and [more](https://docs.chainloop.dev/concepts/material-types.md).

## Install the Chainloop CLI

> [!WARNING]
>
> This guide assumes that you have access to a [Chainloop Cloud](https://app.chainloop.dev/) account or to your own self-hosted Chainloop instance. If you don't, you can [sign up for Chainloop Cloud](https://app.chainloop.dev/login), or [contact us](https://chainloop.dev/contact) if you'd rather run Chainloop yourself.

Typically attestations are created by CI/CD pipelines, but in our quickstart we'll do it locally using the Chainloop CLI.

> [tab] Chainloop SaaS
>
> The install script comes pre-configured for Chainloop Cloud.
>
> ```bash theme={"dark"}
> curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s
> ```
>
> > [accordion] Advanced Options
> >
> > you can install a specific version with
> >
> > ```bash theme={"dark"}
> > curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s -- --version vx.x.x
> > ```
> >
> > and customize the install path (defaults to /usr/local/bin)
> >
> > ```bash theme={"dark"}
> > curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s -- --path /my-path
> > ```
> >
> > To install without sudo, provide a user-accessible path:
> >
> > ```bash theme={"dark"}
> > curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s -- --path ~/.local/bin
> > ```
> >
> > if [cosign](https://docs.sigstore.dev/quickstart/quickstart-cosign/) is present in your system, in addition to the checksum check, a signature verification will be performed. This behavior can be enforced via the --force-verification flag.
> >
> > ```bash theme={"dark"}
> > curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s -- --force-verification
> > ```
> >
> > To install the open-source edition instead:
> >
> > ```bash theme={"dark"}
> > curl -sfL https://dl.chainloop.dev/cli/install.sh | bash -s -- --oss
> > ```

> [tab] On-Prem
>
> Two things have to be true before the CLI can talk to your instance: the binary is installed, and it points at your instance's endpoints. Installing from your own instance's domain does both in a single command.
>
> **1. Download and configure the CLI**
>
> Install from your own instance's domain and the CLI is automatically configured to talk to it — there is nothing else to set up. Copy the exact command from the Chainloop web UI — click the terminal (`>_`) icon in the top-right corner — or replace `YOUR_INSTANCE_DOMAIN` below with your own.
>
> ```bash theme={"dark"}
> curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s
> ```
>
> ![Terminal icon in the top-right corner of the Chainloop web UI that opens the CLI installation dialog](https://mintcdn.com/chainloop/JFPirGFumFqtajI8/img/setup-cli-install.png?fit=max\&auto=format\&n=JFPirGFumFqtajI8\&q=85\&s=efda7dc904d93986d5d73b3c556c4ced)
>
> > [accordion] Advanced Options
> >
> > you can install a specific version with
> >
> > ```bash theme={"dark"}
> > curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s -- --version vx.x.x
> > ```
> >
> > and customize the install path (defaults to /usr/local/bin)
> >
> > ```bash theme={"dark"}
> > curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s -- --path /my-path
> > ```
> >
> > To install without sudo, provide a user-accessible path:
> >
> > ```bash theme={"dark"}
> > curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s -- --path ~/.local/bin
> > ```
> >
> > if [cosign](https://docs.sigstore.dev/quickstart/quickstart-cosign/) is present in your system, in addition to the checksum check, a signature verification will be performed. This behavior can be enforced via the --force-verification flag.
> >
> > ```bash theme={"dark"}
> > curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s -- --force-verification
> > ```
> >
> > To install the open-source edition instead:
> >
> > ```bash theme={"dark"}
> > curl -sfL https://YOUR_INSTANCE_DOMAIN/cli/install.sh | bash -s -- --oss
> > ```
>
> **2. Point the CLI at your instance — only if you installed it another way**
>
> Skip this if you used the command above. Run it when the CLI came from somewhere else — `dl.chainloop.dev`, a package manager, or a **Manual Download** — or when you want to switch an existing install to a different instance.
>
> ```bash theme={"dark"}
> chainloop config save \
>   --control-plane my-controlplane.acme.com:443 \
>   --artifact-cas cas.acme.com:443 \
>   --platform my-platform.acme.com:443
> ```
>
> Confirm which instance the CLI is talking to with `chainloop config view`.

> [tab] Manual Download
>
> Download the CLI binary directly and verify its SHA256 against the published `checksums.txt`. Use this when piping a script into `bash` is not an option, or when binaries need to be validated out-of-band.
>
> > [accordion] v1.159.2
> >
> > | OS | Architecture | Download | SHA256 |
> > | - | - | - | - |
> > | Linux | Intel (amd64) | [chainloop-linux-amd64](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-linux-amd64) | `c58e98a6819f8ee4d477e81e0b36e1f67b6365ae2297597ff80cf3874fae4c3d` |
> > | Linux | ARM64 | [chainloop-linux-arm64](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-linux-arm64) | `d15b4a1cb12a4d2fcf25bd1cc3df5455fa6a40b9cdef182241ae9700be2cf8c3` |
> > | macOS | Intel (amd64) | [chainloop-darwin-amd64](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-darwin-amd64) | `0a7de2cb1fb3c1b988bf3f806ad52198ee74bab2b5b7bcddd735452e5e95adf4` |
> > | macOS | Apple Silicon | [chainloop-darwin-arm64](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-darwin-arm64) | `28fb181127c431395aff74d7eaee80e710a1c38e2f4512ce706c6b83e7133ad9` |
> > | Windows | Intel (amd64) | [chainloop-windows-amd64.exe](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-windows-amd64.exe) | `d8d31baa5b9ac780f7dfd2d8490736a7f03178d11f0cce6fac65599e24e3b38e` |
> > | Windows | ARM64 | [chainloop-windows-arm64.exe](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/chainloop-windows-arm64.exe) | `81e5c9d8165397097697a348bafc5054680da4d94ae825038a0883b98e5b6f59` |
> >
> > Full manifest: [`checksums.txt`](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/checksums.txt) · [signature bundle](https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/v1.159.2/checksums.txt.sigstore.json) · [Release notes](https://docs.chainloop.dev/changelog.md)
> >
> > Download, verify, and install (linux/amd64 shown — swap `chainloop-linux-amd64` for another row from the table above):
> >
> > ```bash theme={"dark"}
> > VERSION=v1.159.2
> > BASE=https://chainloop-baafegchfnekdcde.z02.azurefd.net/public/chainloop-platform-cli/$VERSION
> >
> > # Download the linux/amd64 binary and the checksum manifest
> > curl -fsSLO "$BASE/chainloop-linux-amd64"
> > curl -fsSLO "$BASE/checksums.txt"
> >
> > # Download the signature bundle and confirm the manifest itself came from Chainloop's release pipeline
> > curl -fsSLO "$BASE/checksums.txt.sigstore.json"
> > cosign verify-blob \
> >   --bundle=checksums.txt.sigstore.json \
> >   --certificate-oidc-issuer="https://token.actions.githubusercontent.com" \
> >   --certificate-identity-regexp="^https://github.com/chainloop-dev/platform/\.github/workflows/release_backend\.yml@" \
> >   checksums.txt
> >
> > # Verify the binary against the manifest
> > sha256sum --ignore-missing -c checksums.txt
> > # on macOS: shasum -a 256 --ignore-missing -c checksums.txt
> >
> > # Install it onto your PATH
> > chmod +x chainloop-linux-amd64
> > sudo mv chainloop-linux-amd64 /usr/local/bin/chainloop
> > ```
>
> Unlike the install script, a manually downloaded binary isn't automatically configured for your instance. If you're on an **on-prem or dedicated instance**, point the CLI at your instance's endpoints (Chainloop SaaS users can skip this):
>
> ```bash theme={"dark"}
> chainloop config save \
>   --control-plane my-controlplane.acme.com:443 \
>   --artifact-cas cas.acme.com:443 \
>   --platform my-platform.acme.com:443
> ```

Authenticate to the Control Plane:

```bash theme={"dark"}
chainloop auth login
```

## Perform an attestation

We are now ready to perform our first attestation. In a nutshell, an attestation process has three steps: initialization, adding evidence, and storage. See [lifecycle](https://docs.chainloop.dev/concepts/attestations.md#attestation-lifecycle) for more details.

#### Initialization

We'll start with the [initialization](https://docs.chainloop.dev/concepts/attestations.md#attestation-init) of an attestation. The command requires the name of a [workflow](https://docs.chainloop.dev/concepts/workflows.md), a [project](https://docs.chainloop.dev/concepts/projects-versions.md) and optionally a [contract](https://docs.chainloop.dev/concepts/contracts.md).
Copy the command that suits your environment:

> [tab] Chainloop Platform
>
> ```bash theme={"dark"}
> chainloop att init \
>   --workflow mywf \
>   --project myproject \
>   --contract https://raw.githubusercontent.com/chainloop-dev/chainloop/refs/heads/main/docs/examples/quickstart/quickstart-contract.yaml
> ```

> [tab] Chainloop OSS
>
> ```bash theme={"dark"}
> chainloop att init \
>   --workflow mywf \
>   --project myproject \
>   --contract https://raw.githubusercontent.com/chainloop-dev/chainloop/refs/heads/main/docs/examples/quickstart/quickstart-contract-oss.yaml
> ```

![attestation init](https://mintcdn.com/chainloop/xJ5hNAgMrS6U1u_m/img/quickstart-1.png?fit=max\&auto=format\&n=xJ5hNAgMrS6U1u_m\&q=85\&s=4cf911b7ba4e508387d151133ea182af)

We can see that the command output tell us that we should provide three materials, a container image, an SBOM, and a vulnerability report. These requirements are part of the [contract](https://docs.chainloop.dev/concepts/contracts.md) that we attached during the initialization.

#### Add Pieces of Evidence

Once attestation is initialized, we can start adding materials to it. In this case, we are attesting the latest version of the Chainloop's control-plane image as an example.

> [!TIP]
>
> For a complete list of supported material types, see the [material types](https://docs.chainloop.dev/concepts/material-types.md) reference.

```bash theme={"dark"}
chainloop att add --name container --value ghcr.io/chainloop-dev/chainloop/control-plane
```

Next we'll attest a Software Bill Of Materials (SBOM), note that we are pointing to a remote file location, a local filepath would work too.

```bash theme={"dark"}
chainloop att add --name sbom --value https://raw.githubusercontent.com/chainloop-dev/chainloop/refs/heads/main/docs/examples/quickstart/sbom.json
```

As you can see in the output below, the CLI has automatically 1) validated the SBOM format, 2) uploaded the file to the [content addressable storage](https://docs.chainloop.dev/concepts/cas-backend.md) and 3) run a set of [policies](https://docs.chainloop.dev/concepts/policies.md).

![attestation add sbom](https://mintcdn.com/chainloop/xJ5hNAgMrS6U1u_m/img/quickstart-2.png?fit=max\&auto=format\&n=xJ5hNAgMrS6U1u_m\&q=85\&s=25982cc4ebf2d7793808422d4e6066ac)

And finally, we'll add the vulnerability report:

```bash theme={"dark"}
chainloop att add --name vulnerabilities-report --value https://raw.githubusercontent.com/chainloop-dev/chainloop/refs/heads/main/docs/examples/quickstart/vulnerability-report.json
```

#### Sign and Store

Once we've gathered all the pieces of evidence, we can [push the attestation](https://docs.chainloop.dev/concepts/attestations.md#attestation-push) for permanent storage.

```bash theme={"dark"}
chainloop att push
```

Transparently, Chainloop has [signed](https://docs.chainloop.dev/reference/signing.md) and stored the attestation.

You can now use either the CLI or the web UI to inspect the attestation, verify the signature, and learn more about the data.

> [tab] Web UI
>
> You can find your attestation in the [workflows](https://app.chainloop.dev/workflows) section.
>
> ![The Attestation tab of a workflow run showing the signed in-toto statement](https://mintcdn.com/chainloop/hibEOkV5XjWISiDa/img/quickstart-3.png?fit=max\&auto=format\&n=hibEOkV5XjWISiDa\&q=85\&s=347bf9f1d8c8ecca9198625da5f53e4e)

> [tab] CLI
>
> ```bash theme={"dark"}
> # List workflow runs (attestations)
> chainloop workflow run ls
> # Get information about a specific run
> chainloop workflow run describe --id [runID]
> # Get the raw output of an attestation
> chainloop workflow run describe --id [runID] --output attestation
> ```

Great! You've completed this guide. Now you are ready to dive deeper into our [Getting Started](https://docs.chainloop.dev/get-started) guide.

Good luck, and have fun with Chainloop! 🚀


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