---
title: "Academy Article"
canonical_url: "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication"
locale: en
meta:
  "og:title": "Academy Article"
---

[Go to home](https://academy.laioutr.com/en)

- [For developers](https://academy.laioutr.com/en/bereiche/for-developers)

- [Developer start](https://academy.laioutr.com/en/leitfaeden/developer-start)

- [The Laioutr CLI: commands and authentication](https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication)

# The Laioutr CLI: commands and authentication

The Laioutr CLI fetches the project configuration laioutrrc.json, releases app versions to Cockpit and triggers deployments. Install it with pnpm install -g @laioutr/cli@latest or run it without installation via npx.

## Before you start

<dl>

<dt>Role</dt>
<dd>The project secret for rc fetch, an organisation API key for app release and deploy</dd>

<dt>Duration</dt>
<dd>6 min</dd></dl>

### Prerequisites

- Node.js and pnpm or npx
- Organisation API key with the matching scope

Last reviewed on October 15, 2026

The CLI connects local development and CI pipelines with Cockpit. It has three command groups:

- **rc fetch** and **rc update** download or refresh a project's `laioutrrc.json`, optionally for a specific environment.
- **app release** registers an app version that is already published to the registry with Cockpit, including peer dependencies, channel and settings form.
- **deploy trigger**, **deploy status**, **deploy logs** and **deploy list** start and monitor deployments, including named previews.

There are two ways to authenticate. `rc fetch` uses the project secret from the project settings. `app release` and all `deploy` commands need an organisation API key: with the `app:publish` scope for releases and `project:deploy` for deployments. Pass the key with `--key` or the `LAIOUTR_API_KEY` environment variable.

For CI, the deploy commands return structured output with `--json`, errors included.

## Step by step

1. 1 ### Step 1: Install the CLI

   Run `pnpm install -g @laioutr/cli@latest`, or call single commands with `npx @laioutr/cli@latest <command>`.
2. 2 ### Step 2: Fetch the configuration

   `laioutr rc fetch -p <org>/<project> -s <project-secret>` writes the `laioutrrc.json`; `-e` selects an environment other than **main**. Afterwards, `laioutr rc update` is enough.
3. 3 ### Step 3: Trigger a deployment

   `laioutr deploy trigger --project <org>/<project> --key orgKey_xxx --logs` starts a deployment and streams the build log. `--preview <name>` creates a named preview, `--no-wait` returns immediately.

## Frequently asked questions

When is the project secret needed, and when an API key?

The project secret only covers `rc fetch`. Releases and deployments use an organisation API key with the `app:publish` or `project:deploy` scope.

How does a CI pipeline evaluate errors?

With `--json`, the deploy commands return errors as an object with `code`, `message` and `status`. Colour codes are removed automatically when the output is redirected.

How many deployments does deploy list show?

The last 20 by default; `--limit` returns up to 100.

## Related

- [Set up a local development environment](https://academy.laioutr.com/en/artikel/set-up-a-local-development-environment)15 min

  With the App Starter, a login to the Laioutr npm registry and the project configuration from Cockpit, a custom Laioutr app runs locally within minutes. The Studio command Developer: Use Localhost then shows the local version directly in Studio.
- [Build and release a first custom app](https://academy.laioutr.com/en/artikel/build-and-release-a-first-custom-app)20 min

  A custom app starts from the App Starter: set the package name, register Sections, Blocks or Orchestr handlers with registerLaioutrApp and test them in the playground. npm publish and laioutr app release then bring the version to Cockpit, and an environment's next deployment rolls it out.
- [Create and manage API keys](https://academy.laioutr.com/en/artikel/create-and-manage-api-keys)6 min

  API keys are created in the organisation settings under API keys. An organisation key authenticates the CLI and CI/CD, a restricted key gives an external application access to one project's media only.
- [Start and check a deployment](https://academy.laioutr.com/en/artikel/start-and-check-a-deployment)5 min

  A deployment rebuilds the storefront of an environment and puts changes to apps, versions and configuration live. It is started in Cockpit under Deployments with Deploy; the status and build log show whether it worked.

## Learn it in a lesson

- [Local development and the Laioutr CLI](https://academy.laioutr.com/en/lektionen/developer-local-development-and-cli)12 min

## [Developer start](https://academy.laioutr.com/en/leitfaeden/developer-start)

Search this guide

1. [Set up a local development environment](https://academy.laioutr.com/en/artikel/set-up-a-local-development-environment)15 min
2. [The Laioutr CLI: commands and authentication](https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication)6 min
3. [Build and release a first custom app](https://academy.laioutr.com/en/artikel/build-and-release-a-first-custom-app)20 min
4. [Define custom Sections and Blocks for Studio](https://academy.laioutr.com/en/artikel/define-custom-sections-and-blocks-for-studio)15 min
5. [Orchestr: entities, queries, actions and resolvers](https://academy.laioutr.com/en/artikel/orchestr-entities-queries-actions-and-resolvers)8 min
6. [Declare content collections in code](https://academy.laioutr.com/en/artikel/declare-content-collections-in-code)15 min
7. [Performance and technical SEO in code](https://academy.laioutr.com/en/artikel/performance-and-technical-seo-in-code)10 min

## Structured Data

```json
{
  "@context": "https://schema.org",
  "@graph": [
    {
      "@id": "https://academy.laioutr.com/#website",
      "@type": "WebSite",
      "inLanguage": "en",
      "name": "Default",
      "url": "https://academy.laioutr.com/",
      "translationOfWork": {
        "@id": "https://academy.laioutr.com/#website"
      }
    },
    {
      "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#webpage",
      "name": "Academy Article",
      "url": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication",
      "@type": [
        "WebPage",
        "FAQPage"
      ],
      "breadcrumb": {
        "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#breadcrumb"
      },
      "isPartOf": {
        "@id": "https://academy.laioutr.com/#website"
      },
      "mainEntity": [
        {
          "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/1"
        },
        {
          "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/2"
        },
        {
          "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/3"
        }
      ],
      "potentialAction": [
        {
          "@type": "ReadAction",
          "target": [
            "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication"
          ]
        }
      ]
    },
    {
      "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#breadcrumb",
      "@type": "BreadcrumbList",
      "itemListElement": [
        {
          "@type": "ListItem",
          "name": "Home",
          "item": "https://academy.laioutr.com/en",
          "position": 1
        },
        {
          "@type": "ListItem",
          "name": "For developers",
          "item": "https://academy.laioutr.com/en/bereiche/for-developers",
          "position": 2
        },
        {
          "@type": "ListItem",
          "name": "Developer start",
          "item": "https://academy.laioutr.com/en/leitfaeden/developer-start",
          "position": 3
        },
        {
          "@type": "ListItem",
          "name": "The Laioutr CLI: commands and authentication",
          "item": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication",
          "position": 4
        }
      ]
    },
    {
      "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/1",
      "@type": "Question",
      "inLanguage": "en",
      "name": "When is the project secret needed, and when an API key?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "<p>The project secret only covers <code>rc fetch</code>. Releases and deployments use an organisation API key with the <code>app:publish</code> or <code>project:deploy</code> scope.</p>"
      }
    },
    {
      "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/2",
      "@type": "Question",
      "inLanguage": "en",
      "name": "How does a CI pipeline evaluate errors?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "<p>With <code>--json</code>, the deploy commands return errors as an object with <code>code</code>, <code>message</code> and <code>status</code>. Colour codes are removed automatically when the output is redirected.</p>"
      }
    },
    {
      "@id": "https://academy.laioutr.com/en/artikel/laioutr-cli-commands-and-authentication#/schema/question/3",
      "@type": "Question",
      "inLanguage": "en",
      "name": "How many deployments does deploy list show?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "<p>The last 20 by default; <code>--limit</code> returns up to 100.</p>"
      }
    }
  ]
}
```
