Skip to content

Kiva CLI comes with its own coding and work agents.Meet the built-in agents

Agent setupOpenAI

Set up KIVA in Codex

Codex runs Kiva CLI in its sandbox and reads the Kiva skills from the shared agents folder. Paste one prompt and your agent does the setup, or follow the steps yourself.

One prompt

Paste this into Codex. It reads the setup document and runs the steps below.

Prompt
Read https://kiva.sh/setup/codex.md and follow it to connect this computer to my KIVA workspace.

The document your agent reads is plain markdown: kiva.sh/setup/codex.md

The steps

What your agent does, step by step. Every command is safe to run by hand.

  1. 01Check Node.js

    Kiva CLI needs Node.js 24.11 or newer. If the version is older or Node.js is missing, update it before you continue.

    node --version
  2. 02Install Kiva CLI

    Check whether the CLI is already there. If kiva --help lists ds, studio and automation, it is ready.

    If the command is missing, install it. If a kiva command exists without those commands, stop and ask before changing anything.

    kiva --helpnpm install -g @kivacore/cli
  3. 03Let the sandbox reach KIVA

    Kiva CLI calls the KIVA API, so its commands need network access. If the Codex sandbox blocks a kiva command, approve it when Codex asks.

    To allow network access for commands in the workspace sandbox every time, add this to ~/.codex/config.toml. An agent asks before it changes this file.

    ~/.codex/config.toml
    [sandbox_workspace_write]network_access = true
  4. 04Sign in

    Check who is signed in. If nobody is, start the sign-in: the CLI prints a link and a code. Open the link, approve it in the browser, and the CLI finishes on its own.

    With more than one workspace, list them and choose the one to work in.

    kiva -g auth who --jsonkiva -g auth loginkiva -g auth tenants list --json
  5. 05Install the Kiva skills

    The first command adds a reference for every Kiva CLI command. The second adds the Kiva skills for webforms, automations, data sources, queries, agents and more.

    The skills are installed in ~/.agents/skills/. Read the skills that match a task before starting it.

    kiva skills addnpx skills add Kivacore/agent-skills -a codex -g -y
  6. 06Add KIVA to AGENTS.md

    Optional, for a project that works with KIVA often. Add this note to AGENTS.md so every new session starts with it.

    AGENTS.md
    ## KIVA - Work in the KIVA workspace with the `kiva` CLI (`@kivacore/cli`). Run `kiva <command> --help` for exact flags and add `--json` for structured output.- Read the matching Kiva skill (`kiva-*`) before each task.- Before creating, updating or deleting records, changing a schema, sending an email or turning on an automation, say exactly what you will do and wait for approval.
  7. 07Check the connection

    Read only, nothing changes. Show the account and the active workspace, list the apps, then suggest five things to do with them.

    kiva -g auth who --jsonkiva -g apps list --json