# Data app actions

> Data app actions is an open-source agent skill for developer tools. Lets a Metabase data app insert, update or delete table rows through typed actions. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/metabase/metabase-cli/tree/main/packages/cli/skill-data/data-app-actions
- **Repository:** https://github.com/metabase/metabase-cli
- **GitHub stars:** 20
- **License:** AGPL-3.0
- **Skill name:** data-app-actions
- **Collection:** https://github.com/metabase/metabase-cli
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-03

## About

This skill adds write support to a Metabase data app. It guides the agent to define table actions for insert, update and delete in src/metabase.actions.ts using defineAction, tied to a published table and its primary key, and to wire them into forms or buttons with the useAction hook from the data-app entry of the embedding SDK.

The guidance covers checking that data actions are enabled on the database before any write, asking the user before turning that setting on, mapping each parameter's input type from the field's jsType, and disabling submit based on browser validation. It also explains how to show server error messages as returned, and how to refetch the queries on screen that a write could have changed.

It expects a Metabase data app project using the Metabase CLI (mb), with a schema file generated from the published tables and access to the database settings for the target database. Reads and tests are covered by other skills in the same collection.

## When your agent uses it

> Make a Metabase data app write data — a table action that inserts, updates or deletes a row of a published table, defined with `defineAction` in `src/metabase.actions.ts`, and the `useAction` hook from `@metabase/embedding-sdk-react/data-app` behind a form or a button, with inputs typed from each parameter, the server's error shown as it comes, and every affected query refreshed. Triggers — "a form that saves a row", "a button that updates a record", "delete an entry from the app", "submit doesn't refresh the list", "the action fails in the app". Reads are `data-app-data`; tests are `data-app-testing`.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/metabase/metabase-cli/tree/HEAD/packages/cli/skill-data/data-app-actions)
- [Asks for: Read, Write, Edit, Bash, AskUserQuestion](https://github.com/metabase/metabase-cli/blob/HEAD/packages/cli/skill-data/data-app-actions/SKILL.md)
- [License: AGPL-3.0](https://github.com/metabase/metabase-cli/tree/HEAD/packages/cli/skill-data/data-app-actions)

## Features

- **Table action definitions:** Defines insert, update and delete actions for a published table using defineAction with a stable entity id.
- **Database write toggle check:** Reads whether data actions are enabled on the database and offers the user ways to turn them on.
- **Typed form inputs:** Chooses form inputs from each column's JavaScript type and sends lowercase column names as parameters.
- **Action hook usage:** Shows how to call useAction for execution state, results, errors and reset.
- **Post-write refresh:** Refetches on-screen queries after a successful write so the displayed data stays current.
- **Server error display:** Shows the server's error message as returned, beside the relevant field where available.

## Good for

- Build a form that saves a new row to a database table
- Add a button that marks a record as done
- Delete an entry from a data app with a confirmation step
- Make a list refresh after submitting an edit form
- Show the server error when an action fails in the app

## Install

### Claude Code

Copy the skill folder to `~/.claude/skills/data-app-actions` to use it in all your projects:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/data-app-actions &&
cp -R "$tmp/packages/cli/skill-data/data-app-actions" ~/.claude/skills/data-app-actions &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/data-app-actions` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/data-app-actions` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/data-app-actions &&
cp -R "$tmp/packages/cli/skill-data/data-app-actions" ~/.agents/skills/data-app-actions &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/data-app-actions` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/data-app-actions` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/data-app-actions &&
cp -R "$tmp/packages/cli/skill-data/data-app-actions" ~/.cursor/skills/data-app-actions &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/data-app-actions` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/metabase/metabase-cli.git --path packages/cli/skill-data/data-app-actions
```

Or copy the folder to `~/.gemini/skills/data-app-actions` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/data-app-actions`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/metabase/metabase-cli.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/data-app-actions &&
cp -R "$tmp/packages/cli/skill-data/data-app-actions" ~/.copilot/skills/data-app-actions &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/data-app-actions` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/metabase/metabase-cli.git
```

Then copy `metabase-cli/packages/cli/skill-data/data-app-actions` into your agent's skills folder as `data-app-actions`. Agents that support SKILL.md read one folder per skill.

## FAQ

### What does Data app actions need before writing an action?

The table must have exactly one primary key, and data actions must be turned on for its database. The agent checks the database toggle and asks the user before enabling it.

### Does Data app actions write SQL or support custom queries?

No. Table actions only insert, update or delete one row by primary key. Computed values, multi-row writes and matching on other columns are not supported.

### How are form inputs chosen?

Inputs are picked from each field's jsType in the schema file, not from the column name, with text, number, checkbox and date inputs as appropriate.

### Does the skill run the action in production automatically?

The dev preview runs an action without saving it. Metabase runs it once the app is released.

### How do I install Data app actions in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/data-app-actions to use it in all your projects, or to .claude/skills/data-app-actions in one project.

### Does Data app actions run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Data app actions?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to Data app actions?

The closest alternatives to Data app actions are Data action, Data app, Data app testing, Data app UI and Metabase CLI.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Data action](https://ai-powered.com/skills/data-action): Data action is an open-source agent skill for databases.
- [Data app](https://ai-powered.com/skills/data-app): Data app is an open-source agent skill for developer tools.
- [Data app testing](https://ai-powered.com/skills/data-app-testing): Data app testing is an open-source agent skill for developer tools.
- [Data app UI](https://ai-powered.com/skills/data-app-ui): Data app UI is an open-source agent skill for developer tools.
- [Metabase CLI](https://ai-powered.com/skills/metabase-cli): Metabase CLI is an open-source agent skill for analytics and data.
- [Flowstudio power apps canvas edit](https://ai-powered.com/skills/flowstudio-power-apps-canvas-edit): Flowstudio power apps canvas edit is an open-source agent skill for developer tools.
- [Actions](https://ai-powered.com/skills/actions): Actions is an open-source agent skill for developer tools.
- [Data dictionary](https://ai-powered.com/skills/data-dictionary): Data dictionary is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/data-app-actions
