MDK Logo

Install the CLI

[⏱️ ~3 min] Get `mdk` installed and verified from a source checkout

TL;DR

  • Operate the stack from your terminal
  • Until available as an npm package, link mdk on your PATH with:
    • npm install at mdk/packages
    • npm run build && npm link at mdk/packages/cli

Overview

mdk is MDK's command-line tool for standing up and operating a stack from your terminal. It scaffolds a stack (mdk create), boots it (mdk run), and reports its health (mdk status), all driven by the mdk.yaml spec mdk onboard writes for you.

Prerequisites

Install

Until @tetherto/mdk-cli is published to npm, link mdk on your PATH from a source checkout.

Install the CLI steps

If mdk --version already prints a version, skip to step 6.

  1. Clone the repo and cd into packages.

    git clone https://github.com/tetherto/mdk.git && cd mdk/packages
  2. Stay on main, or pin a tagged release. Pick a tag from mdk tags and check it out.

    git checkout -b {your-branch-name}/v{version} v{version}

    For example, git checkout -b local/v0.7.0 v0.7.0.

  3. Install dependencies.

    npm install
  4. Build and link the mdk binary.

    cd cli && npm run build && npm link
  5. Confirm mdk is on your PATH.

    mdk --version
  6. Run project commands from the app or UI monorepo you are working in. Commands such as mdk skill add and mdk onboard write into your current directory, so run them from your project, not from mdk/packages/cli. Only mdk --version is global once linked.

Command groups

A selection of commands you can run today:

GroupCommands
Onboardingmdk onboard
Scaffoldmdk create worker|plugin|dashboard
Run & managemdk run [target], mdk status
Agent enablementmdk skill add
Metamdk version

The CLI's command surface documents the full flag reference.

Update

git pull && npm install && npm run build

Uninstall

npm rm -g @tetherto/mdk-cli

Next steps

On this page