Skip to content

Quickstart: Foundry CLI

Learn how to create a basic “Hello World” app with the Foundry CLI. This guide walks through the complete app-making process in nine steps.

The Falcon console App builder is excellent for prototyping and visual workflow design. The CLI enables version control, code review, CI/CD, and AI-assisted development. For more info about creating and managing apps in the Foundry UI, see Quickstart: Falcon Console.

  • Default roles: App User, App Developer, or Falcon Administrator
  • Tools: A code editor is required
  • Knowledge: A basic understanding of command-line interfaces (CLI) is helpful

Foundry has both a graphical user interface and a command-line interface. You need the CLI to add certain app capabilities and artifacts, so the first step is to install it.

  1. Install Homebrew.
  2. Add the Foundry CLI brew tap:
    Terminal window
    brew tap crowdstrike/foundry-cli
  3. Install the Foundry CLI:
    Terminal window
    brew install crowdstrike/foundry-cli/foundry
  4. Verify that the CLI is installed:
    Terminal window
    foundry version

Tip: Keep the Foundry CLI up to date with: brew update && brew upgrade crowdstrike/foundry-cli/foundry

  1. Install Scoop.
  2. Add the Foundry CLI bucket:
    Terminal window
    scoop bucket add foundry https://github.com/crowdstrike/scoop-foundry-cli.git
  3. Install the Foundry CLI:
    Terminal window
    scoop install foundry
  4. Verify that the CLI is installed:
    Terminal window
    foundry version

Download, extract, and run the archive file for your operating system:

macOS:

Linux:

Windows:

Extract the archive and add the foundry binary to your PATH environment variable, then verify with foundry version.

To use the Foundry CLI in US-GOV-1, set these environment variables after installation:

Terminal window
export FOUNDRY_UI_DOMAIN="https://falcon.laggar.gcw.crowdstrike.com"
export FOUNDRY_API_GW_DOMAIN="https://api.laggar.gcw.crowdstrike.com"

The Foundry CLI communicates with the Falcon console through a set of APIs. To run commands with the Foundry CLI, you need a CLI profile.

  1. Run:

    Terminal window
    foundry login

    A form opens in your browser.

  2. Log in to the Falcon console if necessary.

Tip: If you use single sign-on, make sure you’re logged in with SSO, then go directly to the URL output by foundry login.

  1. In the form, select the permissions your app needs. Select the minimum set of required permissions — you can add more later.

  2. By default, your profile has the same name as your CID. We suggest including your username in the Profile name so that other users can identify it.

  3. Click Authorize Foundry CLI. You should see: Great! Your CLI is authorized to begin developing apps.

Tip: You can create multiple CLI profiles for different accounts or contexts. Each profile is associated with a specific CrowdStrike CID with its own credentials and scopes.

You can also store credentials as environment variables (these override local credentials):

VariableDescription
FOUNDRY_API_CLIENT_IDThe API client ID
FOUNDRY_API_CLIENT_SECRETThe API client secret
FOUNDRY_CIDFor managing multiple CIDs with environment variables
FOUNDRY_CLOUD_REGIONAvailable values: us-1, us-2, eu-1, us-gov-1, us-gov-2
Terminal window
foundry apps create

Provide this info when prompted:

  • Do you want to use app templates? (y/N): Press Enter (default N)
  • Name: my-first-app
  • Description: My first Foundry app (optional)
  • Logo: Press Enter to skip (optional)

Your new app directory contains a single file, manifest.yml — your app’s blueprint. As you add capabilities, subdirectories are created and the manifest grows.

Tip: Add --no-prompt to turn off prompts for optional flags.

  1. Change to your app’s directory:

    Terminal window
    cd my-first-app
  2. Run:

    Terminal window
    foundry ui extensions create
  3. Provide this info when prompted:

    • Which template would you like to start with? Vanilla JS
    • Name: My First Extension
    • Description: UI extension for Endpoint Detections page
  4. For Sockets, use the arrow keys to highlight Endpoint detection details, press spacebar to select it (marked with [X]), and press Enter.

Sockets are predefined locations within the Falcon console where your extension is rendered. Selecting Endpoint detection details means your app will appear on the detections detail panel.

  1. From your app directory, run:

    Terminal window
    foundry ui run

    Output:

    Starting a local development server at http://localhost:25678. Enter Ctrl-C to shutdown
  2. In the Falcon console, click Developer tools in the toolbar and enable Development mode.

  3. Go to Endpoint security > Monitor > Endpoint detections.

  4. Select any incident to see its details panel and scroll down to see your My First Extension section.

Changes you make to your code are immediately reflected while in development mode.

  1. Shut down the local server (Ctrl+C).

  2. Run:

    Terminal window
    foundry apps deploy
  3. When prompted:

    • Change Type: Major
    • Change log: Initial deployment with UI extension
  1. Copy the link from the deploy output and open it in your browser.
  2. Verify the Status shows Deployed.
  3. Turn off Development mode in the Developer tools menu.
  4. On the Deployments tab, select Preview deployment from the Open menu.
  5. Verify your extension is visible on the endpoint detections page.
Terminal window
foundry apps release

When prompted:

  • Change Type: Major
  • Change log: Initial release

Your app will show status Released with version v1.0.0.

  1. Go to Foundry > App catalog.
  2. Find your app and click Install now.
  3. Click Save and install.

Releases marked Minor and Patch are updated in the catalog automatically. Releases marked Major must be accepted manually.